aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--quantum/via.c2
-rw-r--r--quantum/via.h8
2 files changed, 9 insertions, 1 deletions
diff --git a/quantum/via.c b/quantum/via.c
index 288299ada..f2599d1d2 100644
--- a/quantum/via.c
+++ b/quantum/via.c
@@ -111,7 +111,7 @@ void via_init(void) {
111 if (via_eeprom_is_valid()) { 111 if (via_eeprom_is_valid()) {
112 } else { 112 } else {
113 // This resets the layout options 113 // This resets the layout options
114 via_set_layout_options(0); 114 via_set_layout_options(VIA_EEPROM_LAYOUT_OPTIONS_DEFAULT);
115 // This resets the keymaps in EEPROM to what is in flash. 115 // This resets the keymaps in EEPROM to what is in flash.
116 dynamic_keymap_reset(); 116 dynamic_keymap_reset();
117 // This resets the macros in EEPROM to nothing. 117 // This resets the macros in EEPROM to nothing.
diff --git a/quantum/via.h b/quantum/via.h
index 012547e05..373843f90 100644
--- a/quantum/via.h
+++ b/quantum/via.h
@@ -37,6 +37,14 @@
37# define VIA_EEPROM_LAYOUT_OPTIONS_SIZE 1 37# define VIA_EEPROM_LAYOUT_OPTIONS_SIZE 1
38#endif 38#endif
39 39
40// Allow override of the layout options default value.
41// This requires advanced knowledge of how VIA stores layout options
42// and is only really useful for setting a boolean layout option
43// state to true by default.
44#ifndef VIA_EEPROM_LAYOUT_OPTIONS_DEFAULT
45# define VIA_EEPROM_LAYOUT_OPTIONS_DEFAULT 0x00000000
46#endif
47
40// The end of the EEPROM memory used by VIA 48// The end of the EEPROM memory used by VIA
41// By default, dynamic keymaps will start at this if there is no 49// By default, dynamic keymaps will start at this if there is no
42// custom config 50// custom config