diff options
Diffstat (limited to 'tmk_core/common/magic.c')
| -rw-r--r-- | tmk_core/common/magic.c | 39 |
1 files changed, 0 insertions, 39 deletions
diff --git a/tmk_core/common/magic.c b/tmk_core/common/magic.c deleted file mode 100644 index e14994164..000000000 --- a/tmk_core/common/magic.c +++ /dev/null | |||
| @@ -1,39 +0,0 @@ | |||
| 1 | #include <stdint.h> | ||
| 2 | #include <stdbool.h> | ||
| 3 | #if defined(__AVR__) | ||
| 4 | # include <util/delay.h> | ||
| 5 | #endif | ||
| 6 | #include "matrix.h" | ||
| 7 | #include "bootloader.h" | ||
| 8 | #include "debug.h" | ||
| 9 | #include "keymap.h" | ||
| 10 | #include "host.h" | ||
| 11 | #include "action_layer.h" | ||
| 12 | #include "eeconfig.h" | ||
| 13 | #include "magic.h" | ||
| 14 | |||
| 15 | keymap_config_t keymap_config; | ||
| 16 | |||
| 17 | /** \brief Magic | ||
| 18 | * | ||
| 19 | * FIXME: Needs doc | ||
| 20 | */ | ||
| 21 | void magic(void) { | ||
| 22 | /* check signature */ | ||
| 23 | if (!eeconfig_is_enabled()) { | ||
| 24 | eeconfig_init(); | ||
| 25 | } | ||
| 26 | |||
| 27 | /* debug enable */ | ||
| 28 | debug_config.raw = eeconfig_read_debug(); | ||
| 29 | |||
| 30 | /* keymap config */ | ||
| 31 | keymap_config.raw = eeconfig_read_keymap(); | ||
| 32 | |||
| 33 | uint8_t default_layer = 0; | ||
| 34 | default_layer = eeconfig_read_default_layer(); | ||
| 35 | default_layer_set((layer_state_t)default_layer); | ||
| 36 | |||
| 37 | /* Also initialize layer state to trigger callback functions for layer_state */ | ||
| 38 | layer_state_set_kb((layer_state_t)layer_state); | ||
| 39 | } | ||
