Anyway, It's a low priority feature that I'm going to work-around for now.
This method works:
fseek(f, 0, SEEK_END); // seek to end of file
size = ftell(f); // get current file pointer
fseek(f, 0, SEEK_SET); // seek back to beginning of file
// proceed with allocating memory and reading the file
Would be nice to have a get file size method in espfs
Also fill-out the VFS layer so that this works:
Anyway, It's a low priority feature that I'm going to work-around for now. This method works: