aboutsummaryrefslogtreecommitdiff
path: root/lib/chibios-contrib/ext/mcux-sdk/devices/LPC55S69/project_template/board.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/chibios-contrib/ext/mcux-sdk/devices/LPC55S69/project_template/board.c')
-rw-r--r--lib/chibios-contrib/ext/mcux-sdk/devices/LPC55S69/project_template/board.c31
1 files changed, 31 insertions, 0 deletions
diff --git a/lib/chibios-contrib/ext/mcux-sdk/devices/LPC55S69/project_template/board.c b/lib/chibios-contrib/ext/mcux-sdk/devices/LPC55S69/project_template/board.c
new file mode 100644
index 000000000..6aeed9baf
--- /dev/null
+++ b/lib/chibios-contrib/ext/mcux-sdk/devices/LPC55S69/project_template/board.c
@@ -0,0 +1,31 @@
1/*
2 * Copyright 2017-2018 NXP
3 * All rights reserved.
4 *
5 * SPDX-License-Identifier: BSD-3-Clause
6 */
7
8#include <stdint.h>
9#include "fsl_common.h"
10#include "fsl_debug_console.h"
11#include "board.h"
12
13/*******************************************************************************
14 * Variables
15 ******************************************************************************/
16
17/*******************************************************************************
18 * Code
19 ******************************************************************************/
20/* Initialize debug console. */
21void BOARD_InitDebugConsole(void)
22{
23 /* attach 12 MHz clock to FLEXCOMM0 (debug console) */
24 CLOCK_AttachClk(BOARD_DEBUG_UART_CLK_ATTACH);
25
26 RESET_ClearPeripheralReset(BOARD_DEBUG_UART_RST);
27
28 uint32_t uartClkSrcFreq = BOARD_DEBUG_UART_CLK_FREQ;
29
30 DbgConsole_Init(BOARD_DEBUG_UART_BASEADDR, BOARD_DEBUG_UART_BAUDRATE, BOARD_DEBUG_UART_TYPE, uartClkSrcFreq);
31}