Searching \ for 'Use of PIC for RC-Elektronic Speed Controller' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/microchip/devices.htm?key=pic
Search entire site for: 'Use of PIC for RC-Elektronic Speed Controller'.

Truncated match.
PICList Thread
'Use of PIC for RC-Elektronic Speed Controller'
1998\03\15@085936 by S. Baglatzis

flavicon
face
I want to build an electronic speed controller with pic 16c84 .
The PIC has to generate A PWM and to measure an impuls coming from
receiver.
The PWM should be 3 KHz and the Puls is 1ms to 2 ms long every 20 ms.
I use TMR0 for PWM. How can I measure the puls with minor error so i can
calculate
the right PWM.


Has  someone  software to realize the PWM and measure the puls coming
from receiver ?


Stephanos Baglatzis from Germany
spam_OUTSBAGLATZISTakeThisOuTspammail.online-club.de

1998\03\15@113618 by Nicholas Irias

flavicon
face
Check out http://professionals.com/~cmcmanis//robotics/servo.html

----------
> From: S. Baglatzis <.....SBaglatzisKILLspamspam@spam@MAIL.ONLINE-CLUB.DE>
> To: PICLISTspamKILLspamMITVMA.MIT.EDU
> Subject: Use of PIC for RC-Elektronic Speed Controller
> Date: Sunday, March 15, 1998 5:46 AM
>
> I want to build an electronic speed controller with pic 16c84 .
> The PIC has to generate A PWM and to measure an impuls coming from
> receiver.
> The PWM should be 3 KHz and the Puls is 1ms to 2 ms long every 20 ms.
> I use TMR0 for PWM. How can I measure the puls with minor error so i can
> calculate
> the right PWM.
>
>
> Has  someone  software to realize the PWM and measure the puls coming
> from receiver ?
>
>
> Stephanos Baglatzis from Germany
> .....SBAGLATZISKILLspamspam.....mail.online-club.de

1998\03\15@145005 by Gavin Jackson

flavicon
face
Hi Stephanos

I can't help with RC part, but I have recently
done PWM with a 16C84. I used four 8-bit
registers and just shifted them out an I/O pin.

For your application just one 8bit register will
be fine and if you set the TMR0 to generate an
interrupt every 41uS and then shift a bit out,
you'll have your 3KHz.

e.g.. 0000 0001 will be your slowest speed,
0000 1111 will be half speed and 0111 1111
will be the fastest although you may want
1111 1111 as the fastest.

Regards

Gavin
--------------------------
EraseMEvulcanspam_OUTspamTakeThisOuTihug.co.nz
www.geocities.com/TheTropics/Cabana/2625
--------------------------

1998\03\16@065016 by Goeran Stigler

flavicon
face
S. Baglatzis wrote:
>I want to build an electronic speed controller with pic 16c84 .
>The PIC has to generate A PWM and to measure an impuls coming from

I built an airplane ESC from a kit. Works well, a little expensive.

If you _really_ want to build one to _really_ learn how they work, fine. If
you want to save money, I'd say forget it. After hearing the discussions on
ESC in the EFLIGHT maillist, I know that it'll take me years, if ever, to
design a reliable and safe ESC. Overcurrent protection, safe start
sequence, input glitch filtering.... Believe me, you need those features.

If you want something to start with, Elektor had a 84-based (I believe) car
ESC design about two years ago. You have to buy a preprogrammed chip
though, since only schematics and theory was published.

Regards,


Goeran Stigler                      http://www.pe.chalmers.se/people/ghost/

1998\03\16@125716 by Brian Scearce

picon face
"S. Baglatzis" <SBaglatzisspamspam_OUTMAIL.ONLINE-CLUB.DE> writes:
> I want to build an electronic speed controller with pic 16c84 .
> The PIC has to generate A PWM and to measure an impuls coming from
> receiver.

I took the easy way out with this problem: I used a 16C63, and
measured the incoming pulse widths in an ISR with the capture
modules.  The outgoing pulses are generated with straightforward
code with interrupts disabled.  I might miss an incoming pulse
while I generate the outgoing pulses, but for my application,
missing one pulse doesn't matter.

The drawback to this scheme is that I can only handle two channels,
since the 16C63 only has two capture/compare modules.  If I want
more, I'll have to either multiplex the capture/compare pins (and
reduce my sampling rate), or stick in another 16C63 and SPI them
together.

Brian

1998\03\17@065419 by Andy Kunz

flavicon
face
>The drawback to this scheme is that I can only handle two channels,
>since the 16C63 only has two capture/compare modules.  If I want

If you don't mind losing a _little_ resolution, try having RB pins serve as
inputs, with software timer (perhaps running of TMR0) to get the width.

You can also set up timers of this sort to process outputs.

You get a little jitter, but it works nicely otherwise.  NOTE:  You need a
minimum input and output pulse width to make sure it all works! (don't ask
why

:-(

Andy

==================================================================
                    Andy Kunz - Montana Design
         Go fast, turn right, and keep the wet side down!
==================================================================

1998\03\17@142830 by Mike Keitz

picon face
On Tue, 17 Mar 1998 06:50:30 -0500 Andy Kunz <@spam@montanaKILLspamspamFAST.NET> writes:
>>The drawback to this scheme is that I can only handle two channels,
>>since the 16C63 only has two capture/compare modules.  If I want

I don't know about PCM, but the analog R-C receivers only output one
pulse at a time, since they are transmitted in sequence over the radio.
So you could OR all the pulses together into one capture timer, and also
bring them seperately to inputs so the channel that is currently being
timed could be identified.

The same process could be used to output multiple pulses, use one compare
timer with a demultiplexer at the output to send the pulse to one servo
at a time.


_____________________________________________________________________
You don't need to buy Internet access to use free Internet e-mail.
Get completely free e-mail from Juno at http://www.juno.com
Or call Juno at (800) 654-JUNO [654-5866]

More... (looser matching)
- Last day of these posts
- In 1998 , 1999 only
- Today
- New search...