Hi all,
I'm currently driving a NEMA 23 motor using the motor driver ST-M5045 and AccelStepper library. I wish to release the power to the motor coils when the motor is on standby. I have wired the ST-M5045's (ENA+) port to the digital Pin 6 on Arduino Uno, and I used functions such as enableOutputs() and disableOutputs() from the AccelStepper library in my code.
However, this does not seem to release the power to motor coils. I notice that the motor driver still supplied current to the stepper motor and the motor's temperature does not go down at all. Thank you for the help.
Do you use the setEnablePin() function to set to pin 6?
Yes, I have done that. One thing I forgot to mention is that I connected the driver's (ENA-) port to nothing. The reason is that I originally had this port connected to GND, but the stepper motor will not run at all.
This page shows EN+ connected to Vcc and the EN- pin connected to the controller.
Previously, I connected the ENA(+) to digital Pin6 and ENA(-) to GND Pin on the Arduino. However, the stepper motor does not rotate at all unless I disconnect the wiring between ENA(-) and GND.
The inputs to the stepper driver EN, PULSE and DIR are optical isolators.. The anodes of the internal LEDs are to be connected to Vcc (through internal 240 Ohm resistors). The cathodes are to be connected to Arduino output pins. In the case of the enable, when the ENA- pin is open or HIGH the driver is enabled. When ENA- is grounded or LOW the driver is disabled.
ENA+ and ENA- are the two connections to an optocoupler input.
You MUST connect both of them in order to use this input, and current has to flow from ENA+ to ENA- in order to activate the input, which in turn cuts off the motor current. See the data sheet for more details.
Note: "NEMA 23" informs us of the size of the motor mounting plate, and otherwise conveys no useful information.
Thank you all for your help.
I rewired the motor driver according to the diagram provided in manual sheet and was able to release the motor coils using the AccelStepper library.