radio ID in EEPROM
-
At which address does the Radio ID get stored? I want to use the EEPROM on my sensor, but I want to make sure I'm not overwriting
-
At which address does the Radio ID get stored? I want to use the EEPROM on my sensor, but I want to make sure I'm not overwriting
Pos 0. Have a look in Sensor.h
#define EEPROM_RADIO_ID_ADDRESS 0 // Where to store radio id in EEPROM #define EEPROM_RELAY_ID_ADDRESS 1 // Where to store relay id in EEPROM #define EEPROM_DISTANCE_ADDRESS 2 // Where to store distance to gateway in EEPROMIf you're building a relaying node your have to lease space for routing table also (255 additional bytes).
-
Pos 0. Have a look in Sensor.h
#define EEPROM_RADIO_ID_ADDRESS 0 // Where to store radio id in EEPROM #define EEPROM_RELAY_ID_ADDRESS 1 // Where to store relay id in EEPROM #define EEPROM_DISTANCE_ADDRESS 2 // Where to store distance to gateway in EEPROMIf you're building a relaying node your have to lease space for routing table also (255 additional bytes).
@hek said:
yes, this part I found:
#define EEPROM_RADIO_ID_ADDRESS 0 // Where to store radio id in EEPROM #define EEPROM_RELAY_ID_ADDRESS 1 // Where to store relay id in EEPROM #define EEPROM_DISTANCE_ADDRESS 2 // Where to store distance to gateway in EEPROMThis part, help me to know
If you're building a relaying node your have to lease space for routing table also (255 additional bytes).
means only the relaying node needs this routing table, or if I add the relaying capability to a specific device.
Did you guys plan to reach any deeper into EEPROM in upcoming versions (foreseeable)?
I'm going to take 125 bytes for a project, but it only a project specific need and I want to make sure that I'm not creating another problem later.
In this project, I am going to hold some rain history data in EEPROM in case of a power loss for the rain gauge...
thanks for the help.
-
-
If your write above address 512 you should be safe.
If you look at the beta version of 1.4 you can see I've added eeprom read/write in the API for sketch usage (that doesn't overwrite any important MySensor stuff). Will make life easier for you.
@hek said:
If your write above address 512 you should be safe.
If you look at the beta version of 1.4 you can see I've added eeprom read/write in the API for sketch usage (that doesn't overwrite any important MySensor stuff). Will make life easier for you.
cheers mate
appreciated, as usual.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login