Help with rocket launch controller build - Raspberry Pi Forums
i building rocket launch controller. far have launch sequence working when press 'button.' counts down 10 , fires correct led @ end of countdown. have key switch attached board though , want ot launch when key switch on. want led2 on if switch on , led3 on if switch off indicate 'armed' status of controller. know next nothing python , have scrapped code far several tutorials , others' builds of similar projects. code: select all from gpiozero import led, button time import sleep signal import pause subprocess import popen led = led(17) led2 = led(27) led3 = led(22) button = button(2) armswitch = button (4) led2.on() while true: button.wait_for_press() led2.off() print ('countdown sequence initializing. ignition in...') popen(["flite -t 'countdown sequence initializing. ignition in'"], shell=true) sleep(4) in range(0,10): print (10 - i) popen(["flite -t '" + str(10 - i) +&qu