Merge pull request #342 from atiselsts/contrib/leds-examples

Allow to compile the leds example for platforms with LEDS_LEGACY_API
This commit is contained in:
George Oikonomou 2018-03-09 16:18:24 +00:00 committed by GitHub
commit c99ace0bb4
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -62,12 +62,14 @@ PROCESS_THREAD(leds_example, ev, data)
leds_on(LEDS_ALL);
} else if((counter & 7) == 3) {
leds_toggle(LEDS_ALL);
#if !LEDS_LEGACY_API
} else if((counter & 7) == 4) {
leds_single_on(LEDS_LED1);
} else if((counter & 7) == 5) {
leds_single_off(LEDS_LED1);
} else if((counter & 7) == 6) {
leds_single_toggle(LEDS_LED1);
#endif /* LEDS_LEGACY_API */
} else if((counter & 7) == 7) {
leds_toggle(LEDS_ALL);
}