Index: firmware/App/Drivers/TemperatureSensor.c =================================================================== diff -u -r8d272582cbd2cb5fc0c6af0fead2867ce02658b0 -r81aa682aa24931c7f44aea82ec72fb3dfabc7890 --- firmware/App/Drivers/TemperatureSensor.c (.../TemperatureSensor.c) (revision 8d272582cbd2cb5fc0c6af0fead2867ce02658b0) +++ firmware/App/Drivers/TemperatureSensor.c (.../TemperatureSensor.c) (revision 81aa682aa24931c7f44aea82ec72fb3dfabc7890) @@ -36,8 +36,6 @@ // ********** private definitions ********** -#define USE_PT_100_SENSORS 1 ///< Flag indicates whether we have PT100 or PT1000 temperature sensors. - #define PRIMARY_HEATER_TEMP_SENSORS_GAIN 8U ///< Primary heater temperature sensors gain. #define PRIMARY_HEATER_TEMP_SENSORS_REF_RESISTANCE 20000 ///< Primary heater temperature sensors reference resistance. #define PRIMARY_HEATER_TEMP_SENSORS_0_DEGREE_RESISTANCE 1000U ///< Primary heater temperature sensors zero degree resistance. @@ -118,31 +116,6 @@ //benignPolynomialCalRecord( &tempSensorCalRecord.tempSensors[ i ] ); } - // Initialize P23 and P22 temperature sensors -#ifdef USE_PT_100_SENSORS - tempSensors[ P23_TEMP ].gain = PT100_TEMP_SENSORS_GAIN; - tempSensors[ P23_TEMP ].refResistance = PT100_TEMP_SENSORS_REF_RESISTANCE; - tempSensors[ P23_TEMP ].zeroDegreeResistance = PT100_TEMP_SENSORS_0_DEGREE_RESISTANCE; - tempSensors[ P23_TEMP ].maxAllowedTemp = TEMP_SENSORS_MAX_ALLOWED_DEGREE_C; - tempSensors[ P22_TEMP ].gain = PT100_TEMP_SENSORS_GAIN; - tempSensors[ P22_TEMP ].refResistance = PT100_TEMP_SENSORS_REF_RESISTANCE; - tempSensors[ P22_TEMP ].zeroDegreeResistance = PT100_TEMP_SENSORS_0_DEGREE_RESISTANCE; - tempSensors[ P22_TEMP ].maxAllowedTemp = TEMP_SENSORS_MAX_ALLOWED_DEGREE_C; -#else - tempSensors[ P23_TEMP ].gain = PRIMARY_HEATER_TEMP_SENSORS_GAIN; - tempSensors[ P23_TEMP ].refResistance = PRIMARY_HEATER_TEMP_SENSORS_REF_RESISTANCE; - tempSensors[ P23_TEMP ].zeroDegreeResistance = PRIMARY_HEATER_TEMP_SENSORS_0_DEGREE_RESISTANCE; - tempSensors[ P23_TEMP ].maxAllowedTemp = TEMP_SENSORS_MAX_ALLOWED_DEGREE_C; - tempSensors[ P22_TEMP ].gain = PRIMARY_HEATER_TEMP_SENSORS_GAIN; - tempSensors[ P22_TEMP ].refResistance = PRIMARY_HEATER_TEMP_SENSORS_REF_RESISTANCE; - tempSensors[ P22_TEMP ].zeroDegreeResistance = PRIMARY_HEATER_TEMP_SENSORS_0_DEGREE_RESISTANCE; - tempSensors[ P22_TEMP ].maxAllowedTemp = TEMP_SENSORS_MAX_ALLOWED_DEGREE_C; -#endif - - // Board temperature sensors conversion coefficient -// tempSensors[ TEMPSENSORS_BOARD_TEMPERATURE ].conversionCoeff = conversionCoeff; -// tempSensors[ TEMPSENSORS_BOARD_TEMPERATURE ].maxAllowedTemp = NON_FLUID_PATH_TEMP_SENSORS_MAX_ALLOWED_DEGREE_C; - // Persistent alarm for the temperature sensors range check // initPersistentAlarm( ALARM_ID_DD_TEMPERATURE_SENSOR_OUT_OF_RANGE, TEMP_SENSORS_OUT_OF_RANGE_TIME_OUT_MS, TEMP_SENSORS_OUT_OF_RANGE_TIME_OUT_MS ); @@ -191,8 +164,8 @@ // lastTemperatureReadCounter.data = (U32)getFPGARTDReadCount(); //Read temperature sensors - processTempSnsrsADCRead( P23_TEMP, getFPGAP23Temperature() ); - processTempSnsrsADCRead( P22_TEMP, getFPGAP22Temperature() ); + //processTempSnsrsADCRead( P23_TEMP, getFPGAP23Temperature() ); + //processTempSnsrsADCRead( P22_TEMP, getFPGAP22Temperature() ); // //TODO: Read Board temperature // //processTempSnsrsADCRead( TEMPSENSORS_INTERNAL_COND_TEMP_SENSOR, getFPGACondSnsrInternalTemp() ); @@ -315,12 +288,6 @@ // Different sensors have different ADC to temperature conversion methods switch( sensorIndex ) { - case P23_TEMP: - case P22_TEMP: - temperature = getADC2TempConversion( avgADCReads, (U32)tempSensors [ sensorIndex ].gain, (U32)tempSensors [ sensorIndex ].refResistance, - (U32)tempSensors [ sensorIndex ].zeroDegreeResistance, tempSensors [ sensorIndex ].conversionCoeff ); - break; - case P10_TEMP: temperature = getConductivityTemperatureValue( P9_COND ); break;