aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthias P. Braendli <matthias.braendli@mpb.li>2016-04-17 15:37:18 +0200
committerMatthias P. Braendli <matthias.braendli@mpb.li>2016-04-17 15:37:18 +0200
commitebf3791ddbde81aa7b52d2ea161c3ec0ece3d2a6 (patch)
tree9d7316f85f3bef805df7e3e96674c0940ab6ec17
parent50e0d505bab3bb1d2061c72d1948fdd2da2423ef (diff)
downloadglutte-o-matic-ebf3791ddbde81aa7b52d2ea161c3ec0ece3d2a6.tar.gz
glutte-o-matic-ebf3791ddbde81aa7b52d2ea161c3ec0ece3d2a6.tar.bz2
glutte-o-matic-ebf3791ddbde81aa7b52d2ea161c3ec0ece3d2a6.zip
fsm: disable USART2 RX
-rw-r--r--src/fsm/usart.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/fsm/usart.c b/src/fsm/usart.c
index 70b16ba..ab6fc36 100644
--- a/src/fsm/usart.c
+++ b/src/fsm/usart.c
@@ -78,6 +78,7 @@ void usart_init()
USART_InitStruct.USART_Mode = USART_Mode_Tx | USART_Mode_Rx;
USART_Init(USART2, &USART_InitStruct);
+#if USART2_RECEIVE_ENABLE
// enable the USART2 receive interrupt
USART_ITConfig(USART2, USART_IT_RXNE, ENABLE);
@@ -89,6 +90,7 @@ void usart_init()
NVIC_Init(&NVIC_InitStructure);
NVIC_SetPriority(USART2_IRQn, 6);
+#endif
// finally this enables the complete USART2 peripheral
USART_Cmd(USART2, ENABLE);