comparison Small_CPU/Src/uartProtocol_O2.c @ 932:effadaa3a1f7 Evo_2_23

Cleanup Gnss UART implementation: The first draft of the internal UART implementation was just a copy of the external UART handling. To avoid duplicated code and maintainance issue both UARTs (external/internal 6/1) share the same functions. To enable this a control structure has to be used as function input which defines the none shared resources like DMA control and rx/tx buffers
author Ideenmodellierer
date Sat, 07 Dec 2024 21:28:08 +0100
parents eb4109d7d1e9
children
comparison
equal deleted inserted replaced
931:5a9bc2e6112d 932:effadaa3a1f7
104 memset((char*) &tmpSensorDataDiveO2, 0, sizeof(tmpSensorDataDiveO2)); 104 memset((char*) &tmpSensorDataDiveO2, 0, sizeof(tmpSensorDataDiveO2));
105 externalInterface_SetSensorData(0xFF,(uint8_t*)&tmpSensorDataDiveO2); 105 externalInterface_SetSensorData(0xFF,(uint8_t*)&tmpSensorDataDiveO2);
106 106
107 localComState = UART_O2_CHECK; 107 localComState = UART_O2_CHECK;
108 lastComState = UART_O2_CHECK; 108 lastComState = UART_O2_CHECK;
109 UART_clearRxBuffer(); 109 UART_clearRxBuffer(&Uart1Ctrl);
110 uartO2_SetupCmd(localComState,cmdString,&cmdLength); 110 uartO2_SetupCmd(localComState,cmdString,&cmdLength);
111 UART_SendCmdString(cmdString); 111 UART_SendCmdString(cmdString);
112 rxState = O2RX_CONFIRM; 112 rxState = O2RX_CONFIRM;
113 respondErrorDetected = 0; 113 respondErrorDetected = 0;
114 digO2Connected = 0; 114 digO2Connected = 0;