mirror of
https://github.com/esp8266/Arduino.git
synced 2025-06-07 16:23:38 +03:00
commit
e443b0ce3b
@ -86,8 +86,13 @@ void EEPROMClass::write(int address, uint8_t value) {
|
|||||||
if(!_data)
|
if(!_data)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
_data[address] = value;
|
// Optimise _dirty. Only flagged if data written is different.
|
||||||
_dirty = true;
|
uint8_t* pData = &_data[address];
|
||||||
|
if (*pData != value)
|
||||||
|
{
|
||||||
|
*pData = value;
|
||||||
|
_dirty = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool EEPROMClass::commit() {
|
bool EEPROMClass::commit() {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user