GiorgosXou / NeuralNetworks

A resource-conscious neural network implementation for MCUs
MIT License
73 stars 22 forks source link

error: 'O_WRITE' was not declared in this scope; did you mean 'S_IWRITE'? #38

Closed GiorgosXou closed 3 months ago

GiorgosXou commented 3 months ago

Since the last time I used espressif's core, for some reason it used the SD library of arduino instead of it's own (and I suspect it was because I used the old IDE to compile-test or something)... anyways I think It's now solved with:

#define SD_NN_WRITE_MODE O_WRITE | O_CREAT
#if defined(ESP32)
    #define AS_SOFTWARE_EMULATED_EEPROM
    #undef SD_NN_WRITE_MODE
    #define SD_NN_WRITE_MODE "w"
#endif

and for seek(0)-mode, defaults to SeekSet so I think it's fine