.sysctl_gpio = RCC_APB2_GPIOA,
.sysctl_usart = RCC_APB1_USART2,
},
+#if CPU_CM3_STM32F103RB
/* UART3 */
{
.base = GPIOB_BASE,
.sysctl_gpio = RCC_APB2_GPIOB,
.sysctl_usart = RCC_APB1_USART3,
},
+#endif
};
#define USART1_PORT 0
/* UART port instances */
UART_PORT(1)
UART_PORT(2)
+#if CPU_CM3_STM32F103RB
UART_PORT(3)
+#endif
static struct CM3Serial UARTDesc[SER_CNT] =
{
.base = USART2_BASE,
.irq = USART2_IRQHANDLER,
},
+#if CPU_CM3_STM32F103RB
{
.hw = {
.table = &USART3_VT,
.base = USART3_BASE,
.irq = USART3_IRQHANDLER,
},
+#endif
};
struct SerialHardware *ser_hw_getdesc(int port)