Shop OBEX P1 Docs P2 Docs Learn Events
[Re: [basicstamps] Basic Stamp 2] — Parallax Forums

[Re: [basicstamps] Basic Stamp 2]

ArchiverArchiver Posts: 46,084
edited 2000-11-02 16:11 in General Discussion
I really appreciate the help. Do you by chance know how I can wait a certain
time period between the 6 steps, say 0 wait a minute 1 and so on.

Thanks

Josh








Bruce Bates <bvbates@u...> wrote:
At 11/1/2000 +0000 11:33 PM, you wrote:
>I am trying to writ a program that will control the firing angle of a
>triac in a dimmer circuit. In the following program I can control
>the intensity of the light by changing alpha and running the program
>again. How do I make a loop that will automatically change alpha from
>0 to 6. Any help would be appreciated.
>
>input 10
>alpha var byte
>cnt var byte
>
>alpha=4 <== Why 4 ??

For alpha = 0 to 6 <== Add

>Hold: if IN10 = 0 then Hold
>cnt=0
>bob:cnt=cnt+1
>if cnt >= alpha then ryan
>if cnt < alpha then bob
>ryan: PulsOut 8,10
>pause 7
>PulsOut 8,10
>goto Hold

Next <== Add


>Thanks,
>Josh





____________________________________________________________________
Get your own FREE, personal Netscape WebMail account today at
http://home.netscape.com/webmail
Sign In or Register to comment.