Hello,
I'm working on a keypad LCD alarm.
Is there a way to write a user code to EEPROM memory at the programming stage only? and that bit of code is then ignored when power is reset to the picaxe?
What I don't want to happen is the user code to be changed by the user (I've written this bit of the code and it all ok) and then when the power is reset the code is reset to the default code that was at the beginning of the program.
I tried doing it like this below but when I reset power the code went back to 1234.
data Code1Master,(1) ' Set the default value for data address 'Code1Master' to 1
data Code2Master,(2) ' Set the default value for data address 'Code2Master' to 2
data Code3Master,(3) ' Set the default value for data address 'Code3Master' to 3
data Code4Master,(4) ' Set the default value for data address 'Code4Master' to 4
For now I've removed the above bit of code and rely on the first code being 0000 after programming.
Thanks for any ideas and help,
John
I'm working on a keypad LCD alarm.
Is there a way to write a user code to EEPROM memory at the programming stage only? and that bit of code is then ignored when power is reset to the picaxe?
What I don't want to happen is the user code to be changed by the user (I've written this bit of the code and it all ok) and then when the power is reset the code is reset to the default code that was at the beginning of the program.
I tried doing it like this below but when I reset power the code went back to 1234.
data Code1Master,(1) ' Set the default value for data address 'Code1Master' to 1
data Code2Master,(2) ' Set the default value for data address 'Code2Master' to 2
data Code3Master,(3) ' Set the default value for data address 'Code3Master' to 3
data Code4Master,(4) ' Set the default value for data address 'Code4Master' to 4
For now I've removed the above bit of code and rely on the first code being 0000 after programming.
Thanks for any ideas and help,
John