aboutsummaryrefslogtreecommitdiff
path: root/libraries/EEPROM/examples/eeprom_read/eeprom_read.ino
diff options
context:
space:
mode:
Diffstat (limited to 'libraries/EEPROM/examples/eeprom_read/eeprom_read.ino')
-rw-r--r--libraries/EEPROM/examples/eeprom_read/eeprom_read.ino8
1 files changed, 4 insertions, 4 deletions
diff --git a/libraries/EEPROM/examples/eeprom_read/eeprom_read.ino b/libraries/EEPROM/examples/eeprom_read/eeprom_read.ino
index 8567ed7..68c4ffc 100644
--- a/libraries/EEPROM/examples/eeprom_read/eeprom_read.ino
+++ b/libraries/EEPROM/examples/eeprom_read/eeprom_read.ino
@@ -42,15 +42,15 @@ void loop()
Rather than hard-coding the length, you should use the pre-provided length function.
This will make your code portable to all AVR processors.
***/
- addr = addr + 1;
- if(addr == EEPROM.length())
- addr = 0;
+ address = address + 1;
+ if(address == EEPROM.length())
+ address = 0;
/***
As the EEPROM sizes are powers of two, wrapping (preventing overflow) of an
EEPROM address is also doable by a bitwise and of the length - 1.
- ++addr &= EEPROM.length() - 1;
+ ++address &= EEPROM.length() - 1;
***/
delay(500);