Lathe threading random start

More
30 Aug 2022 16:55 #250789 by DEVILHUNTER
I'm retrofitting my manual lathe with LinuxCNC and I'm stuck with the threading. It's wierd because I have used the same computer and encoder to rigid tap in my mill without problems.

When I perform a G76 cycle, the machine does all it should do, but the threads looks weird, like each pass started in a random position. At first, after configuring the encoder in stepconfig I found the Index was inverted and that made sense, but after inverting the signal it still looked weird.

Got a couple of parts that looked like buttress thread and thought that I may have the compound angle parameter wrong (Q), since I was doing OD thread with an ID tool going backwards. But still did not work either with Q30, Q0 or Q-30. Found somebody with a similar looking issue:

www.forum.linuxcnc.org/38-general-linuxc...ions/38627-g76-issue

Then added the "near" component to the spindle speed to activate the index-enable. Althought it shoulnd't be needed as the threading was starting, I got even more random thread starts.

I'm using LinuxCNC 2.7.14 on parallel port, not ideal but it's fast enough (400rpm at 360ppr) as I have not been able to update this old PC to a newer version. Have adjusted the encoder pots to get the cleanest A/B/Z signals and they look really great on the halscope, plus the pitch is perfect.

Don't think is backlash either, as it's always going in the same direction and would be compensated at thread start. Have also checked for noise in the Index signal, but looked perfect in halscope.

My last bullet will be to do try a "threading without index" component.

This is my HAL file:
Warning: Spoiler!


Thanks to everyone!

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

More
30 Aug 2022 22:00 #250803 by robh
Replied by robh on topic Lathe threading random start
hi, i had this same problem before and it was the encoder shaft screw had come loose on flex coupling on the spindle .. so i would check the encoder couplers

thread at one spindle speed, then speed it up and see what happens if it starts to cut in a different place then you know its a encoder issue, just you have to figure out if its mechanical or electrical, and id guess more mechanical

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

More
31 Aug 2022 16:50 #250872 by DEVILHUNTER
Thanks Robh. I don't think is something mechanical as the encoder and spindle pulleys are press fitted. Anyways checked them and there is no slipage.

Decided to do some more checking. Put an indicator on the chuck jaw and rotated the spindle by hand one turn, then other turn backwards, until encoder.rawcounts in halmeter went back to 0. The indicator shows that did not went back to original position maybe by a couple of degrees. Encoder is 360ppr in quadrature so the error is bigger than the resolution, seems that I'm loosing a few counts.

I have tried duplicatin the base-period just in case I had some unexpected high jitter, also deleted the parport reset time, but again same result.

Funny thing is that it seems to loose steps always in the same direction, no matter what direction I rotate the spindle first. Anyways this error is small and does not fit the random start I'm getting, at least on the start of the thread.

I will check again the A/B sinals in halscope. Also will connect the encoder to the MESA 7i76e of my mill to discard problems either on the encoder or the lathe BOB.

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

More
04 Sep 2022 10:34 #251160 by DEVILHUNTER
Another test in halscope. All signal seems to be reliable, I don't see any missed ones. A/B channels are not exactly 50% but maybe 40/60. I don't see any missed pulse:

 

Also checked the halscope log. I can se how there is at least two readings per quadrature phase change so should be enough for LinuxCNC to read all encoder pulses.
Attachments:

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

More
04 Sep 2022 11:29 #251161 by scotth
Replied by scotth on topic Lathe threading random start
What about the marker pulse? Also, are you giving the thread enough lead in for a good sync?

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

More
06 Sep 2022 23:12 #251366 by andypugh
Is the index exactly 1:1 with the spindle?

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

More
09 Sep 2022 06:42 - 09 Sep 2022 07:59 #251535 by DEVILHUNTER
I think I'm giving enough room for other tasks. Have tested increasing the base thread to double without any change. The machine moves just right so the steps are generated right, and they have higher rate than encoder counts. Don't see any missed steps on them but haven't carefully checked. Did some threads again and the pitch was perfect, bot at 100 and 700rpm.

Both encoder and spindle pulleys are made from the same CAD file. Belt is HTD and the pulleys are press fitted, so the relation is 1:1 for sure. Also checked again in halscope the shape of the index signal and I see a clean signal, evenly spaced and without noise.

Connected the encoder to my 7i76e and checked the movement with the comparator against the chuck jaw. Turned the spindle a few turns in one direction, reading the encoder rawcounts each turn. Then turned it back to 0. Still see some error in the numbers but not too much, a few counts.

This weekend I will connect everything to the 7i76e and do a fresh config on my mill computer with LCNC 2.8.0
Last edit: 09 Sep 2022 07:59 by DEVILHUNTER.

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

More
09 Sep 2022 10:07 #251539 by tommylight

Turned the spindle a few turns in one direction, reading the encoder rawcounts each turn. Then turned it back to 0. Still see some error in the numbers but not too much, a few counts.

That points to encoder interference or fault, do you have another encoder to test with?
-
Had a new encoder, cheap china one, on one side it would count perfectly, on the other side the pulses would get shorter with speed on one chanel. Changed to another of the same make and model and it worked.
Caused plenty of head scratching.

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

More
09 Sep 2022 13:20 #251547 by andypugh

Connected the encoder to my 7i76e and checked the movement with the comparator against the chuck jaw. Turned the spindle a few turns in one direction, reading the encoder rawcounts each turn. Then turned it back to 0. Still see some error in the numbers but not too much, a few counts.

Do 10 (or 20, or more) full turns and see if the error accumulates or is constant (and therefore due only to how accurately you can do a single turn) 
The error isn't by any chance 1000 v 1024 is it? Both are common. 

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

More
09 Sep 2022 13:46 #251549 by andypugh

Do 10 (or 20, or more) full turns and see if the error accumulates or is constant (and therefore due only to how accurately you can do a single turn) 
The error isn't by any chance 1000 v 1024 is it? Both are common. 

Actually, forget that. The threading start doesn't depend on the scale at all, it all resets to index at the start of each pass. 

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

Time to create page: 0.171 seconds
Powered by Kunena Forum