Changes

Jump to navigation Jump to search

X708-Software

611 bytes added, 19:25, 27 April 2022
no edit summary
<span style="color:#23AC38">pi@raspberrypi</span>:<span style="color:#50BEDB">~ $</span> cd ~/x708v2/raspberry-pi-os/
You can control the fan running at high speed or low speed via modify the CPU temperature threshold in fan.py script file(yellow highlight line)
[[File:X708-v2‎<syntaxhighlight lang="python" line highlight="9-11">#!/usr/bin/env python3 import subprocessimport time from gpiozero import OutputDevice  ON_THRESHOLD = 55 # (degrees Celsius) Fan running at high speed at this temperature.OFF_THRESHOLD = 50 # (degress Celsius) Fan running at low speed at this temperature.SLEEP_INTERVAL = 5 # (seconds) How often we check the core temperature.GPIO_PIN = 16 # Which GPIO pin you're using to control the fan.png]]DON'T change it!  def get_temp(): """Get the core temperature. Run a shell script to get the core temp and parse the output.</syntaxhighlight>
9. Uninstall

Navigation menu