I am trying to get the MCU temperature on an
TTSENS_CODE(TLOW) is 0x1647(-40C)
TTSENS_CODE(THIGH) is 0x1D61(150C)
VBG_CODE(TLOW) is 0xF7F
Temperature sensor is ch 128 and returns values roughly 0x16A0 at room temperature/normal running.
Bandgap is ch 45 and returns values roughly 0x1000.
When temperature formula is applied (MPC5644ARM pp 1231), (TTSENS_CODE(T) X B) calculates to a value less than TTSENS_CODE(TLOW) which should be impossible. The reading from ch 128 when bandgap adjusted is below the -40C value. What is wrong?
eQADC is calibrated and works just fine reading various internal voltage and the bandgap.