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.

DRV8871: PWM and bidirectional control of DC motor

Part Number: DRV8871
Hi Team, Seeking some support for this.
  • We set input 1 to "1", and drive input 2 with a 21KHz PWM signal whith the ability to vary its' duty cycle from 0- 100 percent (with 256 step/8 bit resolution). The output drives a small DC motor CW at 15V drawing uner 500mA. In use case, the output waveform is perfect as expected and we can see clear changes on duty cycle with crisp rise and fall times
  • Randomly, but as often as every 1mS, we can (and do) change direction based on a closed loop servo routine.
  • When we want driver the motor CCW (as often as every 1mS) we set input 1 to "0" and drive input 2 with the same 21Khz signal. The output is greatly distorted (very slow aukward rise time, looks like an RC slew limitation), it is not a near vertical rise time. Falling edge look more normal but not as crisp at CW case. Output voltage is also noticably lower than CW case which should not be the case.
So that is our observation. We notice a sleep/low power mode when both inputs =0, for longer than 1mS (but we would like to dissable that feature if possible)but we have been careful not reach a 1mS condition of both inputs =0
Part does not perform as expected for a fully bidirectional PWM driver circuit as the spec/data sheet imply, though our use case is not discussed nor are there any example in support, with examples, etc.
Thanks,
Mark
  • Hey Mark,

    Thank you for your question.

    1) How long does the distorted output signal last? Does it stay distorted forever or does it go back to being crisp after a while?

    2) If you happen to go from CW (expected waveform) to CCW( distorted) back to CW (?) does the waveform remain distorted or go back to being crisp?

    3) It would be beneficial if you can provide waveforms of the aforementioned cases for further analysis.

    4) The device has an integrated feature to enter sleep mode if both inputs = 0 for longer than 1ms and cannot be disabled.

    Best,

    Akshay

  • Hi Akshay, Here is the feedback of the customer.

    I think we have resolved our waveform issue (a rather subtle ground loop problem). As for the sleep mode, since we are switching at 22-40KHz with the random possibility of having one direction (with one input being zero) and a possible "zero PWM" value, it is possible that the device could go into sleep mode. But maybe that isn't a problem if the device can wake up real fast at the next 1 mS interrupt. How fast can awake from sleep occur? It is possible that we could increase our ISR interrupt rate to 0.5 mS but given the mechanical time constant of motors (much much longer than 1 mS), it is still possible multiple intervals could be zero PWM in the direction resulting in both inputs being zero.
    If the 8871 isn't a good fit with the sleep mode, does Ti make a very similar part (package, performance, etc) without a sleep mode?
    Thank you.
  • Hey Mark,

    Glad to know the waveform issue got resolved.

    This device has a turn on time off 40us. tON applies when the device initially powers up, and when it exits sleep mode.

    Does this speed match your need?

    Best,

    Akshay

  • Hi Akshay,

    Switching at 20-40Khz and use an 8 bit value to determine the duty cycle. Since this is closed loop servo application, the output may theoretically change back and forth (CW or CCW) every 1 ms (or 1000 uS). In reality, the mechanical time constant is much slower than 1 mS, closer to 100 mS. So in the event that an output in one direction is en1 = 0 and PWM=0 for longer than 1mS is likely, but with a 40uS wake up I don't think that delay from a sleep condition (and prior zero output) to an output great than zero (in either direction) will create a stability problem in the servo.
    Thank you.
  • Hey Mark,

    Glad to know that it works. Please mark the thread as resolved if your questions have been answered.

    Best,

    Akshay

  • Switching at 20-40Khz and use an 8 bit value to determine the duty cycle. Since this is closed loop servo application, the output may theoretically change back and forth (CW or CCW) every 1 ms (or 1000 uS). In reality, the mechanical time constant is much slower than 1 mS, closer to 100 mS. So in the event that an output in one direction is en1 = 0 and PWM=0 for longer than 1mS is likely, but with a 40uS wake up I don't think that delay from a sleep condition (and prior zero output) to an output great than zero (in either direction) will create a stability problem in the servo.

    Hi, you can easily avoid getting sleep by limit the pwm not equal zero (the MCU doing the close-loop servo control can this

    If (pwm == 0) pwm=1; // pwm=1 is the same as pwm = 0 as far as motor concern, but pwm=1 keep the chip not sleepy).

    Brian