#include <stdint.h>
#include "tr_platform.h"
#include <lpm.h>
#include <gpio.h>
#include <ev_man.h>
Go to the source code of this file.
|
#define | GPIO_CONFIG(btn, lpwd, func, short_press, hold, long_press, release_pin) |
| Macro for setting the configuration of a GPIO.
|
|
#define | GPIO_INFO() |
| Macro for setting the info of a GPIO.
|
|
◆ GPIO_CONFIG
#define GPIO_CONFIG |
( |
| btn, |
|
|
| lpwd, |
|
|
| func, |
|
|
| short_press, |
|
|
| hold, |
|
|
| long_press, |
|
|
| release_pin ) |
Value: { \
.gpio_no = btn, \
.low_power = lpwd, \
.on_value = btn ## _ON, \
.short_event = short_press, \
.hold_event = hold, \
.long_event = long_press, \
.release_event = release_pin, \
}
Macro for setting the configuration of a GPIO.
SPDX-License-Identifier: LicenseRef-TridentMSLA SPDX-FileCopyrightText: 2024 Trident IoT, LLC https://www.tridentiot.com
◆ GPIO_INFO
Value: { \
.gpio_down_count = 0, \
}
@ GPIO_UP
GPIO is up.
Definition apps_hw.h:46
Macro for setting the info of a GPIO.
◆ gpio_config_t
Defines the configuration of a GPIO.
◆ gpio_info_t
Defines the info of a GPIO.
◆ gpio_state_t
Defines the states of a GPIO.
◆ tr_zw_event_id_t
◆ _gpio_state_t
Defines the states of a GPIO.
Enumerator |
---|
GPIO_DOWN | GPIO is down.
|
GPIO_UP | GPIO is up.
|
GPIO_HOLD | GPIO is held.
|
◆ apps_hw_init()
Initializes the application hardware.
- Parameters
-
[in] | p_gpio_config | Address of GPIO configuration. |
[in] | p_gpio_info | Address of GPIO info. |
[in] | gpio_size | Number of configured GPIOs. |
◆ board_indicator_gpio_get()
uint8_t board_indicator_gpio_get |
( |
void | | ) |
|
Returns the GPIO used for CC Indicator.
- Returns
- uint8_t GPIO number.
◆ board_indicator_led_off_gpio_state()
uint8_t board_indicator_led_off_gpio_state |
( |
void | | ) |
|
Returns the GPIO state that defines "off" for the indicator LED.
- Returns
- uint8_t Indicator LED "off" state.