Page 1 of 2 12 LastLast
Results 1 to 12 of 19

Thread: Why does my Gcode not work? Bobcad to Mach3

  1. #1
    Registered
    Join Date
    Aug 2007
    Location
    New Zealand
    Posts
    44
    Downloads
    0
    Uploads
    0

    Why does my Gcode not work? Bobcad to Mach3

    Can someone please help me figure out what is going on with my Gcode, when i run a simulation under bobcad it looks perfect, when i import the code into Mach3 it looks mental. (the not blue part)
    I'm thinking it has to be my post processor.



    GCODE:

    %
    O1(LID)
    G17 G90 G40 G80 G54
    G00 Z1.
    X4.5158 Y2.5119
    G01 Z-1.4286 F100.
    G02 X2.5158 Y4.5119 I0. J2. F600. G41
    G01 Y48.5119
    G02 X4.5158 Y50.5119 I2. J0.
    G01 X36.5158
    G02 X38.5158 Y48.5119 I0. J-2.
    G01 Y4.5119
    G02 X36.5158 Y2.5119 I-2. J0.
    G01 X4.5158 G40
    Z-2.8571 F100.
    G02 X2.5158 Y4.5119 I0. J2. F600. G41
    G01 Y48.5119
    G02 X4.5158 Y50.5119 I2. J0.
    G01 X36.5158
    G02 X38.5158 Y48.5119 I0. J-2.
    G01 Y4.5119
    G02 X36.5158 Y2.5119 I-2. J0.
    G01 X4.5158 G40
    Z-4.2857 F100.
    G02 X2.5158 Y4.5119 I0. J2. F600. G41
    G01 Y48.5119
    G02 X4.5158 Y50.5119 I2. J0.
    G01 X36.5158
    G02 X38.5158 Y48.5119 I0. J-2.
    G01 Y4.5119
    G02 X36.5158 Y2.5119 I-2. J0.
    G01 X4.5158 G40
    Z-5.7143 F100.
    G02 X2.5158 Y4.5119 I0. J2. F600. G41
    G01 Y48.5119
    G02 X4.5158 Y50.5119 I2. J0.
    G01 X36.5158
    G02 X38.5158 Y48.5119 I0. J-2.
    G01 Y4.5119
    G02 X36.5158 Y2.5119 I-2. J0.
    G01 X4.5158 G40
    Z-7.1429 F100.
    G02 X2.5158 Y4.5119 I0. J2. F600. G41
    G01 Y48.5119
    G02 X4.5158 Y50.5119 I2. J0.
    G01 X36.5158
    G02 X38.5158 Y48.5119 I0. J-2.
    G01 Y4.5119
    G02 X36.5158 Y2.5119 I-2. J0.
    G01 X4.5158 G40
    Z-8.5714 F100.
    G02 X2.5158 Y4.5119 I0. J2. F600. G41
    G01 Y48.5119
    G02 X4.5158 Y50.5119 I2. J0.
    G01 X36.5158
    G02 X38.5158 Y48.5119 I0. J-2.
    G01 Y4.5119
    G02 X36.5158 Y2.5119 I-2. J0.
    G01 X4.5158 G40
    Z-10. F100.
    G02 X2.5158 Y4.5119 I0. J2. F600. G41
    G01 Y48.5119
    G02 X4.5158 Y50.5119 I2. J0.
    G01 X36.5158
    G02 X38.5158 Y48.5119 I0. J-2.
    G01 Y4.5119
    G02 X36.5158 Y2.5119 I-2. J0.
    G01 X4.5158 G40
    G00 Z1.


    Please help.
    Last edited by jrslick22; 03-08-2010 at 11:20 PM. Reason: img linking


  2. #2
    Registered
    Join Date
    Jan 2006
    Location
    USA
    Posts
    610
    Downloads
    0
    Uploads
    0
    My version of Mach (v3.042.029) actually renders the toolpath a little differently. I'm just seeing the blue and white and not the extra purple arcs. NCPlot does not show the odd white and purple arcs at all. (BTW, NCPlot is a nice program to have installed, just to do a sanity check on your code when these things happen.)

    If you single step through the code in Mach, it looks perfect. The correct movements are highlighted and I don't see any funny business. The odd stuff looks like it might should on the last straight (G01) line movement before the next downward Z movement.

    Those G01 moves have a G40 (cutter compensation off) at the end. I don't use cutter comp, so I don't know what Mach expects. I see G41 (cutter comp on) but I don't see any values indicating how much to offset for the cutter diameter.

    If you comment out the G40 codes (just use ;G40) then Mach renders everything ok. My guess it you are using a bad post processor or something is funny with the way Mach is setup to handle cutter comp.

    What happens if you try and run the code? No cutting, just set a safe Z height and run the code.

    Steve


  3. #3
    Gold Member dertsap's Avatar
    Join Date
    Oct 2005
    Location
    canada
    Posts
    3,878
    Downloads
    0
    Uploads
    0
    you can't apply cutter comp in an arc move
    use a right angle lead in
    A poet knows no boundary yet he is bound to the boundaries of ones own mind !! ........
    http://microcarve.microcarve.biz/


  4. #4
    Registered
    Join Date
    Aug 2007
    Location
    New Zealand
    Posts
    44
    Downloads
    0
    Uploads
    0
    Quote Originally Posted by stevespo View Post
    My version of Mach (v3.042.029) actually renders the toolpath a little differently. I'm just seeing the blue and white and not the extra purple arcs. NCPlot does not show the odd white and purple arcs at all. (BTW, NCPlot is a nice program to have installed, just to do a sanity check on your code when these things happen.)

    If you single step through the code in Mach, it looks perfect. The correct movements are highlighted and I don't see any funny business. The odd stuff looks like it might should on the last straight (G01) line movement before the next downward Z movement.

    Those G01 moves have a G40 (cutter compensation off) at the end. I don't use cutter comp, so I don't know what Mach expects. I see G41 (cutter comp on) but I don't see any values indicating how much to offset for the cutter diameter.

    If you comment out the G40 codes (just use ;G40) then Mach renders everything ok. My guess it you are using a bad post processor or something is funny with the way Mach is setup to handle cutter comp.

    What happens if you try and run the code? No cutting, just set a safe Z height and run the code.

    Steve
    Im using the Post called Mach of the artsoft website along with the scrips that are also provided as part of the download. is there a newer ver. than this?
    machine is at the workshop so i can try cutting at safe Z. but i can say that the mach on the mill also shows the funny business.

    Ideas


  • #5
    Registered
    Join Date
    Jan 2006
    Location
    USA
    Posts
    610
    Downloads
    0
    Uploads
    0
    Post your .bbcd file and I'll try and take a look at it tomorrow.

    Like I said, I don't use cutter comp, but dertsap says you can't use G41 on an arc and I believe him. Change your lead in and see if that improves anything.

    Also, are you sure you're using the Mach3-Router.MillPst post processor? I don't remember what the installation process was, but it should be visible in your CAM tree.

    Steve


  • #6
    Gold Member dertsap's Avatar
    Join Date
    Oct 2005
    Location
    canada
    Posts
    3,878
    Downloads
    0
    Uploads
    0
    1 problem that I've noticed with bobcad is that when g 41 or g42 is used it will program to the center of the tool , so you will need to add the d comp into your tool offsets manually or you can add a g10 to your code so that the program will put the compensation in there for you , other than that you will have undersized parts .
    A poet knows no boundary yet he is bound to the boundaries of ones own mind !! ........
    http://microcarve.microcarve.biz/


  • #7
    Registered CNCRim's Avatar
    Join Date
    Feb 2006
    Location
    usa
    Posts
    949
    Downloads
    0
    Uploads
    0
    don't see anything wrong with your program...... my backplot is fine, I think Mach itself have trouble. Check the Mach setting, that's all I can see is wrong.
    The best way to learn is trial error.


  • #8
    Gold Member dertsap's Avatar
    Join Date
    Oct 2005
    Location
    canada
    Posts
    3,878
    Downloads
    0
    Uploads
    0
    mach is fine , i put the code into my mach and had the same reaction , removed the g41 and all is good
    the problem is the d comp on an arc
    A poet knows no boundary yet he is bound to the boundaries of ones own mind !! ........
    http://microcarve.microcarve.biz/


  • #9
    Registered
    Join Date
    Mar 2010
    Location
    China
    Posts
    22
    Downloads
    0
    Uploads
    0
    do not suggest use PC to control machine. PC can do many good jobs but that is also its weakness. suggest use a professional controller like DSP or Syntec(with screen)


  • #10
    Registered
    Join Date
    Aug 2007
    Location
    New Zealand
    Posts
    44
    Downloads
    0
    Uploads
    0
    The reason i suggested it was the post.p was because my mill has and does run perfectly.
    Mach in my opinion is a great product, the PC its running has also been problem free and versatile. will DSP or Syntec play Movies or MP3's while its running a job?

    Of course finding the solution to this problem may change all this.


  • #11
    Registered
    Join Date
    Aug 2007
    Location
    New Zealand
    Posts
    44
    Downloads
    0
    Uploads
    0
    I found this post http://www.machsupport.com/forum/ind...ic,3820.0.html and have recreated the code using it, so far i have not produced the junk.

    I would have thought that a decent post for Bobcad and Mach3 would have been really easy to find, the artsoft website only had an old Mach1 post.
    Do peapol make there own? what are you other Mach+bobcad guys using.
    I use to have a perfect one by Sorin on my old machine but lost it when the HD failed. i have since been on Sorins website to DL the same one but can only seem to find posts for everything except Mach.


  • #12
    Registered
    Join Date
    Dec 2008
    Location
    canada
    Posts
    226
    Downloads
    0
    Uploads
    0
    Hi there,
    One thing is the I J commands are incremental in your code, but your machine in in absolute, you could try adding a g91.1 for incremental IJ to the file right after the g90. then its correct every time you run the file, but if you also do stuff in IJ absolute add a g90.1 to the other files...
    Second the white lines are something to do with cutter compensation. It is showing a weird curve because the CC is turned off for the z move then back on again. Third, I did a couple of experiments with the CC and found that unless I specified the tool# on the g41 line the CC did not make an offset.

    So
    G41 P1
    Would be cutter comp. keep left, using the diameter(radius?) of tool #1 in the tool table.
    Last the cutter comp needs some sort of lead in to get the tool in the correct position for cutting. the easiest might be just to start above your work and do an extra thickness cut in "AIR" but on more complex parts that might become an issue.

    If your software will do it, I suggest you let the CAM do the cutter compensation for the tool and not the controller.


  • Page 1 of 2 12 LastLast

    Similar Threads

    1. Need Help!- Can Bobcad be coaxed into making gcode for a 4 axis hot wire machine?
      By seanreit in forum BobCad-Cam
      Replies: 14
      Last Post: 06-03-2010, 04:56 AM
    2. Conditional gcode execution in Mach3
      By bobeson in forum Tormach Personal CNC Mill
      Replies: 5
      Last Post: 12-13-2009, 09:39 PM
    3. Condition gcode execution is possible in Mach3
      By bobeson in forum G-Code Programing
      Replies: 2
      Last Post: 12-05-2009, 02:20 PM
    4. Replies: 7
      Last Post: 12-14-2006, 01:33 PM
    5. Shoptask CNC Lathe and Mach3: Gcode delima
      By KaptainKarst in forum Shopmaster/Shoptask
      Replies: 20
      Last Post: 08-05-2006, 06:55 PM

    Posting Permissions


     


    About CNCzone.com

      We are the largest and most active discussion forum from DIY CNC Machines to the Cad/Cam software to run them. The site is 100% free to join and use, so join today!

    Follow us on

    Facebook Dribbble RSS Feed


    Search Engine Friendly URLs by vBSEO ©2011, Crawlability, Inc.