Issues with Custom G-Code in Matter Control



  • Matter control appears to be adjusting my custom G-code. This seems to happen in both End g-code and cancel g-code.

    My cancel G-code is below:


    M104 S0 ; turn off temperature

    G91 ; Enable relative mode

    G1 Z10

    G90 ; Back to absolute

    G1 X10 Y200

    M84;


    However the G91 is never sent to the printer only the G90.

    If i simplify the G-Code down to


    M104 S0 ; turn off temperatureG1 X10 Y200M84;

    Then matter control seems to send G1 Z10 Y200 Z0

    I can't come up with any reason why it isn't just sending the commands as typed, if I send them via the terminal they do exactly what I expect, but when mattercontrol auto executes everything goes weird!


    Any suggestions?



  • There's a couple of facets to this issue.

    First, MatterControl does filter G-Code and make changes to certain commands, G91 included. Check this page for more information about exactly what changes are made: http://wiki.mattercontrol.com/G-Code_Filtering

    Second, the G91 change should work but as @unlimitedbacon pointed out to me as he tried to run your code to reproduce the problem there is no feed rate specified in your G1 Z10 command; the error "Error: Undefined feed rate" was thrown. Specify a feed rate with the F parameter, so:

    G1 Z10 F5000

    or something like that. Your code should then run just fine.


Log in to reply
 

Looks like your connection to MatterHackers Community was lost, please wait while we try to reconnect.