![]() | ![]() | ![]() |
| | |||||||
| Electronic Projects Design/Ideas/Reviews Are you building an electronic project or want to? Maybe you need some assistance? Come and submit your electronic questions here and let our experienced members find a solution. |
| | LinkBack | Thread Tools | Display Modes |
| | (permalink) |
| Hi, I connected a PIC16F84 to a ULN2803 5volt driver to a 5volt 6-wire stepper motor. The motor was running for about 20 seconds, then stopped and it will not start again. Even if I turn off power and turn it back on. Here is my code to control / pulse the stepper motor. Attached is my schematic. Any idea why it would quit and then not work again? Jen start movlw 0x00 tris PORTA loop movlw b'00000101' movwf PORTA call DELAY_20 movlw b'00001001' movwf PORTA call DELAY_20 movlw b'00001010' movwf PORTA call DELAY_20 movlw b'00000110' movwf PORTA call DELAY_20 goto loop | |
| |
| | (permalink) |
| The ULN2803 continuous collector current is 500ma - so you most likely didnt burn the transistors out.. The code looks fine, although im do not know which digital sequence is used to drive unipolar stepper. Although I highly doubt it - could the stepper be out of range of the magnets (though i didnt even think this is possible) If it made a full rotation then the above problem should not be consider^ I wish I could give some better insight.. im sure a more expierenced member will post soon. Goodluck
__________________ "Stick around" - Arnold Schwarzenegger in The Predator after impaling a soldier to a wood post 9vDC Guitar Pedal PSU PIC16F84a Game Module | |
| |
| | (permalink) |
| Forgot to mention to try with the other 4 transistors of the ULN array.. if they motor moves like normal immediately turn the power off so you dont kill the transistors..! Then use power transistors or MOSFETS.
__________________ "Stick around" - Arnold Schwarzenegger in The Predator after impaling a soldier to a wood post 9vDC Guitar Pedal PSU PIC16F84a Game Module | |
| |
| | (permalink) |
| You don't have current limiting resistors at the input to the ULN. The PIC can output 20mA minimum, the max is not specified. Perhaps the base-emitter junction is fried, use your diode checker to see if the ULN input still looks like a diode.
__________________ see my website: www.geocities.com/russlk | |
| |
| | (permalink) | |
| Quote:
__________________ "Stick around" - Arnold Schwarzenegger in The Predator after impaling a soldier to a wood post 9vDC Guitar Pedal PSU PIC16F84a Game Module | ||
| |
| | (permalink) |
| You don't have the ULN2803 grounded In your schematic. Have a look at this. http://www.voti.nl/stepbots/ Stepbots Hope this helps. | |
| |
| | (permalink) |
| Sorry... Actually, yes I do have it grounded. I just neglected to put in the gnds on the schematic to speed things up for posting the picture. Yes, it was very weird, it worked for a while then stopped, I reprogrammed the PIC with some updated code and tried it again and it worked for about 20-30 seconds then stopped and didn't go again. Any other ideas? Jen Last edited by jenny1985; 1st May 2007 at 03:22 PM. | |
| |
| | (permalink) | |
| Quote:
What are you using to power the circuit ? | ||
| |
| | (permalink) |
| try using a simpler step sequence like this: 1000, 0100, 0010, 0001 also make sure your leads are in the correct order
__________________ If you don't have a planet, what good are gold bars? want to contact me directly? gmail gordonthree check out my project website: http://projects.dimension-x.net Favorite numbers: 09 F9 11 02 9D 74 E3 5B D8 41 56 C5 63 56 88 C0 | |
| |
| | (permalink) |
| Yeah, if your steps start to fast, its not going anywhere.. been there before
__________________ Spency. PIC Micro's - Your mind is the limit PIC's and interfacing with other devices - a PIC Basic Guide @ digital-diy.net | |
| |
| | (permalink) |
| Is MCLR tied high? A floating pin will cause that problem.
__________________ see my website: www.geocities.com/russlk | |
| |
| | (permalink) | |
| Quote:
__________________ "Stick around" - Arnold Schwarzenegger in The Predator after impaling a soldier to a wood post 9vDC Guitar Pedal PSU PIC16F84a Game Module | ||
| |
| | (permalink) |
| Got it! MCLR needed to be tied high via 100 ohm resistor... and I had to lower my delay - it was a little too quick. Thanks for all the help guys! You have proved to be a valuable resource! | |
| |
| | (permalink) | |
| Quote:
__________________ "Stick around" - Arnold Schwarzenegger in The Predator after impaling a soldier to a wood post 9vDC Guitar Pedal PSU PIC16F84a Game Module | ||
| |
| | (permalink) | |
| Quote:
__________________ Spency. PIC Micro's - Your mind is the limit PIC's and interfacing with other devices - a PIC Basic Guide @ digital-diy.net | ||
| |
| Bookmarks |
| Thread Tools | |
| Display Modes | |
| |
| | ||||
| Title | Starter | Forum | Replies | Latest |
| ULTRA clean 9VDC Power Supply Project | Peter_wadley | Electronic Projects | 48 | 17th December 2008 09:49 PM |
| ULN2803 Stepper Motor Circuit Help | godatguitar | Micro Controllers | 17 | 1st December 2008 09:20 PM |
| Newcomers, please read! (PIC regarded) Upd. 0xD | Jay.slovak | Micro Controllers | 0 | 17th April 2005 02:05 PM |
| Stepper code for PIC | raitl | Micro Controllers | 6 | 15th February 2005 02:45 PM |
| stepper motor | jim bro | Electronic Projects Design/Ideas/Reviews | 0 | 26th May 2003 09:54 PM |