summaryrefslogtreecommitdiffstats
path: root/tmk_core/protocol
diff options
context:
space:
mode:
authoryiancar <yiangosyiangou@cytanet.com.cy>2018-08-29 22:14:49 +0200
committerJack Humbert <jack.humb@gmail.com>2018-08-29 22:14:49 +0200
commit621ce29a53e9e94e085fbd86c0b7134e9df4bfe5 (patch)
tree82c7d8258c4169284f7572500f9b292c7ee4634d /tmk_core/protocol
parent30680c6eb396a2bb06928afd69edae9908ac84fb (diff)
downloadqmk_firmware-621ce29a53e9e94e085fbd86c0b7134e9df4bfe5.tar.gz
qmk_firmware-621ce29a53e9e94e085fbd86c0b7134e9df4bfe5.tar.xz
STM32 EEPROM Emulation (#3741)
* STM32 EEPROM Emulation - Added EEPROM emulation libaries from libmaple and Arduino_STM32. https://github.com/rogerclarkmelbourne/Arduino_STM32 and https://github.com/leaflabs/libmaple. - Renamed teensy EEPROM library and added conditional selection of library. - Remapped EEPROM memory map for 16 byte blocks (as is with STM32f3xx MCUs). - Added EEPROM initialization in main.c of Chibios. - Added EEPROM format to clear the emulated pages when EEPROM is marked as invalid. * Fixed ifdef
Diffstat (limited to 'tmk_core/protocol')
-rw-r--r--tmk_core/protocol/chibios/main.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/tmk_core/protocol/chibios/main.c b/tmk_core/protocol/chibios/main.c
index f2abc438d..568c1edb2 100644
--- a/tmk_core/protocol/chibios/main.c
+++ b/tmk_core/protocol/chibios/main.c
@@ -44,6 +44,9 @@
#ifdef MIDI_ENABLE
#include "qmk_midi.h"
#endif
+#ifdef STM32F303xC
+#include "eeprom_stm32.h"
+#endif
#include "suspend.h"
#include "wait.h"
@@ -109,6 +112,10 @@ int main(void) {
halInit();
chSysInit();
+#ifdef STM32F303xC
+ EEPROM_init();
+#endif
+
// TESTING
// chThdCreateStatic(waThread1, sizeof(waThread1), NORMALPRIO, Thread1, NULL);