Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Am I within my limits

Status
Not open for further replies.

dreamproject

New Member
Hi all,

. Just recieved my encoder from US Digital . But I guess i got pretty excited when ordering and screwed up . My encoder i just recieved is specified to have 2500 cycles per rev.

now my calculation yeilds.

. 2500 x 4 = 10000 pulses per rev

at 1000 rpm , i get 10000 x 1000 = 10000000 pulses / min

dividing that by 60 , i get 166666.66 pulses /sec

. or a pulse freq of 166.6 KHz.

The motion control IC LM629 requires the the encoder pulses remain at the input pins for a minimum of 8 clock periods.

running the IC at 6 Mhz , the max input frequency of the encoder pulses is 750 Khz.

I know , i'm safe here . But here's the catch. The 629's architecture is designed to give a 4x increase in position resoultion .

ref : page 2 (sec 2.2) of User Guide .

So ,

. Max rpm = L

. 2500 x 4 x 4 x L
------------------- = 750000 (750 Khz.)
. 60

. 750000 x 60
. L= -------------
. 40000

. yields , L = 1125 rpm

am i safe here ? (is the 750 Khz. capture rate irrespective of the 4x resolution increase). But then , in page 3 of the user guide , it is said that with a 1 Mhz. capture rate (8 Mhz. clock) , a 500 ppr encoder , the max motor speed can be 30000 rpm.

. 1 x 10e6 x 60
. L= ------------------- = 30000 rpm.
. 500 x 4

guess the reslution increase does apply.

Since this output would drive a steering column with 1:3 reduction . A speed of 900 rpm would produce 300 rpm on the steering shaft . This corresponds to 5 rev / sec. Assuming full lock-to- lock of 4 turns , means my steering would turn from full left to right in 1 sec or less .

Am I correct ?

Would i also get a positional accuracy of 360 / 40000 = 0.009 degrees ?

Is this realistically possible ? or are all my assumptions wrong ?. Can the resolution of the encoder be decreased with external circuitry , eg flip flops .

or am i on the right track needlessly worrying ?

Thanks for ur time n patience
 
2500 x 4 x 4 x L

your math is wrong. this chip cannot do miracles it can only detect maximum of 4 transitions of the quadrature encoder.
how it works:
PPR value is how many pulses per revolution you get from ONE channel.
if your encoder has 2500PPR it means that:
channel A will provide 2500 pulses per revolution and
channel B will provide 2500 pulses per revolution

the only trick is that the phases of the two signals are shifted.

if you take a closer look at ONE PERIOD of say channel A
(period in this case is one whole "1" and one whole "0" of the A channel)
and try to figure out how many UNIQUE states you can create
by combining this with signal from channel B, you will see only 4 states.
many encoder interfaces don't go this route, they simply count pulses
depeding on which channel leads at the moment. This chip does
extract all 4 states withing ONE encoder pulse.

So if your encoder has 2500 RPM, using this chip you can get
2500x4 = 10000 pulses per revolution - and that's it
(see quote, you ware multiplying this one more time by 4).

Datasheet says that max pulse rate is CLOCK/8.
with 8MHz clock, you can detect max 1000000 pulses (1MHz).

if you have encoder with 500 PPR, chip can resolve position up to
500x4=2000 pulses per revolution.

1MHz/2000PPR = 1000000 (pulse per sec) / 2000 (pulse per rev) =
500 Revolution per second.

there are 60 sec in a minute so we multiply this by 60 to convert
the value to RPM:
500 (rev per second) = 500 (rev per 1/60 min) =500x60=30000RPM
so the datasheet example is correct.
 
in your case for 2500PPR encoder (interesting resolution, are you sure
it's 2500?) and using 6MHz chip (max 750kHz input freq.) you can go as fast as
60x750000/(4x2500)=4500RPM or 75 rev per second.
most stearing columns are designed for max about 3 rev end to end
meaning that you would have to make end to end turn in less than 40ms
to exceed the max frequency of the chip if there is 1:1 gear ratio.
if you try something like this, i bet you will brake the car's steering system.
the fastest reasonable speed for this should be about 2 seconds not 40ms
(did you ever try to turn the steering wheel by hand and check how fast you can do it?).
with 2500PPR encoder and total resolution extrapolated to 10000PPR
you can detect angle changes as small as 360deg/10000=0.036degree
(this is assuming 1:1 connection ratio).
If you recall the unit I made, it had encoder with 32767PPR. This value was
also extrapolated to 32768x4=131072 PPR but there was gear ratio of
30:1 as well so teoretical precision of the unit was 3932160 PPR or
0.00009155 degree. actually it was a bit worse due mechanical flexing of
the material, steering shaft contact play, thermal changes, use of gearbox
(even though it's expenvice high quality "zero play") etc.
I've limited readout to 0.01 deg resolution so I don't have to answer
questions like how precise it really is...
 
clarification

panic ,

Actually the encoder output is 2500 cpr (cycles per revolution). which i believe (correct me if i'm wrong ) is 10000 ppr coz one cycle is 4 pulses (transitions). That is why in my math i multiplied 2500 x 4 to get pulses per revolution and again by 4 because of resolution gain of the lm629 . Does this mean my encoder specs are right ? .By the way panic , were u also using an lm629 ?.

I want to use a PC's parallel port to control the 629's. But the 629 requires more i/o lines than the port can provide . Can i use an intermediate device like the 8255 to communicate . Also another blunder . I ordered the encoders with a 1/4 inch through shaft hole (which i realize is way too small :cry: ) . If I connect thro' this shaft hole (1/4" aluminium shaft ) to a gear with an ample sleeve length (overlapping most of the free shaft length) , will it hold without failure or do i have to shift to mild steel . shaft length is about 1" (between encoder and gear face , but a sleeve covers this 1")

Thanks for ur input
 
the two 4's are the same thing, you cannot use it twice.
no, i wasn't making electronics for this projects. it was for work and
it was just two units andvery short time to make it work so
i simply used PLC with motion controller and industrial servo.
if i was making my own vechicle for darpa contest i would
probably stay with industrial components as well because to
show the principle it doesn't pay to develop own product.
if i was making prototype for something that is going to be
produced in large quantities and i had time to play with it,
i would look into MCU or DSP to do the job.
 
if you need to lower recolution of encoders, you can use dividers (counters) in either hardware or software.
 
Re: clarification

dreamproject said:
I want to use a PC's parallel port to control the 629's. But the 629 requires more i/o lines than the port can provide . Can i use an intermediate device like the 8255 to communicate . Also another blunder . I ordered the encoders with a 1/4 inch through shaft hole (which i realize is way too small :cry: ) . If I connect thro' this shaft hole (1/4" aluminium shaft ) to a gear with an ample sleeve length (overlapping most of the free shaft length) , will it hold without failure or do i have to shift to mild steel . shaft length is about 1" (between encoder and gear face , but a sleeve covers this 1")

Thanks for ur input


can somebody please answer this though it isn't particularly suited to this forum ,
Thanks/
 
search for 'encoder coupling'... google will have tons of info (search for images to see arangements). we always mount encoders with flexible coupling so that shocks or vibrations are not transfered to sensitive device.
they also take care of misalignment.
 
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top