How to control GPIO via C or Python 3

Did you do this thing, post 1, Libre Computer Wiring Tool?

Did it work?

If yes then:

from os import system

certs.FanOff = “gpioset 0 0=0” #J1 pin 32
certs.FanOn = “gpioset 0 0=1”

                    if ( temperature >= certs.FanTriggerPoint ):
                        system( f"{certs.FanOn}" )
                        fan_enabled = True
                    else:
                        system( f"{certs.FanOff}" )
                        fan_enabled = False

else:
let us know it did not work and what issue you have.

1 Like