@droftarts said in MMU - Single nozzle, multi material (filament):

Another thought: rather than use the endstop to trigger the Arduino, you could connect the wire to a spare output on the Duet, define it as an output with M950, and control the signal with M42, and trigger it that way. You could also use the either the tool change mechanism built into RRF to do the filament change (see here for the tool change macros

How would one do the above. Arduino board requires 5V to the pin, currently triggered by the limit switch, GPIO can also output 5V?
Is there an example for similar connections?
Ok, I believe I found that 3.3V is sufficient to trigger the input on Arduino.

Would this be good code?

; Define GPIO pin 1
M950 P1 C"exp.heater4" Q500 ; Allocate GPIO port 1 to heater4 on expansion connector, 500Hz

; Control GPIO pin 1 for 0.15 seconds
M42 P1 S1 ; Set GPIO pin 1 to high
G4 P150 ; Pause for 0.15 seconds (150 milliseconds)
M42 P1 S0 ; Set GPIO pin 1 to low