-->
Page 1 of 2

FATFS library for internal flash

PostPosted: Wed Jan 11, 2017 8:39 pm
by AdamWu
I am trying to turn my ESP into a small general purpose Web server.
The headache I had was the file system (SPIFFS), it does not support directory, last modification time, and has very limited file name length, not sufficient to support my purposes.

Inspired by MicroPython, I have implemented a FATFS wrapper for builtin flash, which should have enough bells and whistles for the Web server. I would like to release the source to enrich the community.

However, I noticed some discrepancies in licenses.
1. FATFS, which has to be distributed in source with my wrapper, uses MIT
2. MicroPython, which my wrapper heavily references, uses MIT
3. I also borrowed some code from Linux kernel, which is GPL
4. ESP8266 Arduino, uses LGPL

So, how do I license my source? And what the heck may happen if I release the source?
Cease and desist letters from lawyers of some organization?
Eternal hatred by some project owner?
Or nobody really cares?

--- Update: License concern resolved, project released, see: http://www.esp8266.com/viewtopic.php?p=61298#p61298

Re: FATFS for builtin flash, is my code even releasable?

PostPosted: Wed Jan 11, 2017 10:08 pm
by AdamWu
According to my incomplete research, it seems generally it is OK to re-license code from less protective to more protective.

Protection wise, MIT < LGPL < GPL
So if I re-implement the couple of functions borrowed from Linux kernel, I should be able to license the code as LGPL, same as ESP8266 Arduino.



As a side question: it seems the permissiveness of LGPL vs GPL mainly comes from the runtime linking relaxation.

But Arduino projects probably won't be runtime dynamically linked, ever. Imagine partition firmware into separate "library" regions, look up library by name or index, loading and code relocation... just too much for an already underpowered device.

So in terms of restrictions on Arduino projects, LGPL pretty much equals GPL -- any Arduino project, if ever released, must have their source code publicly available, right?

Re: FATFS for builtin flash, is my code even releasable?

PostPosted: Thu Jan 12, 2017 12:58 am
by rudy
This sounds good. Looking forward to try it.

Re: FATFS for builtin flash, is my code even releasable?

PostPosted: Fri Jan 13, 2017 8:54 am
by mrburnette
So in terms of restrictions on Arduino projects, LGPL pretty much equals GPL -- any Arduino project, if ever released, must have their source code publicly available, right?


This FAQ states:

Can I build a commercial product based on Arduino? Yes, with the following conditions:
Physically embedding an Arduino board inside a commercial product does not require you to disclose or open-source any information about its design.
Deriving the design of a commercial product from the Eagle files for an Arduino board requires you to release the modified files under the same Creative Commons Attribution Share-Alike license. You may manufacture and sell the resulting product.
Using the Arduino core and libraries for the firmware of a commercial product does not require you to release the source code for the firmware. The LGPL does, however, require you to make available object files that allow for the relinking of the firmware against updated versions of the Arduino core and libraries. Any modifications to the core and libraries must be released under the LGPL.
The source code for the Arduino environment is covered by the GPL, which requires any modifications to be open-sourced under the same license. It does not prevent the sale of derivative software or its inclusion in commercial products.
In all cases, the exact requirements are determined by the applicable license. Additionally, see the previous question for information about the use of the name “Arduino”.