Dumb question of the day
George99
Posts: 16
Maybe it's just too early.
I was demonstrating the basics of the BS2 so I hooked up an LED in series with a 470 ohm resistor between VSS and P14.
The following program turns the LED on for a second then off.
' {$STAMP BS2}
' {$PBASIC 2.5}
HIGH 14
PAUSE 1000
LOW 14
END
It works great: when I press F9, the LED and the homework board run lights go on for 1 second as planned. But if I press reset on the homework board or disconnect and reconnect the battery, nothing happens.
I added a line DEBUG "Ending now",CR between LOW and END, then it works as expected. Why?
I was demonstrating the basics of the BS2 so I hooked up an LED in series with a 470 ohm resistor between VSS and P14.
The following program turns the LED on for a second then off.
' {$STAMP BS2}
' {$PBASIC 2.5}
HIGH 14
PAUSE 1000
LOW 14
END
It works great: when I press F9, the LED and the homework board run lights go on for 1 second as planned. But if I press reset on the homework board or disconnect and reconnect the battery, nothing happens.
I added a line DEBUG "Ending now",CR between LOW and END, then it works as expected. Why?
Comments
I moved the serial cable from COM2 to COM1 and now it works. Computers, bah.
' {$STAMP BS2}
' {$PBASIC 2.5}
DO
HIGH 14
PAUSE 1000
LOW 14
PAUSE 1000
LOOP
END
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
- Stephen