This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TMS320F28069: Internal temperature sensor (ADC A5) with external reference

Part Number: TMS320F28069


In the SPRUH18 document, section 8.1.13.1, it states:

"The transfer function to determine a temperature is defined as:

Temperature = (sensor - Offset) * Slope 

...

The values listed are assuming a 3.3v full scale range. Using the internal reference mode automatically achieves this fixed range, but if using the external mode, the temperature sensor values must be adjusted accordingly to the external reference voltages."

I have not found any examples that show how to adjust the temperature formula for using an external reference. Which term or terms should be scaled? I'm using a 3.0V external reference.

Thank you

  • Dan,

    Thanks for posting, agreed that we could be a bit more clear in the documentation in this regard.  For your example we would just need to scale the temperature sensor reading you get using an external 3.0V reference(FSR = 3.0V) to be equivalent to what we would get had the internal reference been used(FSR = 3.3V).

    If I use Example_2806xAdc_TempSensorConv.c as a reference; you'll find the below at the end of the code to convert the temp sensor output voltage to a temperature in deg C or K

           temp = AdcResult.ADCRESULT0;
    
            //
            // Convert the raw temperature sensor measurement into temperature
            //
            degC = GetTemperatureC(temp);
            degK = GetTemperatureK(temp);

    To account for the change in your Vref = 3.0V we would insert the following code before the var temp is passed to the GetTemperatureC/K functions:

           temp = (float)AdcResult.ADCRESULT0 * 3.0 / 3.3;  //Normalize to 3.3V FSR
           
        
            //
            // Convert the raw temperature sensor measurement into temperature
            //
            degC = GetTemperatureC(temp);
            degK = GetTemperatureK(temp);

    Best regards,

    Matt