Control on-board LEDs

Access macros to control the on-board LEDs. More...

Detailed Description

Access macros to control the on-board LEDs.

This header contains a set of macros for controlling the on-board LEDs of a board. The LEDs are enumerated, starting from LED0 to LED7. As most platforms have a different number of LEDs, the existing ones are mapped onto the lowest LED numbers, while the higher LED numbers will simply be empty defines. This ensures, that the LED macros are portable to any platform with any number of LEDs.

Providing access macros to 8 LEDs is a random decision, as currently 8 is the maximum number of on-board LEDs found on any board in RIOT (stm32f3discovery).

Files

file  led.h
 Macros for controlling the on-board LEDs.
 

LED fallback macros

#define LED0_ON
 defined empty More...
 
#define LED0_OFF
 defined empty More...
 
#define LED0_TOGGLE
 defined empty More...
 
#define LED1_ON
 defined empty More...
 
#define LED1_OFF
 defined empty More...
 
#define LED1_TOGGLE
 defined empty More...
 
#define LED2_ON
 defined empty More...
 
#define LED2_OFF
 defined empty More...
 
#define LED2_TOGGLE
 defined empty More...
 
#define LED3_ON
 defined empty More...
 
#define LED3_OFF
 defined empty More...
 
#define LED3_TOGGLE
 defined empty More...
 
#define LED4_ON
 defined empty More...
 
#define LED4_OFF
 defined empty More...
 
#define LED4_TOGGLE
 defined empty More...
 
#define LED5_ON
 defined empty More...
 
#define LED5_OFF
 defined empty More...
 
#define LED5_TOGGLE
 defined empty More...
 
#define LED6_ON
 defined empty More...
 
#define LED6_OFF
 defined empty More...
 
#define LED6_TOGGLE
 defined empty More...
 
#define LED7_ON
 defined empty More...
 
#define LED7_OFF
 defined empty More...
 
#define LED7_TOGGLE
 defined empty More...
 

Convenience LED control macros

#define LED_ON(x)   LED ## x ##_ON
 Turn on led x. More...
 
#define LED_OFF(x)   LED ## x ## _OFF
 Turn off led x. More...
 
#define LED_TOGGLE(x)   LED ## x ##_TOGGLE
 Toggle led x. More...
 

Macro Definition Documentation

◆ LED0_OFF

#define LED0_OFF

defined empty

Definition at line 47 of file led.h.

◆ LED0_ON

#define LED0_ON

defined empty

Definition at line 46 of file led.h.

◆ LED0_TOGGLE

#define LED0_TOGGLE

defined empty

Definition at line 48 of file led.h.

◆ LED1_OFF

#define LED1_OFF

defined empty

Definition at line 53 of file led.h.

◆ LED1_ON

#define LED1_ON

defined empty

Definition at line 52 of file led.h.

◆ LED1_TOGGLE

#define LED1_TOGGLE

defined empty

Definition at line 54 of file led.h.

◆ LED2_OFF

#define LED2_OFF

defined empty

Definition at line 59 of file led.h.

◆ LED2_ON

#define LED2_ON

defined empty

Definition at line 58 of file led.h.

◆ LED2_TOGGLE

#define LED2_TOGGLE

defined empty

Definition at line 60 of file led.h.

◆ LED3_OFF

#define LED3_OFF

defined empty

Definition at line 65 of file led.h.

◆ LED3_ON

#define LED3_ON

defined empty

Definition at line 64 of file led.h.

◆ LED3_TOGGLE

#define LED3_TOGGLE

defined empty

Definition at line 66 of file led.h.

◆ LED4_OFF

#define LED4_OFF

defined empty

Definition at line 71 of file led.h.

◆ LED4_ON

#define LED4_ON

defined empty

Definition at line 70 of file led.h.

◆ LED4_TOGGLE

#define LED4_TOGGLE

defined empty

Definition at line 72 of file led.h.

◆ LED5_OFF

#define LED5_OFF

defined empty

Definition at line 77 of file led.h.

◆ LED5_ON

#define LED5_ON

defined empty

Definition at line 76 of file led.h.

◆ LED5_TOGGLE

#define LED5_TOGGLE

defined empty

Definition at line 78 of file led.h.

◆ LED6_OFF

#define LED6_OFF

defined empty

Definition at line 83 of file led.h.

◆ LED6_ON

#define LED6_ON

defined empty

Definition at line 82 of file led.h.

◆ LED6_TOGGLE

#define LED6_TOGGLE

defined empty

Definition at line 84 of file led.h.

◆ LED7_OFF

#define LED7_OFF

defined empty

Definition at line 89 of file led.h.

◆ LED7_ON

#define LED7_ON

defined empty

Definition at line 88 of file led.h.

◆ LED7_TOGGLE

#define LED7_TOGGLE

defined empty

Definition at line 90 of file led.h.

◆ LED_OFF

#define LED_OFF (   x)    LED ## x ## _OFF

Turn off led x.

Definition at line 99 of file led.h.

◆ LED_ON

#define LED_ON (   x)    LED ## x ##_ON

Turn on led x.

Definition at line 98 of file led.h.

◆ LED_TOGGLE

#define LED_TOGGLE (   x)    LED ## x ##_TOGGLE

Toggle led x.

Definition at line 100 of file led.h.