G Codes in Marlin: Difference between revisions
Jump to navigation
Jump to search
(4 intermediate revisions by the same user not shown) | |||
Line 3: | Line 3: | ||
==IO Pin Activation== | ==IO Pin Activation== | ||
*M42 - [http://marlinfw.org/docs/gcode/M042.html] - Ex: M42 P5 S255 (set digital pin 5 to on). Internet sez: ''For a non-PWM digital pin you need to put S0 (or any value <128) to turn off and S255 (or any value >=128) to turn on.'' | *M42 - [http://marlinfw.org/docs/gcode/M042.html] - Ex: M42 P5 S255 (set digital pin 5 to on). Internet sez: ''For a non-PWM digital pin you need to put S0 (or any value <128) to turn off and S255 (or any value >=128) to turn on.'' | ||
*Which pins are available? D0 is the first most convenient at AUX ports - see Mega pins - [https://wiki.opensourceecology.org/wiki/File:Megapins.png] | *Which pins are available? | ||
**D0 is the first most convenient at AUX ports - see Mega pins - [https://wiki.opensourceecology.org/wiki/File:Megapins.png] | |||
**For 2 adjacent pins with ground - use GND - D63. | |||
**Thus - to turn on a gas solenoid for the [[CNC Torch Table v19.10]], use M42 P63 S255. To turn it off, set state to 0. | |||
**D1 if use 5v gnd D1 as an adjacent triplet. This would be M42 P1 S255 | |||
*M42 P57 S0 | |||
=Links= | =Links= |
Latest revision as of 10:12, 28 November 2019
See list at the Marlin site - http://marlinfw.org/meta/gcode/
Top Used
IO Pin Activation
- M42 - [1] - Ex: M42 P5 S255 (set digital pin 5 to on). Internet sez: For a non-PWM digital pin you need to put S0 (or any value <128) to turn off and S255 (or any value >=128) to turn on.
- Which pins are available?
- D0 is the first most convenient at AUX ports - see Mega pins - [2]
- For 2 adjacent pins with ground - use GND - D63.
- Thus - to turn on a gas solenoid for the CNC Torch Table v19.10, use M42 P63 S255. To turn it off, set state to 0.
- D1 if use 5v gnd D1 as an adjacent triplet. This would be M42 P1 S255
- M42 P57 S0