Results 1 to 8 of 8

Thread: This should be easy...

  1. #1
    Registered
    Join Date
    Mar 2007
    Location
    UK
    Posts
    534
    Downloads
    0
    Uploads
    0

    This should be easy...

    N20 G01 X94.625 Y125.000 F320.000
    N21 G03 X85.000 Y134.625 R9.625 F320.000

    So I get the start and end points on the arc, the radius and the direction.

    Unless the separation happens to be 2r there are two possible solutions, two possible locations for the centre of the arc.

    Find one center, mirror it across the two points and get another possible center.

    Perhaps I missing something, not understanding

    Terminally frustrating, have 3 axis mill, have g-codes, need to write an interface, not an Ixxx or Jxxx in sight, stuck, HELP


  2. #2
    Community Moderator ger21's Avatar
    Join Date
    Mar 2003
    Location
    Shelby Twp, MI....USA
    Posts
    22213
    Downloads
    0
    Uploads
    0
    G3 is CCW, G2 is CW. There's only one way to do the arc in your code. Where you may run into problems is arcs of greater than 180°. Then you should either split them up, or use IJ arcs instead of R arcs.
    Gerry

    Mach3 2010 Screenset
    http://home.comcast.net/~cncwoodworker/2010.html

    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)


  3. #3
    Registered
    Join Date
    Mar 2007
    Location
    UK
    Posts
    534
    Downloads
    0
    Uploads
    0
    Well done Gerry

    I put in a >180 degree arc and it obligingly split it in to 2.

    So I simply calculate both arcs and cut the shorter.

    Many thanks

    Robin


  4. #4
    Registered dcoupar's Avatar
    Join Date
    Mar 2003
    Location
    USA
    Posts
    2516
    Downloads
    0
    Uploads
    0
    Robin,

    Many CNC's (Fanuc, Yasnac, Haas, etc.) allow R for any arc up to 359.999 degrees. Only one stipulation: If arc is 180 degrees or less, program R, if arc is greater than 180 degrees, program R-(minus). Full circles require I & J.

    Dave


  • #5
    Registered
    Join Date
    Mar 2007
    Location
    UK
    Posts
    534
    Downloads
    0
    Uploads
    0
    I've done that bit...

    Other G codes he's using (G-Simple), is there a list somewhere? No sticky?

    G28 Rapid move to origin.
    Where the heck is origin? 0,0? 0,0,0 would be a disaster in the making First co-ordinate? Somewhere of my choosing? Can't see him setting it anywhere, he uses it before a tool change.

    G54-59 Select co-ordinate system
    Only found G54, presumed it is for absolute, but he also uses...

    G90 Absolute distance mode.


  • #6
    Community Moderator ger21's Avatar
    Join Date
    Mar 2003
    Location
    Shelby Twp, MI....USA
    Posts
    22213
    Downloads
    0
    Uploads
    0
    What control are you using? G codes can vary a bit between controls. With that in mind, here's a list.
    http://www.teskolaser.com/gcode_list.html

    As for G28, you usually need to "home" the machine or manually pick a reference point before calling G28. Yes, it should be 0,0,0.

    G54-G59 = user defined coordinate offsets

    G90 = move to absolute coordinates, vs G91= move incrementally from prevoius location.
    Gerry

    Mach3 2010 Screenset
    http://home.comcast.net/~cncwoodworker/2010.html

    (Note: The opinions expressed in this post are my own and are not necessarily those of CNCzone and its management)


  • #7
    Registered
    Join Date
    Mar 2007
    Location
    UK
    Posts
    534
    Downloads
    0
    Uploads
    0
    Hi Gerry

    I'm using G-Simple on account of it's a freebie and can accept my dxf's.

    I'm driving the steppers on my mill through the paralel port on a DOS machine using the timer interrupt. All the stepping command stuff happens in the background, so I can fool about doing fancy graphics on screen until the Active flag goes away. I kinda built the hardware and wrote the software before I discovered cnczone and realised I didn't have to

    OTOH it does make it very easy to patch.

    This program I'm writing converts the G codes to my own format which is a sort of compressed dxf.

    best regards

    Robin


  • #8
    Registered
    Join Date
    Feb 2007
    Location
    Greece
    Posts
    41
    Downloads
    0
    Uploads
    0

    G28 and GSimple

    (From Haas operators manual)
    G28 Return To Reference Point

    The G28 code is used to return to the machine zero position on all axes. If an X,Y,Z or A is specified on the same block (meaning the same line), only those axis will move and return to the machine's zero point. If X,Y,Z or A specifies a different location that the current location, the the movement to machine zero will be through the specified point...

    GSimple programs (usually) contain following lines:

    G28 G91 Z0 (near the beginning of the program)

    G28 G91 Z0
    G28 G91 Y0 (near the end of the program)

    G28 G91 Z0 will move to the Z origin (that is move the tool up) through a point which is 0 mm (or inch) away from the current (G91 means relative position) -that is through the current point.

    This part of the code is just for security. The machine will move up and then execute the rest of the code.

    G28 G91 Y0 drives the table out, so you can easily reach your part.

    By the way, these commands are nor "hardwired" into GSimple. Look in the configuration file, and you will find following lines:

    # Program will start with a G28 G91 Z0 (move z axis to mashine origin)
    PROGSTART G28 G91 Z0

    # And will end with
    # Semicolons are used as line separators
    PROGEND G28 G91 Z0;G28 G91 Y0;G90


    If you delete them (or make them comments by inserting a # at the start of the line) G28 will disappear from the code (with the execption of the Drill-Cleaning Option selecteable through the G-Code/make Options menu)


  • Similar Threads

    1. Easy Being Green...& Your Job
      By fizzissist in forum Environmental & Alternate Energy
      Replies: 16
      Last Post: 05-22-2007, 01:15 PM
    2. How easy is it?
      By SPD in forum Employment Opportunity
      Replies: 26
      Last Post: 03-03-2007, 02:50 AM
    3. Easy CNC and Easy Stepp'n
      By kylecroft in forum CNCzone Club House
      Replies: 5
      Last Post: 02-18-2007, 12:54 PM
    4. Pro Nc And Easy Dnc
      By SMACUSTOMS in forum General CNC (Mill and Lathe) Control Software (NC)
      Replies: 0
      Last Post: 05-07-2006, 06:08 PM
    5. Please be easy, I'm new
      By sin-city-custom in forum General Metal Working Machines
      Replies: 4
      Last Post: 03-01-2005, 11:20 AM

    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.