1

**General Mach Discussion / Re: spindle calibration**

« **on:**January 16, 2017, 02:07:38 PM »

Sorted! almost as soon as I made my last post, I found the official instruction:

From here http://www.machsupport.com/forum/index.php?topic=30685.0;wap2

I followed it exactly and now have an accurate spindle running at variable speeds again

*"Hi Guys:*

This proceedure is not in the Doc's, the reason being its likely to change at some point. What I really

woudl liek to know i show linear YOUR system is using this as the speed setting for it. The setitngs are

highly misunderstood, and many run a linearity run when it isnt necessary, and it badly affects their results.

VFD:

A VFD takes an output from Mach3 to control its speed. Initially, Mach3 supposes a 1:1 linearty of the result,

which is pretty close to most vfd's in reality, they have allot of electronics in them to do this on their own. BUT

if the output is not right or not linear as output , then the result is obviously goign to be off. So the

following steps will do it right, and Id be very interested in any posts of the results.

Step 1)

Delete the linearity.dat file in your mach3 installation. The system will recreate it on next startup with 1:1

as the table. Also set the config/pulleys to pulley number 1, with a max speed of 1000, and a min speed of 0.

This means the range of commandis now S0 to S1000. ( Doesnt matter what the real speed of your spindle is, use

these numbers to start with.

Step 2)

We now need to know the max speed of the VFD's input, this is the place most get it wrong. VFDs respond,

as do frequency/analogue convertors to only a specific range typically of input vs output. SO lets figure out the top

speed expectation of a VFD..

In config/motor tuning, set the spindle axis steps/unit to 60. This means the velocity slider will now display in hz..

What we need to find out here is both the max frequency of the spindle and the clip frequency of the VFD.

To do this we now set the velocity slider to max. Youll notice it now reads the kernal frequency your using. 25000

in 25Khz for example. Apply the settings and exit the dialog.

- Turn on the spindle and set a S1000 as the speed. Measure the true spindle speed.

- Set a Speed of S950.. then S900, then S850..etc until the spindle actually slows. What will

happen on many systems is you will still get maximum speed until you lower the speed to some number..say S750..

or it may happen that the speed instantly start to slow slightly at S950..

Whenever it occurs that the spindle starts to run slower, note the S speed just prior to the slowdown.

For example, at S1000 I get a true RPM of 3000. SO the following occurs as I do the series..

S1000 -- 3324RPM

S950 --- 3324 RPM

S900 -- 3324 RPM

S850 -- 3156 RPM

SO the magic number here is S900, the last value where the spindle was at max RPM.

This shows us that using 90% of the max frequency tells the VFD to go full out.

So in motor tuning, set the velocity slider down to 90% of the max setting or current setting in Hz. ( Speed / 10 in % ).

Step 3)

Command a S1000 again, the max speed should still result. ( For higher accuracy and linearity you can repeat step 2

and vary the velocity slider to the % of the current slider position if you wish, the more you do step 2, the less change you

shoudl have to make each time. For example if it was at 21600 at this point , another run through step 2 might make you change it

to 21250.. each time the change will be less and less. )

Note the current S1000 speed and enter it in the config/pulleys as the max speed, leave the min speed to 0.

Step 4)

Turn on the spindle and seta speed of S1 . Note the speed you get and eneter it in the config/pulleys as minimum speed

for that pulley.

OK, so now we have properly set the VFD clip frequency, and the pulley min and max values. They now take into accoutn the expectation

of the VFD, and the resultant speeds at low and high end to be expected. The linearity is now considered to be 1:1 for that VFD/freq->analogue conversion.

If you have done this, please post a report of the following run..

Take max speed and divide by 10. Say max speed in pulley max is 2500, so the increment will be 250. Post for me 10 speeds..

S1 actual RPM:

S250 ""

S500 ""

S750 ""

S1000 ""

..etc..

Using this proceedure takes allot fo the guesswork out of setting up a spindle, forces you to take into

account the VFD clipping limits, forces the setup to show you the outgoing frequency in hz of the output and should

show us a quantifiable spindle vs command relationship as a result.

Take note, this is for step output spindles, PWM is another matter, this will still work, but since the number of steps

in speed is dependent on the PWM settings, the end results may be off in a stepwie fashion if using PWM.

Non-linearity can coem from several directions, frequency->analogue conversion can be way off a linear scale,

most vfd's will be pretty close to linear if clipping is taken into accoutn as above. For my part Id appreciate any feedback

on the speed test results after a fresh setup of spindle speed using the above proceedure. Some may find their max speed

is now higher using this technique, others will find a much more linear resultant spindle speed, it shoudlnt negatively affect

anyone if done right.

Thanks, and good luck..

Art"This proceedure is not in the Doc's, the reason being its likely to change at some point. What I really

woudl liek to know i show linear YOUR system is using this as the speed setting for it. The setitngs are

highly misunderstood, and many run a linearity run when it isnt necessary, and it badly affects their results.

VFD:

A VFD takes an output from Mach3 to control its speed. Initially, Mach3 supposes a 1:1 linearty of the result,

which is pretty close to most vfd's in reality, they have allot of electronics in them to do this on their own. BUT

if the output is not right or not linear as output , then the result is obviously goign to be off. So the

following steps will do it right, and Id be very interested in any posts of the results.

Step 1)

Delete the linearity.dat file in your mach3 installation. The system will recreate it on next startup with 1:1

as the table. Also set the config/pulleys to pulley number 1, with a max speed of 1000, and a min speed of 0.

This means the range of commandis now S0 to S1000. ( Doesnt matter what the real speed of your spindle is, use

these numbers to start with.

Step 2)

We now need to know the max speed of the VFD's input, this is the place most get it wrong. VFDs respond,

as do frequency/analogue convertors to only a specific range typically of input vs output. SO lets figure out the top

speed expectation of a VFD..

In config/motor tuning, set the spindle axis steps/unit to 60. This means the velocity slider will now display in hz..

What we need to find out here is both the max frequency of the spindle and the clip frequency of the VFD.

To do this we now set the velocity slider to max. Youll notice it now reads the kernal frequency your using. 25000

in 25Khz for example. Apply the settings and exit the dialog.

- Turn on the spindle and set a S1000 as the speed. Measure the true spindle speed.

- Set a Speed of S950.. then S900, then S850..etc until the spindle actually slows. What will

happen on many systems is you will still get maximum speed until you lower the speed to some number..say S750..

or it may happen that the speed instantly start to slow slightly at S950..

Whenever it occurs that the spindle starts to run slower, note the S speed just prior to the slowdown.

For example, at S1000 I get a true RPM of 3000. SO the following occurs as I do the series..

S1000 -- 3324RPM

S950 --- 3324 RPM

S900 -- 3324 RPM

S850 -- 3156 RPM

SO the magic number here is S900, the last value where the spindle was at max RPM.

This shows us that using 90% of the max frequency tells the VFD to go full out.

So in motor tuning, set the velocity slider down to 90% of the max setting or current setting in Hz. ( Speed / 10 in % ).

Step 3)

Command a S1000 again, the max speed should still result. ( For higher accuracy and linearity you can repeat step 2

and vary the velocity slider to the % of the current slider position if you wish, the more you do step 2, the less change you

shoudl have to make each time. For example if it was at 21600 at this point , another run through step 2 might make you change it

to 21250.. each time the change will be less and less. )

Note the current S1000 speed and enter it in the config/pulleys as the max speed, leave the min speed to 0.

Step 4)

Turn on the spindle and seta speed of S1 . Note the speed you get and eneter it in the config/pulleys as minimum speed

for that pulley.

OK, so now we have properly set the VFD clip frequency, and the pulley min and max values. They now take into accoutn the expectation

of the VFD, and the resultant speeds at low and high end to be expected. The linearity is now considered to be 1:1 for that VFD/freq->analogue conversion.

If you have done this, please post a report of the following run..

Take max speed and divide by 10. Say max speed in pulley max is 2500, so the increment will be 250. Post for me 10 speeds..

S1 actual RPM:

S250 ""

S500 ""

S750 ""

S1000 ""

..etc..

Using this proceedure takes allot fo the guesswork out of setting up a spindle, forces you to take into

account the VFD clipping limits, forces the setup to show you the outgoing frequency in hz of the output and should

show us a quantifiable spindle vs command relationship as a result.

Take note, this is for step output spindles, PWM is another matter, this will still work, but since the number of steps

in speed is dependent on the PWM settings, the end results may be off in a stepwie fashion if using PWM.

Non-linearity can coem from several directions, frequency->analogue conversion can be way off a linear scale,

most vfd's will be pretty close to linear if clipping is taken into accoutn as above. For my part Id appreciate any feedback

on the speed test results after a fresh setup of spindle speed using the above proceedure. Some may find their max speed

is now higher using this technique, others will find a much more linear resultant spindle speed, it shoudlnt negatively affect

anyone if done right.

Thanks, and good luck..

Art"

From here http://www.machsupport.com/forum/index.php?topic=30685.0;wap2

I followed it exactly and now have an accurate spindle running at variable speeds again