Loading...
Searching...
No Matches
board.h File Reference

Definitions for the Generic CC2538-CC2592-DK Board. More...

Detailed Description

Definitions for the Generic CC2538-CC2592-DK Board.

Author
Marian Buschsieweke maria.nosp@m.n.bu.nosp@m.schsi.nosp@m.ewek.nosp@m.e@pos.nosp@m.teo..nosp@m.net

Definition in file board.h.

#include "cpu.h"
#include "periph/gpio.h"
#include "cc2538_eui_primary.h"
+ Include dependency graph for board.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

LED pin definitions and handlers

#define LED_GREEN_PIN   GPIO_PIN(PORT_C, 0)
 GPIO pin for green LED.
 
#define LED_GREEN_PORT   GPIO_C
 GPIO port register to used to control green LED.
 
#define LED_GREEN_BIT   (1U << 0)
 Bitmask to write to LED_GREEN_PORT.
 
#define LED0_PIN   LED_GREEN_PIN
 Alias for LED_GREEN_PIN.
 
#define LED0_PORT   LED_GREEN_PORT
 Alias for LED_GREEN_PORT.
 
#define LED0_BIT   LED_GREEN_BIT
 Alias for LED_GREEN_BIT.
 
#define LED_RED_PIN   GPIO_PIN(PORT_C, 1)
 GPIO pin for red LED.
 
#define LED_RED_PORT   GPIO_C
 GPIO port register to used to control red LED.
 
#define LED_RED_BIT   (1U << 1)
 Bitmask to write to LED_RED_PORT.
 
#define LED1_PIN   LED_RED_PIN
 Alias for LED_RED_PIN.
 
#define LED1_PORT   LED_RED_PORT
 Alias for LED_RED_PORT.
 
#define LED1_BIT   LED_RED_BIT
 Alias for LED_RED_BIT.
 
#define LED_YELLOW_PIN   GPIO_PIN(PORT_B, 1)
 GPIO pin for yellow LED.
 
#define LED_YELLOW_PORT   GPIO_B
 GPIO port register to used to control yellow LED.
 
#define LED_YELLOW_BIT   (1U << 1)
 Bitmask to write to LED_YELLOW_PORT.
 
#define LED2_PIN   LED_YELLOW_PIN
 Alias for LED_YELLOW_PIN.
 
#define LED2_PORT   LED_YELLOW_PORT
 Alias for LED_YELLOW_PORT.
 
#define LED2_BIT   LED_YELLOW_BIT
 Alias for LED_YELLOW_BIT.
 
#define LED_BLUE_PIN   GPIO_PIN(PORT_B, 0)
 GPIO pin for blue LED.
 
#define LED_BLUE_PORT   GPIO_B
 GPIO port register to used to control blue LED.
 
#define LED_BLUE_BIT   (1U << 0)
 Bitmask to write to LED_BLUE_PORT.
 
#define LED3_PIN   LED_BLUE_PIN
 Alias for LED_BLUE_PIN.
 
#define LED3_PORT   LED_BLUE_PORT
 Alias for LED_BLUE_PORT.
 
#define LED3_BIT   LED_BLUE_BIT
 Alias for LED_BLUE_BIT.
 
#define LED0_ON   (LED0_PORT->DATA |= LED0_BIT)
 
#define LED0_OFF   (LED0_PORT->DATA &= ~LED0_BIT)
 
#define LED0_TOGGLE   (LED0_PORT->DATA ^= LED0_BIT)
 
#define LED1_ON   (LED1_PORT->DATA |= LED1_BIT)
 
#define LED1_OFF   (LED1_PORT->DATA &= ~LED1_BIT)
 
#define LED1_TOGGLE   (LED1_PORT->DATA ^= LED1_BIT)
 
#define LED2_ON   (LED2_PORT->DATA |= LED2_BIT)
 
#define LED2_OFF   (LED2_PORT->DATA &= ~LED2_BIT)
 
#define LED2_TOGGLE   (LED2_PORT->DATA ^= LED2_BIT)
 
#define LED3_ON   (LED3_PORT->DATA |= LED3_BIT)
 
#define LED3_OFF   (LED3_PORT->DATA &= ~LED3_BIT)
 
#define LED3_TOGGLE   (LED3_PORT->DATA ^= LED3_BIT)
 

User button

#define BTN_LEFT_PIN   GPIO_PIN(PORT_C, 4)
 GPIO pin for button "LEFT".
 
#define BTN_LEFT_MODE   GPIO_IN_PU
 GPIO mode for button "LEFT".
 
#define BTN0_PIN   BTN_LEFT_PIN
 Alias for BTN_LEFT_PIN.
 
#define BTN0_MODE   BTN_LEFT_MODE
 Alias for BTN_LEFT_MODE.
 
#define BTN_RIGHT_PIN   GPIO_PIN(PORT_C, 5)
 GPIO pin for button "RIGHT".
 
#define BTN_RIGHT_MODE   GPIO_IN_PU
 GPIO mode for button "RIGHT".
 
#define BTN1_PIN   BTN_RIGHT_PIN
 Alias for BTN_RIGHT_PIN.
 
#define BTN1_MODE   BTN_RIGHT_MODE
 Alias for BTN_RIGHT_MODE.
 
#define BTN_UP_PIN   GPIO_PIN(PORT_C, 6)
 GPIO pin for button "UP".
 
#define BTN_UP_MODE   GPIO_IN_PU
 GPIO mode for button "UP".
 
#define BTN2_PIN   BTN_UP_PIN
 Alias for BTN_UP_PIN.
 
#define BTN2_MODE   BTN_UP_MODE
 Alias for BTN_UP_MODE.
 
#define BTN_DOWN_PIN   GPIO_PIN(PORT_C, 7)
 GPIO pin for button "DOWN".
 
#define BTN_DOWN_MODE   GPIO_IN_PU
 GPIO mode for button "DOWN".
 
#define BTN3_PIN   BTN_DOWN_PIN
 Alias for BTN_DOWN_PIN.
 
#define BTN3_MODE   BTN_DOWN_MODE
 Alias for BTN_DOWN_MODE.
 
#define BTN_SELECT_PIN   GPIO_PIN(PORT_A, 3)
 GPIO pin for button "SELECT".
 
#define BTN_SELECT_MODE   GPIO_IN_PU
 GPIO mode for button "SELECT".
 
#define BTN4_PIN   BTN_SELECT_PIN
 Alias for BTN_SELECT_PIN.
 
#define BTN4_MODE   BTN_SELECT_MODE
 Alias for BTN_SELECT_MODE.
 

Flash Customer Configuration Area (CCA) parameters

#define UPDATE_CCA   1
 
#define CCA_BACKDOOR_ENABLE   1
 
#define CCA_BACKDOOR_PORT_A_PIN   3
 Select button.
 
#define CCA_BACKDOOR_ACTIVE_LEVEL   0
 Active low.
 

Macro Definition Documentation

◆ BTN0_MODE

#define BTN0_MODE   BTN_LEFT_MODE

Alias for BTN_LEFT_MODE.

Definition at line 86 of file board.h.

◆ BTN0_PIN

#define BTN0_PIN   BTN_LEFT_PIN

Alias for BTN_LEFT_PIN.

Definition at line 85 of file board.h.

◆ BTN1_MODE

#define BTN1_MODE   BTN_RIGHT_MODE

Alias for BTN_RIGHT_MODE.

Definition at line 91 of file board.h.

◆ BTN1_PIN

#define BTN1_PIN   BTN_RIGHT_PIN

Alias for BTN_RIGHT_PIN.

Definition at line 90 of file board.h.

◆ BTN2_MODE

#define BTN2_MODE   BTN_UP_MODE

Alias for BTN_UP_MODE.

Definition at line 96 of file board.h.

◆ BTN2_PIN

#define BTN2_PIN   BTN_UP_PIN

Alias for BTN_UP_PIN.

Definition at line 95 of file board.h.

◆ BTN3_MODE

#define BTN3_MODE   BTN_DOWN_MODE

Alias for BTN_DOWN_MODE.

Definition at line 101 of file board.h.

◆ BTN3_PIN

#define BTN3_PIN   BTN_DOWN_PIN

Alias for BTN_DOWN_PIN.

Definition at line 100 of file board.h.

◆ BTN4_MODE

#define BTN4_MODE   BTN_SELECT_MODE

Alias for BTN_SELECT_MODE.

Definition at line 106 of file board.h.

◆ BTN4_PIN

#define BTN4_PIN   BTN_SELECT_PIN

Alias for BTN_SELECT_PIN.

Definition at line 105 of file board.h.

◆ BTN_DOWN_MODE

#define BTN_DOWN_MODE   GPIO_IN_PU

GPIO mode for button "DOWN".

Definition at line 99 of file board.h.

◆ BTN_DOWN_PIN

#define BTN_DOWN_PIN   GPIO_PIN(PORT_C, 7)

GPIO pin for button "DOWN".

Definition at line 98 of file board.h.

◆ BTN_LEFT_MODE

#define BTN_LEFT_MODE   GPIO_IN_PU

GPIO mode for button "LEFT".

Definition at line 84 of file board.h.

◆ BTN_LEFT_PIN

#define BTN_LEFT_PIN   GPIO_PIN(PORT_C, 4)

GPIO pin for button "LEFT".

Definition at line 83 of file board.h.

◆ BTN_RIGHT_MODE

#define BTN_RIGHT_MODE   GPIO_IN_PU

GPIO mode for button "RIGHT".

Definition at line 89 of file board.h.

◆ BTN_RIGHT_PIN

#define BTN_RIGHT_PIN   GPIO_PIN(PORT_C, 5)

GPIO pin for button "RIGHT".

Definition at line 88 of file board.h.

◆ BTN_SELECT_MODE

#define BTN_SELECT_MODE   GPIO_IN_PU

GPIO mode for button "SELECT".

Definition at line 104 of file board.h.

◆ BTN_SELECT_PIN

#define BTN_SELECT_PIN   GPIO_PIN(PORT_A, 3)

GPIO pin for button "SELECT".

Definition at line 103 of file board.h.

◆ BTN_UP_MODE

#define BTN_UP_MODE   GPIO_IN_PU

GPIO mode for button "UP".

Definition at line 94 of file board.h.

◆ BTN_UP_PIN

#define BTN_UP_PIN   GPIO_PIN(PORT_C, 6)

GPIO pin for button "UP".

Definition at line 93 of file board.h.

◆ CCA_BACKDOOR_ACTIVE_LEVEL

#define CCA_BACKDOOR_ACTIVE_LEVEL   0

Active low.

Definition at line 119 of file board.h.

◆ CCA_BACKDOOR_ENABLE

#define CCA_BACKDOOR_ENABLE   1

Definition at line 117 of file board.h.

◆ CCA_BACKDOOR_PORT_A_PIN

#define CCA_BACKDOOR_PORT_A_PIN   3

Select button.

Definition at line 118 of file board.h.

◆ LED0_BIT

#define LED0_BIT   LED_GREEN_BIT

Alias for LED_GREEN_BIT.

Definition at line 39 of file board.h.

◆ LED0_OFF

#define LED0_OFF   (LED0_PORT->DATA &= ~LED0_BIT)

Definition at line 63 of file board.h.

◆ LED0_ON

#define LED0_ON   (LED0_PORT->DATA |= LED0_BIT)

Definition at line 62 of file board.h.

◆ LED0_PIN

#define LED0_PIN   LED_GREEN_PIN

Alias for LED_GREEN_PIN.

Definition at line 37 of file board.h.

◆ LED0_PORT

#define LED0_PORT   LED_GREEN_PORT

Alias for LED_GREEN_PORT.

Definition at line 38 of file board.h.

◆ LED0_TOGGLE

#define LED0_TOGGLE   (LED0_PORT->DATA ^= LED0_BIT)

Definition at line 64 of file board.h.

◆ LED1_BIT

#define LED1_BIT   LED_RED_BIT

Alias for LED_RED_BIT.

Definition at line 46 of file board.h.

◆ LED1_OFF

#define LED1_OFF   (LED1_PORT->DATA &= ~LED1_BIT)

Definition at line 67 of file board.h.

◆ LED1_ON

#define LED1_ON   (LED1_PORT->DATA |= LED1_BIT)

Definition at line 66 of file board.h.

◆ LED1_PIN

#define LED1_PIN   LED_RED_PIN

Alias for LED_RED_PIN.

Definition at line 44 of file board.h.

◆ LED1_PORT

#define LED1_PORT   LED_RED_PORT

Alias for LED_RED_PORT.

Definition at line 45 of file board.h.

◆ LED1_TOGGLE

#define LED1_TOGGLE   (LED1_PORT->DATA ^= LED1_BIT)

Definition at line 68 of file board.h.

◆ LED2_BIT

#define LED2_BIT   LED_YELLOW_BIT

Alias for LED_YELLOW_BIT.

Definition at line 53 of file board.h.

◆ LED2_OFF

#define LED2_OFF   (LED2_PORT->DATA &= ~LED2_BIT)

Definition at line 71 of file board.h.

◆ LED2_ON

#define LED2_ON   (LED2_PORT->DATA |= LED2_BIT)

Definition at line 70 of file board.h.

◆ LED2_PIN

#define LED2_PIN   LED_YELLOW_PIN

Alias for LED_YELLOW_PIN.

Definition at line 51 of file board.h.

◆ LED2_PORT

#define LED2_PORT   LED_YELLOW_PORT

Alias for LED_YELLOW_PORT.

Definition at line 52 of file board.h.

◆ LED2_TOGGLE

#define LED2_TOGGLE   (LED2_PORT->DATA ^= LED2_BIT)

Definition at line 72 of file board.h.

◆ LED3_BIT

#define LED3_BIT   LED_BLUE_BIT

Alias for LED_BLUE_BIT.

Definition at line 60 of file board.h.

◆ LED3_OFF

#define LED3_OFF   (LED3_PORT->DATA &= ~LED3_BIT)

Definition at line 75 of file board.h.

◆ LED3_ON

#define LED3_ON   (LED3_PORT->DATA |= LED3_BIT)

Definition at line 74 of file board.h.

◆ LED3_PIN

#define LED3_PIN   LED_BLUE_PIN

Alias for LED_BLUE_PIN.

Definition at line 58 of file board.h.

◆ LED3_PORT

#define LED3_PORT   LED_BLUE_PORT

Alias for LED_BLUE_PORT.

Definition at line 59 of file board.h.

◆ LED3_TOGGLE

#define LED3_TOGGLE   (LED3_PORT->DATA ^= LED3_BIT)

Definition at line 76 of file board.h.

◆ LED_BLUE_BIT

#define LED_BLUE_BIT   (1U << 0)

Bitmask to write to LED_BLUE_PORT.

Definition at line 57 of file board.h.

◆ LED_BLUE_PIN

#define LED_BLUE_PIN   GPIO_PIN(PORT_B, 0)

GPIO pin for blue LED.

Definition at line 55 of file board.h.

◆ LED_BLUE_PORT

#define LED_BLUE_PORT   GPIO_B

GPIO port register to used to control blue LED.

Definition at line 56 of file board.h.

◆ LED_GREEN_BIT

#define LED_GREEN_BIT   (1U << 0)

Bitmask to write to LED_GREEN_PORT.

Definition at line 36 of file board.h.

◆ LED_GREEN_PIN

#define LED_GREEN_PIN   GPIO_PIN(PORT_C, 0)

GPIO pin for green LED.

Definition at line 34 of file board.h.

◆ LED_GREEN_PORT

#define LED_GREEN_PORT   GPIO_C

GPIO port register to used to control green LED.

Definition at line 35 of file board.h.

◆ LED_RED_BIT

#define LED_RED_BIT   (1U << 1)

Bitmask to write to LED_RED_PORT.

Definition at line 43 of file board.h.

◆ LED_RED_PIN

#define LED_RED_PIN   GPIO_PIN(PORT_C, 1)

GPIO pin for red LED.

Definition at line 41 of file board.h.

◆ LED_RED_PORT

#define LED_RED_PORT   GPIO_C

GPIO port register to used to control red LED.

Definition at line 42 of file board.h.

◆ LED_YELLOW_BIT

#define LED_YELLOW_BIT   (1U << 1)

Bitmask to write to LED_YELLOW_PORT.

Definition at line 50 of file board.h.

◆ LED_YELLOW_PIN

#define LED_YELLOW_PIN   GPIO_PIN(PORT_B, 1)

GPIO pin for yellow LED.

Definition at line 48 of file board.h.

◆ LED_YELLOW_PORT

#define LED_YELLOW_PORT   GPIO_B

GPIO port register to used to control yellow LED.

Definition at line 49 of file board.h.

◆ UPDATE_CCA

#define UPDATE_CCA   1

Definition at line 114 of file board.h.