Go Down

Topic: PASSCODE LOCK SYSTEM USING EEPROM MEMORY (Read 99 times) previous topic - next topic


I want to make password enabled system e.g to make led high at pin 8, but in this case I want to use password once... I don't want to enter the password even after power cut, I don't known how to store the last state of led in eeprom... I am.using DTMF module to enter the password.... pls help

Coding Badly

@Manish51, please do not hijack.  Thread split.


just use the EEPROM library.  If you are just storing the state of an led, you can do that within one byte
Code: [Select]

EEPROM[0] = ledState; // save it
ledState = EEPROM[0];  // restore it


That won't work. Use functions like EEPROM.put() and EEPROM.get().

Of course everything is nicely explained in the Arduino EEPROM page.
Quality of answers is related to the quality of questions. Good questions will get good answers. Useless answers are a sign of a poor question.


Yes, it will work. You should read the link you provided.  Is explains the [] operator which allows array access to EEPROM.

Go Up