I was just wondering what the difference between these to is?
I tried googling but couldn't find anything.
EEPROM.write vs EEPROM.update
I was just wondering what the difference between these to is?
I tried googling but couldn't find anything.
EEPROM.write vs EEPROM.update
update checks first if the value needs to change, so it does a read and if your value is different then it writes it.
this is because you can only write ~100,000 times into EEPROM and then your cell is likely dead (it wears out), so it's not a good idea to write when the value is the same.
okay,
thanks mate
captain_morgan_1999:
I was just wondering what the difference between these to is?
I tried googling but couldn't find anything.EEPROM.write vs EEPROM.update
Sure you used google ?
A google search on;
Arduino EEPROM.update
and
EEPROM.write vs EEPROM.update
Both point to the reference page that explains the difference.
EEPROM.put() also uses the update method, which is useful for writing data types longer than a byte (can also be used with a single byte).