Temperature sensing

Hello. I would like to know if there is a command to take the measurement of the current temperature of the CPU. This is in order to write a script to control a CPU fan speed based on the temperature. For the raspberry exists vcgencmd command, I can't find something similar for the Renegade board.
Tagged:

Comments

  • Not sure which IMG ur using, but this works for me:
    cat /sys/class/thermal/thermal_zone0/temp|cut -c1-2

    What I do is create a script - /usr/local/bin/sysinfo
    #!/bin/bash
    echo
    figlet -f small "Renegade" -c
    echo
    echo -e "CPU Temp: " $(cat /sys/class/thermal/thermal_zone0/temp|cut -c1-2)°C
    echo -e "Uptime: " $(uptime)

    Followed by another one to watch it - /usr/local/bin/temp-monitor
    #!/bin/bash
    watch -n1 /usr/local/bin/sysinfo
  • edited December 2019
    vcgencmd is Raspberry Pi specific firmware userspace trigger. All of Libre Computer boards should use /sys/class/thermal in conformance with upstream Linux.
Sign In or Register to comment.