File tree Expand file tree Collapse file tree 3 files changed +14
-2
lines changed
tmk_core/protocol/chibios Expand file tree Collapse file tree 3 files changed +14
-2
lines changed Original file line number Diff line number Diff line change @@ -99,6 +99,12 @@ ifeq ($(MUSIC_ENABLE), yes)
9999 SRC += $(QUANTUM_DIR ) /process_keycode/process_music.c
100100endif
101101
102+ LAMPARRAY_ENABLE ?= no
103+ ifeq ($(LAMPARRAY_ENABLE ) , yes)
104+ SRC += $(QUANTUM_DIR ) /lamparray/lamparray.c
105+ SRC += $(QUANTUM_DIR ) /lamparray/lamparray_rgb_matrix.c
106+ endif
107+
102108VALID_STENO_PROTOCOL_TYPES := geminipr txbolt all
103109STENO_PROTOCOL ?= all
104110ifeq ($(strip $(STENO_ENABLE ) ) , yes)
Original file line number Diff line number Diff line change 66#include <stdbool.h>
77#include "util.h" // PACKED
88
9+ #if defined(__GNUC__ )
10+ # define PACKED __attribute__((__packed__))
11+ #else
12+ # define PACKED
13+ #endif
14+
915#define LAMPARRAY_REPORT_ID_ATTRIBUTES 0x01
1016#define LAMPARRAY_REPORT_ID_ATTRIBUTES_REQUEST 0x02
1117#define LAMPARRAY_REPORT_ID_ATTRIBUTES_RESPONSE 0x03
Original file line number Diff line number Diff line change @@ -728,7 +728,7 @@ static bool usb_request_hook_cb(USBDriver *usbp) {
728728
729729#ifdef LAMPARRAY_ENABLE
730730 case LAMPARRAY_INTERFACE :
731- switch (setup -> wValue . lbyte ) {
731+ switch (usbp -> setup [ 2 ] ) { /*LSB(wValue) */
732732 case LAMPARRAY_REPORT_ID_ATTRIBUTES :
733733 static lamparray_attributes_report_t ret = {.report_id = LAMPARRAY_REPORT_ID_ATTRIBUTES };
734734 lamparray_get_attributes (& ret .attributes );
@@ -778,7 +778,7 @@ static bool usb_request_hook_cb(USBDriver *usbp) {
778778 break ;
779779#ifdef LAMPARRAY_ENABLE
780780 case LAMPARRAY_INTERFACE :
781- switch (setup -> wValue . lbyte ) {
781+ switch (usbp -> setup [ 2 ] ) { /*LSB(wValue) */
782782 case LAMPARRAY_REPORT_ID_ATTRIBUTES_REQUEST :
783783 case LAMPARRAY_REPORT_ID_RANGE_UPDATE :
784784 case LAMPARRAY_REPORT_ID_MULTI_UPDATE :
You can’t perform that action at this time.
0 commit comments