Mercurial > public > ostc4
comparison Small_CPU/Src/uartProtocol_O2.c @ 921:eb4109d7d1e9 Evo_2_23
Improved mix mode ADC conversion:
Activity of UART sensors may have an impact to ADC measurement. To avoid the ADC trigger was moved into a time window ~300ms after last UART command request => After UART sensor performed measurement but before next measurement is requested. In addition the general ADC measurement cycle has been changed to one second to avoid jitter in the value updates on the display.
author | Ideenmodellierer |
---|---|
date | Sun, 03 Nov 2024 18:19:51 +0100 |
parents | 4832981f9af8 |
children | effadaa3a1f7 |
comparison
equal
deleted
inserted
replaced
920:c4c9850a2039 | 921:eb4109d7d1e9 |
---|---|
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 uartO2_SetupCmd(localComState,cmdString,&cmdLength); | 110 uartO2_SetupCmd(localComState,cmdString,&cmdLength); |
110 UART_SendCmdString(cmdString); | 111 UART_SendCmdString(cmdString); |
111 rxState = O2RX_CONFIRM; | 112 rxState = O2RX_CONFIRM; |
112 respondErrorDetected = 0; | 113 respondErrorDetected = 0; |
113 digO2Connected = 0; | 114 digO2Connected = 0; |