Controlling stepper motor with PIC


Closed Thread
Results 1 to 4 of 4
  1. #1
    Join Date
    Jun 2007
    Location
    Mansfield, UK
    Posts
    697

    Default Controlling stepper motor with PIC

    Hi, I decided to have another go at controlling a stepper motor again the other day. Its the first time ive given it much thought since i was about 10 and now i know about PICs i managed to link a stepper motor through a ULN...something driver chip into a PIC. I was quite impressed with the results but i feel like it should be better. The motor ive been testing with is a 6 wire type. I told the PIC to turn the 4 outputs on and off in sequence and the motor worked. The problem i have is that i cant make it move fast. If i try to speed it up the PIC chip works faster than the motor and sometimes it even runs backwards.

    Should stepper motors be connected to PICs using a proper stepper motor driver circuit or can it be done how ive done it here? The motor i have is really old and aparently its a 15 degree one. I was thinking about buying some bigger motors which are 1.8 degrees. Would my circuit work better with newer motors or do i need the driver circuit?

  2. #2
    Join Date
    Nov 2003
    Location
    Greece
    Posts
    3,807


    Did you find this post helpful? Yes | No

    Default

    I am sure there are a lot of special function chips but make sure that the motor can go faster. Usually stepper motors are slower than servos, asynchronus or classic PM motors. No surprise that it skips some steps or even turns back.

    On an old application note, I saw a technique to improve every step by doubling or even tripling the voltage driven to the motor with carefully selected coil in series and appropriate current limiting.

    But even like that, I don't see a more than 20% increase.

    You might want to have a look at the very cheap L297/L298 pair.

    Ioannis

  3. #3
    Join Date
    Aug 2006
    Location
    Look, behind you.
    Posts
    2,818


    Did you find this post helpful? Yes | No

    Default

    Roman Black whipped one up which works pretty well : http://www.piclist.com/tecHREF/io/st...step/index.htm
    If you do not believe in MAGIC, Consider how currency has value simply by printing it, and is then traded for real assets.
    .
    Gold is the money of kings, silver is the money of gentlemen, barter is the money of peasants - but debt is the money of slaves
    .
    There simply is no "Happy Spam" If you do it you will disappear from this forum.

  4. #4
    Join Date
    Jun 2007
    Location
    Mansfield, UK
    Posts
    697


    Did you find this post helpful? Yes | No

    Default

    Im not completely sure that this motor should go faster. I know stepper motors arnt the fastest in the world and i suppose with this one being quite old it might not be designed for speed. I do want to use them for the accuracy and speed doesnt really matter anyway but its still nice to make things run as fast as possible. If its possible to do it with just a PIC chip then i would like to do that. Im sure the newer motors should run a little faster and be a bit more powerfull.

    If i use the normal voltage can i hold the motor in 1 position without it overheating? Does this depend on the exact type of motor? The type of motors i plan to buy are these http://www.rapidonline.com/Electrica...-size-14/73211

    I like the idea in that link about smoothing the steps. Is that easy to do? I dont really need it but it might be usefull to learn. Is it something like PWM?

Similar Threads

  1. PIC 16F877A circuit for stepper motor...
    By kristina in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 27th June 2012, 08:13
  2. HSERIN & Interupts (aka controlling PIC programs from a remote PC)
    By HankMcSpank in forum mel PIC BASIC Pro
    Replies: 16
    Last Post: - 17th June 2009, 14:46
  3. Controlling power to a PIC with another PIC
    By jswayze in forum Off Topic
    Replies: 3
    Last Post: - 28th May 2005, 19:44
  4. Serial Pic to Pic using HSER
    By Chadhammer in forum mel PIC BASIC Pro
    Replies: 5
    Last Post: - 11th March 2005, 23:14
  5. Battery Backup with PIC controlling switch
    By Dwayne in forum Schematics
    Replies: 1
    Last Post: - 27th December 2003, 13:16

Members who have read this thread : 1

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts