LED#

Sample API funtions for controlling LEDs.

See sl_si91x_led.c for source code.

Modules#

sl_led_t

Functions#

void
sl_si91x_led_init(const sl_led_t *handle)

Configures GPIOs pertaining to the control of LEDs.

void
sl_si91x_led_toggle(uint8_t pin)

Atomically wraps an XOR or similar operation for a single GPIO pin attached to an LED.

void
sl_si91x_led_set(uint8_t pin)

Turns on (sets) a GPIO pin connected to an LED so that the LED turns on.

void
sl_si91x_led_clear(uint8_t pin)

Turns off (clears) a GPIO pin connected to an LED, which turns off the LED.

void

Called by the stack to indicate activity over the radio (for both transmission and reception).

Function Documentation#

sl_si91x_led_init#

void sl_si91x_led_init (const sl_led_t * handle)

Configures GPIOs pertaining to the control of LEDs.

Parameters
[in]handle

The pointer to led structure that has the specific led information.

Returns

  • none


Definition at line 46 of file components/device/silabs/si91x/mcu/drivers/hardware_drivers/led/inc/sl_si91x_led.h

sl_si91x_led_toggle#

void sl_si91x_led_toggle (uint8_t pin)

Atomically wraps an XOR or similar operation for a single GPIO pin attached to an LED.

Parameters
[in]pin

LED pin for the LED to be toggled.

Returns

  • none


Definition at line 57 of file components/device/silabs/si91x/mcu/drivers/hardware_drivers/led/inc/sl_si91x_led.h

sl_si91x_led_set#

void sl_si91x_led_set (uint8_t pin)

Turns on (sets) a GPIO pin connected to an LED so that the LED turns on.

Parameters
[in]pin

LED pin for the LED to turn on.

Returns

  • none


Definition at line 67 of file components/device/silabs/si91x/mcu/drivers/hardware_drivers/led/inc/sl_si91x_led.h

sl_si91x_led_clear#

void sl_si91x_led_clear (uint8_t pin)

Turns off (clears) a GPIO pin connected to an LED, which turns off the LED.

Parameters
[in]pin

LED pin for the LED to turn off.

Returns

  • none


Definition at line 78 of file components/device/silabs/si91x/mcu/drivers/hardware_drivers/led/inc/sl_si91x_led.h

sl_si91x_led_StackIndicateActivity#

void sl_si91x_led_StackIndicateActivity (bool turnOn)

Called by the stack to indicate activity over the radio (for both transmission and reception).

Parameters
N/AturnOn

See Usage.

It is called once with turnOn true and shortly thereafter with turnOn false.

Typically does something interesting, such as change the state of an LED.

Returns

  • none


Definition at line 93 of file components/device/silabs/si91x/mcu/drivers/hardware_drivers/led/inc/sl_si91x_led.h