Skip to content

Instantly share code, notes, and snippets.

View tarikhagustia's full-sized avatar
🎯
Focusing

Tarikh Agustia tarikhagustia

🎯
Focusing
View GitHub Profile
@ah01
ah01 / cpu-tamp.sh
Created October 11, 2015 14:15
Send CPU temperature to MQTT
while true
do
t=$(cat /sys/class/thermal/thermal_zone0/temp)
t=$(($t/1000))
echo Teplota CPU $t
mosquitto_pub -h mqtt.sh.cvut.cz -t linuxdays/raspberry/temperature -m "$t °C"
sleep 5
done