From ad8dbd5ca5390ad9e441943b705684fce521bc15 Mon Sep 17 00:00:00 2001 From: Joel Challis Date: Tue, 24 Sep 2019 15:24:12 +0100 Subject: ARM split - Add bootmagic/magic keycodes for setting handedness (#6545) * Add docs on bootmagic/magic keycodes for setting handedness * Clang format fixes * Maintain backwards compatibility * Maintain backwards compatibility --- tmk_core/common/eeconfig.c | 19 +++++++++++++++++-- 1 file changed, 17 insertions(+), 2 deletions(-) (limited to 'tmk_core/common/eeconfig.c') diff --git a/tmk_core/common/eeconfig.c b/tmk_core/common/eeconfig.c index 61aaec2054..933ac42bd2 100644 --- a/tmk_core/common/eeconfig.c +++ b/tmk_core/common/eeconfig.c @@ -153,8 +153,8 @@ uint32_t eeconfig_read_kb(void) { return eeprom_read_dword(EECONFIG_KEYBOARD); } * * FIXME: needs doc */ - void eeconfig_update_kb(uint32_t val) { eeprom_update_dword(EECONFIG_KEYBOARD, val); } + /** \brief eeconfig read user * * FIXME: needs doc @@ -166,9 +166,24 @@ uint32_t eeconfig_read_user(void) { return eeprom_read_dword(EECONFIG_USER); } */ void eeconfig_update_user(uint32_t val) { eeprom_update_dword(EECONFIG_USER, val); } +/** \brief eeconfig read haptic + * + * FIXME: needs doc + */ uint32_t eeconfig_read_haptic(void) { return eeprom_read_dword(EECONFIG_HAPTIC); } -/** \brief eeconfig update user +/** \brief eeconfig update haptic * * FIXME: needs doc */ void eeconfig_update_haptic(uint32_t val) { eeprom_update_dword(EECONFIG_HAPTIC, val); } + +/** \brief eeconfig read split handedness + * + * FIXME: needs doc + */ +bool eeconfig_read_handedness(void) { return !!eeprom_read_byte(EECONFIG_HANDEDNESS); } +/** \brief eeconfig update split handedness + * + * FIXME: needs doc + */ +void eeconfig_update_handedness(bool val) { eeprom_update_byte(EECONFIG_HANDEDNESS, !!val); } -- cgit v1.2.3