see https://forum.pjrc.com/threads/59813-Teensy-4-0-Internal-Temperature-measurement
and you can look in the core source files to see how tempmonGetTemp() does it