Skip to content

Updated all references of EEPROM.write to EEPROM.update #18

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 30, 2019

Conversation

makinako
Copy link
Contributor

@makinako makinako commented Jan 30, 2019

Patch to reduce unnecessary EEPROM writes by using .update() method, which compares the current value first. The comparatively small cost of the read should be more than made up for by the reduction in writes for the majority of operations. Also since there is currently no way to read the settings back, it reduces writes where application firmware needs to set the OpenLCD to an initial state at reset.

This resolves issue #16 and has been tested using a Serial connection only.

Patch to reduce unnecessary EEPROM writes by using .update() method, which compares the current value. The comparatively small cost of the read should be more than made up for by the reduction in writes for most operations. Also since there is currently no way to read the settings back, it reduces writes where firmware needs to set the OpenLCD to a default state every reset.
@nseidle
Copy link
Member

nseidle commented Jan 30, 2019

I had just pulled hardware out to work on this and you've got it done! Thank you so much.

@nseidle nseidle merged commit 5287e59 into sparkfun:master Jan 30, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants