While looking into G-code I was wondering why Cura inserts G0 commands in between G1 commands every other line like this:

G1 F2400 X144.612 Y130.187 E1652.56358
G0 F6000 X144.612 Y129.621
G1 F2400 X72.905 Y57.914 E1654.16570
G0 F6000 X73.471 Y57.914
G1 F2400 X144.612 Y129.056 E1655.75518
G0 F6000 X144.612 Y128.490
G1 F2400 X74.036 Y57.914 E1657.33203
G0 F6000 X74.602 Y57.914
G1 F2400 X144.612 Y127.924 E1658.89623
G0 F6000 X144.612 Y127.359

It seems like it wants to move to a slightly offset starting position for the next extrusion. I dont understand why, though. It wants to have touching lines as a result, doesn't it?

I do see this making sense in a fill situation, - this section is called 'type: skin'. How does slic3r get away doing infill without this?

Am I correct to read slic3r gcode correctly to use G1 instead of G0 commands for this?

  • 1
    $\begingroup$ It might be a smoothing-type option set in your slicing engine. Smoothing essentially performs an action similar to this. $\endgroup$
    – tbm0115
    Jan 5, 2017 at 1:34

1 Answer 1


Formally, G0 is a rapid move and G1 is a coordinated move. A G1 will cause the printhead to move in a straight line from the begin to the end position, whereas a G0 allows the printhead to move in any curve, so long as it ends up in the target position. Because of acceleration and deceleration constraints, it can sometimes be faster to move in a curve rather than a straight line.

However, I don't think any actually firmware implements this, and a G0 behaves in the exact same way as a G1.

What the piece of G-code you posted is doing is creating a solid infill, which consists of a bunch of parallel lines, each slightly offset from the next:

Section of G-code render, showing parallel lines of solid inflil.

It makes sense that no material is extruded when it moves from one line to the other, as otherwise too much material would get deposited at the edge.

  • $\begingroup$ If you set the pattern to Zig Zag then Cura will shorten the long infill lines a bit and connect them with a printed line in such a way that you don't deposit too much material. $\endgroup$ Jul 30, 2017 at 10:02

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .