Arduino core for the esp32 - Add new function "bool isDirty()" to EEPROM.h and EEPROM.cpp (#9611)

* Update EEPROM.h - Added new function: bool isDirty()

* Update EEPROM.cpp - Added new function: bool isDirty()
This commit is contained in:
Rob58329 2024-05-10 13:10:29 +01:00 committed by GitHub
parent 84376a765a
commit afa5f41328
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
2 changed files with 5 additions and 0 deletions

View file

@ -133,6 +133,10 @@ void EEPROMClass::end() {
_handle = 0;
}
bool EEPROMClass::isDirty() {
return _dirty;
}
uint8_t EEPROMClass::read(int address) {
if (address < 0 || (size_t)address >= _size) {
return 0;

View file

@ -45,6 +45,7 @@ public:
uint16_t length();
bool commit();
void end();
bool isDirty();
uint8_t *getDataPtr();
uint16_t convert(bool clear, const char *EEPROMname = "eeprom", const char *nvsname = "eeprom");