Hello Guest it is April 29, 2024, 08:01:37 AM

Author Topic: Step by step it does not fail but in automatic it does. Please help.  (Read 1055 times)

0 Members and 1 Guest are viewing this topic.

Greetings, I have a CNC manufactured by me controlled by Mach3, I have generated this G code with SheetCam because it is a very simple design, it is made up of several programs since it uses several tools, specifically this part (drilling) is the one that fails me but only if I run the program automatically and it always fails at the same point and in the same way, the three axes are out of phase and it is not due to machine jamming, since the machine follows the DRO coordinates, but if I run the program step by step and from the beginning it works perfectly, if I start the program automatically but a little more advanced, from line 160 for example, before the error, it works perfectly, it drives me crazy, I leave you the complete program with comments so that see it as clearly as possible and see if you can give me a hand.

Many thanks in advance. Greetings.

N0010 (Filename: 2 Soporte motor Z 10mm taladrado.tap)
N0020 (Post processor: Mach3.scpost)
N0030 (Date:08/11/2022 Time:20:55:54)
N0040 G21 (Units: Metric)
N0050 G40 G90 G91.1
N0060 F1
N0070 (Part: Soporte motor)
N0080 (Operation: Taladrado, Taladro, T28: Taladrado, 8 mm Diámetro, 10 mm Profundidad)
N0090 S9000
N0100 G00 Z70.0000
N0110 (Taladrado, 8 mm Diámetro)
N0120 ;T28 M06
N0130 ;G43 H28
N0140 G00 Z5.0000
N0150 S9000 M03
N0155 G04 P13

N0160 X11.5000 Y11.0000
N0170 Z2.0000
N0180 G01 Z-5.0000 F400.0
N0190 G00 Z-1.0000
N0200 Z-3.0000
N0210 G01 Z-10.0000
N0220 G00 Z5.0000

N0230 Y59.0000
N0240 Z2.0000
N0250 G01 Z-5.0000
N0260 G00 Z-1.0000
N0270 Z-3.0000
N0280 G01 Z-10.0000
N0290 G00 Z5.0000

N0300 X58.5000
N0310 Z2.0000
N0320 G01 Z-5.0000
N0330 G00 Z-1.0000
N0340 Z-3.0000
N0350 G01 Z-10.0000
N0360 G00 Z5.0000            ;Go up to Z5.0 and stay

N0370 X75.0000 Y47.0000    ;This displacement does it well
N0380 Z2.0000               ;** Here instead of going down to Z2.0 it goes up to Z7.0 and then goes down out of phase **
N0390 G01 Z-5.0000           ;It does not go down to Z-5.0, it stays at Z-3.0
N0400 G00 Z-1.0000           ;All the axes are progressively offset
N0410 Z-3.0000
N0420 G01 Z-10.0000
N0430 G00 Z5.0000            ;At this point it goes up to Z12.0, totally out of phase

N0440 X115.0000      ;This movement is also super out of phase at X131 approx.
N0450 Z2.0000
N0460 G01 Z-5.0000
N0470 G00 Z-1.0000
N0480 Z-3.0000
N0490 G01 Z-10.0000
N0500 G00 Z5.0000
N0510 Y23.0000
N0520 Z2.0000
N0530 G01 Z-5.0000
N0540 G00 Z-1.0000
N0550 Z-3.0000
N0560 G01 Z-10.0000
N0570 G00 Z5.0000
N0580 X75.0000
N0590 Z2.0000
N0600 G01 Z-5.0000
N0610 G00 Z-1.0000
N0620 Z-3.0000
N0630 G01 Z-10.0000
N0640 G00 Z5.0000
N0650 X58.5000 Y11.0000
N0660 Z2.0000
N0670 G01 Z-5.0000
N0680 G00 Z-1.0000
N0690 Z-3.0000
N0700 G01 Z-10.0000
N0710 G00 Z70.0000
N0720 M05
N0725 X0 Y0
N0730 M05 M30

Offline Graham Waterworth

*
  • *
  •  2,673 2,673
  • Yorkshire Dales, England
    • View Profile
Re: Step by step it does not fail but in automatic it does. Please help.
« Reply #1 on: November 08, 2022, 06:45:18 PM »
Reduce the velocity and acceleration on all axis by 50% and see if that helps in automatic mode.

We would need more details of the Mach3 settings and the machine to help further.
Without engineers the world stops
Re: Step by step it does not fail but in automatic it does. Please help.
« Reply #2 on: November 10, 2022, 03:17:24 PM »
Thanks, let's see if this helps...

I'm still investigating the bug that I have in hand, I have to say that all my equipment has worked perfectly before finishing mounting all the electronics in a box.

The conclusion I have reached from the tests carried out is that the VF introduces electrical noise and makes the system go out of control in an extremely rare way, I insist that this has not happened to me before and the same components have been working perfectly, to say that I have the cables shielded and with a ground connection at one end of each cable harness, the negative poles of the sources are not connected to each other or grounded, I have tested the ferrite core that brings the VF to both the AC input As for the U-V-W output that goes to the spindle motor, I have finally managed to remove the VF from the box and move it about 60cm away from it to see if I could isolate it enough with this.

The fact is that if I run the programs with the VF in RUN and at any speed (from S9000 to S24000) the axis positioning control fails, it is not that pulses are lost because the motors do what appears in the DRO, the problem is that, it is as if the program sends to other coordinates without being like that because the program has and visualizes the original and correct coordinates but the motors do not go there, now well, with the VF on but in STOP, that is, I comment the lines start (M03) and speed (S*********xx) of the spindle so the motor does not start but the program runs normally, because the whole program WORKS perfectly, it NEVER fails!!! I have also tried removing the cable from the spindle, leaving it in the air and separated from the rest of the cables and electronics and I can't remove the fault, but now the best is here!!!!....

If I load the program for normal operation, everything connected correctly, I adjust the 0 part for X, Y and Z, and before starting cycles, I press the "GOTO Z" key on the MACH3 screen, and with it all the axes go to 0 (if I have moved them to remove the probe for example) including the Z that goes down to the same piece, then YES !!!! the program works perfectly, the axes, the dimensions, the milling.... EVERYTHING, it works without any error if I press this key, if I don't press it it doesn't work... ??????????

I'm running out of ideas, I can only think of putting one of these filters https://inverterdrive.com /group/EMC-Filters/Universal-Motors-FLT-PS2010L-C-G/ for the VFs that go to the input (220VAC), but on the other hand I am totally confused that if I click on "GOTO Z" it does work and it is not affected by possible electrical interference.

Please, does anyone have an idea that I could try or have an explanation for this?

Here are some photos of my installation. Greetings.

Re: Step by step it does not fail but in automatic it does. Please help.
« Reply #3 on: November 12, 2022, 05:04:42 AM »
SOLVED!!!!

As rare as the error is, as simple and simple as the solution, that error had no logic at all so I thought of software, as simple as that, I have reinstalled Mach3 and it has been solved, sometimes we get more complicated than necessary and the obvious is before our eyes, but hey, this helps me to learn, we always learn...

Greetings.