Order of instruction
-
Hello every one
I'm having an issue with my machine
I'm writing my GCode as POC and I was wondering if the order of instruction is important on Duet.
To be clear isG19 G2 F3183 X144.716 Y188.322 Z10.202 I0.394 J-0.919 K0.000
the same as
G2 G19 F3183 X144.716 Y188.322 Z10.202 I0.394 J-0.919 K0.000
I'm having some trouble with my printing and was wondering if it was possible that this was the origin of the issue
thanks a lot
-
@Jean-Baptiste The first one should be correct, as it is two separate commands, G19 then G2.
The second one is unlikely to work, and either you'll get a message about G2 missing parameters before the G19 is called, and then the rest of the line is ignored, or the G19 will be ignored as G isn't a valid parameter for G2. It doesn't really conform to the example given in the NIST Gcode standard, which RRF tries to adhere to: https://tsapps.nist.gov/publication/get_pdf.cfm?pub_id=823374 page 24.
In CNC mode, if a line of GCode does not begin with G or M (after skipping N and the line number, if present) but the previous command was G0, G1, G2 or G3, then the line is taken to be another G0, G1, G2 or G3 command. However, because you have a G19, I don't think the values will be related to the G2 command.
Ian
-
@droftarts Thanks for your confirmation on my issue...
I have discretization of every G1 movement at a moment long before any G2/G3 movement.
G1 Xxxx Yyyyy
This line does first the movement in X direction then in Y direction instead of doing it in the same time and I have no clue on why it does that
Any idea?
-
@Jean-Baptiste What version of RRF are you using? Are you using CNC mode? Is it sent as one line? If there's a line break between the Xxxx and Yyyy, you could be running into the feature that I highlighted in the last paragraph of my last post.
Ian
-
@droftarts For the Duet, I've got this:
RepRapFirmware for Duet 3 MB6HC version 3.5.0-rc.3 (2024-01-24 17:58:49) running on Duet 3 MB6HC v1.02 or later (SBC mode)
I'm not using CNC mode (I think, I'm not the one configuring it and we do 3D printers)
I send it as a single line, as it should be if we want a straight movement, isn't it? -
@Jean-Baptiste said in Order of instruction:
I send it as a single line, as it should be if we want a straight movement, isn't it?
yes it should be executed as a single movement. what kinematics do you have configured in config.g?
-
@Jean-Baptiste yes the order matters. Each G or M or T command in the line of GCode introduces a new command as far as RRF is concerned, and these commands are executed in order. So in the first of your examples RRF executes this:
G19
G2 F3183 X144.716 Y188.322 Z10.202 I0.394 J-0.919 K0.000In the second it is executes this:
G2
G19The other parameters in the second line will be ignored because the G19 command doesn't take any parameters.
Within each command, the order of the parameters doesn't matter.
-
@Jean-Baptiste said in Order of instruction:
@droftarts Thanks for your confirmation on my issue...
I have discretization of every G1 movement at a moment long before any G2/G3 movement.
G1 Xxxx Yyyyy
This line does first the movement in X direction then in Y direction instead of doing it in the same time and I have no clue on why it does that
Any idea?
My reply that the command should be executed in one move was in reference to this comment.
-
Turns out my colleague made another post on the forum, I'll leave them handle this issue.
It seems to be linked with circular interpolation on a beta version, I don't have more intel on it.Thanks for your help