CircuitPython CPU Temp

This little built in sensor comes with all ATSAMD21 chips, and its really nice to have a temperature sensor so we let you read it via CircuitPython, its new since 2.0.0 and only available on the ATSAMD21-based boards (e.g. not ESP8266)

It's so easy, we'll just give you the two REPL commands

>>> import microcontroller
>>> microcontroller.cpu.temperature

That's it! You'll have the temperature in Centigrade printed out. Note it is not exactly the same as ambient temperature, and its not super precise. But it's kinda close!

Last updated on 2017-12-01 at 04.59.09 PM Published on 2017-08-23 at 05.57.02 PM