Encoder Scale Problem - Reporting Wrong RPM

More
10 years 3 months ago #77837 by russtuff

andypugh wrote: Can you swap to a 1:1 ratio? Mesa (or Pico) hardware would still be able to cope.

Yeah I could, but I want the higher speed. As is I can do about 7200rpm on my mill but I want to go even faster.

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

More
10 years 3 months ago #77838 by andypugh

rusmannx wrote: My encoder is quadrature, but it looks like I'm stuck with only using index until I can divide my resolution down. Or get another encoder which I prefer not to do.


I may have been unclear.

For threading and rigid tapping LinuxCNC requires a once-per-SPINDLE-rev pulse to the encoder counter. This is used to start the threading pass so that subsequent passes all line up.

If your index is from an encoder that is geared to the spindle then the index will not align with the work (in a lathe) or the tap (in a rigid-tapping mill). This might not matter to you on your machine, of course.

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

More
10 years 3 months ago - 10 years 3 months ago #77839 by PCW
Unfortunately index wont work with the software encoder either (same problem: too narrow a pulse to sample reliably with software)

One solution would be to divide the count and then use a Proximity switch on the spindle for index
Note that you need A/B and index for rigid tapping so a simple divider wont work
Last edit: 10 years 3 months ago by PCW.

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

More
10 years 3 months ago #77840 by russtuff

andypugh wrote: I may have been unclear.

For threading and rigid tapping LinuxCNC requires a once-per-SPINDLE-rev pulse to the encoder counter. This is used to start the threading pass so that subsequent passes all line up.

If your index is from an encoder that is geared to the spindle then the index will not align with the work (in a lathe) or the tap (in a rigid-tapping mill). This might not matter to you on your machine, of course.


I understand, and have that working on my lathe right now. The code segment I posted above was adapted from my lathe, and I see I have made an error. My lathe encoder is on the spindle and on my mill where I am having the trouble the encoder is on the motor. I seem to be scaling 'A' but not 'Z'.

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

More
10 years 3 months ago #77854 by russtuff
I'm having trouble still. I can't get the index pulse alone to report to pyVCP, it seems to only want to report phase-a.
Any idea what I'm doing wrong?
My preference is to only post the index pulse to pyVCP so I don't have to count phase-a at all (due to running way over 50khz).
Code:
# 1 SPINDLE INDEX PPR BUT WITH BELT DRIVE IT'S .54 PPR setp encoder.0.position-scale .54 setp encoder.0.counter-mode 1 net spindle-position encoder.0.position => motion.spindle-revs net spindle-velocity encoder.0.velocity => motion.spindle-speed-in net spindle-index-enable encoder.0.index-enable <=> motion.spindle-index-enable net spindle-phase-a encoder.0.phase-A # net spindle-phase-b encoder.0.phase-B net spindle-index encoder.0.phase-Z # THESE ARE THE PHASE-A PHASE-Z PINS net spindle-phase-a <= parport.0.pin-10-in net spindle-index <= parport.0.pin-11-in # THIS TIES PHASE-A TO INDEX FOR SINGLE SENSOR SETUP # PHASE-A IS REPORTED EVEN THOUGH I'M REFERENCING PIN-11 net encoder-output parport.0.pin-11-in => encoder.0.phase-Z encoder.0.phase-A

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

More
10 years 3 months ago #77856 by PCW
As I mentioned before, the software encoder will not reliably detect the index of a high resolution encoder
its really the same problem as counting the "A" line, the pulse is to short to detect reliably at the base thread sampling rate

Some companies make pulse stretchers (one-shots) to solve this issue

Also a index that not on the spindle itself or geared 1:1 to the spindle cannot be used for threading
or rigid tapping (and rigid tapping needs a full 3 wire encoder)

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

Time to create page: 0.306 seconds
Powered by Kunena Forum