forked from Qortal/Brooklyn
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
7 lines
215 B
7 lines
215 B
3 years ago
|
#!/bin/bash
|
||
|
prefix="temp="
|
||
|
suffix="'C"
|
||
|
gpu=$(/opt/vc/bin/vcgencmd measure_temp)
|
||
|
gpu_temp=${gpu#$prefix}
|
||
|
gpu_temp=${gpu_temp%$suffix}
|
||
|
echo -e "{\"cpu\":"$(</sys/class/thermal/thermal_zone0/temp)", \"gpu\":$gpu_temp}"
|