Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

adding a file API #8

Open
marcmerlin opened this issue Jan 1, 2020 · 3 comments
Open

adding a file API #8

marcmerlin opened this issue Jan 1, 2020 · 3 comments

Comments

@marcmerlin
Copy link
Contributor

marcmerlin commented Jan 1, 2020

Some code that does graphics loads graphics from "disk" before displaying it on neopixels/RGBPanels/TFT.
You are probably familiar with the "diskless" method that adafruit uses in
https://github.com/ChrisMicro/ArduinoOnPc/blob/master/examples/Adafruit_pictureDragon/Adafruit_pictureDragon.h
When doing animated gifs, we can do better.
On teensy, people read from sdcard
On ESP8266, ESP32 the more common way to do this is FatFS (which now replaces SPIFFS) from flash.
https://github.com/marcmerlin/AnimatedGIFs
supports all 3 methods.

If you want to see an example of API use, see:
https://github.com/marcmerlin/AnimatedGIFs/blob/master/FilenameFunctions.cpp
I think it would be best to emulate the ESP32 File API (the ESP8266 is a bit weird), so you can ignore the #ifdef FSOSD (filesystem object SDcard) an any ifdef ESP8266.

Full API test:
https://github.com/espressif/arduino-esp32/blob/master/libraries/FFat/examples/FFat_Test/FFat_Test.ino

And if you're wondering, yes, it's nice to emulate that code on PC, but it's even better to be able to run arduino code on Raspeberry Pi (which I can now do thanks to your code) on X11 using your driver (even if it's a bit slow as per #6 ) via my glue driver https://github.com/marcmerlin/FastLED_TFTWrapper_GFX or my new RGBPanel glue driver, which I just wrote: https://github.com/marcmerlin/FastLED_RPIRGBPanel_GFX

@marcmerlin
Copy link
Contributor Author

I just merged my rPi RGBPanel work in case you are curious:
marcmerlin#1

@marcmerlin
Copy link
Contributor Author

So, I'm now stuck with arduino code that does need access to a file API. Is that something that you might have time/resources to add, or not so much?

@ChrisMicro
Copy link
Owner

Having a file API would be a good idea. But at the moment I have a lot of other projects.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants