2015-04-16 08:33:35 +02:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2014 Freie Universität Berlin
|
|
|
|
*
|
|
|
|
* This file is subject to the terms and conditions of the GNU Lesser
|
|
|
|
* General Public License v2.1. See the file LICENSE in the top level
|
|
|
|
* directory for more details.
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
2018-07-26 11:59:14 +02:00
|
|
|
* @ingroup boards_saml21-xpro
|
2015-04-16 08:33:35 +02:00
|
|
|
* @{
|
|
|
|
*
|
|
|
|
* @file
|
|
|
|
* @brief Board specific definitions for the Atmel SAM L21 Xplained Pro board.
|
|
|
|
*
|
|
|
|
* @author Thomas Eichinger <thomas.eichinger@fu-berlin.de>
|
2017-06-20 21:11:34 +02:00
|
|
|
* @author Sebastian Meiling <s@mlng.net>
|
2015-04-16 08:33:35 +02:00
|
|
|
*/
|
|
|
|
|
2015-12-02 10:56:28 +01:00
|
|
|
#ifndef BOARD_H
|
|
|
|
#define BOARD_H
|
2015-04-16 08:33:35 +02:00
|
|
|
|
|
|
|
#include "cpu.h"
|
2024-07-11 15:11:21 +02:00
|
|
|
#include "periph/gpio.h"
|
2015-04-16 08:33:35 +02:00
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
|
|
|
/**
|
2017-04-10 19:04:32 +02:00
|
|
|
* @name LED pin definitions and handlers
|
2015-04-16 08:33:35 +02:00
|
|
|
* @{
|
|
|
|
*/
|
2016-03-11 18:04:26 +01:00
|
|
|
#define LED0_PIN GPIO_PIN(1, 10)
|
2015-04-16 08:33:35 +02:00
|
|
|
|
2016-03-11 18:04:26 +01:00
|
|
|
#define LED_PORT PORT->Group[1]
|
|
|
|
#define LED0_MASK (1 << 10)
|
2015-04-16 08:33:35 +02:00
|
|
|
|
2016-03-11 18:04:26 +01:00
|
|
|
#define LED0_ON (LED_PORT.OUTCLR.reg = LED0_MASK)
|
|
|
|
#define LED0_OFF (LED_PORT.OUTSET.reg = LED0_MASK)
|
|
|
|
#define LED0_TOGGLE (LED_PORT.OUTTGL.reg = LED0_MASK)
|
2015-04-16 08:33:35 +02:00
|
|
|
/** @} */
|
|
|
|
|
2016-03-02 12:11:16 +01:00
|
|
|
/**
|
2017-06-20 21:11:34 +02:00
|
|
|
* @name SW0 (Button) pin definitions
|
|
|
|
* @{
|
2016-03-02 12:11:16 +01:00
|
|
|
*/
|
2017-06-20 21:11:34 +02:00
|
|
|
#define BTN0_PIN GPIO_PIN(PA, 2)
|
|
|
|
#define BTN0_MODE GPIO_IN_PU
|
|
|
|
/** @} */
|
|
|
|
|
2015-04-16 08:33:35 +02:00
|
|
|
#ifdef __cplusplus
|
|
|
|
}
|
|
|
|
#endif
|
|
|
|
|
2017-05-23 18:19:52 +02:00
|
|
|
#endif /* BOARD_H */
|
2015-04-16 08:33:35 +02:00
|
|
|
/** @} */
|