Add macro for compiling with led matrix disabled
This commit is contained in:
parent
9a6b1cc49d
commit
f56f9030f6
@ -138,7 +138,7 @@ NKRO_ENABLE = yes # USB Nkey Rollover - not yet supported in LUFA
|
||||
BACKLIGHT_ENABLE = yes # Enable keyboard backlight functionality
|
||||
KEYMAP_EX_ENABLE = yes # External keymap in eeprom
|
||||
KEYMAP_SECTION_ENABLE = yes # Fixed address keymap for keymap editor
|
||||
LED_MATRIX_ENABLE = yes
|
||||
#LED_MATRIX_ENABLE = yes
|
||||
|
||||
# Optimize size but this may cause error "relocation truncated to fit"
|
||||
#EXTRALDFLAGS = -Wl,--relax
|
||||
|
@ -51,13 +51,14 @@ void backlight_set(uint8_t level)
|
||||
OCR1B = 0;
|
||||
}
|
||||
}
|
||||
#elif #defined(GH60_REV_CNY)
|
||||
#elif defined(GH60_REV_CNY)
|
||||
static const uint8_t backlight_table[] PROGMEM = {
|
||||
0, 16, 128, 255
|
||||
};
|
||||
|
||||
void backlight_set(uint8_t level)
|
||||
{
|
||||
#ifdef LED_MATRIX_ENABLE
|
||||
if (level > 0) {
|
||||
led_matrix_disable();
|
||||
for (uint8_t row = 0; row < LED_MATRIX_ROWS; row++) {
|
||||
@ -70,6 +71,7 @@ void backlight_set(uint8_t level)
|
||||
else {
|
||||
led_matrix_disable();
|
||||
}
|
||||
#endif
|
||||
}
|
||||
#else
|
||||
static const uint8_t backlight_table[] PROGMEM = {
|
||||
|
Reference in New Issue
Block a user