585,981 active members*
4,338 visitors online*
Register for free
Login
IndustryArena Forum > CAM Software > Uncategorised CAM Discussion > Help needed to Debug G41 G42 problem
Results 1 to 5 of 5
  1. #1
    Join Date
    Dec 2003
    Posts
    24221

    Help needed to Debug G41 G42 problem

    I am in the process of testing a new control and I am getting something quirky when using the G41 & G42 and I am not sure if it is me, my post processor or the control itself. I am trying to mill three circles with a Z feed in and Z feed up between each circle, What happens it come to the Z axis moves, wether rapid or feed down, I get a simultaneous X or Y move as though it is moving in and out of radius correction mode when moving between circles.
    This is a sample of code, Can anyone see where the problem might be.
    %
    O12
    N10 T1 M6
    N20 G90 S3200 M3
    N30 G0 Z.1
    N40 Y-.25
    N50 G0 G41 X0 Y.25
    N60 G1 Z-.125 F28.
    N70 G3 I0 J-.25
    N80 G1 Z-.26
    N90 G41 G3 I0 J-.25
    N100 G0 Z.1
    N110 G41 Y.6
    N120 G1 Z-.125 F8.
    N130 G3 I0 J-.6
    N140 G0 Z.1
    N150 G0 X0 Y.98
    N160 Z.1
    N170 G1 G41 F16.
    N180 G3 I0 J-.98
    N190 G0 Z.10
    N200 X0 Y1.462
    N210 G1 Z-.125
    N220 G2 I0 J-1.462
    N230 G1 Z-.26
    N240 G2 I0 J-1.462
    N250 G0 Z.1
    N260 G40 G49

    Thanks
    Al

  2. #2
    Join Date
    May 2004
    Posts
    83
    Al, on most controls, when you issue a G41, it stays in effect until a G40 is issued. Z moves can be made while in cutter comp, but not in conjunction with X and Y moves. I'm wondering if the repeated G41's are making it do wierd things. I see some Z moves are followed by another G41, but some are not, so I assume this isnt some control where a Z move cancels comp.....correct? Unless there's some reason for them being there, I'd edit out all the extra G41's and see what happens. It may not fix the problem, but at least the code will look more normal

  3. #3
    Join Date
    Apr 2003
    Posts
    3578
    what are you using to program this and what are the controls or the machine if I may ask.
    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)
    Cadcam
    Software and hardware sales, contract Programming and Consultant , Cad-Cam Instructor .

  4. #4
    Join Date
    Mar 2003
    Posts
    927
    Al,

    I would have to con cure with metlmunchr about G41 being modal with most controls, until canceled. So the duplicate G41 would not be necessary.

    That being the case, your moves between circles would be comp-ed also. This may be the weird moves you are seeing as the control comps the rapid moves instead of the normal "straight line" rapids your are used to.

    I also noticed that you have not called out a diameter number for the control (IE: D1 for tool #1). Not knowing your control's likes and dislikes, this may not matter.

    Line N140 to N190 appear to be cutting air as they are at clearance height. (z.10) Again maybe this is how you intended it to be.

    Also line N170 you have called out a G41 without any x/y move. This may not be accepted by some controls. As they need an x/y move on the same line as the G41/G42 call out. And some only accept a G01 or G00 move and not a G03/G02 move with the G41/G42.

    Just some ideas as I don't know what controller you are using.
    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)

  5. #5
    Join Date
    Dec 2003
    Posts
    24221
    Thanks Guys, I believe I have found it, The control does not use a standard D & H offsets for the tool, just H & a entry called a Kerf offset, I was using the Kerf instead of the H which has length and diameter.
    Bit odd ball but I as long as I can get around it. OK. I cleaned up the redundant G41 etc also.
    Thanks
    Al
    CNC, Mechatronics Integration and Custom Machine Design

    “Logic will get you from A to B. Imagination will take you everywhere.”
    Albert E.

Similar Threads

  1. G41 and G42 How are works ?
    By bunalmis in forum G-Code Programing
    Replies: 25
    Last Post: 06-29-2018, 01:31 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •