Shop OBEX P1 Docs P2 Docs Learn Events
Fan Control Problem — Parallax Forums

Fan Control Problem

Dan TaylorDan Taylor Posts: 207
edited 2008-05-28 05:20 in BASIC Stamp
Hi,
· I·am a beginner and have a small black square motorized fan. Like the one shown... http://www.mpja.com/prodinfo.asp?number=17441+FN·I was wondering how to control it with a Basic Stamp commad. I tried Pulsout with a Loop command but it moved in tiny ity bity jerks not enough for anything.

Any Ideas?

▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Dan Taylor

Comments

  • JonathanJonathan Posts: 1,023
    edited 2008-05-26 12:52
    Dan,

    How are you driving the fan? If you are going directly from a Stamp pin, not only will it not work, but you will damage the Stamp pin. You know that fan is 24V, right?

    With a transistor, I would imagine the pulsout command would work fine. I would start with simple on/off control however. Once you have the fan working, experiment with the pulsout command. I assume you are looking for speed control of the fan.

    Another thing, you will want to place a diode across the power leads of the fan to prevent back EMF from messing with the stamp.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
  • Dan TaylorDan Taylor Posts: 207
    edited 2008-05-26 16:27
    OK... I'll try that. The fan I have looks like the one I showed. But mine works fine on 5-9v.


    Did you mean to put a diode across the Negative and Positive?


    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Dan Taylor
  • JonathanJonathan Posts: 1,023
    edited 2008-05-26 18:10
    Even if it is a 5V fan, you can't run it form a Stamp pin. The Stamp simply can't provide enough current, so you need a transistor.

    Place the diode across the power leads to the fan, as close to the fan as you can. Connect the end of the diode with the band to + (VDD) and the other end to - (gnd). Inductive loads like fans produce power spikes when turned off. The diode gives that spike a place to go, other than to your transistor and Stamp pin.

    Start by getting an LED to turn on and off using a transistor. Then connect that to the stamp and get it to turn the LED n and off. Then add the diode and test again. Then connect the fan.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    www.madlabs.info - Home of the Hydrogen Fuel Cell Robot
  • jtrzjtrz Posts: 40
    edited 2008-05-27 19:14
    Hi Dan,

    I'm a beginner too. Saw your post. I had posted a similar question recently. It was how to control a small 1.5 v DC motor with a BS2. I was trying to do it with the output of a pin on the BS2. Replies showed me why it could not be done and the correct way to do it.

    Over the weekend, I finally got it. Here's the thread:

    http://forums.parallax.com/forums/default.aspx?f=5&m=269450

    Has a few snapshots on how the basic circuit should be wired.

    The reed relay will not work on your scale. We're tallking 1.5V vs. your 24v among other things. You also need something to substitute for the relay. You have a separate power supply for the fan just like I do with the AA battery for the motor. The diode to protect the Stamp, etc.

    Just thought it might help...

    John
  • Dan TaylorDan Taylor Posts: 207
    edited 2008-05-27 21:11
    Ok,

    Thanks guys! Thats very helpful.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Dan Taylor
  • ercoerco Posts: 20,261
    edited 2008-05-28 05:20
    Actually, that same little reed relay should work fine for you. It can handle up 60 volts and 500 mA, your fan is rated 24V, 160 mA. Game on!

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    ·"If you build it, they will come."
Sign In or Register to comment.