mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2025-01-15 11:12:43 +01:00
bd929a3746
The QN908x has four FLEXCOMM interfaces that support a subset of UART, SPI or I2C each one. This patch adds generic support for dealing with the FLEXCOMM initialization and interrupts and adds a driver for RX/TX support in UART. With this patch is now possible to use a shell on the device over UART.
64 lines
1.0 KiB
C
64 lines
1.0 KiB
C
/*
|
|
* Copyright (C) 2020 iosabi
|
|
*
|
|
* 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.
|
|
*/
|
|
|
|
/**
|
|
* @ingroup boards_qn9080dk
|
|
* @{
|
|
*
|
|
* @file
|
|
* @brief Configuration of CPU peripherals for QN9080DK base board board
|
|
*
|
|
* @author iosabi <iosabi@protonmail.com>
|
|
*/
|
|
|
|
#ifndef PERIPH_CONF_H
|
|
#define PERIPH_CONF_H
|
|
|
|
#include <stdint.h>
|
|
|
|
#include "cpu.h"
|
|
#include "periph_cpu.h"
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
/**
|
|
* @name UART configuration
|
|
* @{
|
|
*/
|
|
static const uart_conf_t uart_config[] = {
|
|
{
|
|
.dev = USART0,
|
|
.rx_pin = GPIO_PIN(PORT_A, 17),
|
|
.tx_pin = GPIO_PIN(PORT_A, 16),
|
|
},
|
|
};
|
|
|
|
#define UART_NUMOF ARRAY_SIZE(uart_config)
|
|
/** @} */
|
|
|
|
/* put here the board peripherals definitions:
|
|
- Available clocks
|
|
- Timers
|
|
- PWMs
|
|
- SPIs
|
|
- I2C
|
|
- ADC
|
|
- RTC
|
|
- RTT
|
|
etc
|
|
*/
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif /* PERIPH_CONF_H */
|
|
/** @} */
|