If you’re planning to build a basic digital readout using iGaging “Remote DRO” scales and the “Touch DRO” Android application, you will need to make a controller that will interface the scales to the tablet. At this point I’ve designed two different version: one is based on Texas Instruments MSP430 LaunchPad and the other uses an Arduino. Both controllers offer the same functionality so the choice comes down to a personal preference and the availability of the microcontroller board. Yesterday I posted build instructions for the Launchpad version. In this post I will provide detailed step-by-step directions for a DRO controller using Arduino UNO and an inexpensive Bluetooth adapter.
To build a basic version of the Arduino based controller you will need only a few parts:
- Arduino UNO (in theory any arduino should work)
- Bluetooth Transceiver Module
- One 220 Ohm resistor
- One 330 Ohm resistor
- Three resistors in the 10-47 Kohm range
Tip: Sparkfun 500 1/4W Resistor Kit from Amazon or Sparkfun.com includes all of the needed resistor values (and then some).
If you live in the USA these parts, with the exception of the Bluetooth adapter, are likely available at your local Radio Shack. If you’re lucky you might be able to find a Bluetooth shield or ArduinoBT locally as well. Otherwise there is a number of Bluetooth adapters on the market. I am using the so-called “Linvor Bluetooth Transceiver because its very inexpensive and is readily available on eBay and from many other online retailers.
|Most of the parts for a basic DRO controller are sold at the Radio Shack|
Additionally, to keep the build neat I’m using an Arduino Proto shield. It adds about $16 to the total cost, though.
Please note, I removed the top part of the stackable headers because they were getting in the way but you don’t have to do it. Never the less, if you decide to get rid of them simply pull out the black plastic part and clip the pins with a pair of wire cutters.
If you are planning to use Sparkfun’s Mini-USB breakout boards to connect the scales please take a look at step 2A in the LaunchPad build instructions. Otherwise you can simply cut off the USB plug and solder the wires directly to the board. For consistency's sake I am intentionally sticking to the Red-White-Green-Black color coding for Vcc, Clock, Data and Ground respectively.
Step 1 - Build the voltage divider for the clock pin
First solder a 220 Ohm resistor as shown in the picture
|220 Ohm resistor soldered to Arduino's Pin 2|
Then add the 330 Ohm resistor next to it
|330 Ohm resistor (left) added|
Step 2 - Add the pulldown resistors
Insert three 10-47 KOhm resistors (any value in that range should work) into the board but leave the leads uncut
|Three 47 KOhm pull down resistors inserted into the board|
Now flip the board over, bend the leads as shown in the picture and cut the excess
|On the underside the leads are bent to make the needed connections|
Solder the leads farthest from the board edge but leave the ones next to the header pins unsoldered for now
Step 3 - Connect the data lines
Insert three green data-in wires into holes nearest pins 3,4, and 5 (X, Y and Z axes respectively).
|While the leads on the right remain unsoldered the green wires can be inserted|
Flip the board over and solder the wires and the unsoldered leads of the resistors making sure they are connected.
Step 4 - Connect the clock lines
Solder the white clock line to the point where 220 and 330 Ohm resistors meet.
|White clock line inserted into the hole where in the middle of the voltage divider|
Make sure to strip about ¼" to ⅜” of isolation so there is enough exposed wire to tie all three points together as shown below.
|On the underside the bent wires are soldered to make the needed connections|
If you chained the USB boards you will have a single white wire going to the board. Otherwise you can try inserting all three wires into one hole or making a three-into-one wire as shown in the picture.
Step 5 - Connect Vcc
Prepare a piece of [red] wire just long enough to reach from the 3.3V pin to the lower right corner of the board.
Solder one end to the hole next to the 3.3V pin and leave the other end unsoldered.
|Red wire is used to bring the 3.3V supply to the right side of the shield|
Insert the Vcc wire coming from the scales in the hole next to it, bend the two ends (on the flip side of the board) so they make a connection and solder them together.
Step 6 - Connect the Ground
Prepare a piece of [black] wire long enough to reach from the Gnd pin to the hole just next to the 330 Ohm resistor. Make sure to expose a bit of extra wire on the end that goes to the resistor. Insert the wire into the appropriate holes and bend the extra bit of the wire on the resistor end so it touches resistors lead.
Strip ¼” or so of isolation off the [black] ground wire coming from the scales and insert it into the hole next to the Z-axis pull down resistor as shown in the picture. Bend the extra bit of wire so it touches the resistor’s lead on the underside.
|Vcc and Ground connected to the Arduino V3.3 and Gnd respectively|
When Vcc and Ground are soldered as described in the above two steps the underside should look similar to the picture below. At this point you should have all the connections involved in reading the scales done. If you own a multimeter it might be a good idea to check for continuity and shorts (just in case).
|At this point the underside should look similar to this|
Additionally I would suggest to upload the sketch to the Arduino, plug it into the PC and make sure you are getting position readings in the “Serial Monitor”. When you move the scales you should see readout similar to “x12345;y2345;z;12345;x12345;y2345;z;12345;” and so on; if you see only “x0;y0;z0;x0;...” the scales aren’t working right.
Step 7 - Connect the Bluetooth transceiver
The transceiver requires only 3 wires: Vcc, Ground and Rx. I’m using a piece of Brown-Red-Orange hobby servo cable but you might as well use the Black-Red-White scheme (which happens to be another hobby servo standard).
- Prepare a piece of black (brown) wire and connect connect it to Linvor’s Ground pin
- Prepare a piece of red wire and connect it to Linvor’s Vcc pin
- Prepare a piece of white (orange) wire and connect it to Linvor’s Rx pin
Step 8 - Connect the transceiver to the shielda. Strip a bit of extra isolation on the end of the black (brown) wire. Insert it into a hole next to the X axis pull down resistor’s ground lead. Bend the end of the wire so it touches the lead and solder it in place b. Expose a bit of extra conductor on the end of the black (brown) wire and insert it into the hole next to scale’s Vcc wire. bend the tip so it touches the Vcc line and solder it in place. c. Solder the end of white (orange) data wire to the Tx pin of the Proto shield.
|Bluetooth transceiver connected to the shield|
Side note: Since Arduino uses it’s Tx/Rx pins for programming (uploading the sketches) you will need to be able to disconnect the [orange] data line from the bluetooth module when programming. The simples way to go about this is to simply remove the shield; since I used a piece of servo cable I got the connectors on the end “for free”, I kept them as a convenience feature.
After following these steps you should end up with an assembly that looks something like the one in the picture below.
|The board should be functions with these connections|
On the underside all Vcc lines should be tied together and so should be the Ground lines.
|The underside of a completed shield|
At this point you should have a functional Arduino digital readout adapter.