Author Topic: Need help  (Read 4787 times)

0 Members and 1 Guest are viewing this topic.

Offline leebleleebleTopic starter

  • Beginner
  • *
  • Posts: 3
  • Helpful? 0
Need help
« on: June 16, 2008, 11:18:25 PM »
i just started working with microcontollers and bought a BASIC Stamp to begin learning how. I have some extra motors lying around but when i try and add them to my breadboard they don't work. Also, some of the LEDs don't work either. Anyone know what i'm doing wrong?

Offline bens

  • Expert Roboticist
  • Supreme Robot
  • *****
  • Posts: 335
  • Helpful? 3
Re: Need help
« Reply #1 on: June 17, 2008, 12:31:02 AM »
My guess is that no one has any idea what you're doing wrong because you haven't told us any details about what you've done.  For example, can you describe how you have your LEDs connected?  And what are you using to drive your motors?  I can envision around 500 things that you could be doing wrong so it would help me greatly if you could narrow the scope some rather than my having to list them all first.

- Ben

Offline izua

  • Supreme Robot
  • *****
  • Posts: 682
  • Helpful? 0
    • izua electronics
Re: Need help
« Reply #2 on: June 17, 2008, 01:26:50 AM »
you can't add motors directly to a microcontroller (like BASIC stamp). ucs supply little current. it's like connecting stage lightning to a 1.5V battery. If the LEDs don't work when tested separately, throw them away.
If you connect them to the BASIC stamp, you will have to program it before they will do something.
« Last Edit: June 17, 2008, 01:27:37 AM by izua »
Check out my homepage for in depth tutorials on microcontrollers and electronics.

Offline leebleleebleTopic starter

  • Beginner
  • *
  • Posts: 3
  • Helpful? 0
Re: Need help
« Reply #3 on: June 17, 2008, 09:53:39 AM »
I'm just trying to connect the motor into the breadboard and have it run. I'm using a BASIC stamp so i just ran a resistor from P14 over to the Vdd side at P14 and put an LED from  there into Vdd's terminal thing. However, when i try to do this using a motor it won't budge. Do i need to use a transistor or something? I'm a beginner so sorry for not giving precise details.

Offline leebleleebleTopic starter

  • Beginner
  • *
  • Posts: 3
  • Helpful? 0
Re: Need help
« Reply #4 on: June 17, 2008, 01:58:35 PM »
basically i wanna know how to put a motor into my circuit. I have a breadboard, resistors, 2 motors, capacitors and transistors.

Offline Private Reid

  • Robot Overlord
  • ****
  • Posts: 272
  • Helpful? 0
  • I love apples ... Yum !!!
Re: Need help
« Reply #5 on: June 19, 2008, 03:41:09 AM »
wiki

Offline Admin

  • Administrator
  • Supreme Robot
  • *****
  • Posts: 11,704
  • Helpful? 173
    • Society of Robots
Re: Need help
« Reply #6 on: June 21, 2008, 02:09:21 PM »
You will need a motor driver to connect a motor to a microcontroller. Just search for it in this forum and google for more info.

Offline izua

  • Supreme Robot
  • *****
  • Posts: 682
  • Helpful? 0
    • izua electronics
Re: Need help
« Reply #7 on: June 21, 2008, 07:10:55 PM »
dude, let me get this clear for you :P
Quote
you can't add motors directly to a microcontroller
read this ten times, and then try to repeat. have a break, do something you enjoy, and then try to repeat again.
if you remember, the next question comes in place.

why, you ask? take a watch or calculator battery, and connect a 100W bulb to it. it doesn't work. that's why motors don't spin from a microcontroller, either. in both cases, they don't have enough power.

now, you say you have transistors. those are switches. you can drive a motor with a transistor, and control the transistor with the microcontroller. but first, plug the motor into your power supply, and check if it works.
then, put a motor pin in +, and the other pin in the drain/collector of the transistor.
put a switch to + on the gate/base. put a resistor between the switch and the base/gate (500-1k)
last, connect a small resistor (1-5ohms) to ground and to source/emitter.

when you push the switch the motor should turn.
now, instead of using the switch, use a microcontroller's pin. That's basically it :P

Check out my homepage for in depth tutorials on microcontrollers and electronics.

 

SMF spam blocked by CleanTalk