## Encoder Ratio

Moderators: TomKerekes, dynomotion

CNC_Machines
Posts: 30
Joined: Fri Apr 27, 2018 10:43 pm

### Encoder Ratio

Greetings,

I want to be sure I understand how the input/output gain works. To ensure I am setting up correctly.

Hardware:
1. KStep - 16X Microstepping
2. Oriental Motor 0.9 Step Angle Stepper
3. Encoder - US Digital 5000 count quadrature

I am getting confused with "Inv Dist Per Cycle", I have always set that to 1. Is this how the math works?

Cycles/Rotation = 400/4 = 100
Micro Steps / Rotation = 16x100 = 1600

Encoder / Motor = 1600/5000 = 3.125

So the value I would enter into the "Input Gain" field would be 3.125?

Or would it be this way?

Steps / Rotation = 400 x 16 = 6400
Encoder Pulses / Rotation = 5000 x 4 = 20000

Ratio = 20000/6400 = 3.125

They both end up being the same value. I am just wondering which is the correct way to think about it?

Thanks,

Scott

TomKerekes
Posts: 793
Joined: Mon Dec 04, 2017 1:49 am

### Re: Encoder Ratio

Hi Scott,
I am getting confused with "Inv Dist Per Cycle", I have always set that to 1. Is this how the math works?
Inv Dist Per Cycle doesn't apply to Step/Dir Drives like KStep.

Micro Steps / Rotation = 16x100 = 1600
No.
400 full steps/rev x 16 uSteps/Full Step = 6400 uSteps/rev

Encoder Pulses / Rotation = 5000 x 4 = 20000
This depends on whether the number 5000 is quadrature counts/rev or Pulses or cycles per rev. You initially state it is quadrature count but then treat it as cycles.

Assuming the 20000 quadrature counts is correct then an input Gain of:
6400/20000 = 0.32

Its easy to figure out these things yourself. Try a number and if it is off by a factor of X change it.
Regards,

Tom Kerekes
Dynomotion, Inc.