PaulS:
// if the file opened okay, set flag okay
What part of that code sets any flag?
None, my bad, thx.
PaulS:
FILE_WRITE is NOT how you open a file for reading.
Mediatek LDrive library documentation states LDrive::open Method opens a file (or folder).
The following happens when the file path does not exist:
- If FILE_WRITE mode is provided, an empty file is created;
- If FILE_READ mode is provided, it returns Failed.
FILE_READ: It can read from the beginning of file. It cannot write.
FILE_WRITE: It can read and write, starting from the end of file in order to append the written data.
For now, I keep this file open. If I can, I'll later manage this point a bit later when the concept will work.
PaulS:
What if you, temporarily, create the EDB instance in the sketch, and pass it to the DBAbstraction instance? Does that get rid of the multiple instances issue?
I'll give this a try and will keep you posted soon.
Thank you PaulS