Skip to main content
/

Site Navigation

Your Account

Choose Language

Help

Revision to M670

Steve Miller

+[title|M670]
+
+
+==== M670: Set IO port bit mapping ====
+
+***Parameters***
+
+* ***Pnn:nn:nn...*** - List of logical port numbers that bits 0, 1, 2... control (supported in RRF2.x and earlier)
+* ***Cnnn*** - Used to specify the pin name(s) to be controlled (supported in RRF3), see [[RepRapFirmware_3_overview#Section_Pin_names|Pin Names]]
+* ***Tnnn*** - Port switching time advance in milliseconds
+
+***Notes***
+
+* In RRF3, the P parameter is removed. Use the new C parameter to specify the pin names to be used.
+
+Example - old code:
+
+[code]M670 T5 P220:221:222[/code]
+
+New code:
+
+[code]M670 T5 C"sx1509b.0+sx1509b.1+sx1509b.2"[/code]
+
+* RepRapFirmware 1.19 and later provides an optional P parameter on the G1 command to allow I/O ports to be set to specified states for the duration of the move. The argument to the P parameter is a bitmap giving the required state of each port. The M670 command specifies the mapping between the bits of that argument and logical port numbers. Optionally, the T parameter can be used to advance the I/O port switching a short time before the corresponding move begins.