From cbdda3c9903283635822695ce7cfc0278cd83bdc Mon Sep 17 00:00:00 2001 From: Alexandre Abadie Date: Wed, 13 Nov 2019 08:23:00 +0100 Subject: [PATCH] cpu/native: read/persist EEPROM data at startup/reboot/exit --- cpu/native/startup.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/cpu/native/startup.c b/cpu/native/startup.c index 33013a46cc..9c149f203c 100644 --- a/cpu/native/startup.c +++ b/cpu/native/startup.c @@ -47,6 +47,10 @@ #include "periph/init.h" #include "periph/pm.h" +#ifdef MODULE_PERIPH_EEPROM +#include "eeprom_native.h" +#endif + #define ENABLE_DEBUG (0) #include "debug.h" @@ -583,6 +587,10 @@ __attribute__((constructor)) static void startup(int argc, char **argv, char **e } #endif +#ifdef MODULE_PERIPH_EEPROM + eeprom_native_read(); +#endif + periph_init(); board_init();