Saturday 16 September 2017

G28 (machine zero return) problems

I've spent the last couple of evenings trying to figure out why I'm suffering from Z axis "soft limit" errors when I try to compile my programs on the controller.

But even when I manage to set the WCS to keep the Z axis moves within legal extents, the manual tool change sequence at the end of each sub program screws up. I can't help thinking it's not behaving the way it should. I've buggered about with every possible parameter in the setup screens that might remotely, conceivably affect the operation of the "return to machine zero" instruction.

The problems include:

  • No matter what I do, the vertical movement will not exceed 80mm before I get an annoying message about a missing reference limit switch signal. Annoying, not least because I wouldn't expect it to need to be using the Z axis top limit switch to return to machine zero - but that seems to be what it does each time. For a start, I can't see why it has a maximum 80mm movement. If I had a bed mill rather than a turret (quill) mill, I'd be needing a lot more than 80mm of movement to get back to Z axis machine zero. But after several hours I can say safely that none of the parameters available have any obvious (or even subtle) effect on this behaviour.
  • Trying to run G28 (return to machine zero) actually seems to run some sort of search for a limit switch signal. There doesn't seem to be valid signal being returned - and in the process it almost always encounters the 80mm maximum travel issue. If you manually jog the tool to within 80mm of machine zero (which is at the very top of the quill travel), it gets to the top limit switch, then stops and settles back several mm. It seems to be behaving as if it's doing a home switch search. But on occasion I've had it trying to go past that position, which isn't desirable unless you want to bugger something mechanically.

To use the G28 command, you actually need to specify a coordinate(s) of a point along the way. So in the screenshot above, the first command specifies an incremental move of zero on the Z axis. All rather confusing to a newcomer. But you'll see that it was looking for a reference switch signal anyway, which it didn't find. As I said, it's not obvious to me why a simple move to G53 Z0 would require looking for a switch input.

If I'm right, the second statement specifies an incremental movement of zero in X and Y, which could explain why nothing much happens. I'm still learning 2 things slowly - what is supposed to happen and what is actually happening. I'm currently fumbling about in semi-darkness.

In the course of my frustrations, I've discovered several things, some of which are almost useful:
  • You can "run" a program in automatic mode, even with the drives unpowered and in estop. Obviously the axes don't actually move but you can step through or run the program to check for problems.
  • You can run programs in "simulate" mode (the display says "Imit"(ate?)). Nothing moves, even if you have the drives powered up. Again, quite useful.
  • The "step" mode is also useful in both simulation and automatic operation. Allows you to run through, line-by-line.
  • You can edit the program in the controller, then compile (press the "rapid" and "N" keys together). If there are any issues with limits / extents etc, it will let you know. Therein lies the root of the frustration of course....
  • In the course of the G28 command failing to complete, you get the home switch search movement. Once that has failed, you are left in G53. And being in G53, you can't set the WCS - so pressing the "setup" button doesn't do anything. So if you want to change the WCS coordinate (eg to see if a particular WCS value is acceptable without causing a "soft limit" issue), you need to run G54 in the MDI. So last night I had the MDI set up with just the empty G54 command. To run it, I just press "MDI" followed by the green start button. 
What I need is a way to get the machine to return to Z axis machine zero at the end of each operation. Oh, that would be G28 on a normal machine.....

No comments:

Post a Comment

Final assembly and test of the spindle nose adaptor - RESULT!!

After the recent distraction caused by the 3D scanner, resurrecting the 3D printer and buggering about with the throttle bodies for my Honda...