Loading...
Searching...
No Matches
board.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2016 UC Berkeley
3 *
4 * This file is subject to the terms and conditions of the GNU Lesser
5 * General Public License v2.1. See the file LICENSE in the top level
6 * directory for more details.
7 */
8
21#ifndef BOARD_H
22#define BOARD_H
23
24#include "cpu.h"
25#include "periph_conf.h"
26#include "periph_cpu.h"
27#include "periph/gpio.h"
28
29#ifdef __cplusplus
30extern "C" {
31#endif
32
37#define XTIMER_DEV TIMER_DEV(1)
38#define XTIMER_CHAN (0)
45#define AT86RF2XX_PARAM_SPI SPI_DEV(0)
46#define AT86RF2XX_PARAM_SPI_CLK SPI_CLK_5MHZ
47#define AT86RF2XX_PARAM_CS GPIO_PIN(PB, 31)
48#define AT86RF2XX_PARAM_INT GPIO_PIN(PB, 0)
49#define AT86RF2XX_PARAM_SLEEP GPIO_PIN(PA, 20)
50#define AT86RF2XX_PARAM_RESET GPIO_PIN(PB, 15)
57#define LED0_PIN GPIO_PIN(0, 19)
58
59#define LED0_PORT PORT->Group[0]
60#define LED0_MASK (1 << 19)
61
62#define LED0_ON (LED0_PORT.OUTCLR.reg = LED0_MASK)
63#define LED0_OFF (LED0_PORT.OUTSET.reg = LED0_MASK)
64#define LED0_TOGGLE (LED0_PORT.OUTTGL.reg = LED0_MASK)
71#define BTN0_PIN GPIO_PIN(0, 18)
72#define BTN0_MODE GPIO_IN_PU
81#define FXOS8700_PARAM_I2C I2C_DEV(0)
82#define FXOS8700_PARAM_ADDR (0x1E)
83#define FXOS8700_PARAM_RENEW_INTERVAL (1000000ul)
90#define HDC1000_PARAM_I2C I2C_DEV(0)
91#define HDC1000_PARAM_ADDR (0x40)
92#define HDC1000_PARAM_RES HDC1000_14BIT
93#define HDC1000_PARAM_RENEW_INTERVAL (1000000ul)
100#define PIR_PARAM_GPIO GPIO_PIN(PA, 6)
101#define PIR_PARAM_ACTIVE_HIGH (1)
108#define PULSE_COUNTER_GPIO BTN0_PIN
109#define PULSE_COUNTER_GPIO_FLANK GPIO_FALLING
118#define TMP00X_PARAM_I2C I2C_DEV(0)
119#define TMP00X_PARAM_ADDR (0x44)
120#define TMP00X_PARAM_RATE TMP00X_CONFIG_CR_AS2
129#ifdef __cplusplus
130}
131#endif
132
133#endif /* BOARD_H */
Native CPU peripheral configuration.
Low-level GPIO peripheral driver interface definitions.