1. Hey guyz. Welcome to the All New Phlatforum!



    Sign Up and take a look around. There are so many awesome new features.

    The Phlatforum is a place we can all hang out and

    have fun sharing our RC adventures!

  2. Dismiss Notice

Changing G-Code output Z-values and axis

Discussion in 'SketchUcam Help' started by J.Hainer, Sep 18, 2015.

  1. J.Hainer

    J.Hainer New Member

    Offline
    Messages:
    3
    Trophy Points:
    1
    Hello, Iam new to the Forum,
    At first I want to say THANK YOU ( sorry for Caps:) ) for the great Plugin;
    I hope you can help me with my Problem, I need to carve Letters into Plywood,
    There are many Words to cut and since our old Pentium 1 Computer stopped working
    I need to get G-code for the Carvings.

    Unfortunately my Machine needs the G- codes like in this post http://www.phlatforum.com/xenforo/threads/changing-gcode-out.2380/
    Besides that I need the Axis for drilling and carving in another Order, as follows first: X-Axis second: Y-Axis third: Z-Axis
    Since the Script has been overhauled completely, I did not find the Values for the Syntax-Change i have to do.

    Any Help would be very apreciated Thanks a lot, J.Hainer
     
  2. swarfer

    swarfer Moderator Staff Member

    Offline
    Messages:
    808
    Trophy Points:
    28
    Location:
    Grahamstown, South Africa
    If you have version 1.3a then you already have this:
    From the help
    Force all Gcodes on for Marlin
    FALSE (default) = use optimized Gcode output that does not repeat G commands if they are not needed
    TRUE = force output of G code on all lines, useful for Marlin firmware that requires this.​

    This item can be found on the Feature Options menu, if you don't know where that is, RTFM!
    hit the
    helptool_large.png
    in the toolbar (1)

    I don't fully understand this statement. axis words are always output in that order.

    If you mean that every line must have every axis word, ie all of X Y and Z words, then:
    a) upgrade your controlle;) seriously, being restricted like this means your controller is very old and you will be much happier with a new one since any 'modern' Gcode generator will generate optimized code that will be a problem to your controller.
    b) hire a programmer to write a post processor for you, that will take *any* Gcode format as input and output it in a format that your controller likes.

    c) you will have to delve into PhlatMill.rb and do some editing

    you will need to find *all* lines like
    if (xo != @cx)
    and change them to
    if ((xo != @cx) || @axisoverride)
    and similar for 'yo' and for 'zo'.
    Then add
    @axisoverride = true
    at the top of the file among the other preset globals like @debug

    This will force output on for all axis words even when the current position has not changed.
    (and you will have to do this every time you update SketchUcam, and yes, a new version is about 2 weeks away)
    Leaving out axis words, and also G words when the new line is doing the same move like G01, originated with paper tape readers and limited memory in the controllers. To save paper and memory, G01 and G00 (and others) are 'modal', once set, they stay in effect as the current 'mode' until changed by a new code. This is part of the Gcode language specification and a controller that does not support it is 'broken'.

    BTW, upgrading your machine will probably have the side benefit of it running faster.
    Running faster = more parts per hour = more money :doubleup:

    (1) a general note on help systems. The help that comes with your software is seldom perfect. However, it did take a programmer HOURS to write it, and programmers hate writing help, we would rather be programming!
    So, everyone, please read the help, it really will help you!
     
    Last edited: Sep 19, 2015
  3. J.Hainer

    J.Hainer New Member

    Offline
    Messages:
    3
    Trophy Points:
    1
    Thank You Swarfer,
    I activated the G-Codes for Marlin-Option, nice Feature.
    Didnt want to be such a dumb... who doesnt RTFM :sorry: but I am really in a Hurry and need to get this done as fast as possible, since my Customer needs the Parts on Tuesday.
    I did not mean I need the X,Y and Z in every Line, but now that I see the Commands,
    it outputs 2 g00`s in two seperate after another, one for Z-axis and one for X-and Y-axis.
    But It could be that its my fault because I tried to edit the PhlatMill.rb to fit
    the Output to the Machine.
    btw. it is a Morbidelli Author 503 from 1996 running on a Tria7500 , cant afford a new one now.
    The original separate PC for Programming stopped working and the Software runs only on DOS.
    Parts for this PC are very hard to get since it is a Slot- Pentium-Processor.
    Tried everything emulating Dos and to get the Dongle to work, but since the Serial Drivers of Win 7 64bit
    are no longer capable of accepting Hardware-Dongles and the other Software Solutions I know of are
    about 3000€ (quite expensive for a Software for a Machine where I dont know how long it will work)
    I need to look for another Solution.

    I Will read the Help !!!
    Promised !!!
    :)
     
  4. swarfer

    swarfer Moderator Staff Member

    Offline
    Messages:
    808
    Trophy Points:
    28
    Location:
    Grahamstown, South Africa
    well, reading the help would have been faster, that feature is mentioned on the front page in the release notes (-:
    a few clicks and you would have been producing code!
    If I had gone flying this morning you would have waited another 12 hours! >-:

    I have added about 11 things for the next version and need to write help for all of it..... so maybe I am a little touchy about help right now :angry: :banghead: LOL

    it does that on purpose, you want to retract Z before moving X and Y to 0 so you do not crash into anything.
    have you looked at FreeDOS? it is a relatively modern replacement for MSDOS and will run on new motherboards.

    and, you do not need to have a specific machine for it, you can run it in a virtual machine (like Microsoft Virtual machine) on your normal Windows desktop. The virtual machine is just a file on the harddrive and can be backed up along with all your other files so if the hardware dies you can just load it on a new computer.
    ah, ok, so running in a virtual machine will not work. Well, you should be able to get a new PC working with FreeDOS, and with some hassle with Windows, even dual boot it.
    have you looked at Vectric Vcarve Pro? and also Fusion 360. Fusion 360 is impressive, search youtube for NYC CNC and watch his videos about it. and you can try it for free for at least 30 days. Vcarve Pro is more geared toward doing flat panels and is probably even better for that machine.

    Although the new version of SketchUcam I am working on will be able to do toolchanges, I really think you need software that is geared toward multiaxis machines like that one, both for safety and for productivity.
    thank you (-:
     
  5. J.Hainer

    J.Hainer New Member

    Offline
    Messages:
    3
    Trophy Points:
    1
    Thanks a lot for reply Swarfer,:)
    I will definetly check out Vcarve and Fusion 360, thanks for the Hint.
    Setup of the old software is even more complicated than just setting up a dos-Enviroment
    since the Dongle-Drivers for the original Tria-Software are Windows-.ddl-based when I still
    know it correctly.

    Tried setting up the whole thing with FreeDos about a year ago and didnt get it to work together.
    I also tried setting up a virtual Windows XP since dos was still a Part of it plus the Dongle-Driver
    should work with it.
    The Problem here is if I set it up with an emulated PC lets say thru VMwarePlayer or something like
    that, the whole thing comunicates with the real hardware thru the emulated Hardware and thru the
    actual Drivers which really communicate with the Hardware and the whole Security-Dongle thing
    doesnt work because of the additional instances.

    Unfortunately for actual Hardware you dont get actual Drivers for XP.

    Thanks to you:doubleup: I now know of Vcarve, never heard before, but since The A503 is only 2.5D
    I think I will give it a try soon, I just check it out first.
    In the meantime I try to use SketchUcam output and replace the not matching Snippets with ReplaceText aka BK ReplaceEm.

    Have a nice Weekend.
    PS: I allready started reading the Manual :reading: and will keep reading tomorrow.
     

Share This Page