Go Down

Topic: Looking for some input for school related work (Read 1 time) previous topic - next topic


You probably need to focus on your programming project first instead of buying general hardware. If your self study is to be programming orentated, the outside hardware needs to support the internal programming you are going to demonstrate.
Consider the daffodil. And while you're doing that, I'll be over here, looking through your stuff.   8)


It looks like you have the fan thing under control! Get a three wire fan and everything should be able to be worked from there!
With regards to the Sensor, as zoomkat said, if your project is meant to be programming biased you really need to concentrate on that.
The LM335A and OP AMP approach will look cool if you can demonstrate the HW and how it works and all of its calculations, but if your not getting marked on it, its more woirk than really needed!

So the other option is to look for a 10k Ohm NTC this will give you 25 deg C at 10k ohms and using another 10k resister in a p.d. you get 2.5V at 25 degree's and its then a simple curve calc to give you your temperature.
Very simple HW but could be a little more difficuilt to calibrate, but it might do what you want it to do, and it is small enough to be fitted in front of the fan to get a good air temperature.

One other way, is to use a I2C Temp sensor, according to the spec's there very sensitive and pre calibrated, sparkfun do a TMP102 board.
Its about 15mm x 15mm so still quite small and could be positioned so that the fan pulls or blowns air over it. But you get a much more accruate reading.
IF your trying to be clever you could get the ntc, the LM335A and the TMP102 and do a project to calibrate the ntc and the LM335A against the TMP102. Fairly boring on HW but the software would be quite indepth espically if you try to write the code so that is dynamically calbrates the sensors!!! I've done some work on that if you want a hand!


Jesse B

milneandfletch, thanks again for the help.  I do have a couple questions, however.

I understand pretty well how I should go about controlling the fans.  One thing I'm unsure of however, is how I read the RPM.  Is it as simple as connecting the proper wire to an input on my Arduino, or is there more required than that?

I'm gonna order up a couple 10k NTC's, as well as the LM335A and the TMP102, just for some variety.

Thanks again,

- Jesse


Hi Jesse,
Its very simple, the tacko output from the fan is put to ground two to three times (depending on the fan) per rotation, so all you have to do is wire that directly into the Ardunio's I/O pin with a 10k ish resistor connected to + 5V (Pull up resistor) so that you get a square wave.
Then you use pulseIn to measure the time between pulses.
And from that you can calculate your RPM.

I would suggest you start of looking at the fan at 100% (Fully on) and work backwards, as you may not know if it is a 2 or 3 pulse per rotation fan.
For simplisty I would suggest you start of controlling the fan in a percentage manner, (this should make the control routes much more straight forward) then if you really want to know RPM calculate this from the percentage, or from the pulseIn routine.
Also bear in mind that the fan will only start at about 40% but may go down to 10-20% due to the produced emf needed to move the fan from standing or emf needed to keep the fan moving.
So you may need a start routine.

Good Luck.



Jesse, just to be controversial, I would recommend you avoid flowcharts.

If your code is so complex and opaque that flowcharts actually help, then go fix your code and make it easier to understand, rather than try to solve its opaqueness with a flowchart. After all, if the code doesn't match the flowchart, the flowchart hurts, and if the code is broken, the time and effort sent drawing a reasonable flowchart would IMHO be better spent fixing the code or making it easier to understand.

My other concern is some folks draw flowcharts which might look okay, but are awful to implement in code. IMHO, it's better to have clean, easy to read code than any flowcharts.

I agree strongly with using comments to add value which the code, with well chosen variable names, would lack.

Version control is well worth the effort. If you have to maintain a log book, it can be helpful for that too. Add your log book to the versioned files.

A VERY low-cost project if you have an Arduino is a LED which comes on when it's dark, and off when it's light. You aren't allowed to use any other sensors than the LED itself. This is a nice illustration of the physics of LEDs, they can emit photons or detect photons.

Hall effect sensors are pretty interesting, and low cost. You can use them to time movements (like something spinning) by gluing a magnet onto a moving part. So you could do speed estimation with any existing 'dumb' motorised object, which may earn you more kudos from your teachers.

Also, making a tacho with an LED and a phototransistor (or photodiode) would give you an approach for fan control, or for a robot to track its speed, and hence estimate position.

You could also make a wireless communication system with LEDs and phototransistors/diodes. You could use an analogue electronic system, or use two Arduino's for a digital system.

If you are happy soldering, and have access to a USB to serial lead, you might even make an Arduino (without the USB part) on some stripboard/veroboard. Then you could show a free-standing product (and have a second Arduino :-).

Having said all that, I'd echo the earlier sentiment - focus on what you want to have working at the end, and buy bits to support it.


Go Up