Probably not a feature request
Posted: Tue Jul 13, 2021 1:06 pm
From the help file:-
This command read 512 bytes from the file data.bin starting from the file position 123 in the buffer 0:
FILE.READ_IOBUFF(0), “/data.bin”, 123, 512
There does not seem to be a matching FILE.WRITE_IOBUFF command to place the iobuffer into the particular file locations.
I was attempting to answer the recent EEPROM question by writing two functions {sub EEPROMwrite(addr,byte) and sub EEPROMread(addr,byte) } using a file as an EEPROM substitute. The read function worked as expected but could not find a suitable write function.
I could read the whole file then modify the buffer and write the whole file but thought there might have been a simpler way.
It is not important as I have no application in mind - it was just an exercise.
This command read 512 bytes from the file data.bin starting from the file position 123 in the buffer 0:
FILE.READ_IOBUFF(0), “/data.bin”, 123, 512
There does not seem to be a matching FILE.WRITE_IOBUFF command to place the iobuffer into the particular file locations.
I was attempting to answer the recent EEPROM question by writing two functions {sub EEPROMwrite(addr,byte) and sub EEPROMread(addr,byte) } using a file as an EEPROM substitute. The read function worked as expected but could not find a suitable write function.
I could read the whole file then modify the buffer and write the whole file but thought there might have been a simpler way.
It is not important as I have no application in mind - it was just an exercise.