Index: firmware/App/Drivers/TemperatureSensors.c =================================================================== diff -u -r9e6e86f604c8cce7c1704ae55d1e026de3422782 -r89f18a07a6d5837bf9b4559a69046e2b06f32c35 --- firmware/App/Drivers/TemperatureSensors.c (.../TemperatureSensors.c) (revision 9e6e86f604c8cce7c1704ae55d1e026de3422782) +++ firmware/App/Drivers/TemperatureSensors.c (.../TemperatureSensors.c) (revision 89f18a07a6d5837bf9b4559a69046e2b06f32c35) @@ -266,11 +266,11 @@ // Make sure the baro sensor coefficients are not corrupted checkBaroSensorCRC(); #endif - baroConvConsts.refTemperature = getFPGABaroReferenceTemperature(); - baroConvConsts.temperatureCoeff = getFPGABaroTempCoeffOfTemperature(); - lastBaroTempReadCounter.data = (U32)getFPGABaroReadCount(); - - processTempSnsrsADCRead( BARO_TEMP, getFPGABaroTemperature() ); +// baroConvConsts.refTemperature = getFPGABaroReferenceTemperature(); +// baroConvConsts.temperatureCoeff = getFPGABaroTempCoeffOfTemperature(); +// lastBaroTempReadCounter.data = (U32)getFPGABaroReadCount(); +// +// processTempSnsrsADCRead( BARO_TEMP, getFPGABaroTemperature() ); } } @@ -504,38 +504,38 @@ *************************************************************************/ static void checkBaroSensorCRC( void ) { - U32 baroCRC = (U32)getFPGABaroCoeffsCRC(); - BOOL hasCRCChanged = ( baroCRC != getU32OverrideValue( &baroConvConsts.coeffsCRC ) ? TRUE : FALSE ); - - // Once FPGA is ready get the barometric sensor's temperature conversion constants - if ( TRUE == hasCRCChanged ) - { - U08 calculatedCRC; - BARO_SENSORS_COEFFS_T baroCoeffs; - - baroCoeffs.mfgInfo = getFPGABaroMfgInfo(); - baroCoeffs.pressSensitivity = getFPGABaroPressureSensitivity(); - baroCoeffs.pressOffset = getFPGABaroPressureOffset(); - baroCoeffs.tempCoeffOfPressSens = getFPGABaroTempCoeffOfPressSensitvity(); - baroCoeffs.tempCoeffPressOffset = getFPGABaroTempCoeffOfPressOffset(); - baroCoeffs.referenceTemp = getFPGABaroReferenceTemperature(); - baroCoeffs.tempCoeffOfTemp = getFPGABaroTempCoeffOfTemperature(); - baroCoeffs.crc = MASK_OFF_LSB & getFPGABaroCoeffsCRC(); - calculatedCRC = crc4( (U16*)&baroCoeffs, sizeof( baroCoeffs ) ); - baroConvConsts.coeffsCRC.data = baroCRC; - baroCRC = (U16)( baroCRC & MASK_OFF_MSB ) & MASK_OFF_NIBBLE_MSB; - baroConvConsts.hasCRCBeenChecked = TRUE; - - if ( calculatedCRC != baroCRC ) - { - SET_ALARM_WITH_2_U32_DATA( ALARM_ID_DD_BAROMETRIC_SENSOR_COEFFS_BAD_CRC, calculatedCRC, baroCoeffs.crc ); - } - } - else if ( ( TRUE == didTimeout( baroConvConsts.waitForCoeffStartTimeMS, BARO_SENSOR_WAIT_FOR_COEFF_TIME_OUT_MS ) ) && - ( FALSE == baroConvConsts.hasCRCBeenChecked ) ) - { - SET_ALARM_WITH_2_U32_DATA( ALARM_ID_DD_BAROMETRIC_SENSOR_COEFFS_BAD_CRC, 0, baroCRC ); - } +// U32 baroCRC = (U32)getFPGABaroCoeffsCRC(); +// BOOL hasCRCChanged = ( baroCRC != getU32OverrideValue( &baroConvConsts.coeffsCRC ) ? TRUE : FALSE ); +// +// // Once FPGA is ready get the barometric sensor's temperature conversion constants +// if ( TRUE == hasCRCChanged ) +// { +// U08 calculatedCRC; +// BARO_SENSORS_COEFFS_T baroCoeffs; +// +// baroCoeffs.mfgInfo = getFPGABaroMfgInfo(); +// baroCoeffs.pressSensitivity = getFPGABaroPressureSensitivity(); +// baroCoeffs.pressOffset = getFPGABaroPressureOffset(); +// baroCoeffs.tempCoeffOfPressSens = getFPGABaroTempCoeffOfPressSensitvity(); +// baroCoeffs.tempCoeffPressOffset = getFPGABaroTempCoeffOfPressOffset(); +// baroCoeffs.referenceTemp = getFPGABaroReferenceTemperature(); +// baroCoeffs.tempCoeffOfTemp = getFPGABaroTempCoeffOfTemperature(); +// baroCoeffs.crc = MASK_OFF_LSB & getFPGABaroCoeffsCRC(); +// calculatedCRC = crc4( (U16*)&baroCoeffs, sizeof( baroCoeffs ) ); +// baroConvConsts.coeffsCRC.data = baroCRC; +// baroCRC = (U16)( baroCRC & MASK_OFF_MSB ) & MASK_OFF_NIBBLE_MSB; +// baroConvConsts.hasCRCBeenChecked = TRUE; +// +// if ( calculatedCRC != baroCRC ) +// { +// SET_ALARM_WITH_2_U32_DATA( ALARM_ID_DD_BAROMETRIC_SENSOR_COEFFS_BAD_CRC, calculatedCRC, baroCoeffs.crc ); +// } +// } +// else if ( ( TRUE == didTimeout( baroConvConsts.waitForCoeffStartTimeMS, BARO_SENSOR_WAIT_FOR_COEFF_TIME_OUT_MS ) ) && +// ( FALSE == baroConvConsts.hasCRCBeenChecked ) ) +// { +// SET_ALARM_WITH_2_U32_DATA( ALARM_ID_DD_BAROMETRIC_SENSOR_COEFFS_BAD_CRC, 0, baroCRC ); +// } } /*********************************************************************//**