Stepper motor 1st time run with DRV8834

Hi all ,

I built a mechanical design that is too much sensitive to position consists of gears driven by Nema 17 stepper motor driven by DRV8834 .

Things are good in working . But if I totally disconnect the power from total system and then energized it ( which looks like 1st time ) the stepper motor moves some steps before any signals sent to it .

After I made some research some mentioned that this is a self positioning of the stepper for its teeth . So I tried to use the Sleep / enable pins in the DRV8834 to postpone the wake of the stepper before sending the signal to it and things didn’t solved .

Some others suggests using a begin point routine that reset the stepper to the required point before going on . But this also wouldn’t be a good solution for me .

So I’m looking for an electronic solution that may use software rather than hardware ( not using encoders or similar ) for it .

So please advise if there is a way to avoid that


Steppers like this have very little holding torque when they are not powered, so your mechanical system must have enough friction to prevent the motor shaft from spinning to avoid losing the position.

Also, the electrical states that the stepper driver uses to control the stepper motor repeat every four full steps. When the driver is powered it starts at a “home” state, so if the stepper was being held in one of the three intermediate positions, it will move forward or backward to the nearest home position. Also, toggling the SLEEP pin will cause the driver to return to the home position when it wakes. You can find a little more about the home position on page 16 of the DRV8834 datasheet.

If your system has sufficient friction to prevent external forces from moving the stepper when the system is unpowered and you ensure the stepper motor is in one of the home positions when it is switched off, you might be able to retain the position when the system turns on.

Also, the if you hold the ENABLE pin high instead of switching the power off or using the SLEEP pin, the indexer on the chip will remember the STEP position, which might help you if you can leave the driver chip powered.


1 Like