old stamp1, VERY basic program attempt
Archiver
Posts: 46,084
I have an old basic one, just trying to get it to simply do the
following:
when power is applied to one input, i want it to start a CD player
with a push button type start, when power is turned off I want to
push the stop button on the cd player. Here is what I have, what am
I doing wrong?
input 0
output 6
output 7
CHKON: if pin0=1 then START
goto CHKON
START: high 6
pause 1000
low 6
CHKOFF: if pin0=0 then STOP
goto CHKOFF
STOP: high 7
pause 1000
low 7
seems simple, but it doesnt seem to run, i get no change in state on
pins 6 and 7 (connected to LED via 200 ohm resistor).
any ideas would be nice, thanks
following:
when power is applied to one input, i want it to start a CD player
with a push button type start, when power is turned off I want to
push the stop button on the cd player. Here is what I have, what am
I doing wrong?
input 0
output 6
output 7
CHKON: if pin0=1 then START
goto CHKON
START: high 6
pause 1000
low 6
CHKOFF: if pin0=0 then STOP
goto CHKOFF
STOP: high 7
pause 1000
low 7
seems simple, but it doesnt seem to run, i get no change in state on
pins 6 and 7 (connected to LED via 200 ohm resistor).
any ideas would be nice, thanks
Comments
input either high or low
Put your Start subroutine into a loop so that the next change in state
will exit the loop
and into your chkoff routine
On Sat, 10 Nov 2001 21:06:22 -0000 daronwilson@y... writes:
>
> I have an old basic one, just trying to get it to simply do the
> following:
>
> when power is applied to one input, i want it to start a CD player
> with a push button type start, when power is turned off I want to
> push the stop button on the cd player. Here is what I have, what am
>
> I doing wrong?
>
> input 0
> output 6
> output 7
>
> CHKON: if pin0=1 then START
> goto CHKON
>
> START: high 6
> pause 1000
> low 6
>
> CHKOFF: if pin0=0 then STOP
> goto CHKOFF
>
> STOP: high 7
> pause 1000
> low 7
>
> seems simple, but it doesnt seem to run, i get no change in state on
>
> pins 6 and 7 (connected to LED via 200 ohm resistor).
>
> any ideas would be nice, thanks
>
>
> To UNSUBSCRIBE, just send mail to:
> basicstamps-unsubscribe@yahoogroups.com
> from the same email address that you subscribed. Text in the
> Subject and Body of the message will be ignored.
>
>
> Your use of Yahoo! Groups is subject to
> http://docs.yahoo.com/info/terms/
>
>