/* * Copyright (c) 2006-2021, RT-Thread Development Team * * SPDX-License-Identifier: Apache-2.0 * * Change Logs: * Date Author Notes * 2013-11-15 bright the first version */ #ifndef __USART_H__ #define __USART_H__ #include #include #include "cmsis.h" /* USART - Peripheral instance base addresses */ /** Peripheral USART0 base address */ #define USART0_BASE (0x40064000u) /** Peripheral USART0 base pointer */ #define USART0 ((LPC_USART_T *)USART0_BASE) /** Peripheral USART1 base address */ #define USART1_BASE (0x40068000u) /** Peripheral USART1 base pointer */ #define USART1 ((LPC_USART_T *)USART1_BASE) /** Peripheral USART2 base address */ #define USART2_BASE (0x4006C000u) /** Peripheral USART2 base pointer */ #define USART2 ((LPC_USART_T *)USART2_BASE) /** Array initializer of USART peripheral base addresses */ #define USART_BASE_ADDRS { USART0_BASE, USART1_BASE, USART2_BASE } /** Array initializer of USART peripheral base pointers */ #define USART_BASE_PTRS { USART0, USART1, USART2 } /** Interrupt vectors for the USART peripheral type */ #define USART_IRQS { USART0_IRQn, USART1_IRQn, USART2_IRQn } int rt_hw_usart_init(void); #endif