Skip to content

REQUEST: EEPROM.update() should return whether or not a value was written #123

Open
@noisymime

Description

@noisymime

The EEPROM.update() function is the preferred way of writing to the built in EEPROM as it will only perform a write operation if the current value is different, thus not performing unneeded writes.

Currently however there is no way of knowing whether this function performed a write operation or not. In most cases this is not required, however given that writes take approximately 3ms to complete, performing a large number of these at a time can cause significant delays in time critical applications.

If the update() function was to return a 1 if the write operation was performed an 0 if it wasn't, a sketch could easily track how many writes have been performed and limit their frequency if they are taking too long. Currently the update() function is void, so making this change should not impact any existing sketches.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions