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

Zolertia Z1 board configuration. More...

Detailed Description

Zolertia Z1 board configuration.

Components

  • MSP430F2617
  • CC2420
Author
Kévin Roussel Kevin.nosp@m..Rou.nosp@m.ssel@.nosp@m.inri.nosp@m.a.fr
Hauke Petersen hauke.nosp@m..pet.nosp@m.ersen.nosp@m.@fu-.nosp@m.berli.nosp@m.n.de

Definition in file board.h.

#include <stdint.h>
#include "cpu.h"
+ Include dependency graph for board.h:

Go to the source code of this file.

#define __MSP430F2617__
 Define the CPU model for the <msp430.h>
 

Xtimer configuration

#define XTIMER_WIDTH   (16)
 
#define XTIMER_BACKOFF   (40)
 

ztimer configuration values

#define CONFIG_ZTIMER_USEC_ADJUST_SET   (99)
 
#define CONFIG_ZTIMER_USEC_ADJUST_SLEEP   (100)
 

LED pin definitions and handlers

#define LED0_PIN   GPIO_PIN(5, 4)
 
#define LED1_PIN   GPIO_PIN(5, 6)
 
#define LED2_PIN   GPIO_PIN(5, 5)
 
#define LED_OUT_REG   P5OUT
 
#define LED0_MASK   (0x10)
 
#define LED1_MASK   (0x40)
 
#define LED2_MASK   (0x20)
 
#define LED0_ON   (LED_OUT_REG &=~LED0_MASK)
 
#define LED0_OFF   (LED_OUT_REG |= LED0_MASK)
 
#define LED0_TOGGLE   (LED_OUT_REG ^= LED0_MASK)
 
#define LED1_ON   (LED_OUT_REG &=~LED1_MASK)
 
#define LED1_OFF   (LED_OUT_REG |= LED1_MASK)
 
#define LED1_TOGGLE   (LED_OUT_REG ^= LED1_MASK)
 
#define LED2_ON   (LED_OUT_REG &=~LED2_MASK)
 
#define LED2_OFF   (LED_OUT_REG |= LED2_MASK)
 
#define LED2_TOGGLE   (LED_OUT_REG ^= LED2_MASK)
 

User button configuration

#define BTN0_PIN   GPIO_PIN(2, 5)
 
#define BTN0_MASK   (0x20)
 
#define BTN0_MODE   GPIO_IN
 
#define BTN0_PRESSED   ((BTN0_PIN & BTN0_MASK) == 0)
 
#define BTN0_RELEASED   ((BTN0_PIN & BTN0_MASK) != 0)
 

Definition of the interface to the CC2420 radio

#define CC2420_PARAM_CS   GPIO_PIN(P3, 0)
 
#define CC2420_PARAM_FIFO   GPIO_PIN(P1, 3)
 
#define CC2420_PARAM_FIFOP   GPIO_PIN(P1, 2)
 
#define CC2420_PARAM_CCA   GPIO_PIN(P1, 4)
 
#define CC2420_PARAM_SFD   GPIO_PIN(P4, 1)
 
#define CC2420_PARAM_VREFEN   GPIO_PIN(P4, 5)
 
#define CC2420_PARAM_RESET   GPIO_PIN(P4, 6)
 

Macro Definition Documentation

◆ __MSP430F2617__

#define __MSP430F2617__

Define the CPU model for the <msp430.h>

Definition at line 42 of file board.h.

◆ BTN0_MASK

#define BTN0_MASK   (0x20)

Definition at line 92 of file board.h.

◆ BTN0_MODE

#define BTN0_MODE   GPIO_IN

Definition at line 93 of file board.h.

◆ BTN0_PIN

#define BTN0_PIN   GPIO_PIN(2, 5)

Definition at line 91 of file board.h.

◆ BTN0_PRESSED

#define BTN0_PRESSED   ((BTN0_PIN & BTN0_MASK) == 0)

Definition at line 95 of file board.h.

◆ BTN0_RELEASED

#define BTN0_RELEASED   ((BTN0_PIN & BTN0_MASK) != 0)

Definition at line 96 of file board.h.

◆ CC2420_PARAM_CCA

#define CC2420_PARAM_CCA   GPIO_PIN(P1, 4)

Definition at line 106 of file board.h.

◆ CC2420_PARAM_CS

#define CC2420_PARAM_CS   GPIO_PIN(P3, 0)

Definition at line 103 of file board.h.

◆ CC2420_PARAM_FIFO

#define CC2420_PARAM_FIFO   GPIO_PIN(P1, 3)

Definition at line 104 of file board.h.

◆ CC2420_PARAM_FIFOP

#define CC2420_PARAM_FIFOP   GPIO_PIN(P1, 2)

Definition at line 105 of file board.h.

◆ CC2420_PARAM_RESET

#define CC2420_PARAM_RESET   GPIO_PIN(P4, 6)

Definition at line 109 of file board.h.

◆ CC2420_PARAM_SFD

#define CC2420_PARAM_SFD   GPIO_PIN(P4, 1)

Definition at line 107 of file board.h.

◆ CC2420_PARAM_VREFEN

#define CC2420_PARAM_VREFEN   GPIO_PIN(P4, 5)

Definition at line 108 of file board.h.

◆ CONFIG_ZTIMER_USEC_ADJUST_SET

#define CONFIG_ZTIMER_USEC_ADJUST_SET   (99)

Definition at line 57 of file board.h.

◆ CONFIG_ZTIMER_USEC_ADJUST_SLEEP

#define CONFIG_ZTIMER_USEC_ADJUST_SLEEP   (100)

Definition at line 58 of file board.h.

◆ LED0_MASK

#define LED0_MASK   (0x10)

Definition at line 70 of file board.h.

◆ LED0_OFF

#define LED0_OFF   (LED_OUT_REG |= LED0_MASK)

Definition at line 75 of file board.h.

◆ LED0_ON

#define LED0_ON   (LED_OUT_REG &=~LED0_MASK)

Definition at line 74 of file board.h.

◆ LED0_PIN

#define LED0_PIN   GPIO_PIN(5, 4)

Definition at line 65 of file board.h.

◆ LED0_TOGGLE

#define LED0_TOGGLE   (LED_OUT_REG ^= LED0_MASK)

Definition at line 76 of file board.h.

◆ LED1_MASK

#define LED1_MASK   (0x40)

Definition at line 71 of file board.h.

◆ LED1_OFF

#define LED1_OFF   (LED_OUT_REG |= LED1_MASK)

Definition at line 79 of file board.h.

◆ LED1_ON

#define LED1_ON   (LED_OUT_REG &=~LED1_MASK)

Definition at line 78 of file board.h.

◆ LED1_PIN

#define LED1_PIN   GPIO_PIN(5, 6)

Definition at line 66 of file board.h.

◆ LED1_TOGGLE

#define LED1_TOGGLE   (LED_OUT_REG ^= LED1_MASK)

Definition at line 80 of file board.h.

◆ LED2_MASK

#define LED2_MASK   (0x20)

Definition at line 72 of file board.h.

◆ LED2_OFF

#define LED2_OFF   (LED_OUT_REG |= LED2_MASK)

Definition at line 83 of file board.h.

◆ LED2_ON

#define LED2_ON   (LED_OUT_REG &=~LED2_MASK)

Definition at line 82 of file board.h.

◆ LED2_PIN

#define LED2_PIN   GPIO_PIN(5, 5)

Definition at line 67 of file board.h.

◆ LED2_TOGGLE

#define LED2_TOGGLE   (LED_OUT_REG ^= LED2_MASK)

Definition at line 84 of file board.h.

◆ LED_OUT_REG

#define LED_OUT_REG   P5OUT

Definition at line 69 of file board.h.

◆ XTIMER_BACKOFF

#define XTIMER_BACKOFF   (40)

Definition at line 50 of file board.h.

◆ XTIMER_WIDTH

#define XTIMER_WIDTH   (16)

Definition at line 49 of file board.h.