1
0

fantastic60: change rgb fade to only 1 level

This commit is contained in:
Kai Ryu 2016-01-05 12:20:31 +09:00
parent 712510350c
commit 763f524db8
2 changed files with 4 additions and 8 deletions

View File

@ -182,9 +182,7 @@ void rgb_set_level(uint8_t level)
rgb_refresh(&rgb_color);
/* shift_register_write_word(0x0000); */
break;
case RGB_FADE_SLOW:
case RGB_FADE_MID:
case RGB_FADE_FAST:
case RGB_FADE:
if (backlight_config.enable) {
if (backlight_config.level >= 1 && backlight_config.level <= 3) {
rgb_brightness = backlight_brightness;
@ -193,7 +191,7 @@ void rgb_set_level(uint8_t level)
else {
rgb_brightness = 16;
}
rgb_fading_enable = 3 - (level - RGB_FADE_SLOW);
rgb_fading_enable = 1;
/* shift_register_write_word(0x0000); */
break;
}

View File

@ -41,10 +41,8 @@ typedef union {
enum {
RGB_OFF = 0,
RGB_FIXED,
RGB_FADE_SLOW,
RGB_FADE_MID,
RGB_FADE_FAST,
RGB_LEVELS = RGB_FADE_FAST
RGB_FADE,
RGB_LEVELS = RGB_FADE
};
enum {