Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Last revision Both sides next revision
g1 [2017/01/25 16:15]
arthur
g1 [2019/05/13 21:02]
arthur [Parameters]
Line 17: Line 17:
 The command is used as such :  The command is used as such : 
  
-[[code]]+<code>
 G1 X10 Y20 F30 G1 X10 Y20 F30
-[[/code]]+</code>
  
 Which means : move to X position 10, Y position 20, at a speed of 30 millimeters/​minute Which means : move to X position 10, Y position 20, at a speed of 30 millimeters/​minute
Line 26: Line 26:
  
 ||~ Parameter ||~ Usage ||~ Example || ||~ Parameter ||~ Usage ||~ Example ||
-|| {{X}} || Move to this position in the X axis || G1 X10 || +|| <kbd>X</​kbd> ​|| Move to this position in the X axis || G1 X10 || 
-|| {{Y}} || Move to this position in the Y axis || G1 Y10 || +|| <kbd>Y</​kbd> ​|| Move to this position in the Y axis || G1 Y10 || 
-|| {{Z}} || Move to this position in the Z axis || G1 Z10 || +|| <kbd>Z</​kbd> ​|| Move to this position in the Z axis || G1 Z10 || 
-|| {{A}} || Move to this position in the A axis || G1 A10 || +|| <kbd>A</​kbd> ​|| Move to this position in the A axis || G1 A10 || 
-|| {{B}} || Move to this position in the B axis || G1 B10 || +|| <kbd>B</​kbd> ​|| Move to this position in the B axis || G1 B10 || 
-|| {{C}} || Move to this position in the C axis || G1 C10 || +|| <kbd>C</​kbd> ​|| Move to this position in the C axis || G1 C10 || 
-|| {{E}} || Move to this position in the E ( extruder ) axis || G1 E10 || +|| <kbd>E</​kbd> ​|| Move to this position in the E ( extruder ) axis || G1 E10 || 
-|| {{F}} || Move at this speed in millimeters/​minute || G1 Z10 F100 || +|| <kbd>F</​kbd> ​|| Move at this speed in millimeters/​minute || G1 Z10 F100 || 
-|| {{S}} || Laser power, ​{{S1}} is 100%, {{S0}} is 0% || G1 X10 S0.5 ||+|| <kbd>S</​kbd> ​|| Laser power, ​<kbd>S1</​kbd> ​is 100%, <kbd>S0</​kbd> ​is 0% || G1 X10 S0.5 || 
 + 
 +<callout type="​warning"​ icon="​true"​ title="​Extruder moves and scientific notation">​ 
 + 
 +If you write this Gcode : 
 + 
 +<​code>​ G1X100E100 </​code>​ 
 + 
 +You want Smoothie to interpret it as :  
 + 
 +<​code>​  
 +G1 : move 
 +X10 : by 10mm in the X direction 
 +E10 : while feeding the extruder 10mm of extrusion 
 +</​code>​ 
 + 
 +However Smoothie is going to interpret this as  
 + 
 +<​code>​  
 +G1 : move 
 +X10E10 : move in X by 10E10, which is also 10 to the power of 10, or 10000000000. 
 +</​code>​ 
 + 
 +The lesson here is : use spaces. 
 +</​callout>​
  
 === Feedrate === Feedrate
  
-The {{F}} parameter is modal. The speed is remembered and each subsequent command uses it.+The <kbd>F</​kbd> ​parameter is modal. The speed is remembered and each subsequent command uses it.
  
 This means if you do :  This means if you do : 
  
-[[code]]+<code>
 G1 X10 F100 G1 X10 F100
 G1 X20 G1 X20
 G1 X30 F200 G1 X30 F200
 G1 X40 G1 X40
-[[/code]]+</code>
  
 The first two moves will happen at 100 mm/minute, and the last two moves will happen at 200mm/​minute. The first two moves will happen at 100 mm/minute, and the last two moves will happen at 200mm/​minute.
Line 56: Line 80:
 This means if you do : This means if you do :
  
-[[code]]+<code>
 G0 X10 F100 G0 X10 F100
 G1 X20 F200 G1 X20 F200
 G0 X30 G0 X30
-[[/code]]+</code>
  
 The third move will actually move at 100 mm/minute as that is the latest feedrate set for G0 moves. The third move will actually move at 100 mm/minute as that is the latest feedrate set for G0 moves.
Line 67: Line 91:
 === Default feedrate === Default feedrate
  
-If you have just started your Smoothieboard and have never sent a {{F}} parameter, your G1 moves will move at the default "​feed"​ feedrate.+If you have just started your Smoothieboard and have never sent a <kbd>F</​kbd> ​parameter, your G1 moves will move at the default "​feed"​ feedrate.
  
-This is set in the[[http://​smoothieware.org/​configuring-smoothie|configuration file]] by setting the {{default_feed_rate}} config option.+This is set in the [[http://​smoothieware.org/​configuring-smoothie|configuration file]] by setting the <kbd>default_feed_rate</​kbd> ​config option.
  
 === Modal use === Modal use
  
-The G1 command is modal, if a line doesn'​t contain any gcode, it is assumed to be a {{G0}} or a {{G1}} command depending on the latest used+The G1 command is modal, if a line doesn'​t contain any gcode, it is assumed to be a <kbd>G0</​kbd> ​or a <kbd>G1</​kbd> ​command depending on the latest used
  
 This means if you do :  This means if you do : 
  
-[[code]]+<code>
 G1 X10 G1 X10
  X20  X20
  Y10  Y10
-[[/code]]+</code>
  
 It is the same as doing :  It is the same as doing : 
  
-[[code]]+<code>
 G1 X10 G1 X10
 G1 X20 G1 X20
 G1 Y10 G1 Y10
-[[/code]]+</code>
  
 Note the space character before each modal line, without that space, Smoothie will not know this is a modal command. Note the space character before each modal line, without that space, Smoothie will not know this is a modal command.
Line 107: Line 131:
 This means if you do :  This means if you do : 
  
-[[code]]+<code>
 G90 G90
 G1 X10 G1 X10
 G1 X20 G1 X20
-[[/code]]+</code>
  
 Smoothie will move to the X position 10, then move to the X position 20, relative to the origin. Smoothie will move to the X position 10, then move to the X position 20, relative to the origin.
Line 117: Line 141:
 But if you do :  But if you do : 
  
-[[code]]+<code>
 G91 G91
 G1 X10 G1 X10
 G1 X20 G1 X20
-[[/code]]+</code>
  
 Smoothie will move 10 millimeters relative to the current position, then move 20 millimeters further away from that new position ( moving 30 millimeters total ). Smoothie will move 10 millimeters relative to the current position, then move 20 millimeters further away from that new position ( moving 30 millimeters total ).
Line 128: Line 152:
  
 These resources are used as references for Gcode :  These resources are used as references for Gcode : 
-*[[http://​linuxcnc.org/​docs/​html/​gcode.html|LinuxCNC Gcode list]] +* [[http://​linuxcnc.org/​docs/​html/​gcode.html|LinuxCNC Gcode list]] 
-*[[http://​reprap.org/​wiki/​G-code|Reprap Gcode list]]+* [[http://​reprap.org/​wiki/​G-code|Reprap Gcode list]]