# HG changeset patch # User ideenmodellierer # Date 1561922285 -7200 # Node ID 37ee61f93124fba9cc2cb6116e9a0624e41a3b82 # Parent 117a7ec23385f20e259a654a63f90e2637f7f2af Moved indication variable for received HUD data to tCCR file. To avoid global functions an interface function for indication and handling of received HUD data has been added diff -r 117a7ec23385 -r 37ee61f93124 Discovery/Inc/ostc.h --- a/Discovery/Inc/ostc.h Wed Jun 19 13:12:25 2019 +0000 +++ b/Discovery/Inc/ostc.h Sun Jun 30 21:18:05 2019 +0200 @@ -69,7 +69,6 @@ #ifdef USART_IR_HUD extern UART_HandleTypeDef UartIR_HUD_Handle; #endif -extern __IO ITStatus UartReadyHUD; #ifdef USART_PIEZO extern UART_HandleTypeDef UartPiezoTxHandle; diff -r 117a7ec23385 -r 37ee61f93124 Discovery/Inc/tCCR.h --- a/Discovery/Inc/tCCR.h Wed Jun 19 13:12:25 2019 +0000 +++ b/Discovery/Inc/tCCR.h Sun Jun 30 21:18:05 2019 +0200 @@ -38,6 +38,8 @@ void tCCR_restart(void); void tCCR_tick(void); +void tCCR_SetRXIndication(void); + float get_ppO2Sensor_bar(uint8_t sensor_id); float get_sensorVoltage_mV(uint8_t sensor_id); float get_HUD_battery_voltage_V(void); diff -r 117a7ec23385 -r 37ee61f93124 Discovery/Src/ostc.c --- a/Discovery/Src/ostc.c Wed Jun 19 13:12:25 2019 +0000 +++ b/Discovery/Src/ostc.c Sun Jun 30 21:18:05 2019 +0200 @@ -46,7 +46,6 @@ UART_HandleTypeDef UartIR_HUD_Handle; __IO ITStatus UartReady = RESET; -__IO ITStatus UartReadyHUD = RESET; /* Private types -------------------------------------------------------------*/ @@ -304,7 +303,7 @@ UartReady = SET; } -//void HAL_UART_RxCpltCallback(UART_HandleTypeDef *huart) + void HAL_UART_RxCpltCallback(UART_HandleTypeDef *huart) { if(huart == &UartHandle) @@ -312,7 +311,7 @@ else if(huart == &UartIR_HUD_Handle) { - UartReadyHUD = SET; + tCCR_SetRXIndication(); } }