Intro: ArduSensor Fun Pack
ArduSensors are open source plug-in-play sensors for Arduino. These were originally made for beginners to get started with Arduino, a very cool electronics prototyping platform, but anyone can use them. I still play around with them all of the time, and I bet a ton of people that are experienced with electronics still love them. That's why ArduSensors fit the whole crowd. ArduSensors fit directly into the power pins and A0, like a mini shield. They come with male headers, not stackable headers, so that you can plug them easily into the Arduino. The entire line of ArduSensors are available now at my website, www.qtechknow.com if you would like to make a purchase, or check them out.
Types of ArduSensors
I will cover the ArduSensor Pot and the QBar Graph in this Instructable. I have 12 ArduSensors available now and more coming soon. The ArduSensors currently available include: ArduSensor Arcade, Button, Fart, Flex, Force, Knock, Light, Magnet, Phototransistor, Pot, Switch, and Temperature. I carry a shield for Arduino that can read up to 4 different ArduSensors at once and have 3 different output options. Also, if you would like output, there is the QBar Graph, QColor, and QBuzz. The QBar Graph is an LED Bar Graph that goes into the digital pins on the Arduino, the QColor is an RGB LED that goes into the digital PWM pins on the Arduino, and the QBuzz is a buzzer add-on that can make many different noises!
Below are the Eagle files (the schematic and the PCB design), since ArduSensors are all open source.
Step 1: Parts
All of the parts that are listed below you can get at Sparkfun.
Arduino UNO, Arduino Leonardo, or later
A computer running Arduino IDE 1.0.1 (free)
USB-B Cable (for programming the Arduino UNO only)
USB micro-B Cable (for programming the Arduino Leonardo only)
The ArduSensor Fun Pack includes the ArduSensor Pot and QBar Graph.
ArduSensor Pot Kit from my website, Qtechknow.com includes:
Qtechknow ArduSensor Pot PCB (not yet available)
Male Headers (5)
QBar Graph Kit from my website, Qtechknow.com includes:
Qtechknow QBar Graph PCB (not yet available)
10 Segment LED Bar Graph
Resistor Network - 330 Ohm (2)
Male Headers (14)
Step 2: ArduSensor Pot Assembly
The ArduSensor Pot is a potentiometer that you can use in any of your Arduino projects. Let’s teach you how to build your kit:
Step 1: Take out all of the parts.
Step 2: Put the potentiometer on the front of the PCB, in the 3 holes in the middle and the two big holes on the lower corners.
Step 3: Flip the PCB over and solder the potentiometer in place. Solder all 5 of the holes that your potentiometer is placed in, even the two big holes.
Step 4: Get your Arduino out (this step doesn’t depend on which Arduino you use). Cut the male headers so that you have a 1 pin male header separate from the other 4 pins. Put the long side of the 1 pin male header into A0 on the Arduino. Put the long side of the 4 pin male headers into VIN, GND, GND, and +5V, which should be all together. Now, put the ArduSensor PCB (with the potentiometer already soldered) onto the 1 and 4 pin male headers. Solder the holes for the headers in place. I have found this tip to be very helpful in keeping the PCB perpendicular to the male header pins.
You are now finished assembling your ArduSensor Pot, and ready to program (or if you like, copy my programs)!
Step 3: ArduSensor Pot Coding
Plug your Arduino UNO or Arduino Leonardo into your computer via the cable that corresponds to that Arduino. If you are a first time Arduino user, you can install the drivers necessary to use the Arduino here (on step 4 of this Arduino page). If you know how to use and run the blink sketch in the Arduino IDE already, select the COM port for your Arduino, and the correct board from the boards menu.
Download the example code for ArduSensors here. Press "Download as Zip" and unzip the folder. Double click on the ArduSensor-LED.ino sketch and run it on your Arduino by clicking on the right arrow key in the Arduino IDE. Plug your ArduSensor Pot into the Arduino (the 4 pin male header goes into VIN, GND, GND, and +5V, and the 1 pin male header goes into A0). ArduSensor-LED.ino is a program to make the built-in LED on D13 to blink at a rate specified by the value (in this case, how much you twist the knob) of the ArduSensor (in this case, the ArduSensor Pot).
Now double-click on the SimpleRead.ino sketch which is in your ArduSensor example code downloads folder and press upload. Plug your ArduSensor Pot into the correct pins (see prior paragraph). Open up the serial monitor (a monitor that you can see on your computer that spits out data) by pressing the magnifying glass in the upper right hand corner. A box that has numbers on the screen should pop up. If you look at the numbers (which are called analog values in Arduino), they will change when you twist the knob.
The Arduino analog values can range from 0 to 1023. So when the potentiometer is all the way one direction, it will read 0 in the serial monitor, while when it is twisted all the way the other direction, it will read 1023. Any position other than that will read 1 to 1022, depending on the direction and degree of twist of the potentiometer.
Below are the schematic and PCB design files, since this is all open source.
Step 4: QBar Graph Assembly
The QBar Graph is an LED Bar Graph that you can use in any Arduino project. Let’s teach you how to build your kit.
Step 1: Take out all of the parts.
Step 2: Find the LED Bar Graph and find the side that says “YS” on the side. These are the anodes of the LEDs in the bar graph. Put the side that says “YS” into the side on the bar graph on the PCB that says “Anodes”. Put the unmarked side into the “Cathodes” side of the bar graph on the PCB. Solder the bar graph into place.
Step 3: Find the 2 resistor networks and find the small black dot on them (on only one side). The pin that has the small black dot above it will go into the square hole, while the 5 other pins will go into the circle holes. As you will notice, the two resistor networks will not be oriented the same way. Solder the resistor networks in place.
Step 4: Get out your Arduino UNO or Arduino Leonardo and place it in front of you. Take the 14 pin male header and with your diagonal cutters, cut the the 14 pin male header into a 10 pin male header and a separate 4 pin male header. Plug the 10 pin male header into Arduino pins: SCL, SDA, AREF, GND, D13-D8. Plug the 4 pin male header into Arduino pins D7-D4. Put the QBar Graph PCB onto the 10 and 4 pin male headers. Solder the pins at the holes. Use the soldering pointer described in the ArduSensor Potentiometer assembly, try to keep the male headers perpendicular to the PCB.
You’re now finished soldering the QBar Graph, and ready to use the kit.
Step 5: QBar Graph Coding
To use the QBar Graph, plug it into the pins that you soldered it into, and also plug in the ArduSensor Pot. Open up QBarGraph.ino (included in your example code folder) and load it onto the Arduino. This sketch reads the value of the potentiometer and lights the LEDs accordingly. In other words, when you twist the potentiometer, the LEDs will light up depending on how much you twisted it.
Below are the schematic and the PCB layout, since these are open source.
Step 6: Go Grab a Kit!
Go grab a kit at my website, Qtechknow.com, or if I’m lucky with the Kit Contest, Instructables might send you one!!! There are plenty of other projects to do with the QBar Graph and ArduSensor Pot out there too, if you would like to look at them. If you have a great project in mind, leave a comment below or post an Instructable and send me a link!