Index: firmware/App/Controllers/Temperatures.c =================================================================== diff -u -rf5f00981805e265ce63058f650d784f06db4d188 -r98e24f0db83de34e3d44c4bd72df9f506f8ceddc --- firmware/App/Controllers/Temperatures.c (.../Temperatures.c) (revision f5f00981805e265ce63058f650d784f06db4d188) +++ firmware/App/Controllers/Temperatures.c (.../Temperatures.c) (revision 98e24f0db83de34e3d44c4bd72df9f506f8ceddc) @@ -142,6 +142,15 @@ break; } + // Convert the ADC values to temperature + convertADC2Temperature(); + + // Monitor the values for a gross range check + // Monitor is called in this function because this driver is constantly reading + // the temperatures values. Also the internal ADC values are processed with moving average in the internalADC driver + // So the temperatures drivers just gets the latest ADC value and converts it to temperature + monitorTemperatures(); + // Publish the data publishTemperaturesData(); } @@ -223,15 +232,6 @@ temperaturesStatus[ TEMPSENSOR_VENOUS_PRESSURE_SENSOR ].rawADCRead = getFPGAVenousPressureTemperature(); temperaturesStatus[ TEMPSENSOR_PBA_ADC_SENSOR ].rawADCRead = getFPGAPBAADCTemperature(); - // Convert the ADC values to temperature - convertADC2Temperature(); - - // Monitor the values for a gross range check - // Monitor is called in this function because this driver is constantly reading - // the temperatures values. Also the internal ADC values are processed with moving average in the internalADC driver - // So the temperatures drivers just gets the latest ADC value and converts it to temperature - monitorTemperatures(); - // Zero the counter for the next round of reading adcReadCounter = 0; }