EmbeddedRelated.com
Forums

resolution for PWM driven servo on HCS12

Started by Steve Auch-Schwelk September 30, 2004
This sounds like a homework project.
There are app notes and code example on using the PWM module
on the Freescale web site.
In other words, make SOME effort to find out what you
need to do before coming here.

Robert

John Tobias wrote:

> Mike,
>
> I don't know how to convert the 1.5ms and 0.9-2.2ms in the actual value and
> which registers of PWM should I put that value to run in one direction and
> other way around.
> Could you pls send me some instructions and how to get the relative value of
> 1.5, 0.9-2.2ms pulse width.
>
> Thanks,





This question is more-or-less where this thread started. Read the
whole thread from the beginning again, in conjunction with the PWM
data sheet, and you should have the values that you need.

Steve

--- In , "John Tobias" <johnjohntobias@m...>
wrote:
> Mike,
>
> I don't know how to convert the 1.5ms and 0.9-2.2ms in the actual
value and
> which registers of PWM should I put that value to run in one
direction and
> other way around.
> Could you pls send me some instructions and how to get the relative
value of
> 1.5, 0.9-2.2ms pulse width.
>
> Thanks,
>
> John
>
> >From: "Mike" <mike@b...>
> >Reply-To:
> >To: <>
> >Subject: Re: [68HC12] Re: resolution for PWM driven servo on HCS12
> >Date: Tue, 12 Oct 2004 12:39:17 +0200
> >
>
> _________________________________________________________________
> Check out Election 2004 for up-to-date election news, plus voter
tools and
> more! http://special.msn.com/msn/election2004.armx >



John,

It sounds like you are using an RC servo in which the servo operation
has been defeated (by a modification) so that it can be used as a gear
motor for amateur robotics. Is that the case?

(An example of such a modification is
<URL: http://www.seattlerobotics.org/guide/servohack.html >.)

It might be worth noting that if the servo has been modified in such
a way, it's not a servo any more; it's just a gear motor. A servo, by
definition, is controlled by a feedback loop. The modification disables
that feedback loop.

Stephen

--
Stephen Trier
Technical Development Lab
Cleveland FES Center


Stephen,

Thanks for your input but I've done that before to disable the feedback loop
and it works fine with my program and my motor. But in my last attempt to
replace the potentiometer I've destroyed 2 of my servos for unknown reason
maybe I overheat the Iron to remove the soldered potentiometer in the
circuit to replace a resistors then damaged one of the parts of the circuit.
(My soldering experience is not good when it comes into a small parts of the
circuit so that's why I am little bit afraid to do it again in my 6 servos).

So I followed the instructions to these link
http://www.junun.org/MarkIII/Manual/Appendix.jsp#Servos
so no need to use soldering Iron to replace any parts of the circuit but I
have to calibrate the servo to stay in the middle when I feed 1.5ms. Then, I
could run the servo in either clockwise or counter clockwise if I will feed
it <1.5ms or >1.5ms pulse. But, my problem is I don't have experience,
proper education on hcs12, how to get the ms pulse...

Well, I'll do my effort to have a proper education, experience on the hcs12
controller. So I will not disturbing anybody especially some of the
conservatives in the list... :)

Thanks again,
-John

>From: "Stephen Trier" <>
>Reply-To:
>To:
>Subject: Re: [68HC12] Re: resolution for PWM driven servo on HCS12
>Date: Thu, 14 Oct 2004 12:14:39 -0400
>

_________________________________________________________________
Dont just search. Find. Check out the new MSN Search!
http://search.msn.click-url.com/go/onm00200636ave/direct/01/