Bodmer / JPEGDecoder

A JPEG decoder library
Other
227 stars 65 forks source link

ESP32 does now support SPIFFS #17

Closed universam1 closed 6 years ago

universam1 commented 7 years ago

https://github.com/Bodmer/JPEGDecoder/blob/4164a392bd7ebde7692e08c6e8020b6499c1b921/src/JPEGDecoder.h#L39

Is this still correct? https://github.com/espressif/arduino-esp32/tree/master/libraries/SPIFFS

Bodmer commented 7 years ago

Thanks for letting me know about the SPIFFS support for the ESP32. I will see if I can get it working on an ESP32.

Ierlandfan commented 6 years ago

I use the unofficial SPIFFS library for the ESP32 (https://github.com/copercini/arduino-esp32-SPIFFS) I I had to add in file -- JPEGDecoder.cpp --

ifdef USE_SPIFFS

#include <SPIFFS.h> <<<<<<<<
#include <FS.h>
Hubberthus commented 6 years ago

The official library is already there, as @universam1 wrote it. It has to include "SPIFFS.h" if you want to use it. Including only "FS.h" is not enough. So the whole #ifndef ESP32 stuff can be reduced in "JPEGDecoder.h" to this:

#define LOAD_SPIFFS
#define FS_NO_GLOBALS
#include <FS.h>
#include <SPIFFS.h>
Bodmer commented 6 years ago

Support for ESP32 SPIFFS and an example for ESP32 added.