Translations:Dimensionner et faire un tracker solaire photovolatïque low tech/206/en

def forwardzero(wait):

   led16=gpiozero.LED(16) #motor1
   led23=gpiozero.LED(23) #motor1
   led20=gpiozero.LED(20) #enable
   led21=gpiozero.LED(21) #enable
   led1=gpiozero.LED(1)
   led7=gpiozero.LED(7)
   try:
       print("forwardzero")
       #case where Hbridge needs a enable signal
       led21.off()
       led20.on()
       #zero signal off on switch 2
       led1.off()
       led7.off()
       #positive signal off on switch 1
       led23.on()
       led16.off()
       #let signal active during wait time
       for k in range(wait):
           print(k)
           time.sleep(1)
       #put signal off on the switch
       led23.off()
       led20.off()
   except KeyboardnInterrupt:
       print("keyboard interrupt")
   except Exception as err:
       print(err)
   finally:
       print("zero")
       #zero signal off on switch 2
       led1.off()
       led7.off()
       #signal off on switch 1
       led16.off()
       led23.off()
       #signal off on enable pin
       led20.off()
       led21.off()

def backwardzero(wait):

   led1=gpiozero.LED(1)
   led7=gpiozero.LED(7)
   led16=gpiozero.LED(16) #motor1
   led23=gpiozero.LED(23) #motor1
   led20=gpiozero.LED(20) #enable
   led21=gpiozero.LED(21) #enable
   try:
       print("backwardzero")
       #signal off on switch 1
       led16.on()
       led23.off()
       #case where Hbridge needs a enable signal
       led20.off()
       led21.on()
       #signal on switch 2
       led1.off()
       led7.off()
       #wait
       for k in range(wait):
           print(k)
           time.sleep(1)
       #signal off on switches
       led16.off()
       led21.off()
   except KeyboardInterrupt:
       print("keyboardinterrupt")
   except Exception as err:
       print(err)
   finally:
       print("zero")
       #signal off on switch 1
       led16.off()
       led23.off()
       #signal off on switch 2
       led1.off()
       led7.off()
       #signal off on enable pin
       led20.off()
       led21.off()