From 0edf3f363b0e8222477f1bf956a421ab6e7d2cd5 Mon Sep 17 00:00:00 2001 From: Uladzimir Pylinski Date: Tue, 19 Jul 2016 18:56:03 +0000 Subject: [STM32. USARTv2] Added receiver timeout handling. git-svn-id: svn://svn.code.sf.net/p/chibios/svn/trunk@9713 35acf78f-673a-0410-8e92-d51de3d6d3f4 --- testhal/STM32/STM32F3xx/UART/main.c | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'testhal/STM32/STM32F3xx') diff --git a/testhal/STM32/STM32F3xx/UART/main.c b/testhal/STM32/STM32F3xx/UART/main.c index 30abb55d3..1ef5bb6b9 100644 --- a/testhal/STM32/STM32F3xx/UART/main.c +++ b/testhal/STM32/STM32F3xx/UART/main.c @@ -91,6 +91,14 @@ static void rxend(UARTDriver *uartp) { (void)uartp; } +/* + * This callback is invoked when configured timeout reached. + */ +static void rxtimeout(UARTDriver *uartp) { + + (void)uartp; +} + /* * UART driver configuration structure. */ @@ -100,6 +108,8 @@ static UARTConfig uart_cfg_1 = { rxend, rxchar, rxerr, + rxtimeout, + 0, 38400, 0, USART_CR2_LINEN, -- cgit v1.2.3