>
>
> Beats me! For V6 and an OOPic II+ (B2.2+) the following code works
> fine:
>
> ' Code for V6 of compiler
>
> Dim BLINK As New oEvent
> Dim WIRE As New oWire
> Dim LED As New oDIO1
>
> Sub Main()
> LED.IOLine = 7
> LED.Direction = cvOutput
> WIRE.Input.Link(ooPIC.Hz1)
> WIRE.Output.Link(BLINK.Operate)
> WIRE.Operate = cvTrue
> End Sub
>
> Sub BLINK_Code()
> LED = cvOn
> ooPIC.Delay = 250
> LED = cvOff
> ooPIC.Delay = 250
> End Sub
>
> I had to change the IOLine, I have a permanent LED on IOLine 7 and
I
> got rid of the useless DO...LOOP construct.
>
> Pay heed to what Andrew said earlier, you don't want to hang around
> in an event handler. Toggle the LED, use a counter, anything
EXCEPT
> OOPic.Delay.
>
> The same code works in V5 if the OOPic.Delay values are set to 25.
>
> Richard
>
Richard,
Thanks for the reply.
In my response to Andrew I replaced the wordy handler with one that
simply toggles the led. I got the same response. It only works if I
call the handler as a subroutine first.
I am using ooPic III+ instead of II+ and C.1.1+ instead of B.2.2+.
IN another post Dennis suspects the C.1.1+ compiler.
By the way, thanks for pointing out that you don't need to keep the
main thread alive with an endless loop like you do in higher multi-
threaded environments. Good to know.
Thanks,
Dogulas
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/oopic/
<*> Your email settings:
Individual Email | Traditional
<*> To change settings online go to:
http://groups.yahoo.com/group/oopic/join
(Yahoo! ID required)
<*> To change settings via email:
mailto:oopic-digest@yahoogroups.com
mailto:oopic-fullfeatured@yahoogroups.com
<*> To unsubscribe from this group, send an email to:
oopic-unsubscribe@yahoogroups.com
<*> Your use of Yahoo! Groups is subject to:
No comments:
Post a Comment