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.

Tuesday, January 8, 2008

Re: [oopic] Program Resetting Upon Completion of Stepper Motor Script

When connecting any electromechanical devices (relays, motors etc.) to a circuit it is always a good bet that they will generate spikes and noise back into the circuit driving them. The best bet is to use a separate power supply. You will still have noise feeding back on the control pin to the microprocessor. It is best to make sure that you use the proper bypass capacitors to help filter the noise out. I believe most relay circuits also employ reverse diodes to shunt any reverse spike voltages.

Take a look at the following article for a good explanation of this.

http://www.seattlerobotics.org/encoder/jun97/basics.html

Hop this is of some help, Wayne..

ooPIC Tech Support <dennis.clark@oopic.com> wrote: It sounds like as soon as you turn things on your power bus tanks and
the ooPIC resets, which turns the power off allowing the ooPIC to turn
back on. Are you running the motor on the same power supply as the
ooPIC logic?

DLC

turgrid wrote:
> Hello,
>
> I am working with oopic-r c1.x+ and compiler 6.1.1. The h-bridge
> we're using is the L298 and is wired correctly as per the data sheet
> with ground and +5v for the oopic and the L298 both coming from the
> same battery source. The following snippet of code is
> looping--resetting the oopic upon execution of the last line. The
> behavior happens during similar scripts as well.
>
> code:
>
> oStepper stepper = New oStepper;
>
> Void Main(Void) {
> ooPIC.Delay = 500;
> stepper.IOPack = 3;
> stepper.Phasing = 1;
> stepper.Mode = 0;
> stepper.Rate = 124;
> stepper.Value = 800;
>
> stepper.Operate = 1
> }
>
> In this sample case, the stepper travels 800 steps and restarts and
> travels another 800 steps and restarts, etc.
>
> Why is it doing this and how can I stop it from resetting? Thanks in
> advance.
>
>
>
>
>
>
> Yahoo! Groups Links
>
>
>
>

--
------------------------------------------------------
Dennis Clark ooPIC Tech Support
www.oopic.com

------------------------------------------------------




---------------------------------
Never miss a thing. Make Yahoo your homepage.

[Non-text portions of this message have been removed]


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: