element14 Community
element14 Community
    Register Log In
  • Site
  • Search
  • Log In Register
  • Community Hub
    Community Hub
    • What's New on element14
    • Feedback and Support
    • Benefits of Membership
    • Personal Blogs
    • Members Area
    • Achievement Levels
  • Learn
    Learn
    • Ask an Expert
    • eBooks
    • element14 presents
    • Learning Center
    • Tech Spotlight
    • STEM Academy
    • Webinars, Training and Events
    • Learning Groups
  • Technologies
    Technologies
    • 3D Printing
    • FPGA
    • Industrial Automation
    • Internet of Things
    • Power & Energy
    • Sensors
    • Technology Groups
  • Challenges & Projects
    Challenges & Projects
    • Design Challenges
    • element14 presents Projects
    • Project14
    • Arduino Projects
    • Raspberry Pi Projects
    • Project Groups
  • Products
    Products
    • Arduino
    • Avnet Boards Community
    • Dev Tools
    • Manufacturers
    • Multicomp Pro
    • Product Groups
    • Raspberry Pi
    • RoadTests & Reviews
  • Store
    Store
    • Visit Your Store
    • Choose another store...
      • Europe
      •  Austria (German)
      •  Belgium (Dutch, French)
      •  Bulgaria (Bulgarian)
      •  Czech Republic (Czech)
      •  Denmark (Danish)
      •  Estonia (Estonian)
      •  Finland (Finnish)
      •  France (French)
      •  Germany (German)
      •  Hungary (Hungarian)
      •  Ireland
      •  Israel
      •  Italy (Italian)
      •  Latvia (Latvian)
      •  
      •  Lithuania (Lithuanian)
      •  Netherlands (Dutch)
      •  Norway (Norwegian)
      •  Poland (Polish)
      •  Portugal (Portuguese)
      •  Romania (Romanian)
      •  Russia (Russian)
      •  Slovakia (Slovak)
      •  Slovenia (Slovenian)
      •  Spain (Spanish)
      •  Sweden (Swedish)
      •  Switzerland(German, French)
      •  Turkey (Turkish)
      •  United Kingdom
      • Asia Pacific
      •  Australia
      •  China
      •  Hong Kong
      •  India
      •  Korea (Korean)
      •  Malaysia
      •  New Zealand
      •  Philippines
      •  Singapore
      •  Taiwan
      •  Thailand (Thai)
      • Americas
      •  Brazil (Portuguese)
      •  Canada
      •  Mexico (Spanish)
      •  United States
      Can't find the country/region you're looking for? Visit our export site or find a local distributor.
  • Translate
  • Profile
  • Settings
Community Hub
Community Hub
Member's Forum New Member & Can RPi Zero Control Stepper Motors Query
  • Blog
  • Forum
  • Documents
  • Quiz
  • Events
  • Leaderboard
  • Polls
  • Files
  • Members
  • Mentions
  • Sub-Groups
  • Tags
  • More
  • Cancel
  • New
Join Community Hub to participate - click to join for free!
Actions
  • Share
  • More
  • Cancel
Forum Thread Details
  • State Verified Answer
  • Replies 16 replies
  • Answers 6 answers
  • Subscribers 509 subscribers
  • Views 1278 views
  • Users 0 members are here
  • bipolar stepper motor
  • new_member_introduction
  • pi zero
Related

New Member & Can RPi Zero Control Stepper Motors Query

drmac
drmac over 8 years ago

Just joined, hello all.

I joined to help learn about controlling stepper motors for a few little projects I'm working on. One query is whether or not the RPi Zero can also be used to run stepper motors as out lined for example in TUTORIAL - How to control a bipoloar 4 wire stepper motor? I've not come across anything about the zero doing so. If there is info out there I would appreciate a pointer or two


 

Cheers,


 

Niel


 

  • Sign in to reply
  • Cancel

Top Replies

  • Former Member
    Former Member over 8 years ago in reply to drmac +3 suggested
    A further suggestion would be to look into using an L297 & L298 combo board, the L297 is a dedicated stepper motor controller which can simplify the task. Rather than having to drive all 4 connections…
  • Former Member
    Former Member over 8 years ago in reply to drmac +3 suggested
    Use Ohms law V=IR (voltage = current x resistance). The sum can be reconfigured to I=V/R (Current = Voltage divided by Resistance). You know the voltage is 12V right so you have 1 piece of information…
  • Robert Peter Oakes
    Robert Peter Oakes over 8 years ago +2 suggested
    Looking at the project and assuming it is working, there is nothing to stop you replicating this pretty much exactly on the PI Zero. The GPIO is completely compatible so it should work without alteration…
  • Robert Peter Oakes
    0 Robert Peter Oakes over 8 years ago

    Looking at the project and assuming it is working, there is nothing to stop you replicating this pretty much exactly on the PI Zero. The GPIO is completely compatible so it should work without alteration. Just make sure the power for the motor controller is not coming from the PI

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
  • DAB
    0 DAB over 8 years ago

    I agree with Peter.

     

    The main thing you have to keep in mind is that the IO pins on the PI Zero can only source so much current.

     

    So to properly drive stepper motors you want to put either a motor controller between them or add driver transistors on a separate power buss to ensure that you do not overtax the PI Zero, or any other processor, IO capabilities.

     

    The devil is in the details, so you need to look at the current drive requirements of the motors, and the control card.

     

    As long as you do not violate those limits, you can drive a lot of different devices with any MCU, but you need to take care or you release the magic smoke.

     

    DAB

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
  • drmac
    0 drmac over 8 years ago in reply to Robert Peter Oakes

    Thanks for the pointer.

    Cheers.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Reject Answer
    • Cancel
  • Former Member
    0 Former Member over 8 years ago in reply to drmac

    A further suggestion would be to look into using an L297 & L298 combo board, the L297 is a dedicated stepper motor controller which can simplify the task. Rather than having to drive all 4 connections in the correct sequence patterns, the L297 takes just 2 inputs, 1 for direction and 1 for speed (which you pulse, the faster you pulse it the faster the stepper turns). I think they only work in full step and half step mode though so if you are going to want to use wave control you'll probably have to do that yourself.

    • Cancel
    • Vote Up +3 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
  • drmac
    0 drmac over 8 years ago in reply to DAB

    DAB

     

    Understood, thanks for the info, However I can't find the stepper motor (OKI EM-546 12V with 48 steps per revolution) datasheet so any suggestion regards measuring the motor drive current?

     

    Cheers,

    Niel.

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • drmac
    0 drmac over 8 years ago in reply to Former Member

    Yes, I noticed the L298 data sheet flags use of the L297 so currently trying to tack down a boards with both on.

     

    Cheers,

    Niel

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • DAB
    0 DAB over 8 years ago in reply to drmac

    I think you will find that most stepper motors can support multiples of 48 steps/ revolution.

     

    You just might have to do more steps.

     

    The motor you select will provide you with the drive requirements depending upon the amount of load the motor has to drive.

     

    DAB

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
  • Former Member
    0 Former Member over 8 years ago in reply to drmac

    Use Ohms law V=IR (voltage = current x resistance). The sum can be reconfigured to I=V/R (Current = Voltage divided by Resistance).

     

    You know the voltage is 12V right so you have 1 piece of information, the next part is to find the resistance of the coils. Bipolar stepper motors have 4 wires, you'll find that they are connected in pairs to a coil within the stepper motor. Measure each pair with a multimeter on Ohm's or resistance setting (each pairs result should be the same) and apply the sum above to your value so Current=12/ohm's

     

    (another useful piece of information is that stepper motors can be used at a greater voltage by reducing the current proportionally, this helps with overcoming back emf and energising each coil phase faster resulting in increased performance but is probably getting out of the scope of somebody just approaching stepper motors).

     

    Hope this helps and good luck!!

    • Cancel
    • Vote Up +3 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
  • DAB
    0 DAB over 8 years ago in reply to Former Member

    You also need to assess the coil reactance, not just the wire resistance.

     

    You get different effects with frequency and stray capacitance in the leads.

     

    DAB

    • Cancel
    • Vote Up +2 Vote Down
    • Sign in to reply
    • Verify Answer
    • Reject Answer
    • Cancel
  • sikandar
    0 sikandar over 8 years ago in reply to Former Member

    Agree

    • Cancel
    • Vote Up 0 Vote Down
    • Sign in to reply
    • Verify Answer
    • Cancel
>
element14 Community

element14 is the first online community specifically for engineers. Connect with your peers and get expert answers to your questions.

  • Members
  • Learn
  • Technologies
  • Challenges & Projects
  • Products
  • Store
  • About Us
  • Feedback & Support
  • FAQs
  • Terms of Use
  • Privacy Policy
  • Legal and Copyright Notices
  • Sitemap
  • Cookies

An Avnet Company © 2025 Premier Farnell Limited. All Rights Reserved.

Premier Farnell Ltd, registered in England and Wales (no 00876412), registered office: Farnell House, Forge Lane, Leeds LS12 2NE.

ICP 备案号 10220084.

Follow element14

  • X
  • Facebook
  • linkedin
  • YouTube