<p>No, M108 does not do that. You are looking for <strong>T#</strong>, where # is the tool position you want:</p>

<pre><code>T1 ; switch to tool position 1 

T3 ; switch to tool position 3 
</code></pre>

<p>This tells the processor to send all heating, cooling and flow commands to this tool until another tool change is specified, and invokes the X/Y(/Z) offset for the new tool position.</p>

<p>See <a href="http://reprap.org/wiki/G-code#T:_Select_Tool" rel="nofollow noreferrer">http://reprap.org/wiki/G-code#T:_Select_Tool</a></p>

CC BY-SA 3.0
2017-03-08T12:25:55.697Z
2017-04-07T16:29:28.217Z
2017-04-07T16:29:28.217Z
Davo
<p>As @tbm0115 has mentioned - it differs. Your <code>M108 T{index of tool}</code> command is perfectly fine on some FlashForge printers, a company known for its different sorts of proprietary code. It is indeed used for tool changing here.</p>
<p>While on the common Marlin firmware (e.g. used on the popular Creality Ender printers), <code>M108</code> does a completely different thing-namely acting as a break sequence if the G-code parser is in a closed-loop-condition (after certain commands like <code>M109</code> that wait until a certain action takes place).</p>

CC BY-SA 4.0
2021-01-26T14:56:26.587Z
2021-01-26T15:25:53.923Z
2021-01-26T15:25:53.923Z
Yannik Z.
<p>I have been playing around with creating scripts to generate some custom G-code for a Malyan M180 and I am having trouble understand what commands to use to switch nozzles. Sometimes I can get the nozzles to switch and it doesn't recenter but sometimes it does.
I have been using:</p>
<pre><code>G54
M108 T0; switch to left
</code></pre>
<p>and</p>
<pre><code>G55
M108 T1; switch to right
</code></pre>
<p>Has anyone else looked into this and have any idea what commands or sequence of commands should be used to change nozzles?</p>

CC BY-SA 3.0
2017-03-09T15:19:44.450Z
Be careful with questions about G-Code as it is no longer standardized and can technically be different between manufacturers and even between models. This is true across all machines (mills, lathes, 3d printers, routers, etc.)
tbm0115
CC BY-SA 3.0
2017-04-10T22:27:55.907Z
Adding on to tbm0115's comment, G-code differs across firmwares, and can change between firmware releases. The reprap wiki, linked in one of the answers, attempts to provide information for the most popular 3D printing firmwares, but it is not always accurate or up-to-date.
K .
<g-code><dual-nozzle>
What G-code commands tell the printer to change nozzle on a dual extruder printer?
user802599
# What G-code commands tell the printer to change nozzle on a dual extruder printer?

(Asked by: username_0 on 2017-03-08)

I have been playing around with creating scripts to generate some custom G-code for a Malyan M180 and I am having trouble understand what commands to use to switch nozzles. Sometimes I can get the nozzles to switch and it doesn't recenter but sometimes it does.
I have been using:
G54
M108 T0; switch to left

and
G55
M108 T1; switch to right

Has anyone else looked into this and have any idea what commands or sequence of commands should be used to change nozzles?

**Tags:** g-code, dual-nozzle
> **Comments:**
> **username_1**: Be careful with questions about G-Code as it is no longer standardized and can technically be different between manufacturers and even between models. This is true across all machines (mills, lathes, 3d printers, routers, etc.)  
> **username_2**: Adding on to tbm0115's comment, G-code differs across firmwares, and can change between firmware releases. The reprap wiki, linked in one of the answers, attempts to provide information for the most popular 3D printing firmwares, but it is not always accurate or up-to-date.  

---

## 2 answers

### Answer by username_3 on 2017-03-08. Score: 3 | Accepted answer

No, M108 does not do that. You are looking for T#, where # is the tool position you want:
T1 ; switch to tool position 1 

T3 ; switch to tool position 3 

This tells the processor to send all heating, cooling and flow commands to this tool until another tool change is specified, and invokes the X/Y(/Z) offset for the new tool position.
See http://reprap.org/wiki/G-code#T:_Select_Tool


---

### Answer by username_4 on 2021-01-26. Score: 1

As @tbm0115 has mentioned - it differs. Your `M108 T{index of tool}` command is perfectly fine on some FlashForge printers, a company known for its different sorts of proprietary code. It is indeed used for tool changing here.

While on the common Marlin firmware (e.g. used on the popular Creality Ender printers), `M108` does a completely different thing-namely acting as a break sequence if the G-code parser is in a closed-loop-condition (after certain commands like `M109` that wait until a certain action takes place).


---

