This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

Difficulties with Chinese DRV8825 "StepSticks" on my own controller board

Other Parts Discussed in Thread: DRV8825, DRV8825EVM

Hello.

In advance, I got some miniature PCBs with a DRV8825 chip on them (the violet colored ones), and I successfully use some of them in a little CNC mill (logics voltage there 5.0V) with forced air cooling.  -> So this modules actually work.

This brought me to the idea to use the same modules in my development of a Pick&Place machine. The mainboard is running here mostly on 3.3V, because the PIC microcontroller also has to read from SD-Card and to control a graphical display (also requiring 3.3V only). Running everything on 3.3V simplifies things a lot, this is the background.

Reading the datasheet of DRV8825, I see that this part accepts high levels from 2.2...5.25V, so it should perfectly work.

Well, practice is somewhat different, and I kindly please for suggestions on how to fix this issues:

  • My microcontroller (PIC 18F4685) is directly connected to STEP and DIR of four stepper driver boards (search for "Geetech StepStick DRV8825") with PortB, and I am able to generate the individual pulses and signal levels for every particular StepStick.  The adjusted current is very low (0.2A), the motor voltage somewhere around 24V.

  • During my tests I generated very slow STEP pulses (5 pulses/second with a width of 1ms) with DIR="LOW". The stepper motor turned clockwise.

  • In next step, I wanted to reverse the rotating direction, but here I noticed that the stepper motor continuously turns CW, regardless if the DIR pin is set to HIGH (3.3 Volts) or LOW. 

  • I extended my software to do 100 step pulses with DIR=LOW, then another 100 step pulses with DIR continuously HIGH. So the motor should turn CW and CCW repeatedly, but it continuously turned CW.

  • By accident I kept the testing board powered on. After a longer while (I searched for a possible mistake in my software), I suddenly saw that the stepper turns in both directions!  I powered the board off and on, but now the stepper again turned only CW again. I also was not able to reproduce that the stepper starts changing the rotation direction later again.

From my point of understanding, 3.3V logic input level is perfectly in the center of the high level range (2.2-5.25V).  I also verified (measured) that the DIR pin is switched between 0V and 3.3V after every 100 steps.   As the stepper turns and the STEP pulses come from the same microcontroller port, this also indicates that 3.3V are sufficient - otherwise the stepper would not move at all.

I also pulled the microcontroller entirely, connected a frequency generator (generating square waves of 500Hz) to the STEP pin, and connected then the DIR pin once to +3.3V, then to GND. This usually should work if it is an issue with the microcontroller, but it did not.

Can somebody give me an idea on what might possibly be going wrong here, please?  

I am close to buy some boards with Allegro A-4988 to see if they behave differently. But they do not allow up to desired 38V operationg voltage and also support only lower current, therefore I'd prefer the DRV8825 chip with forced air cooling.

  • Hi Rainer,

    Are all four boards exhibiting the same problem? Is it possible there is an intermittent connection from the header to the DRV8825?

    This would cause the device to remain in the DIR=LOW state.

    You should be able to measure approximately 100kOhm from the DIR signal on the header to GND.

    By the way, 3.3V on DIR should cause the indexer to reverse the motor. The DRV8825EVM drives the DIR pin from 0 to 3.3V and works as expected.
  • Hello, Rick,

    I measured on a brand new (never used) StepStick 99 kOhms, while the StepStick pulled from my board shows only 3-5 kOhms (the measurement is not stable.

    When orienting the little board in a way that DIR is on lower-left corner, I measured between lower-left and lower-right pin.
    When the + pole of my meter is on DIR and the other one on GND, I read 100k, when replacing the testing tips, I read 66k. ON THREE UNUSED DRV8825.

    When testing the one I used until now, I measure 2.3k instead of 100k.

    What can be wrong here?

    If you want to see the schematic of my main board, I can make it available for you.

    What I wonder about is: I currently use a power adapter from 3COM (very old, with transformer, no switching regulator). This adapter (12V/1000mA) is giving 17 Volts in free-run, Measuring the voltage when connected to my mainboard, I see 23 Volts on my DMM (I assume because of additional capacitors).
  • Hello, again, Rick.
    For the case that I accidentally marked my issue as "solved", how can I un-mark it again (or can you do that)?

    I didnot mention that I used heat conducting compound to mount the heat-sink to the bottom side of the PCB. This compound is named TBS (from Electrolube), and I have verified that there is not conduction to ground (at least my DMM shows >20 MOhms (= open).

    Also, my board has a power mosfet with a 24V Zener diode to + supply. So the NMOS get conducting when approx 27-28 Volts are reached on its gate. This I use to keep the maximum voltage below critical 45 Volts. And, of course, every StepStick has its own 100uF/64V electrolytic capacitor directly below, between its pinhead rows. I took this over from 3D printer boards to my own board layout.
  • Hi Rainer,

    For now, let's not worry about the post marked as "solved". We will continue to work with you.

    Would you please make your schematic available? From what you are describing, it appears as though the StepStick has been damaged.
    Do you have another power supply to try? It is is concerning that you are measuring 17 and 23V using the DMM. The 17V and 23V is an average number so the voltage could be higher, though the NMOS should clip the voltage.

    If you do re-connect the power adaptor to the board, please take a look at VM and provide scope captures if possible.
  • Rick,

    thanks for your hint with the 100k measurement.   I risked now to insert a new stepstick and the stepper turns in both directions, as expected.

    I made the PCB schematic available for download on my server (replace carets "^" with dots "." to get a working URL:

    www^hantsch^co^at/_temp/ti.zip      <--  The file will automatically be deleted in 2 days.

    This leads into the conclusion that my first DRV8825 must have a fault, but this does not explain how I could have damaged it in my environment, and why another one (borrowed from my friend because I needed it in my weekend house) also didn't reverse the direction.

    Anyway, this leaves the following questions:

    • Does the DRV8825 have internal diodes and/or protection against voltage coming from the stepper (turned by accident without a connected supply?
    • If such diodes exist, the voltage from the stepper should be forwarded to the Vmot pin (in reverse direction) and supply the whole board, until the protection NMOS starts to become conducting and shortens it.  The whole remaining electronics is supplied through an LM2592-5.0V switching regulator and a MAX882 (linear low drop 3.3V regulator) from 5.0V -> 3.3V.

    I added now in addition a VDR with nominal 30V across the DRV8825 to catch really every spike coming from there.

    Well, I will place the ti.zip in a few minutes from now.

  • Hi Rainer,

    Thanks. I have looked at the schematic, and don't see any immediate concerns.

    There are internal diodes in the device. Refer to Figure 7 of the datasheet for details.

    Also, there is no power sequence required. Refer to section 10.2 of the datasheet for details.

    It does appear like something is damaging the devices. Usually it is an absolute maximum or minimum being violated. This could occur when the DRV8825 is driving at high current and suddenly stops. With the local ceramic capacitors and the bulk being near, it is less likely.

    Have you looked to see how well regulated the 24V is? Can you use a lower voltage on the power supply? You may not be able to spin the motor as fast, but it may be acceptable in your application.

    Keep us posted on your progress.
  • Hi, Rick!

    Usually the internal diodes should lead out any voltage generated by the stepper motor, and this voltage will be charged to the capacitors then. As the manual sais, at least 47 uF should be placed very close to the DRV8825 in addition to capture such spikes. I used 100uF capacitors, and now also a varistor with 30V to keep this voltage in range.

    Also, I run the stepper currently at a very low current of not more than 0.3 A, this is more or less "kidding" the drv8825.

    About the supply voltage:

    The drv8825 is officially able to support up to 45 Volts. I am running it currently with 12-24 Volts (where I do not really have an explanation for this voltage rise). But I am far away from the chip's 45V limit.

    Is it possible that a badly connected wire from one stepper winding can cause damages? But even that should not be possible if the diodes inside the drv8825 are working properly.

    What I see now (watching the stepper forward and backward in 5 steps/sec (I will let it run over night now) is:

    The stepper mode is set to 0-1-0  (Mode pin 0-1-2), so this is  1/4 stepping.    I see a very unequal move from microstep to microstep.  First steps are with very small move, then the stepper suddenly does a relatively big move (I guess this is the last 1/4th of the sequence. This is almost useless for precise positioning without gearboxes.

    Well I compare this little and cheap stick with a GeckoDrive 201 now, where every microstep is really very precisely of same width. Can I enhance this?  I cannot rise the current too high, otherwise this little stepper (currently I use one with 100 steps/revolution) gets hot.

    I guess that the stepstick is using mixed decay by default. I heared that I should try fast or low decay mode instead, but before I start a trial and error odyssee and possibly ruin another stepstick, I ask. You know this stepstick board, I assume. Where do I have to solder a jumper(wire)?

  • Hi Rainer,

    The DRV8825 has internal protection for many stress conditions. Overvoltage one that is not available.

    Placing the 100uF caps and the varistor should be enough to keep the voltage in check, but it is always good to look at the voltage spikes on a scope.

    Depending on the motor parameters, voltage, and decay mode used, the current may not be what is expected. During mixed decay, slow decay is used when the current is increasing. This can lead to unexpected current steps, and unequal movements as you described. Having access to a current probe can show any unexpected current steps.

    Changing to fast decay (connecting pin 19 to a logic high) should prevent this behavior, but will increase the current ripple.

    For more information on this, please see LINK

    By the way, I am not familiar with the stepstick board. I found the schematics online.