Stepper Motor speed

Discussion in 'The Projects Forum' started by vish2207, Jan 28, 2014.

  1. vish2207

    Thread Starter New Member

    Jan 28, 2014
    6
    0
    Hi Everyone,

    My project is to make a Bipolar stepper motor drive using discrete components. I have NEMA 34 86mm 4A 1.8degree stepper motor as a load. I have made drive using two full H bridge which uses IRF540(N Mosfet) and IRF9540(P Mosfet). I am driving these Mosfets using discrete transistors BC547. After few tweaking in the gate drive circuit, now MOSFETs are driven correctly.

    I am driving the Motor in the Full step mode which has following waveforms.

    [​IMG]

    In my case, the time for one step which is shown by two dotted green lines in the waveforms, is kept 1850uS. This time has been decided by lot of iteration of different timings. This creates minimum vibration in the motor and optimum current consumption. Now at this stage the RPM of the motor is around 160. Theorically it is 162.

    I want to increase Motor RPM to around 300. If I reduce the step time from 1850uS to 900uS, the motor stalls. What should I do to fix this?

    I tried to run the same motor with another small off the shelf drive which is using TB6560 IC from TOSHIBA. If I drive it in full step mode, it gives some where around 300 RPM for the same motor without considerable vibration and limited current.

    Thanks in advance,
    Vishal Prajapati
     
  2. MrChips

    Moderator

    Oct 2, 2009
    12,421
    3,357
    You need to use acceleration. Start off at a slow speed and then gradually increase the speed.
     
    vish2207 likes this.
  3. Papabravo

    Expert

    Feb 24, 2006
    10,136
    1,786
    The velocity profile (velocity versus time) should look like a trapezoid. Starting at zero velocity you increase the speed linearly (aka constant acceleration) up to some running speed and you maintain that speed (zero acceleration) until it is time to slow down. Then you decrease the speed linearly to zero.

    Like all motors, there is a zero torque speed in the neighborhood of 5000 steps per second at which there will be zero torque and the motor will stall again.
     
    vish2207 likes this.
  4. vish2207

    Thread Starter New Member

    Jan 28, 2014
    6
    0
    Thanks a lot guys. Your trick worked. Now I am able to run the motor till 288 RPM instead of 162 earlier. I have tried to give linear acceleration but does not work properly. It skips the intermediate steps and gets locked in between revolution as if it is skiping intermediate steps. So I am not giving exact linear acceleration but with trial and error of different timings try to smooth the steps.

    I still needs higher speed. So, if try to reduce the step time below 1050uS, it again starts skeeping steps. I think I should go for half step sequence and then try to decrease the step time to increase speed beyond 288 RPM.

    What if I want to reduce the speed during run time? I am thinking of reduce the step on time and lock the motor before next step so lock time will become off time of motor. Is this the right approach to decrease speed of motor?
     
  5. John P

    AAC Fanatic!

    Oct 14, 2008
    1,632
    224
    What voltage are you running the motor at? Generally if you want to go faster, you must turn up the voltage. If you're going to say that then there'll be too much current when the motor is going slow or stopped, then yes, that's another problem to solve.
     
  6. THE_RB

    AAC Fanatic!

    Feb 11, 2008
    5,435
    1,305
    You have built a full-step motor driver which causes a massive amount of resonance, so at some speeds the motor will stall.

    If you want good high speed performance and speed ramping you need a current-limited stepper driver with microstepping and a PSU that is many times higher voltage than the motor coil voltage. There are many types available cheap. :)
     
  7. vish2207

    Thread Starter New Member

    Jan 28, 2014
    6
    0
    I am using 24V supply to H bridge. I have tried Half step sequence and linear acceleration profile be which I get 428 RPM now but with almost zero torque.

    So, I think if I want to go faster, I need to provide PWM in sine and cosine pattern to all the lower MOSFETs of both H Bridge to make it a micro stepping drive which I think will compensate for torque better.

    By the way I also asked if I want to decrease the speed of motor which is correct method for it?

    Opt 1: Increasing delay between two step sequences which increases current and consequently torque?

    Opt 2: I should provide One step sequence for x time and then lock the motor for y time. After x + y time, I provide second step sequence for another x time and wait for y time.

    Opt 3: I should keep the time according to max speed and use reduced PWM duty cycle to decrease current there by reducing speed?

    Note: I am right now not using any PWM inputs to H bridges. I will need to change the MCU for that.
     
  8. THE_RB

    AAC Fanatic!

    Feb 11, 2008
    5,435
    1,305
    Using 24v to the driver? You said your motor is 4A, but how many volts?

    And how are you providing the critically important constant current drive to the motor?
     
  9. tubeguy

    Well-Known Member

    Nov 3, 2012
    1,157
    197
    I know you stated in the first post that you are driving the mosfet gates correctly. But it might be a good idea to post the complete schematic including the gate drive circuitry.
     
  10. vish2207

    Thread Starter New Member

    Jan 28, 2014
    6
    0
    I am using 24V to the H bridge circuit which generates the voltage sequences of 24V pulses around two windings of motor. I am not using any constant current source for driving motor. I am using 24V SMPS which is in Constant Voltage mode. This SMPS has been used with other microstep drivers also earlier. And I am trying to create a Stepper Driver with only Full step and Half step functionality which has lower cost than Microstep driver.

    Below is my schematic diagram for the complete driver and H bridge. For simulation I have tied the BC547 transistor base to signal generator but actually they are driven by PIC16F877A.

    https://www.dropbox.com/l/wb9uxVHWkRb1cUISFIUbfQ3
     
  11. tubeguy

    Well-Known Member

    Nov 3, 2012
    1,157
    197
    Thanks for posting the schematic.

    To drive a stepper motor efficiently you need high current pulses.
    The Mosfet gates are like a capacitor, and need to be driven with enough current to turn them on quickly. The resistors are keeping the gate voltage safe but don't allow a lot of current for fast turn on, especially the lower Mosfet which is being driven through ~11k ohms.

    Make the upper resistors a lower value like 120 and 220 ohms. You should make those values as low possible while keeping the current reasonable for the BC547.

    Edit: These resistors will need to be higher wattage than typical 1/4 or 1/2 watt.

    It would be better to drive the lower Mosfets with a PNP transistor in a mirror of the upper configuration, with the lower value resistors. You can then drive those with a NPN, so the PIC can turn them on.
     
    Last edited: Feb 4, 2014
  12. THE_RB

    AAC Fanatic!

    Feb 11, 2008
    5,435
    1,305
    You need to have constant current limiting. Using crude fullstep or halfstep drive will really limit performance and give you a lot of problems with motor stalling (which you have), and not using current limiting makes everything worse.

    Have you read "Jones on steppers"?
    http://homepage.cs.uiowa.edu/~jones/step/
     
Loading...