'====================================================================== ' File..... SPST Push-Button Switch Test 11.11.07.bs1 ' Author... Geoff @ The GARAGE OF EVIL!! ' Web...... http://www.garageofevil.com ' {$STAMP BS1} ' {$PBASIC 1.0} ' ' -----[ Program Descripton ]------------------------------------------ ' Using a Radio Shack SPST Switch Button (Part #275-011), connected via ' two wires (WR) on the Prop-1 to PIN0, when pressed, it completes the ' circuit, and then prints out "Success!" to the DEBUG window, letting ' you know that the button has been pressed. '====================================================================== ' -----[ Constants ]--------------------------------------------------- SYMBOL IsOn = 1 SYMBOL IsOff = 0 SYMBOL Trigger1 = PIN0 ' -----[ Program Code ]------------------------------------------------ Main: IF Trigger1 = IsOn THEN TestButton GOTO Main TestButton: DEBUG "Success! " GOTO Main