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.

Wednesday, February 20, 2008

[oopic] trying to link a oKnob to a oPWM

Hello,

I hope you can help me im trying to link a 0 to 5 Volts analoug input
to a PWM so when no voltage comes in the pulsing is off and when a
voltage is introduced that it switches the PWM
This is the code i have but it does not work.


Dim A As New oPWM
Dim B As New oKnob

Dim bus As New oBus

Sub Main()


ooPIC.Delay = 500

A.IOLine = 17
A.Operate = 1
B.IOLine = 1


B = cvInput

bus.Input.Link(B)
bus.Output.Link(A.Value)
bus.Operate = cvTrue

Do
A.Value = B.Position/2
Loop

End Sub


Thanks for your help in advance

Fred


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: