diff options
author | fishsoupisgood <github@madingley.org> | 2020-10-02 09:48:01 +0100 |
---|---|---|
committer | fishsoupisgood <github@madingley.org> | 2020-10-02 09:48:01 +0100 |
commit | 91f71bc582f184043df851ead61b636442663b83 (patch) | |
tree | df10f87b86dd2889cc596cff6ff97ef049e0eb36 /keyboards | |
parent | 28bd394eb775b5f3180ada278d69f3ddadd28ec1 (diff) | |
download | firmware-91f71bc582f184043df851ead61b636442663b83.tar.gz firmware-91f71bc582f184043df851ead61b636442663b83.tar.bz2 firmware-91f71bc582f184043df851ead61b636442663b83.zip |
fish
Diffstat (limited to 'keyboards')
-rw-r--r-- | keyboards/ymdk/ymd09_32a/keymaps/jmm/keymap.c | 2 | ||||
-rw-r--r-- | keyboards/ymdk/ymd09_32a/rules.mk | 6 | ||||
-rw-r--r-- | keyboards/ymdk/ymd09_32a/ymd09_32a.c | 39 |
3 files changed, 9 insertions, 38 deletions
diff --git a/keyboards/ymdk/ymd09_32a/keymaps/jmm/keymap.c b/keyboards/ymdk/ymd09_32a/keymaps/jmm/keymap.c index 982fd95f1..6d0443934 100644 --- a/keyboards/ymdk/ymd09_32a/keymaps/jmm/keymap.c +++ b/keyboards/ymdk/ymd09_32a/keymaps/jmm/keymap.c @@ -4,7 +4,7 @@ const uint16_t PROGMEM keymaps[][MATRIX_ROWS][MATRIX_COLS] = { [0] = LAYOUT(KC_A, KC_B, KC_C, KC_D, LT(1,KC_E), KC_F, - KC_G, KC_H, KC_U ), + KC_G, KC_H, KC_I ), [1] = LAYOUT(RGB_RMOD, RGB_VAI, RGB_MOD, RGB_HUI, KC_TRNS, RGB_SAI, diff --git a/keyboards/ymdk/ymd09_32a/rules.mk b/keyboards/ymdk/ymd09_32a/rules.mk index 57b0c1c1b..b104cba4b 100644 --- a/keyboards/ymdk/ymd09_32a/rules.mk +++ b/keyboards/ymdk/ymd09_32a/rules.mk @@ -13,11 +13,11 @@ BOOTLOADER = bootloadHID # build options BOOTMAGIC_ENABLE = no -MOUSEKEY_ENABLE = yes -EXTRAKEY_ENABLE = yes +MOUSEKEY_ENABLE = no +EXTRAKEY_ENABLE = no CONSOLE_ENABLE = no COMMAND_ENABLE = yes BACKLIGHT_ENABLE = yes RGBLIGHT_ENABLE = yes WS2812_DRIVER = i2c -ENABLE_RAW = yes +RAW_ENABLE = yes diff --git a/keyboards/ymdk/ymd09_32a/ymd09_32a.c b/keyboards/ymdk/ymd09_32a/ymd09_32a.c index e600ddd3a..870593e6a 100644 --- a/keyboards/ymdk/ymd09_32a/ymd09_32a.c +++ b/keyboards/ymdk/ymd09_32a/ymd09_32a.c @@ -19,43 +19,14 @@ void raw_hid_receive( uint8_t *data, uint8_t length ) { - uint8_t *command_id = &(data[0]); - uint8_t *command_data = &(data[1]); - switch ( *command_id ) + switch ( data[0] ) { - case RAW_COMMAND_GET_PROTOCOL_VERSION: //0x01(id) 0x00(payload_length) - { - *command_id =RAW_COMMAND_GET_PROTOCOL_VERSION; - command_data[0]=0x01; - command_data[1]=PROTOCOL_VERSION; - break; - } - case RAW_COMMAND_CHANGE_COLOR: // 0x05 0x03 0xRR 0xGG 0xBB - { - *command_id=RAW_COMMAND_CHANGE_COLOR; - if(command_data[0] != 3 ) - { - command_data[0]=0x01; - command_data[1]=FAILED; - } - else - { - rgblight_sethsv(command_data[1], command_data[2], command_data[3]); - command_data[0]=0x04; - command_data[4]=SUCCESS; - } - break; - } - default: //0xff ... - { - *command_id=RAW_COMMAND_UNDEFINED; - command_data[0]=0x01; - command_data[1]=FAILED; - break; - } + case RAW_COMMAND_CHANGE_COLOR: // 0x05 0x04 0xLL 0xRR 0xGG 0xBB +// rgblight_mode_noeeprom(RGBLIGHT_MODE_STATIC_LIGHT); + rgblight_setrgb_at(data[2],data[3],data[4],data[1]); + break; } - raw_hid_send(data,length); } void keyboard_pre_init_kb(void) { |