led_counters[i] = 0;
led_patterns[i] = off_pattern;
}
- led_patterns[N_PWMLEDS] = boot_pattern;
- led_counters[N_PWMLEDS] = boot_pattern->duration;
+ led_patterns[N_PWMLEDS+1] = boot_pattern;
+ led_counters[N_PWMLEDS+1] = boot_pattern->duration;
gpio_set(GPIO_LED2, 1);
test_running = 0;
}
{
if (n < N_PWMLEDS) {
pwmled_set_mode(n, mode);
- } else if (n == N_PWMLEDS) {
- gpio_set(GPIO_LED2, mode);
+ } else if (n < N_LEDS) {
+ gpio_set(n - N_PWMLEDS, mode);
}
- // TODO LED 1
}
static void inline led_set_level(unsigned char n, unsigned char level)