Machsupport Forum

Mach Discussion => Mach4 General Discussion => Topic started by: SEREGIUS on July 09, 2018, 02:53:54 AM

Title: Mach4 problems when moving.
Post by: SEREGIUS on July 09, 2018, 02:53:54 AM
Hi,
I use Mach4 on a laser cutting machine and ran into several problems when moving. The machine has high speed and acceleration. Servo Drives 400W.
1. CycleStop. During operation, if I need to stop the GCode execution, I press CycleStop, the machine stops very quickly and the servo drives issue an overload error. Is it possible to increase the braking from 0 to 1 second, 2 seconds ... ???
2. Jogging. I use the keyboard of the computer for manual movements. If you move one axis, then everything works well. If you move two axes at once, then smooth braking does not work, the axes stop abruptly as with CycleStop and servodrivers issue an overload error. Everything works fine on Mach 3.
3. RunFromHere. If you press this button, the correct position window pops up, select the axes, click Move Select. If you need to move along one axis - then everything works. If two of them - it's moving along a strange trajectory and when one of the axes reaches the required position of the first one, it stops very quickly, as in the case of Jogging, with instantaneous braking and an error of servo overload can appear.

Sorry for my English.
Title: Re: Mach4 problems when moving.
Post by: Peter Knell on July 09, 2018, 10:18:22 PM
Sounds like most of the servos havent been tuned yet possibly? Why not increase your decel in tuning? Also depending on how much weight on each axis you might need regen resistors on certain axis depending on how much decel you need also. Your acceleration might need slowing down too.

Title: Re: Mach4 problems when moving.
Post by: joeaverage on July 09, 2018, 10:27:04 PM
Hi,
yes you could  set a max de-acceleration in your servo but with a Cycle Stop command where the
pulse stream stops immediately the servo must overrun a little bit and you end up with a following error
rather than an over current or over voltage fault.

I don't think CycleStop is the correct way to stop Mach, the sudden cessation of movement is effectively
an infinte acceleration and any servo will fault. If there is a means to cause Mach to de-accelerate gracefully
in response to a CycleStop I don't know what it is.

Craig
Title: Re: Mach4 problems when moving.
Post by: joeaverage on July 09, 2018, 11:20:16 PM
Hi,
I think the correct way is <FeedHold> followed by <CycleStop>.

FeedHold allows the co-ordinated move already committed to complete including its graceful de-accel
phase.

Craig
Title: Re: Mach4 problems when moving.
Post by: SEREGIUS on July 10, 2018, 01:58:41 AM
Hi,
Sounds like most of the servos havent been tuned yet possibly?
The servomotors are tuned.
Quote
Why not increase your decel in tuning?
This laser cutting machine, I need high acceleration and deceleration values, and high PID control of servo motors.
Quote
Also depending on how much weight on each axis you might need regen resistors on certain axis depending on how much decel you need also.
Servomotors up to 750 volts have a built-in braking resistor.

Hi Craig, thank you for the constant help.
Quote
Hi,
yes you could  set a max de-acceleration in your servo but with a Cycle Stop command where the
pulse stream stops immediately the servo must overrun a little bit and you end up with a following error
rather than an over current or over voltage fault.
I'm sure it's wrong to stop the impulse step instantly. I use other CNC systems, different manufacturers - there are no problems with braking, there are no problems with manual movements and return to cutting.
Quote
I don't think CycleStop is the correct way to stop Mach, the sudden cessation of movement is effectively
an infinte acceleration and any servo will fault. If there is a means to cause Mach to de-accelerate gracefully
in response to a CycleStop I don't know what it is.
I'm sure the CycleStop is the right way to stop work. The instantaneous stop of the step pulses is incorrect. I have never encountered the error of servomotors at a stop, only in mach3 and mach4.
Quote
I think the correct way is <FeedHold> followed by <CycleStop>.
Craig, watch the video. The laser cutting machine and milling machine are different machines and work differently. If you use a FeedHold, the machine will stop after a long distance, this is not correct.
https://www.youtube.com/watch?v=O0oDtbkMR7A

For the following machines, I want to increase the speed from 30 meters per minute to 50 meters per minute. Problems with stopping, manual movements and returning to the cutting edge will become even greater.
Guys, thanks for trying to help!
Title: Re: Mach4 problems when moving.
Post by: Tweakie.CNC on July 10, 2018, 03:28:48 AM
Quote
I'm sure the CycleStop is the right way to stop work. The instantaneous stop of the step pulses is incorrect. I have never encountered the error of servomotors at a stop, only in mach3 and mach4.

I agree, however Mach3 requires Feed-Hold then Stop if exact position is not to be lost and this will never change. Mach4 is under development and who knows, future changes may be made to the Stop process to avoid the need for Feed-Hold.

Tweakie.
Title: Re: Mach4 problems when moving.
Post by: SEREGIUS on July 10, 2018, 03:56:44 AM
Quote
I'm sure the CycleStop is the right way to stop work. The instantaneous stop of the step pulses is incorrect. I have never encountered the error of servomotors at a stop, only in mach3 and mach4.

I agree, however Mach3 requires Feed-Hold then Stop if exact position is not to be lost and this will never change. Mach4 is under development and who knows, future changes may be made to the Stop process to avoid the need for Feed-Hold.

Tweakie.
If you need to keep the exact position - then I use a Feed-Hold.
In any other situation - CycleStop. But it should not cause errors in the servo system of the machine.

It is not clear that the correct operation of the manual movements and the return to the ...
Title: Re: Mach4 problems when moving.
Post by: joeaverage on July 10, 2018, 03:58:47 AM
Hi,

Quote
I'm sure it's wrong to stop the impulse step instantly.
I agree, if the pulses were to stop immediately it would imply an infinite acceleration. But isn't that exactly what you have described as the fault?
That the deceleration is that violent that the servo faults?

Quote
I use other CNC systems, different manufacturers
That may be so but remember that Mach is not a feedback control system, it can't because Windows is not a realtime environment.

Lets say for example that a move involving the X and Y axes is planned. Mach will plan the trajectory and commit pages of motion data to the motion controller,
one page of position data for every 1 ms of the move. During this move you hit <CycleStop>. If Mach aborts the remainder of the move Mach no longer knows
where it is. It knew where it was at the start of the move and it knows where it was supposed to be by end of the move but it has no idea how far along the move it
got when you hit <CycleStop>. I suppose if the motion controller reported the position of its axis motors then Mach could recover its position, after all this is
exactly how G31 probing works.

Mach is not a feedback control system so the motion controller does not report back to Mach in the normal course of events which includes TO MY KNOWLEDGE
ONLY <CycleStop>.

Lets say that we wanted <CycleStop> to introduce a graceful deceleration phase. First mach would have to abandon the remaining portion of the existing move
and then recalculate the pages of position data required to decelerate the axes. The communication delays  between Mach and the motion controller and back again are
way too slow for that to work.

Quote
If you use a FeedHold, the machine will stop after a long distance, this is not correct.
I agree it is not desirable but I believe it has to work that way. I reason it that because a deceleration phase is built into the planned move and given that Mach cannot go back
and recalculate the move once its already been committed to the controller the ONLY way to decelerate is to allow the current move to complete and THEN stop.

A I said earlier this is based on my understanding of how Mach works, I am by no means sure. I'm interested how you think it works. Its interesting that you claim that
you have had issues with Mach3 and Mach4....could it that this constitutes an explanation why that should be so?

Quote
The laser cutting machine and milling machine are different machines and work differently
I am not convinced this is true. What is true is that Laser requires very VERY high accelerations which make a problem that happens with a mill way WAY worse in a Laser,
but they are both affected by the same phenomenon.

Craig
Title: Re: Mach4 problems when moving.
Post by: joeaverage on July 10, 2018, 04:07:07 AM
Hi,

Quote
If you need to keep the exact position - then I use a Feed-Hold.
In any other situation - CycleStop. But it should not cause errors in the servo system of the machine.
My misunderstanding, you are not concerned with keeping exact position? You just want to stop?

If that's the case just program your servo to some maximum deceleration. You will have to disable the following error also as there will
be an overrun that will cause a fault.

Craig
Title: Re: Mach4 problems when moving.
Post by: joeaverage on July 10, 2018, 05:13:55 AM
Hi,
what sort of servos and drives do you have?

I'm thinking of my Allen Bradley AC servo and with that it is possible to limit acceleration and decelerations. I'm wondering if it is so for your
drivers.

I understand you seek to have the highest acceleration you can. Currently however your maximum acceleration on your motor tuning page must be less than
the capability of your servo or otherwise it would cause a fault, either over current or following error on acceleration. When you hit <CycleStop> however the
cessation of pulses implies a much greater acceleration than your maximum allowed under Machs tuning and in fact greater than your servo is capable of and
that does cause a fault.

I think there is some room to move there.....you could limit the servos acceleration somewhat by imposing a current limit but would still allow a slighty greater acceleration
than Machs tuned max acceleration.

What I am proposing is that you limit your servo/drive acceleration to be just a bit more than your max tuned acceleration. Your max tuned acceleration would become the effective
maximum acceleration AND deceleration.

Craig
Title: Re: Mach4 problems when moving.
Post by: SEREGIUS on July 10, 2018, 06:13:20 AM
Quote
That the deceleration is that violent that the servo faults?
Yes, it's very fast. When the machine cuts the laser at a speed of 30 meters per minute, then there is no problem with braking. He cuts the angle of 90 degrees without problems, you can see the video above. When the CycleStop button is pressed, the deceleration speed is not taken from the Motor Tuning window, but what is the maximum possible.
Quote
I'm interested how you think it works.
I think there should be two braking modes: with the saved position (FeedHold) and when the current exact position is not important (CycleStop).
I could be wrong.
If I press FeedHold, then I want to return to the position and continue the cut.
If I press a stop, I don't want to keep cutting. It's bad that the Match will lose its position, but if the deviation is not strong, there are no servo errors and loss of parallelism of the slave axis relative to the master, this will suit me. There should be a braking installation for the CycleStop, all machines and parameters are different.
Completely could not translate your questions.
Quote
My misunderstanding, you are not concerned with keeping exact position? You just want to stop?

If that's the case just program your servo to some maximum deceleration. You will have to disable the following error also as there will
be an overrun that will cause a fault.
Completely could not translate your questions.
Title: Re: Mach4 problems when moving.
Post by: SEREGIUS on July 10, 2018, 06:19:59 AM
Quote
What I am proposing is that you limit your servo/drive acceleration to be just a bit more than your max tuned acceleration. Your max tuned acceleration would become the effective maximum acceleration AND deceleration.
Craig,
This is wrong (I think so ....), mach does not have feedback. For such control systems, the internal PID loop must be faster than the external one!
Title: Re: Mach4 problems when moving.
Post by: SEREGIUS on July 10, 2018, 06:37:32 AM
Here is the servodriver and the engine. Reduction gear 14/1.
Title: Re: Mach4 problems when moving.
Post by: joeaverage on July 10, 2018, 06:40:53 AM
Hi.

Quote
I think there should be two braking modes: with the saved position (FeedHold) and when the current exact position is not important (CycleStop).
This is the same conclusion I come to. If you wish to retain exact position the <FeedHold> then <CycleStop>.  If you wish to stop with the maximum
possible deceleration obtainable with your servo then <CycleStop>

At the current time when you <CycleStop> the deceleration is so abrupt that the servo faults which is less than desirable. You do know however that it can
mange the acceleration in your motor tuning page because otherwise it would fault under acceleration as well.

I'm going to guess that you can program a maximum current in your drive which will in turn limit the acceleration. If however you turn the
current limit down eventually the servo will not be able to even accelerate as quickly as your Mach tuning. If you have the current limit just above that threshold
then your servo will accelerate at the max Mach tuning rate and should decelerate at the same.

There are three fault conditions that could be happening when you execute <CycleStop>:
1) Overcurrent....the drive is trying to decelerate so quickly that the drives current limit is exceeded
2) Overvoltage.....the servo after run is generating voltage which has to be absorbed by the drive and regen resistor if fitted. If the voltage gets too high the drive
     will fault rather than have the DC link capacitors blow up
3) Following error....under normal operating conditions we want the following error window to be small and so be assured that the servo is following its commanded
    position as closely as possible. Under <CycleStop> conditions the commanded position stops whereas the encoder runs on as the servo decelerates with an ever
    widening error and eventually the following error will be exceeded. One possibility it to set the following error window much wider so that it doesn't fault under
    <CycleStop> condition or program Mach to ignore a following error under <CycleStop> condition.

Can you post some details about your servos and drives? A manual would be great.

Craig

Title: Re: Mach4 problems when moving.
Post by: SEREGIUS on July 10, 2018, 09:14:33 AM
Quote
I'm going to guess that you can program a maximum current in your drive which will in turn limit the acceleration. If however you turn the
current limit down eventually the servo will not be able to even accelerate as quickly as your Mach tuning. If you have the current limit just above that threshold
then your servo will accelerate at the max Mach tuning rate and should decelerate at the same.
The problem is that the match does not use braking, but simply cuts off the steps. I'm sure that the PID settings in the servo drive should be as high as possible, so that you can accurately perform the task of the match. On the laser cutting machine, the speed G0 is equal to the speed G1, the servomotors are tuned to the minimum possible following error. Limiting current, voltage, speed is the wrong way. When the machine performs the job, then there are no errors, everything works. Reducing the parameters in the servo will reduce the accuracy of the operation.
Quote
There are three fault conditions that could be happening when you execute <CycleStop>:
1) Overcurrent....the drive is trying to decelerate so quickly that the drives current limit is exceeded
2) Overvoltage.....the servo after run is generating voltage which has to be absorbed by the drive and regen resistor if fitted. If the voltage gets too high the drive
     will fault rather than have the DC link capacitors blow up
3) Following error....under normal operating conditions we want the following error window to be small and so be assured that the servo is following its commanded
    position as closely as possible. Under <CycleStop> conditions the commanded position stops whereas the encoder runs on as the servo decelerates with an ever
    widening error and eventually the following error will be exceeded. One possibility it to set the following error window much wider so that it doesn't fault under
    <CycleStop> condition or program Mach to ignore a following error under <CycleStop> condition.
What a mistake on the servo - it does not matter. You eliminate one mistake, the other appears. Instant step breaks can not withstand more than one servomotor. I need the exact part and high speed (see photo)!
Quote
Can you post some details about your servos and drives? A manual would be great.
http://www.leadshine.com/productdetail.aspx?type=products&category=servo-products&producttype=brushless-servo-drives&series=ACS&model=ACS806
Title: Re: Mach4 problems when moving.
Post by: joeaverage on July 10, 2018, 10:18:42 AM
Hi,
already the acceleration that the servo is capable of is MORE than what you have set as max acceleration in Machs tuning page.

Quote
I'm sure that the PID settings in the servo drive should be as high as possible, so that you can accurately perform the task of the match
Yes and I see that you've done that but then in Machs tuning you must have limited it or it would fault under acceleration as well as deceleration.

From:
Quote
Software Manual
Of the ACS306, ACS606 V2.0 & ACS806 V2.0

Page 12 / 34 The Error Trace window will give you which of the conditions is causing the fault. You can probably cure 1) and 3), but I don't think you can
cure 2)

Craig
Title: Re: Mach4 problems when moving.
Post by: SEREGIUS on July 11, 2018, 01:26:13 AM
Quote
Yes and I see that you've done that but then in Machs tuning you must have limited it or it would fault under acceleration as well as deceleration.
The problem occurs with any acceleration. Now it costs 3000, put 1500, put 500. At a speed of 30 meters per minute with any acceleration a problem arises. If I leave a little acceleration on the machine, then the car will never be able to catch up to 30 meters per minute.
Quote
Page 12 / 34 The Error Trace window will give you which of the conditions is causing the fault. You can probably cure 1) and 3), but I don't think you can
cure 2)
I have number 2 error.  ;D
I put a braking resistor, Damper PLZ005-G2 ...
On other CNS systems, servodrivers with these settings work well, CycleStop works, no errors occur, the position is not lost ...
Title: Re: Mach4 problems when moving.
Post by: joeaverage on July 11, 2018, 02:47:14 AM
Hi,
the picture in your previous post was a part cut by your machine? If it was then the velocity and acceleration in Machs  motor tuning must be adequate.
If the servos were not fast enough or powerful enough to at least equal the acceleration and velocity settings in Mach your machine would
fault 'following' error and fail to cut accurately.

Clearly your servos are at least big enough and powerful enough to meet Machs demands, except at <CycleStop>.

Lets say you put some really big powerful servos  on your machine that could exceed Machs acceleration and velocity settings. The precision of the cut is still
determined by the acceleration and velocity settings in Mach so the extra big servos haven't improved the precision of cutting but might have enough power
to stop really quickly at <CycleStop>.

I am of the opinion that your servos are big enough that even if you detuned them a bit they would still comfortably exceed Machs acceleration and velocity settings
but be a little less aggressive when decelerating at <CycleStop>. In short you have tuned your servos to be more aggressive than they have to be.

This is my suggestion, 'try detuning your servos a bit so they are still at least as good as the current acceleration and velocity settings in Machs motor tuning'.
I'm hoping that by detuning a bit that you retain the current level of precision BUT REDUCE the tendency to fault.

You don't have to buy anything, just try a slighty less aggressive tuning, if it doesn't work put it back, no harm done.

Craig
Title: Re: Mach4 problems when moving.
Post by: SEREGIUS on July 11, 2018, 08:45:54 AM
Quote
the picture in your previous post was a part cut by your machine?
The pictures and videos I laid out are the machine we are talking about. In the photo the details are cut out on the video.
Quote
Clearly your servos are at least big enough and powerful enough to meet Machs demands, except at <CycleStop>.
Quote
Lets say you put some really big powerful servos  on your machine that could exceed Machs acceleration and velocity settings. The precision of the cut is still
determined by the acceleration and velocity settings in Mach so the extra big servos haven't improved the precision of cutting but might have enough power
to stop really quickly at <CycleStop>.
No. I tried the servo motors 1000 W. The problem is even worse. I'm afraid of getting mechanical damage on the machine.
I was looking for a lot of solutions on this problem, only then decided to write to the forum.
Quote
This is my suggestion, 'try detuning your servos a bit so they are still at least as good as the current acceleration and velocity settings in Machs motor tuning'.
I'm hoping that by detuning a bit that you retain the current level of precision BUT REDUCE the tendency to fault.
Craig, thank you for solving my problem.
I will try to explain why I will not change the servo settings.
Mach4 should change the settings for the machine, and not change the machine for Mach4.
Quote
This is my suggestion, 'try detuning your servos a bit so they are still at least as good as the current acceleration and velocity settings in Machs motor tuning'.
I'm hoping that by detuning a bit that you retain the current level of precision BUT REDUCE the tendency to fault.
I made a lot of cars with these servos. Everywhere were the same settings. If you change them, you need to save the settings for each machine separately. A lot of work. If the engine does not work, I can program it and send it to the buyer by mail, he will install it himself. Do you remember what settings were on the car sold 5 years ago? If the car sold 600 pieces?
If my car can move 50 meters per minute with an acceleration of 10,000 meters per second in the square, why should I reduce and not increase?

Title: Re: Mach4 problems when moving.
Post by: joeaverage on July 11, 2018, 02:08:35 PM
Hi,
if you choose to ignore a suggestion that is of course your choice. Maybe someone else will have another idea, unless you ignore them to.

Quote
Mach4 should change the settings for the machine, and not change the machine for Mach4.


Good luck and goodbye.

Craig
Title: Re: Mach4 problems when moving.
Post by: SEREGIUS on July 12, 2018, 01:07:30 AM
Thank you, Craig.
Title: Re: Mach4 problems when moving.
Post by: Tweakie.CNC on July 12, 2018, 02:20:11 AM
Quote
Mach4 should change the settings for the machine, and not change the machine for Mach4.
Quote

Hi Seregius,

I think everything in this world is financially driven - if you were a potentially enormous customer then the software would, I am sure, be changed to suit your machine and your requirements. However, in reality, we have to learn to adapt our machine's and their set-up's to suit the software that is currently available and if you choose Mach4 then Craig has made some excellent suggestions to achieve a compromise solution to your exact stop issue.

As I mentioned earlier Mach4 is under development and if enough users need it, the cycle stop function may well be modified in the future.

Tweakie.
Title: Re: Mach4 problems when moving.
Post by: Fledermaus on July 12, 2018, 06:56:12 AM

Does the setting "Cycle Stop is Controlled Stop" have any effect on your machine?

Allan
Title: Re: Mach4 problems when moving.
Post by: SEREGIUS on July 12, 2018, 10:26:42 AM
Hi Tweakie.CNC ,
Quote
I think everything in this world is financially driven - if you were a potentially enormous customer then the software would, I am sure, be changed to suit your machine and your requirements. However, in reality, we have to learn to adapt our machine's and their set-up's to suit the software that is currently available and if you choose Mach4 then Craig has made some excellent suggestions to achieve a compromise solution to your exact stop issue.

As I mentioned earlier Mach4 is under development and if enough users need it, the cycle stop function may well be modified in the future.
I'm writing a message through Google translation, maybe I do not understand you correctly, and you, too, me.
It's right that Mach4 does not want to change for one buyer, just like the seller does not want to change the machine for one Mach4.
Which car the buyer chooses, I do this for the buyer. If the mach4 will be more ordered, I will buy more mach4.
Now mach3 choose more buyers than mach4.
I wrote why I will not change the settings of the servos. Most importantly, these settings work with other controllers and do not work with mach.
The greater the speed and acceleration of the laser cutting machine, the higher the servo settings must be for high cut quality.
This is not the main problem. I will delete this button. I asked if there is a solution.
I wrote two more problems that arise when moving.
Title: Re: Mach4 problems when moving.
Post by: Tweakie.CNC on July 12, 2018, 10:42:47 AM
Hi Seregius,

Why not talk to Artsoft / NFS directly about the problems you see with Mach4. They can be easily contacted by the ticket system here;  http://www.machsupport.com/support/

Tweakie.
Title: Re: Mach4 problems when moving.
Post by: joeaverage on July 12, 2018, 11:22:46 AM
Hi Seregius,
<CycleStop> is effectively a crash stop and you insist that you tune your servos so aggressively that they fault when you crash stop.
You could tune them and STILL attain the current cut quality but REDUCE the aggressive crash stop so they don't fault.

Rather than learn how to tune your servos properly you blame Mach.

Craig
Title: Re: Mach4 problems when moving.
Post by: Cbyrdtopper on July 12, 2018, 03:43:06 PM
I'm just throwing this out there.  
A lot of machine tools only have a "cycle start" and a "feed hold" button, no cycle stop button, on our Johnfords for example, it has a Green Button that is Cycle Start and a Red Button that is Feed Hold and if it is pressed a second time then it acts a Cycle Stop.  The "Cycle Stop" occurs after "Reset" is pressed on other machine tools.  
If you want a faster Stop of Motion after Feed Hold you will need to tune your motors to handle the rapid deceleration.