Adafruit_Learning_System_Gu.../CircuitPython_Templates/cpu_temperature_f/code.py
2021-12-06 13:41:02 -05:00

9 lines
291 B
Python

# SPDX-FileCopyrightText: 2021 Kattni Rembor for Adafruit Industries
# SPDX-License-Identifier: Unlicense
"""CircuitPython CPU temperature example in Fahrenheit"""
import time
import microcontroller
while True:
print(microcontroller.cpu.temperature * (9 / 5) + 32)
time.sleep(0.15)