Wirepas SDK
board.h
Go to the documentation of this file.
1/* Copyright 2020 Wirepas Ltd. All Rights Reserved.
2 *
3 * See file LICENSE.txt for full license details.
4 *
5 */
6
13#ifndef BOARD_BG22_EK4108A_BOARD_H_
14#define BOARD_BG22_EK4108A_BOARD_H_
15
16// usart definitions
17#define BOARD_USART_ID 0
18
19#define BOARD_USART_TX_PORT GPIO_PORTA
20#define BOARD_USART_TX_PIN 5
21#define BOARD_USART_RX_PORT GPIO_PORTA
22#define BOARD_USART_RX_PIN 6
23
24// List of GPIO pins
25#define BOARD_GPIO_PIN_LIST {{GPIO_PORTA, 4},\
26 {GPIO_PORTC, 7},\
27 {GPIO_PORTA, 6}} /* required by the dual_mcu app. usart wakeup pin (= BOARD_USART_RX). */
28
29// User friendly name for GPIOs (IDs mapped to the BOARD_GPIO_PIN_LIST table)
30#define BOARD_GPIO_ID_LED0 0 // mapped to pin PA04
31#define BOARD_GPIO_ID_BUTTON0 1 // mapped to pin PC07
32#define BOARD_GPIO_ID_USART_WAKEUP 2 // mapped to pin PA06
33
34// List of LED IDs
35#define BOARD_LED_ID_LIST {BOARD_GPIO_ID_LED0}
36
37// Active high polarity for LEDs
38#define BOARD_LED_ACTIVE_LOW false
39
40// List of button IDs
41// NOTE! EFR32xG22 can wake up from deep sleep (EM2) using GPIO input trigger
42// only from A or B ports. Having the button in port C prevents button
43// to be used for waking up from deep sleep.
44#define BOARD_BUTTON_ID_LIST {BOARD_GPIO_ID_BUTTON0}
45
46// Active low polarity for buttons
47#define BOARD_BUTTON_ACTIVE_LOW true
48
49// Board has external pull-up for buttons
50#define BOARD_BUTTON_INTERNAL_PULL false
51
52#endif /* BOARD_BG22_EK4108A_BOARD_H_ */