Driver support bipolar stepper motors for 3 axes. They are named A/B/C and usually have defined function:
$S
- Return version stringCommand returns version string concentrated into single line [EVB.1.0.2, SCF4-M RevB, Kurokesu, 5DDFF39-3739584E-xxxxxxxx
] received information is comma separated:
EVB.1.0.2
- Module firmware versionSCF4-M RevB
- Module PCB revisionKurokesu
- Manufacturer Brand5DDFF39-3739584E-xxxxxxxx
- Unique serial numberG0
- Rapid positioningThe main motor drive command. It moves motor specified number steps. Any or all axes can be specified at the same time. Minimal step size is 1. G0
command replies as soon as the command is parsed and does not wait until motors stop.
G0 A100
] - drives A-axis 100 stepsG0 A-100
] - drives A-axis -100 stepsG0 A100 B-100 C1000
] - drives all three axes by specified step countG4
- WaitInstructs controller to delay (stall) defined interval in milliseconds [ms]. This is an only command which sends response not after parsing command but after prolonged execution time. During this time command parser is blocked and the only way to complete this command is to wait until it finishes.
G90
- Relative coordiantesSwitch to relative coordinate programming mode. Motors can be instructed to turn positive or negative 0 ~ 65535 steps (16-bits). When the counter exceeds this range, it will overflow. And will not affect motor movement.
G91
- Absolute coordiantesSwitch to absolute coordinate programming mode. In this mode, the range is limited by the internal 16-bit motor register and can be operated in a range of 0 ~ 65535.
G92
- Set positionThe controller sets an internal counter to the specified value.
G92 A0
] - Set A axis counter to 0G92 A100
] - Set A axis counter to 100G92 A100 B1000 C200
] - Set all axis counters to specified counter valuesM0
- Compulsory stopIf the controller is not in G4 delay mode it will instruct motors to stop moving
M7
and M8
- Infrared filter switch commandsInstructs controller to shift filter one of two fixed positions
M230
and M231
- normal / forced moveM0
or reset command is issued. PIN_x is connected to internal 12bit Analog to Digital Converter (ADC), lower and upper thresholds can be controlled with M232
commandM232
- Set PI low/high detection voltageSet 12bit comparator values for limit switch detection inputs. Upper voltage is 3.3V, lower - 0V
M232 A1242 E2483
] - If the input voltage is below ~1V - set flag to 0
. If the value is above ~2V, set flag to 1
. Everything in between - is hysteresis and does not change the flag. Used to debounce and filter the input signalM234
- Set motor and DN drive currentSets motor and coil drive current. Expects 8-bit value.
M234 A120 B120 C120 D80
] - Set A, B, C stepper motors strength to 120 and IR filter driver to 80M235
- Set motor idle currentWhen motors are not moving, idle current can be reduced to eliminate heating and save energy. It is not advised to completely turn off motors as the driver can lose micro-step holding position
M234 A50 B50 C50
] - Sets A/B/C motors holding current to value 50M238
and M239
- control output pinsOpto-interrupter LEDs can be controlled by connecting them to PIS_AB and PIS_C pins. They can stay in either state, but some lenses in IR mode can leak light into the sensor so after referencing/calibration procedure is complete it is advised to switch them off
M240
- Set motor drive speedEach motor can drive at different speeds. Speed is 16-bit register. Register specifies internal timing interval, the lower value is the faster pulse rate will be.
M240 A800 B800 C1200
] - Set motion speeds for each axis to corsponding valueM241
, M242
, M243
, M244
- advanced timing registers!1
- Return statusCommand returns 9 values indicating:
[4000, 20000, 0, 0, 0, 0, 0, 0
] - example output
A Motor position counter
B Motor position counter
C Motor position counter
A Limit switch status
B Limit switch status
C Limit switch status
A Moving status
B Moving status
C Moving status