Demystifying Spindle Sensors

More
11 Mar 2016 15:47 #71416 by Trispectiv
After I converted the Orac and I was trying to use it with Mach3, I was checking the inverter frequency against the spindle RPM with a tachometer (a piece of reflective was already on the backplate when I got the lathe). Now with LinuxCNC I was just checking against the know VFD frequency and expecting the known RPM. For instance, I only get up to around 1500 RPM hen I max the VFD frequency, which should mean 2000 RPM.

Please Log in or Create an account to join the conversation.

More
11 Mar 2016 16:17 #71419 by andypugh
I assume you have set the encoder scaling correctly, and have enabled counter-mode?

The encoder velocity output is in revs per second, with a factor of 60 there and a factor of 4 for quadrature you get an overall factor of 133.333. Is that what you are seeing?

Please Log in or Create an account to join the conversation.

More
11 Mar 2016 16:30 #71422 by Trispectiv
Well, for someone coming from Mach3 your post is.. complex :)

All I did is follow the example here:
linuxcnc.org/docs/2.4/html/examples_spindle.html
for setting my VFD PWM 0-10V signal and the encoder at the back of the spindle.

I see no counter-mode related settings in that tutorial, so I definitely did not add such a thing. I will look into that.
Same for scaling, I don't even know what that is about at this moment.

One other thing, that panel displays random erroneous RPM even when idle. Like 0-500 random numbers, even if the spindle is still.

Should I take it the software thinks I am doing quadrature while the machine is A Z only?

Please Log in or Create an account to join the conversation.

More
11 Mar 2016 16:33 - 11 Mar 2016 16:49 #71424 by cncbasher
i'd recon . this is mostly because of not selecting counter mode , so give it a go . and report back
see if you have this for counter-mode
setp encoder.0.counter-mode 1
( or in other words set encoder 0 counter-mode true)

i found setting the true spindle rpm equaling the shown spindle speed , and disregarding what the vfd was telling me , gave better results . and testing this at different speeds across the range .
so i.e s500 did give me 500 rpm both on my tacho and the shown spindle rpm
Last edit: 11 Mar 2016 16:49 by cncbasher.

Please Log in or Create an account to join the conversation.

More
11 Mar 2016 16:39 #71428 by andypugh

linuxcnc.org/docs/2.4/html/examples_spindle.html


Section 2.1 contains
setp encoder.0.position-scale 100

You need that to be 50, and then add

setp encoder.0.counter-mode 1

But be aware that the output is in revs-per-second.

Please Log in or Create an account to join the conversation.

More
11 Mar 2016 16:50 #71431 by Trispectiv
Tough one, I checked the HAL file and I have both settings there.
50.0000 for encoder scale and mode 1
They were set by the wizard, I remember looking at the file after that and seeing that very floating 50.00000.

I guess it is one of those points were I have to attach my HAL file, huh?
(that particular box is not networked yet)

Please Log in or Create an account to join the conversation.

More
11 Mar 2016 17:03 #71434 by andypugh
One other way to measure spindle speed.

Put a long length of threaded rod in the spindle with a nut on it.
Using a stopwatch time how long it takes the nut to travel a set distance when you hold it and stop it turning.

That gives you an rpm measurement based on fundamental physical quantities (time and length)

Please Log in or Create an account to join the conversation.

Moderators: piasdom
Time to create page: 0.138 seconds
Powered by Kunena Forum