This Forum is Dedicated For all The Object Oriented PIC Lovers .......... The concept behind OOPic is straight forward. Use preprogrammed multitasking Objects from a library of highly optimized Objects to do all the work of interacting with the hardware. Then write small scripts in Basic, C, or Java syntax styles to control the Objects. During operation, the Objects run continuously and simultaneously in the background while the scripts run in the foreground telling the objects what to do.

Friday, December 21, 2007

[oopic] Re: New to OOPIC Event Programming..pls help..

And it is written for V5 of the IDE/compiler...

--- In oopic@yahoogroups.com, "rtstofer" <rstofer@...> wrote:
>
> This code is known to work:
>
> Dim LED as new oDIO1
> Dim Button as new oDIO1
> Dim Wire as new oWire
> Dim Evt as new oEvent
>
> Sub Main()
>
> OOPic.Delay = 500 ' always delay at startup
>
> OOPIC.Node = 5 ' for debugging
> OOPIC.PullUp = cvOn ' pull up IOLines 8..15 (inputs)
>
> LED.IOLine = 7
> LED.Direction = cvOutput
>
> Button.IOLine = 8 ' use IOLines 8..15 as inputs (pull-ups)
> Button.Direction = cvInput
>
> Wire.Input.Link(Button)
> Wire.Output.Link(Evt.Operate)
> Wire.Operate = cvTrue
>
> end sub
>
> sub Evt_Code()
>
> LED = cvOn
> OOPic.Delay = 100
> LED = cvOff
>
> End Sub
>
> It has 3 drawbacks: it is for the S board, it is written in Basic
and
> it doesn't use a tone.
>
> It has only 1 positive attribute: it works.
>
> Richard
>



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:

http://docs.yahoo.com/info/terms/

No comments: