Machsupport Forum

Mach Discussion => General Mach Discussion => Topic started by: Lotus Pack on February 10, 2014, 11:34:46 AM

Title: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 11:34:46 AM
Hi All,
Does anyone have an idea what this error means?

Used a PC (PC1) to set up Mach3 turn on my SC2 lathe and cut a thread to check all was working ok, and it was and still is for PC number 1.  Copied the XML to another PC  (PC2) and now on this one I get the following errors in the Last Errors file:
Mon - 16:11:10 --- Threading Calc:  Vel (IPM): 178.7176 Actual Calc Pitch: 0.8000 Spindle: 223.3971
Mon - 16:11:10 --- Last Reported Thread run values.....

 
Mon - 16:11:10 ---Spindle Lock: 5424 , Total Ints: 0, Total Spindle Ints: 0, Error: 844, Adder: 0 LastRot: 6758
Mon - 16:11:10 ---Spindle Lock: 5424 , Total Ints: 5871, Total Spindle Ints: 5424, Error: 447, Adder: 0 LastRot: 6707
Mon - 16:11:10 ---Spindle Lock: 5424 , Total Ints: 12102, Total Spindle Ints: 10848, Error: 1254, Adder: 0 LastRot: 6674
Mon - 16:11:10 ---Spindle Lock: 5424 , Total Ints: 17555, Total Spindle Ints: 16272, Error: 1283, Adder: 0 LastRot: 6713
Mon - 16:11:10 ---Spindle Lock: 5424 , Total Ints: 23102, Total Spindle Ints: 21696, Error: 1406, Adder: 0 LastRot: 6856
Mon - 16:11:10 ---Spindle Lock: 0 , Total Ints: 0, Total Spindle Ints: 0, Error: 0, Adder: 0 LastRot: 0
Mon - 16:11:10 --- Threading Calc:  Vel (IPM): 178.2317 Actual Calc Pitch: 0.8000 Spindle: 222.7896
Mon - 16:11:10 --- Last Reported Thread run values.....

 
Mon - 16:11:10 ---Spindle Lock: 0 , Total Ints: 0, Total Spindle Ints: 0, Error: 0, Adder: 0 LastRot: 0
Mon - 16:11:41 ---Too Slow for Pulley..Using Min.


Considering a bit further, the only difference between the two computers is the parallel address port, I imported my XML files for the preferences into a databse and found no differences.
I need to understand where this is coming from as it must be due to a PC clocking issue or something like that. Hoping that if the cause of the error can be established I can rule out thios PC complelety.
Hope you can help.  :(
Paul
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Hood on February 10, 2014, 01:25:26 PM
Looks like you have the Threading test plugin enabled. you should not use this now as it was a test for early versions whilst Art was trying to find issues with the threading using the parallel port.
Hood
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 03:12:59 PM
The Plugin Control menu has only a Video Window.  This is a new install and I have not applied any plugins as yet.
Do you think it is actuating somehow or by some other means, how can I confirm the plugin is disabled?
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 03:22:31 PM
Hi Hood,
I have just cheched all plugins are disabled but still producing the same error log, is there anyone who can source this error condition.  As it had a 10-90% duty cyucle on the index slot, I have just made a new index pulse card with a 50% duty cycle, this alo made no difference. 
Regards
Paul
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Hood on February 10, 2014, 04:36:05 PM
Attach your xml and I will have a look through it and see if I can find an issue.
Hood
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Hood on February 10, 2014, 04:37:04 PM
BTW is the date on your computer set correctly?

Hood
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 04:58:19 PM
Hi Hood,
Yep, date is set correctly , I am in the UK!  It is 9:47pm.

Just seen that the Mach3 version on PC1 is version 3.00 where the version on PC2 is 3.044.066, I will try to install the olders version on PC2 and see if this error still happens.  I do have two Mach3 Licences!

Enclosed:
The last run of thread TEST 2_LP1.txt
produced the last errors_LP1.txt
using the Mach3Turn_LP1.xml

Thank you.
I'm off for a cup tea now :)
I will bae back on line tomorrow...
LP
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 05:02:30 PM
Hang on the Error file in empty!
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 05:03:01 PM
Just creating a new one!
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Hood on February 10, 2014, 05:03:44 PM
All of them are 0KB :D


Hood
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 05:06:25 PM
Run for a few passes then hit Cycle Stop.
Enclosed... ::)
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 05:07:36 PM
Oh, ok I try again!
Just a minute...
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 05:16:54 PM
 ???
Try These
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 05:18:43 PM
Think I need a coffee now to keep going here :)
Thank you again,
LP
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Hood on February 10, 2014, 05:22:39 PM
Ok go to ports and pins then Inputs and scroll down and disable Timing.
It is no longer used, used to be you could use that instead of Index if you had multiple slots but now only a single Index can be used with the parallel port.
Hood
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 05:27:32 PM
BTW Updated my profile with the 5 hrs difference...so the time should now be international. :)
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Hood on February 10, 2014, 05:28:56 PM
It was actually your error file I was looking at and thought it was the date but its the time I think :D
Hood
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Hood on February 10, 2014, 05:35:41 PM
Also just looked in the xml and the Turn Diagnostics plugin is indeed turned on, must have been from an earlier install and you reused the xml.
You can either install an old version of Mach with the plugin so you can turn it off or you could open the xml in notepad or similar and change the value from 1 to 0.

The value will be as such

<TurnDiags-Turn-Diags-1.00.1>
1
</TurnDiags-Turn-Diags-1.00.1>

and it should be

<TurnDiags-Turn-Diags-1.00.1>
0
</TurnDiags-Turn-Diags-1.00.1>
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 10, 2014, 05:48:00 PM
Hi Hood,
Ok, done...the XML modification.
Checked the diags are off in the enclosed XML ...LP5.
Run produced results in error file ...LP5

Still producing erros, I recon it is a version thing as yoiu say!

Sorry but I must go to bed now as I have been up for over 16hrs...
Latest files enclosed...
Regard
LP
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Hood on February 10, 2014, 05:54:21 PM
Are you actually having issues threading or is it just the last errors you are looking at?
Hood
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 11, 2014, 07:12:09 AM
Yes, having some synchronisation problems on this PC so the error seems logical.  It seems to me that Mach3 is detecting some timing errors and therefore kicking out these lines in the error log file. The thread is indexing ok to start but something is interfering with the progress through the thread length and it sometimes changes pitch toward the end of the thread.  Which is why this error is so intriguing, It may be the PC has its own timing issue.  Is there anyone that can determine what part of the program actually produces these error condition messages?
LP
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Hood on February 11, 2014, 02:28:04 PM
I will see if Art will have a look, he is the only one that will know.
Hood
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: ART on February 11, 2014, 03:13:58 PM
Hi Guys:

 Well, lets see what it says..

>>Mon - 22:31:31 ---Spindle Lock: 4721 , Total Ints: 0, Total Spindle Ints: 0, Error: 728, Adder: 0 LastRot: 5830
Mon - 22:31:31 ---Spindle Lock: 4721 , Total Ints: 5221, Total Spindle Ints: 4721, Error: 500, Adder: 0 LastRot: 5964
Mon - 22:31:31 ---Spindle Lock: 4721 , Total Ints: 10606, Total Spindle Ints: 9442, Error: 1164, Adder: 0 LastRot: 5876
Mon - 22:31:31 ---Spindle Lock: 4721 , Total Ints: 15426, Total Spindle Ints: 14163, Error: 1263, Adder: 0 LastRot: 6009
Mon - 22:31:31 ---Spindle Lock: 4721 , Total Ints: 20116, Total Spindle Ints: 18884, Error: 1232, Adder: 0 LastRot: 5937
.....

  Ok, so the spindle was seen to be running at 4721 interrupts per rotation with no load just prior to threading..( thats what the spindle lock means). Not sure of your interrupt freq., assume its 25K so you have
40us per int so .188 seconds per rot for 5.29 per second or approx 320RPM. ( again, assuming 25K interrupt time, always use the lowest interrupt freq you can get away with for stabilities sake..).

  Then you started the trhead. Amazingly it ran slow even before it hit the material.. it took 5221 on the first pass, so Mach likely slowed the axis to compensate..it kept slowing every rotation as the
error kept building. It never really catches up to the expected time. Really, the Total Ints number should try to stay near the Total Spindle Ints. Mach tries to slow things down to make that so. The number
under Error: is the actual number Mach uses to slow down. So its slowing every rotation and by a variable amount.

  Try running a thread in the air, the numbers should be much closer.( Total Ints: *********, Total Spindle Ints: yyy, ) If they are not , then you probably have either noise ( because of a 3..5 volt port maybe being ore sensitive?), or the interrupt
on that pc isnt very stable. Your driver test should display spikes or other patterns instead of a straight line if thats so. The printout seems to simply show that Mach doesnt seem to be able to track very
closely though it IS trying to. The problem seems to be there is too much variation. Id suspect noise or PC interrupt stability as the root issue if the threads wander..

Art
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 11, 2014, 03:53:22 PM
Got it, thanks Art.  Think you are right with your prognosis. This was run in the air!
On the case now!  I will get back with the results as soon as complete or abandoned!
What does the LastRot: parameter signify?
 
I will focus on the Spindle PWM stability first, as it ran slow before hitting the material and get my scope on the pins and trace where the fluctuation is coming from.  This really helps with the starting point for the analysis.  

Thanks Hood for your input too.
LP
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: ART on February 11, 2014, 06:08:38 PM
LP:

  Lastrot is the int's of the last rotation counted.

NOTE:  I recommend if threading that you do not allow Mach3 to pwm control the spindle. The reason for this is that most spindles these
days have their own internal regulator so Mach tries to control the speed at the same time and it can create instabiility as the twp controls
fight each other. Most will find stability in threading increases drastically if you set a static speed in the invertor alone.,

  I recommend allowing the operator to dial in a speed for the spindle, and not to let MAch3 control anything other than on/off.

Art
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 11, 2014, 06:55:49 PM
Hi Art,
I am using the Little Machine Shop Spindle interface for the Sieg brushless motor spindle drive.  Current setup uses a PWM output from Mach3 through a low band pass filter and into the 0-5 volt AVI on their board. There is no RPM state or one time frequency to set a spindle speed, so I am pretty sure there is no battle going on between two regulators here. But, thanks for your point and may move over to a Mobus control instead a bit later.  After all, I do get a good thread of the first PC, it is only the second PC that is producing the Spindle Lock error information and causing threads to come out wrong.

FYI
The interrupt handler on the PC is working fine according to the driver test.
Ok there is a significant difference here, the LastRot shows about 30rpm difference, under no load, recon you are right with the interference thought.
Investigation so far, have found a level of background noise on the Index pin, coincidently a shade lower frequency than the spindle pulses at 250rpm, in fact, hit the spindle button, turn the spindle off while the thread cycle is running and the thread still engages after seeing a trigger, the spindle is stooped so the trigger should never arrive. The Index LED stops flashing while the spindle stops. The interference is a spike that lasts a tiny amount of time, much higher voltage so I am guessing the spike is enough to trigger a thread pass.

Still think this is a combination of issues. Found a GND inconsistency on the controller, Opto-isolator with active low not linked to the PC GND.  Needs to be active high and linked to PC GND then filter some of this noise out with strategically placed caps and ferrite rings.    Now I understand the Spindle Lock errors I can test and check the results shown in the log.

No need to reply.
LP
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: ART on February 11, 2014, 07:52:15 PM
good luck. :)

Art
Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: RICH on February 12, 2014, 06:04:05 AM
LP,

- RPM stability along with adequate motor torque is most important for threading.
  1 or 2 rpm difference and the thread should be ok. I get an occasional flicker from whatever it is set at to 1 rpm under.

- When or if using the threading Wizard, click the "calc number of passes" as that will show you if your exceeding your velocity.
   Even if it is ok, leave some head room from the max.

- As Art has replied, set the speed manualy. Play as you wish, but, your on your owne.
  Would venture to quess that anything that is manipulating the rpm for output to Mach is not in real time and thus must be totaly repeatable.
  Just a matter of degree as how much influence it will have on the actual threading.

- Scribing is a very effective way of seeing results and can tell you just what your machine is capable of doing since it's a visual of air running.

FWIW,

RICH


Title: Re: Spindle Lock Error G76 Thread Cycle
Post by: Lotus Pack on February 12, 2014, 06:52:27 AM
Thanks RICH, good advice.