diff options
Diffstat (limited to 'keyboards/handwired')
9 files changed, 12 insertions, 12 deletions
diff --git a/keyboards/handwired/2x5keypad/keymaps/default/keymap.c b/keyboards/handwired/2x5keypad/keymaps/default/keymap.c index 91a0e28f6..23614a9b7 100644 --- a/keyboards/handwired/2x5keypad/keymaps/default/keymap.c +++ b/keyboards/handwired/2x5keypad/keymaps/default/keymap.c @@ -143,7 +143,7 @@ layer_state_t layer_state_set_user(layer_state_t state) { turn_off_leds(); - switch (biton32(state)) + switch (get_highest_layer(state)) { case NORMAL_LAYER: break; diff --git a/keyboards/handwired/bluepill/keymaps/default/keymap.c b/keyboards/handwired/bluepill/keymaps/default/keymap.c index 8a3493039..3d93c24d9 100644 --- a/keyboards/handwired/bluepill/keymaps/default/keymap.c +++ b/keyboards/handwired/bluepill/keymaps/default/keymap.c @@ -50,8 +50,8 @@ KC_GRAVE, KC_1, KC_2, KC_3, KC_4, KC_5, KC_6, KC_7, KC_8, KC_9, }; /* Layer based ilumination, just binary */ -uint32_t layer_state_set_user(uint32_t state) { - switch (biton32(state)) { +layer_state_t layer_state_set_user(layer_state_t state) { + switch (get_highest_layer(state)) { case _FNONE: palSetPad(GPIOA, 0); //OFF Color A palClearPad(GPIOA, 1); //ON Color B diff --git a/keyboards/handwired/jot50/keymaps/default/keymap.c b/keyboards/handwired/jot50/keymaps/default/keymap.c index 7342dcd22..7b674af52 100644 --- a/keyboards/handwired/jot50/keymaps/default/keymap.c +++ b/keyboards/handwired/jot50/keymaps/default/keymap.c @@ -74,7 +74,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { ), }; -uint32_t layer_state_set_user(uint32_t state) { +layer_state_t layer_state_set_user(layer_state_t state) { return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST); } diff --git a/keyboards/handwired/jotanck/keymaps/default/keymap.c b/keyboards/handwired/jotanck/keymaps/default/keymap.c index 2467559a6..3de30d396 100644 --- a/keyboards/handwired/jotanck/keymaps/default/keymap.c +++ b/keyboards/handwired/jotanck/keymaps/default/keymap.c @@ -78,9 +78,9 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { }; -uint32_t layer_state_set_user(uint32_t state) { +layer_state_t layer_state_set_user(layer_state_t state) { #ifdef JOTANCK_LEDS - switch (biton32(state)) { + switch (get_highest_layer(state)) { case _LOWER: writePinHigh(JOTANCK_LED1); writePinLow(JOTANCK_LED2); diff --git a/keyboards/handwired/prime_exl/keymaps/default/keymap.c b/keyboards/handwired/prime_exl/keymaps/default/keymap.c index 1dac7825e..7cf919708 100644 --- a/keyboards/handwired/prime_exl/keymaps/default/keymap.c +++ b/keyboards/handwired/prime_exl/keymaps/default/keymap.c @@ -132,9 +132,9 @@ void led_set_user(uint8_t usb_led) { } //function for layer indicator LED -uint32_t layer_state_set_user(uint32_t state) +layer_state_t layer_state_set_user(layer_state_t state) { - if (biton32(state) == 2) { + if (get_highest_layer(state) == 2) { writePinHigh(C6); } else { writePinLow(C6); diff --git a/keyboards/handwired/promethium/keymaps/default/keymap.c b/keyboards/handwired/promethium/keymaps/default/keymap.c index 207984407..14a293bb3 100644 --- a/keyboards/handwired/promethium/keymaps/default/keymap.c +++ b/keyboards/handwired/promethium/keymaps/default/keymap.c @@ -986,7 +986,7 @@ void process_doublespace(bool pressed, bool *isactive, bool *otheractive, bool * } #endif -uint32_t layer_state_set_kb(uint32_t state) +layer_state_t layer_state_set_user(layer_state_t state) { // turn on punc layer if both fun & num are on if ((state & ((1UL<<_NUM) | (1UL<<_FUN))) == ((1UL<<_NUM) | (1UL<<_FUN))) { diff --git a/keyboards/handwired/pteron/keymaps/default/keymap.c b/keyboards/handwired/pteron/keymaps/default/keymap.c index 3079cc7af..976fbb6e1 100644 --- a/keyboards/handwired/pteron/keymaps/default/keymap.c +++ b/keyboards/handwired/pteron/keymaps/default/keymap.c @@ -99,6 +99,6 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { }; -uint32_t layer_state_set_user(uint32_t state) { +layer_state_t layer_state_set_user(layer_state_t state) { return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST); } diff --git a/keyboards/handwired/wulkan/keymaps/default/keymap.c b/keyboards/handwired/wulkan/keymaps/default/keymap.c index 5134fb000..fec8442ee 100644 --- a/keyboards/handwired/wulkan/keymaps/default/keymap.c +++ b/keyboards/handwired/wulkan/keymaps/default/keymap.c @@ -102,7 +102,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { ) }; -uint32_t layer_state_set_user(uint32_t state) { +layer_state_t layer_state_set_user(layer_state_t state) { return update_tri_layer_state(state, _LOWER, _RAISE, _ADJUST); } diff --git a/keyboards/handwired/xealous/keymaps/default/keymap.c b/keyboards/handwired/xealous/keymaps/default/keymap.c index ca82445a5..41a3f8c80 100644 --- a/keyboards/handwired/xealous/keymaps/default/keymap.c +++ b/keyboards/handwired/xealous/keymaps/default/keymap.c @@ -87,7 +87,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { float tone_qwerty[][2] = TONE_QWERTY; float tone_numpad[][2] = TONE_NUMPAD; -uint32_t default_layer_state_set_kb(uint32_t state) { +layer_state_t default_layer_state_set_kb(layer_state_t state) { if (state == 1UL<<_QWERTY) { PLAY_SONG(tone_qwerty); } else if (state == 1UL<<_NUMPAD) { |