The uno type EEPROM library has an “Update” call that will only update the location if the new number is different than the current number in memory. With limited writes to flash memory, this seems like a great idea! If we do any volume of writes to EEPROM it seems like we should also do this test first before we just write to EEPROM.
Hi William.
The EEPROM library works differently with the Arduino and with the ESP32.
I wrote the tutorial about the ESP32 EEPROM a long time ago. But for what I remember, the update() function, didn’t work with the ESP32.
Also, with the ESP32, after calling the write() function, you need to call the commit() function. In this case, it will just commit the changes, if you’re writing something different on the EEPROM (just like the update() function).
So, you don’t need to worry about reading before writing.
(I don’t know if this is different now, someone correct me if I’m wrong.)
Regards,
Sara