Giter Club home page Giter Club logo

spiffsinifile's People

Contributors

bascy avatar yurilopes avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

spiffsinifile's Issues

#include "SPIFFS.h" which is missing in SPIFFSIniFile.h

Problem:
Compilation error on SPIFFSIniFile.h library, see following error message from the Arduino IDE compiler

In file included from C:\Users\rj\Documents\Arduino\libraries\SPIFFSIniFile\src\SPIFFSIniFile.cpp:1:0:
C:\Users\rj\Documents\Arduino\libraries\SPIFFSIniFile\src\SPIFFSIniFile.h: In member function 'bool SPIFFSIniFile::open()':
C:\Users\rj\Documents\Arduino\libraries\SPIFFSIniFile\src\SPIFFSIniFile.h:130:10: error: 'SPIFFS' was not declared in this scope
_file = SPIFFS.open(_filename, _mode);
^

The inclusion of the SPIFFS.h file is needed for using one of its functions in line 130: _file = SPIFFS.open(_filename, _mode);

Solution:
manually add one line for including SPIFFS.h library in the SPIFFSIniFile library

  1. search following library source code file:
    \SPIFFSIniFile-1.0.0\src\SPIFFSIniFile.h

  2. open in text editor

  3. insert: #include "SPIFFS.h" after line 9 #include "FS.h" as follows:

use line 9 and following in SPIFFSIniFile.h like this:

#include "FS.h"
#include "SPIFFS.h" // additional line inserted for including missing SPIFFS library
#include "IPAddress.h"

instead of original line 9 and 10 in SPIFFSIniFile.h:

#include "FS.h"
#include "IPAddress.h"

a tiny little bit of documentation

Hello Yuri,

Would mind investing 30 to 45 minutes into some basic documentation?
Your demofile uses FS.h. Fpr using SPIFFS there is the library SPIFFS.h
Are they compatible with each other?

There is a small note inside the example
"Remeber to upload the data directory to your board!"

Does this mean that the library SPIFFS-Ini has a hardcoded filepath "\data" ??

How would I create a subfolder?

if yes why would you do that? IMHO it is up to the user to take care if he is accidently formatting his SPIFFS or not

Do you happen to know another example that does the following things additionally?

  • create a subfolder "dat" (if really nescessary)
  • write content of an inif-file using SPIFFS-commands (to avoid uploading something with additional tools)

best regards

Stefan

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.