DUEX GPIO configuration
-
I'm currently running a Duet and Duex5, and trying to control some external pumps and solenoids. I would like to trigger the solenoid using a gpio, but I have read the documentation and it's as clear as mud to me. I don't need high current, just a simple on and off for switching a MOSFET through gcode. I have no hotends and no fans, i'm using the Duet+Duex for controlling fluid dispensing on the E3D toolchanger.
So far I have tested:
-
Turning on and off existing fans I/Os with:
M106 P7 S1.0. ; Turns on Fan7(according the PCB label)
I have also set the fan voltage jumper to both 5V and 12V with no detectable voltage -
M307 P27 I-1. ;Disable fan 7? Not sure
M42 P27 S1.0 ;Turn on what was Fan7 output to high?
I also tried using the Duex GPIO pins which is my preferred method, but I honestly find the pin documentation sheet to be unreadable:
https://duet3d.dozuki.com/Wiki/Duet_2_Pinout_table.
What am I missing? Is there an example I can go off of that someone else had done for triggering something similar?Board: Duet WiFi 1.02 or later + DueX5
Firmware: RepRapFirmware for Duet 2 WiFi/Ethernet 2.05.1 (2020-02-09b1)
Duet WiFi Server Version: 1.23 -
-
@npretor said in DUEX GPIO configuration:
M307 P27 I-1. ;Disable fan 7? Not sure
M42 P27 S1.0 ;Turn on what was Fan7 output to high?- If you want to use
M42
, you must first unmap the fan port.
This is done by commandM106 P7 I-1
, P7 refers to Fan #7 on the duex board. - Now you can use
M42 P27 S255
to set the pin High orM42 P27 S0
to set the pin low.
P27 is the logical pin number for Fan #7 as shown in the documentation - Be aware that the Duet board switches V- of the port, V+ is set to the Fan voltage jumper selection
- If you want to use
-
Ok thank you, appreciate the reply. I'll give it a shot!