Skip to content

Instantly share code, notes, and snippets.

@limontec
Forked from kevalpatel2106/monitor-temp.py
Last active March 12, 2021 14:02
Show Gist options
  • Save limontec/16f831b4f385df33e2d9de958b59cfd3 to your computer and use it in GitHub Desktop.
Save limontec/16f831b4f385df33e2d9de958b59cfd3 to your computer and use it in GitHub Desktop.
import os
import time
def measure_temp():
temp = os.popen("vcgencmd measure_temp").readline()
return (temp.replace("temp=",""))
while True:
print(measure_temp())
time.sleep(1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment