This is another experiment with the Arduino. It’s not finished yet, but I think it’s worth it to show it working.

A fellow iRacer asked me if I could do something like a “wind simulator”, that changed the speed of a fan depending on the speed of the car. The project is quite simple and the only electronic component needed excluding the Arduino and the fan itself is a U$0,10 NPN transistor. The transistor is needed because the Arduino can only source 5v from its PWM ports and the fan operates at 12v, so I used it to amplify the 5v PWM signal using a 12v power supply.

You can see it working below. I’ve added a high-tech piece of paper into the fan just to make some noise, as it would be hard to notice the fan speed changing watching the video.

Yeah, I’m aware that the Riley DP is a closed cockpit and the “wind on my hair” feeling doesn’t make too much sense in it, but I only noticed after I recorded the video.

The source code couldn’t be more simple. It just sends a PWM signal through port 11 on you Arduino board. Usually those computer fans are not designed to be controlled with pulse width modulation, but it works. The lifespan of the fan will probably be reduced, but nothing that you should worry about. You can also buy an PWM motor/fan if you like.

Anyway, simply paste this code into the Arduino IDE and upload it to the board.

const int outpin = 11; void setup() { Serial.begin(9600); pinMode(outpin, OUTPUT); } void loop() { if (Serial.available()) { int inByte = Serial.read(); analogWrite(outpin, inByte); } }

The wiring is just as simple. Below you see a “fancy” wiring with the protoboard and also a regular schematic design.

The parts list is very short:

1x Arduino board (Uno or Duemilanove for example)

1x NPN Transistor (eg. 2N2222)

1x 12V DC computer fan (or PWM fan)

It’s worth noting that you will need to use an external power source connected to your Arduino in order to make the 12V fan work properly. You can use those simple DC adapters that you can find with almost any home gadget. Pay attention to the pinout polarity. If you choose to use a 5V DC fan instead of a 12V one, you don’t need an external power source and you also don’t need the transistor. Simply connect the pin 11 to the positive pole of the fan and ground the other pole.

Below is the download link for the client software (includes source code and executable). Code was written in Visual C# 2010, so you’ll need .NET Framework for it to work properly.

The contents of this project is distributed as “donationware”. If you find them useful, please consider doing a small donation.

DOWNLOAD: http://fergonez.net/files/iRacingWind.rar