Kinect Fan Control via Arduino

On March 22, 2011, in Kinect Dev, by Vlad Cazan

Multiple FansAs my final year at Ryerson University comes to a close, there is one last project that I must do in order to graduate. It is called special projects and for my special project I will be creating an interactive sensory room using the Kinect as the central control system. Since I wanted my project to stimulate the senses I am looking toward playing with 2-3 senses in general. Light and sight are a huge part of our body and how we interact with everyday object so I knew one of the senes to stimulate would be using visual objects like lights. For the next part of my project I wanted to find a way to stimulate the sense of felling and touching. For this part I have decided to use fans to blow air towards the user. I will set up 15-20 fans in a row and when the user walks by, or places his hand in front of the fans, they will turn on. Not all of them will be on at the same time and I need to control each fan individually. Through a few experiments I have learned that there are two ways of accomplishing this task.

The first way to control individual motors with an arduino is by using IC chips like a motor driver to power the motors externally and switch them on and off. Although this seems like the easier way to do this task, it is not very cheap. Each chip can cost up to $5 and each chip can only do 2 motors. Another way to do this is by using relays. The 5v signal from the digital pin of the arduino can be used to energize the coil and open the connect. Since the arduino does not have much current, you also need to add a simple n2222 transistor to boost the current and voltage so that the coil can stay open or closed. Since I could buy each relay for about $1 and the transistor for under $0.10 I opted to go with this instead of the IC chips.

After a quick visit to the dollar store I found some great portable fans for $1 and bought a few to try out. Using relays really makes the organization of parts really easy. Switching the fans on and off is also really simple and fast. There is no lag time and I have been able to switch the relays at 50ms with no problem. One issue I am finding is that these fans create a ton of vibration. Finding a suitable way to attach the fans to a piece of wood is going to be really important.

I wrote a quick program in processing using the processing wrapper for Kinect and send the info to arduino my via the serial communication port. When my hand it down both fans are off, when my hand is up on the left side the left motor turns on a vise versa. Here is a video of my progress.


 


 

9 Responses to “Kinect Fan Control via Arduino”

  1. jason says:

    So, can you get a variable switch so that it is not just on and off, but rather comes up and down in increments? That would be curious.

    • Vlad Cazan says:

      Yes, it is possible, using the pulse width modulation feature on some of the digital pins on the arduino. The problem with using the digital pins to power the fans is that there is no way enough current could get through. So the only solution to this problem would be using a chip like the L293D motor diver to power the motors externally but controlling their speed via the PWM pins:) this solution would work for 4 fans but no more then that since you would run out of pins.

      You got me excited about trying this, gonna warm up the soldering iron, and report back.

      Lucky I have this chip in my stash never used before tho.

  2. hex705 says:

    Hey Vlad,

    you can multiplex PWM if you are needing more fans. You are right about current — but that will just impact the low-end — getting over minimum current — after that you would have some level of control.

    • Vlad Cazan says:

      I have a 16 channel analog multiplexer (HP4067). Would that work the same as the PWM pins? If thats the case I would only need a few more motor drivers and i’d be on my way.

      Kinda regretting the 15 5v relays I ordered from spark fun last week now….

      Im just building a quick POC as we speak, Ill get a video up soon.

  3. […] out the sweet hack/video of EDGElab RA, Vlad, controlling a fan using Kinect and […]

  4. mxl says:

    hello vlad!
    very cool project,
    i am having trouble to set up a simple communication between the kinect and arduino. could you maybe tell me how you accomplished this? beginner level here.

    • Vlad Cazan says:

      I am just using processing and TUIO Kinect to send serial data to the arduino. The arduino then listens for these commands. Let me know if you need any help.

  5. Chris Sketch says:

    This is a really awesome project and really well done. Have you been able to get more than two working?
    I’m working on a project like this that uses stepper motors rather than DC motors, but I’m having power issues. The stepper motors run on 12V and they’ve blown up a couple arduinos :-/

    • Vlad Cazan says:

      Hey Chris,

      What you need to do is power the motors externally using a 12v supply, and power the arduino with 5v,

      You can do this with relays or a motor/steeper driver chip.
      Let me know if you need more info.

Leave a Reply

WordPress主题

Page 1 of 1 1

Looking for something?

Use the form below to search the site:

Still not finding what you're looking for? Drop a comment on a post or contact us so we can take care of it!

Visit our friends!

Highslide for Wordpress Plugin WordPress主题