Using EEPROM Memory
07.22
By
Unknown
0
komentar
This example illustrates write to and read from built-in
EEPROM memory. The program
works as follows. The main loop constantly reads
EEPROM memory location at address 5 (decimal).
The program then enters an endless loop in which PORTB is incremented and PORTA.2 input state is
checked. At the moment of pressing the push button called MEMO, a number stored in PORTB will be saved in EEPROM and directly read and shown on PORTD in binary form.
In order to check
this circuit, it is sufficient
to press
the MEMO button and turn off the device. After restarting the device,
the
program
will
display
the
saved
value
on port D. Remember that at the moment of writing, this value was displayed on port B).
In order to make this example work properly, it is necessary to tick off the EEPROM library in the Library Manager
prior to compiling:
§ EEPROM
0 komentar: