Shop OBEX P1 Docs P2 Docs Learn Events
Stepper motor — Parallax Forums

Stepper motor

mynet43mynet43 Posts: 644
edited 2010-06-19 15:07 in Propeller 1
Hi,

Can someone point me to a stepper motor driver for a Unipolar stepper motor, using 4 pins to control the phasing. I already have an interface circuit to control the motor load, using mosfets.

I looked in the OBX and couldn't spot something, I probably missed it.

Thanks for your help.

Jim

Comments

  • bazibazi Posts: 29
    edited 2010-06-09 02:00
    L293/L298

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    some say the devil is dead... ...tish army!
  • lardomlardom Posts: 1,659
    edited 2010-06-09 02:29
    I posted my stepper code. I hope it helps.
    Search these keywords. ...Stepper software for prop chip... and look for my username.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔


  • ElectricAyeElectricAye Posts: 4,561
    edited 2010-06-09 02:46
    Have a look at the attached articles.

    Also look at experiment 27 in the StampWorks Manual, page 150.

    www.parallax.com/dl/docs/books/sw/Web-SW-v2.1.pdf

    www.solarbotics.net/library/pdflib/pdf/motorbas.pdf


    hope that helps,
    smile.gif
  • mynet43mynet43 Posts: 644
    edited 2010-06-09 03:40
    Hi,

    Thanks all for the quick replies.

    I can't use the L293/L298 solution because the motor is drawing too much power. I'm driving it directly with 4 I/O pins into mosfets.

    I was able to find Larry's code. I think this will give me what I need to get started. You should post this in the OBX, since there don't seem to be any stepper drivers there...

    Thanks again,

    Jim
  • GeeksGoneBadGeeksGoneBad Posts: 100
    edited 2010-06-17 18:33
    {quote}
    I posted my stepper code. I hope it helps.
    Search these keywords. ...Stepper software for prop chip... and look for my username.
    {/quote}

    I do not find your code - can someone point me to some code for stepper motors?

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my CNC (and more) projects at http://www.backyard-workshop.com
  • StefanL38StefanL38 Posts: 2,292
    edited 2010-06-17 19:25
    http://forums.parallax.com/showthread.php?p=611371

    animated schematics
    for different kinds of stepper-motors.

    That's the reason why there is no general purpose object depending on unipolar / bipolar 4 coils, 6coils fullstep / halfstep microstepping

    all these different types need different swiching of the wires of the steppermotor

    best regards

    Stefan
  • GeeksGoneBadGeeksGoneBad Posts: 100
    edited 2010-06-17 19:51
    Thanks - I did a search of the forums (using the seach button above) and it found nothing - I guess the search is broke?

    I'll do what that post says from now on and use the google search

    Thanks!

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Check out my CNC (and more) projects at http://www.backyard-workshop.com
  • hover1hover1 Posts: 1,929
    edited 2010-06-17 20:19
    Yes, the forum search is kinda' broken. Works on some searches, but not all.

    The best way to search is with Google. In Google enter <search term(s) site:forums.parallax.com> . In addition, you can use, <search term(s) site:forums.parallax.com f=25> to reduce the search to only propeller subjects.

    Jim
  • mynet43mynet43 Posts: 644
    edited 2010-06-17 20:49
    Here's a copy of the stepper code I've been playing with. Right now it's just a test program. But it supports full, wave and half-step outputs. It's hard-coded to pins 0..3 as output, but can easily be changed to any pins. I have the pins driving mosfets directly. I'll supply the circuit if you're interested.

    I'm planning to make it into a cog routine with general interfaces, but I haven't had the time.

    Please let me know if you have any questions or feedback, and feel free to change it to suit your needs.

    Jim
  • hinvhinv Posts: 1,255
    edited 2010-06-18 06:14
    I would be interested in seeing the circuit.

    Thanks,
    Doug
  • mynet43mynet43 Posts: 644
    edited 2010-06-18 22:12
    Hi,

    Here's a copy of the schematic.

    A couple of notes:

    1. The 4 diodes are to prevent back emf from the motor from hurting the circuit.
    2. The 74HCT365 between the Prop and the MOSFETS is needed to boost the voltage from 3.3V to 5V to trigger the MOSFETS. These won't switch until about 4V.
    3. I redrew it today to make it match the final circuit, so let me know if you see anything I missed.

    Please let me know if you have any questions or feedback.

    Jim
  • ElectricAyeElectricAye Posts: 4,561
    edited 2010-06-19 00:27
    mynet43 said...
    ....
    Please let me know if you have any questions or feedback.

    ...

    I think if you were to replace your Mosfets with IRF3708, you could eliminate your 74HCT365. The IRF3708 can be driven directly off the pin of a Propeller and I think it will handle your voltage and current requirements, too.

    search.digikey.com/scripts/DkSearch/dksus.dll?Detail&name=IRF3708PBF-ND

    smile.gif
  • mynet43mynet43 Posts: 644
    edited 2010-06-19 00:47
    Thanks for the feedback.

    I think you're on the right track. This one should switch at a little over 2V. The only problem with it is that the max voltage is 30V, and I need to drive it as high as 48V. The one I'm using goes up to 100V.

    The reason I used these is that I had a bag of them and they seemed to be good. I didn't discover the 4V problem until I had already breadboarded the circuit, so it was easier to add the chip.

    By the way, I didn't mention it, but this circuit should work fine also at lower battery voltages.

    Thanks again.

    Jim
  • lardomlardom Posts: 1,659
    edited 2010-06-19 15:07
    @GeeksGoneBad I never posted it to the obex because it doesn't yet follow the format. I've attached it and I'll post it to the obex soon because it is basic building block stuff. Something should be there.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔


Sign In or Register to comment.