diff options
| author | Nick Brassel <nick@tzarc.org> | 2025-03-21 23:38:34 +1100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2025-03-21 23:38:34 +1100 |
| commit | 2b00b846dce1d1267dfdb2a3c2972a367cc0dd44 (patch) | |
| tree | 6d801a8d83c58ee646b789bfa9ab912857ee7d8c /quantum/unicode | |
| parent | c9d62ddc78e879053241202b288d0129073b07dc (diff) | |
Non-volatile memory data repository pattern (#24356)
* First batch of eeconfig conversions.
* Offset and length for datablocks.
* `via`, `dynamic_keymap`.
* Fix filename.
* Commentary.
* wilba leds
* satisfaction75
* satisfaction75
* more keyboard whack-a-mole
* satisfaction75
* omnikeyish
* more whack-a-mole
* `generic_features.mk` to automatically pick up nvm repositories
* thievery
* deferred variable resolve
* whitespace
* convert api to structs/unions
* convert api to structs/unions
* convert api to structs/unions
* fixups
* code-side docs
* code size fix
* rollback
* nvm_xxxxx_erase
* Updated location of eeconfig magic numbers so non-EEPROM nvm drivers can use them too.
* Fixup build.
* Fixup compilation error with encoders.
* Build fixes.
* Add `via_ci` keymap to onekey to exercise VIA bindings (and thus dynamic keymap et.al.), fixup compilation errors based on preprocessor+sizeof.
* Build failure rectification.
Diffstat (limited to 'quantum/unicode')
| -rw-r--r-- | quantum/unicode/unicode.c | 4 | ||||
| -rw-r--r-- | quantum/unicode/unicode.h | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/quantum/unicode/unicode.c b/quantum/unicode/unicode.c index 78a4cad585..b0729335f0 100644 --- a/quantum/unicode/unicode.c +++ b/quantum/unicode/unicode.c | |||
| @@ -136,7 +136,7 @@ static void unicode_play_song(uint8_t mode) { | |||
| 136 | #endif | 136 | #endif |
| 137 | 137 | ||
| 138 | void unicode_input_mode_init(void) { | 138 | void unicode_input_mode_init(void) { |
| 139 | unicode_config.raw = eeprom_read_byte(EECONFIG_UNICODEMODE); | 139 | eeconfig_read_unicode_mode(&unicode_config); |
| 140 | #if UNICODE_SELECTED_MODES != -1 | 140 | #if UNICODE_SELECTED_MODES != -1 |
| 141 | # if UNICODE_CYCLE_PERSIST | 141 | # if UNICODE_CYCLE_PERSIST |
| 142 | // Find input_mode in selected modes | 142 | // Find input_mode in selected modes |
| @@ -165,7 +165,7 @@ uint8_t get_unicode_input_mode(void) { | |||
| 165 | } | 165 | } |
| 166 | 166 | ||
| 167 | static void persist_unicode_input_mode(void) { | 167 | static void persist_unicode_input_mode(void) { |
| 168 | eeprom_update_byte(EECONFIG_UNICODEMODE, unicode_config.input_mode); | 168 | eeconfig_update_unicode_mode(&unicode_config); |
| 169 | } | 169 | } |
| 170 | 170 | ||
| 171 | void set_unicode_input_mode(uint8_t mode) { | 171 | void set_unicode_input_mode(uint8_t mode) { |
diff --git a/quantum/unicode/unicode.h b/quantum/unicode/unicode.h index 90a54c8b18..f19d803335 100644 --- a/quantum/unicode/unicode.h +++ b/quantum/unicode/unicode.h | |||
| @@ -26,7 +26,7 @@ | |||
| 26 | * \{ | 26 | * \{ |
| 27 | */ | 27 | */ |
| 28 | 28 | ||
| 29 | typedef union { | 29 | typedef union unicode_config_t { |
| 30 | uint8_t raw; | 30 | uint8_t raw; |
| 31 | struct { | 31 | struct { |
| 32 | uint8_t input_mode : 8; | 32 | uint8_t input_mode : 8; |
