File /sys/class/thermal/thermal_zone0/temp is missing it no longer exists with these 6.1 kernel versions.
I have a simple program which I call pitemp which tells me the temperature of all my Raspberry Pi's. #!/bin/sh
milcel=$(cat /sys/class/thermal/thermal_zone0/temp)
echo "CPU Temperature:" echo ctemp=$(echo "scale=3;$milcel/1000" | bc) echo $ctemp "°C" echo ftemp=$(echo "scale=3;(($milcel/1000)*(9/5))+32" | bc) echo $ftemp "°F" echo
It serves the same function as vcgencmd measure_temp. I've noticed that whenever I was testing the 6.1-rc series kernels, that whenever I'd run my script, that I would get this message: /sys/class/thermal/thermal_zone0/temp: The file or directory does not exist I've been combing through the kernel config and I can't account for this. both configurations for kernel 6.0.14 and 6.1.1, essentially seem to be the same so I'm at a loss. Both kernels seem to work flawlessly, and curiously enough, whenever I run vcgencmd measure_temp I get the desired result on both kernels. The only difference that is observed, is what I have already stated, that /sys/class/thermal/ exists, however, thermalzone0/temp, does not.
I would appreciate any insights. I still have some more tests and experiments to make on different devices possibly some running different distributions to see if I have consistent results. Thank you for your time and I'll be paying attention to any replies.