Menu

Creating

falldeaf
2016-06-10
2016-06-14
  • falldeaf

    falldeaf - 2016-06-10

    Hi Lars!

    I've got pycam working as part of a commandline toolchain to turn 2d dxf's into gcode for my custom implementation of a Magelangelo drawbot ( A 2d polargraph drawing robot). But the gcode that it's outputting is different than the gcode that the Makelangelo software outputs. I'm using the 'engrave' process which gets it very close mostly a list of 2d coordinates with a 'pen up and down' z change. Below is an example of what the Makelangelo software outputs. I read about a post-processing machine specific system in another forum post, is it possible to make custom versions? Or is there generally any way to process the gcode so that it matches without have to do dirty text based post processing?

    Thank you for any guidance you could offer!

    M101 T42.55 B-42.55 L-42.55 R42.55 I1 J1;
    D1 L3.0 R3.0;
    G00 G90;
    M06 T0;
    G00 Z50.0 F120.0;
    G04 P50;
    G00 F3500.0;
    G00 X-7.3623366 Y-204.67612;
    G00 Z90.0 F120.0;
    G04 P50;
    G00 F3500.0;
    G00 X-8.458519 Y-204.60669;
    G00 X-9.5425205 Y-204.53113;
    G00 X-10.614848 Y-204.44939;
    G00 X-11.676006 Y-204.36134;
    G00 X-5.5999656 Y-204.76483;
    G00 X-6.4873967 Y-204.72443;
    G00 X-7.3619065 Y-204.67612;
    G00 Z50.0 F120.0;
    G04 P50;
    G00 F3500.0;
    G00 X-10.686661 Y-198.89671;
    G00 Z90.0 F120.0;
    G04 P50;
    G00 F3500.0;
    G00 X-10.851079 Y-197.77538;
    G00 X-10.931402 Y-196.73613;
    G00 X-10.925154 Y-195.75955;
    
     
  • Lars

    Lars - 2016-06-10

    Did you already try to use pycam's GCode with your device?
    GCode is just like most other imperative descriptions: you can choose different paths while still reaching the same goal.
    If it does not work: could you post pycam's gcode for comparison?

     

    Last edit: Lars 2016-06-10
    • falldeaf

      falldeaf - 2016-06-13

      Thanks so much for your response! It wasn't working but I was able to figure out why by talking to the guy who wrote the gcode interpreter I'm using.

      Looks like two issues:

      "Pycam has many lines with no G command at the start. They are using a feature I only just learned about, which is to use the last-seen g command. Pycam is also expecting a rotating cutting tool (M3)."

      Is it possible to specify that g commands are explicitly expressed on each line? (If not this seems like it would be easy to fix with a post-processing script.)

      Also, is it possible to leave out rotating cutting tool commands? (Though I think this might also not be an issue, because the interpreter would just ignore these commands. And I could also remove these with a simple post processing script.)

      Thank you again for taking the time to respond to my last question.

       
  • Lars

    Lars - 2016-06-14

    I used the GCode implementation of LinuxCNC (http://linuxcnc.org/docs/html/gcode/overview.html) as a reference for pycam's output format.

    Both of your issues seem to be indeed good candidates for a small postprocessing script with sed, awk or something similar. Since pycam is not under active development for quite some time, this will probably be the best approach for you.

    Have fun!

     
  • falldeaf

    falldeaf - 2016-06-14

    That makes good sense and thanks for the reference standard!

    I'll take your advice and create a quick post-processing script. Thanks again for your time!

     

Log in to post a comment.