Thread pitch only 72% of commanded value.

More
17 Jan 2016 14:36 #68585 by RotarySMP
Hi all,

I didn't get change wheels with my Boley 4LV, so I have made up a bracket to run a Nema 34 stepper as an electronic lead screw.

I made a spindle encoder with 45 slots on the A phase, and a single deeper slot for the indexer (Z).

I have three issues:
1/ Did a threading test and when commanded G33 Z-95 K 10, I am only getting a 7.2mm thread pitch. Linear moves are correctly scaled. The behaviour is consistant, as the two pictures show the first and second pass along the same thread, and they overlap. I have the .HAL set for 45 count encoder.

setp encoder.0.position-scale 45
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

I have posted my .Hal, .Ini and Custom_postgui files.

2/ I am running the Z motor from a Gecko G201 at 65V, and used the StpConf to set up. I selected G201, and it gave really aggressive timeings which didn't work at all. I have now used very slow conservative timeing which worked for my Zylotec drivers from my old lathe. Anything Need to be updated so that StpConf gives correct timing for Geckos?

3/ StpConf produced configurations fail out when first used, as it gives a "Spindle at speed" error. Once I comment out these lines in the Custom _Postgui , it works:
# **** set up spindle at speed indicator ****
# **** force spindle at speed indicator true because we chose no feedback ****

#sets spindle-at-speed true
#net spindle-at-speed => pyvcp.spindle-at-speed-led

I don't really understand the syntax, but the spindle at speed concept is good. What would I need toedit to make it wait before starting a pass until the spindle is at speed?

Thanks for your help,
Regards,
Mark

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

More
17 Jan 2016 16:26 #68594 by PCW
Do you get exactly 45 counts per turn if you turn the spindle by hand?

Does the scale change if you slow the spindle speed?
The following user(s) said Thank You: RotarySMP

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

More
17 Jan 2016 21:12 - 18 Jan 2016 07:12 #68618 by RotarySMP
Hi PCW,

Thanks. I turned the spindle by hand while counting the transitions shown by Halmeter-->parameter-->spindle encoder A. It showed all 45 counts. If the thread pitch is short, it would means that it is counting too many teeth per Revolution. When I first started to set it up, I had the Default 100 Counts in the HAL file, and it gave a 4.xx mm pitch when commanded for 10.

I had assumed because the spindle speed read out is about right that the encoder was working, but the speed read out uses the encoder index (Z) rather than channel A doesn't it?

Is there a way to see how many encoder channel A counts it is seeing per Index signal while the spindle is actually running?

Regards,
Mark
Last edit: 18 Jan 2016 07:12 by RotarySMP.

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

More
18 Jan 2016 15:40 #68690 by andypugh
My first guess was that the thread time and stepper gearing was such that the system could not output pulses fast enough, but that would trigger a following-error.

Does a G0 move of the Z-axis give the correct movement? ie, is this a general scaling problem or a threading-only problem?
The following user(s) said Thank You: RotarySMP

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

More
19 Jan 2016 18:59 - 19 Jan 2016 19:00 #68775 by RotarySMP
Hi Andy. Thanks for taking look. I tried G0 z100 moves and distance traveled against a ruler was 100mm.

It is a 200 step motor. 10x microstepping. 1:1 toothed belt and a 6mm pitch leadscrew.

Before I corrected the HAL servo count from 100 to 45 G33 K10 gave a 4.xx pitch.
Mark
Last edit: 19 Jan 2016 19:00 by RotarySMP.

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

More
20 Jan 2016 14:18 #68820 by andypugh

Before I corrected the HAL servo count from 100 to 45 G33 K10 gave a 4.xx pitch.
Mark


You know, 45 counts is very unusual. Can you check that motion.spindle-revs increases by exactly 1 for one turn of the spindle?

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

More
23 Jan 2016 20:42 - 23 Jan 2016 20:49 #68997 by RotarySMP
Thanks Andy,

Sorry for the slow response. I was out of the country on businees this week.

I made the 45 count encoder wheel, because my rotary table gives 8° per rotation of the handle. This way dividing was easy, and I didn't screw it up :) I figured it is a nice round number from an angular measuring perspective, and didn't want too high an encoder count limiting rpm.

I used the Hal meter to monitor motion.spindle-revs. Whether turning the spindle by hand or when running under machine power at 900 or 1800 rpm it seems to keep sync fine. I ran 1900 RPM for about 985 rotations, and then turned it a bit by hand, and the index slot still lined up with it's starting angle as it completed each full rotation with the motion.spindle-revs clicking over as as an integer.

I ran G33 Z-100 K10 again three times. The Z move ended correctly after 100mm. All three threads were perfectly aligned, but at 7.2mm pitch. I was wondering if it could be stray light affecting the sensor, so I turned the machine light off and shielded the area of the sensor, but it made no difference.

I noticed that the .hal file still has
net spindle-phase-b encoder.0.phase-B

Although I am not running this a quadrature encoder. I only have the index =Z and Phase A implemented. Should I delete this line (and are there any others which might have an effect)?

It would have to picking up extra counts to run the pitch short doesn't it? If it was loosing counts it should be an elongated prich.

Regards,
Mark
Last edit: 23 Jan 2016 20:49 by RotarySMP. Reason: Typo's and incomplete text.

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

More
23 Jan 2016 20:54 #69000 by andypugh
Can you confirm that it is exactly the same pitch at half the spindle speed?

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

More
24 Jan 2016 20:58 #69067 by RotarySMP
What your were thinking seems correct Andy. The problem was simply that the 10mm pitch at 235RPM which I was testing at is beyond the speed of the Z Axis. Once I slowed the rpm down, it seems to cut accurate pitches. Doesn't LinuxCNC have an error warning if Z can't keep up with the commanded value of K? I used to use TurboCNC and it would fault out and warn of that.

I guess the fact that it cut the same thread near perfectly each time threw me off track. Thanks for the help.

Regards,
Mark

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

More
24 Jan 2016 21:34 - 24 Jan 2016 21:34 #69069 by PCW
Yes, LinuxCNC should have thrown a "Joint following error"
if the Z axis could not keep up with the commanded velocity.

The fact that it didn't suggests that the following error settings
in your HAL or INI file are set too wide.
Last edit: 24 Jan 2016 21:34 by PCW.
The following user(s) said Thank You: RotarySMP

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

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