Tuesday, March 23, 2010

Introducing the IXM Micro SD Cell

Matt, Dave, and Chris originally kicked off the Illuminato X Machina ecosystem to create a working prototype platform for modeling robust computational systems. After a few months of limited beta testing and development with the community of IXM’ers, the latest module in the IXM platform is ready.


The IXM Micro SD Cell provides a removable media interface for the IXM ecosystem. Fitting the standard IXM cell form factor, the Micro SD Cell allows portable information to be processed on the fly.

In the realm of robust and redundant systems, quite a few hackers suggested that they could use a “data cell” to explore more complex, decentralized RAID systems on modular, distributed scale. Others mentioned the lack of a “removable media” counterpart in the IXM (non-Von Neumann) architecture – see below.

image An onboard 12V voltage regulator provides 3.3V protection, and 2 sets of power pins provide an additional power routing option. The standard pin interface communicates through an SPI emulator, which allows each IXM cell to read information from multiple Micro SD Cells simultaneously. SONY DSCThe standard SD data transmission interface is also accessible via 2 unpopulated solder pads in the center of the board. The standard SD protocol is still in development, and I’ll upload it in the near future when the code is ready.SONY DSC

The IXM Micro SD Cell has a reversible connector, allowing for communication regardless of board orientation, and data from the micro SD card can be processed and propagated across the entire IXM network through the network of interconnections.

IXM SD Pin Map-2

In any case, I’m really excited to hack and experiment with networked data systems, and Dave, Chris, Matt and I will be uploading code and projects when they get wrapped up. Meanwhile, the board itself is up over at the Liquidware shop.

And as with the other modules of the IXM ecosystem, I feel like each board and project gets everyone churning on ideas for other modules that might be neat to have. I’m starting to think about the next couple boards, so any ideas are welcome :) – jhuynh at gmail

Wednesday, March 17, 2010

DIY Mad Scientist Chalkboard

What does every mad scientist share in common? I can't believe it's been overlooked for so many years... everyone's always trying to say that it's the folds in their brains, or intense academic upbringing. But after long, hard, extremely rigorous research... :-) I have concluded... that every mad, brilliant scientist has one thing in common:

They own chalkboards.

I hate whiteboards. They're horrible, they're a strain on my eyes, and they reflect fluorescent light in conference rooms and class rooms, blinding me, and making me want to look elsewhere, and that's defeating the purpose of having a collaborative, large writing surface.

So I decided to do something about it, and I looked around online for how to buy large chalkboards to replace the whiteboards, but they're way too expensive, so I decided to make my own...

Step 1: Buy wood

I found these nice square sheets at home depot. They're about a quarter inch thick, and are artificial:

Step 2: Get Tools and Primer

First, I got a kit of brushes and rollers:

And then I got Latex based primer, and Kilz odorless primer:

Step 3: Apply 2 Coats of Primer

This was actually a bit tricky. The trick is to let the latex sit over night, and also the basic trick is to make sure you're using latex. The reason is that the latex fills the holes and pores in the wood. One coat covers the basic pores, but the grain shows through. The second coat covers the grain of the wood as well, making it ready for the blackboard paint.

Step 4: Get Blackboard Paint

I bought Rust-oleum blackboard paint, because that's what they had at Home Depot. I'm sure there are many other types of paints out there, but I didn't really feel like testing them all out this time, so I went with the easiest solution:

Step 5: Apply 2 Coats of Blackboard Paint

I did this for a total of 4 blackboards :-) I also let this sit overnight, which naturally meant that it took 3 days from start to finish for me to have nice blackboards...

Step 6: Write Genius Equations

Naturally, I found that as soon as I had chalk in my hand, ideas started to flow like wine from the fountains of gods and goddesses...

That, or I just looked these up from my old physics notes to make it seem like I'm smart :-)

The point is, they look infinitely better on a blackboard than on a white board!

And here's me writing on the surface, after erasing a few times, and brainstorming about how to make the crash test sensor car with Justin:

I uploaded the other pictures up over at my flickr photostream...

Thursday, March 11, 2010

Introducing the Dual-Axis Gyro Module

The Dual-Axis Gyro is the latest project from the joint engineering effort between Liquidware and Modern Device.

I was looking through some of the nautical navigation books I picked up when I did a little research for the Compass Sensor a couple weeks ago. When compasses were inaccurate or unavailable, seafarers would turn to gyroscopes as a “keeper of direction”, the same way a pendulum in a clock was a “keeper of time”.

I had always been under the impression that the gyroscope was all about balance, and that it was more or less a kid’s toy (they are actually pretty fun to play with) Something similar to a popular corporate desk toy…or one of those plastic grip spinners that tennis players use…

The aspect about keeping balance is true, but in tilting to keep balance, the gyroscope also measures angular acceleration and helps keep track of an object’s orientation, independent of any other landmarks or determinants of direction.

File:Foucault's gyroscope.jpg

Luckily, I don’t have to strap one of these contraptions to the UAV I’m building, and the dual-axis gyro Paul and I came up with is pretty mobile.


The board uses an InvenSense IDG-500 MEMS chip that provides 500°/sec full scale range and 2mV/°/sec sensitivity of rotation. The chip also reads out temperature as well, and has an Auto Zero feature to reduce bias drift. Since it’s a 3V chip, the board itself has 5V tolerance protection for all those overvoltages I’ve ever had.

The hollow center makes the board axis mountable, and I’m thinking of using some jumper cables to hook it back up to an Arduino or mini protoboard. Here’s a snapshot of what I’m playing with at the moment:

I’m thinking about maybe putting it on the axis of a turntable? Or something else that spins and wobbles? I’ll post it as soon as I figure it out, and upload some “up and running code” as well.

In the meantime, I’ve built and tested the first batch, and they’re online over at Modern Device :)

Tuesday, March 9, 2010

The Making of: Gravitational RC Driving by Arduino

Last week, Chris and I hacked the 3-Axis accelerometer into the remote for an RC car, making it “drive by gravitation”. It turned out to be a little more complicated than expected, since the remote actually used a potentiometer to affect the radio frequency transmitted, which in turn altered the velocity of the car.

The controls on the remote were split into two parts, a steering knob, which made three contact points on the remote control PCB…


And a velocity trigger, which controlled the speed as well as backward/forward direction…

The left/right steering knob was a pretty simple switch, and connecting one pair of contacts made the wheels turn left, and connecting another pair of contacts made the wheels turn right:

I simply wired these to a set of Arduino Digital Pins, so they could be controlled from the software.

Tweaking the velocity trigger took a little bit more circuit work. The trigger was actually a spring-loaded lever hooked to a potentiometer. The gradual change in resistance was what triggered the changes in the car’s velocity, so Chris made a couple measurements to figure out what resistance thresholds made the car go forward, stop, and in reverse. Keeping the potentiometer fixed, it became just another static resistor. Then the resistance of the potentiometer could be varied in stepwise fashion by connecting (or switching on) additional resistors in parallel.

Since it was easier to simply add resistors in parallel and lower the total resistance, I set the potentiometer to the “forward” and on position, and then reduced the resistance from there.

The switches were connected to and controlled by Arduino Digital Pins. From this sketch, there are three logic levels, represented by the different resistances: 3.0 kOhm, 2.4 kOhm, and 1.6 kOhm, which corresponds backward, stop, and forward.

With the logic switches in place, it was time to put the 3-axis accelerometer into the setup, and let gravity work its magic :)

Because the switches would be digitally controlled, I used a couple TIP120 transistors to do the job.

The idea is to use the outputs of the accelerometer to set off the switches once it hit a threshold value.

To set the right thresholds, I took measurements from the accelerometer over serial on the X and Y axes. First, I held it level, parallel to the floor. Then I tilted left and right, to get a read on the X axis, and toward and away from me to get a read on the Y axis. This way, I could set how much tilt it would take to steer or drive, and make the remote more or less sensitive. I’ve put the full code over on the App Store:

#define THROTTLE_FWD 160
#define THROTTLE_REV 350
#define STEER_LEFT  200
#define STEER_RIGHT 300

void loop() {
  y_axis = analogRead(0);
  x_axis = analogRead(1);
  if (y_axis < THROTTLE_FWD) {
   digitalWrite(2, HIGH);
   digitalWrite(3, HIGH);
  } else if (y_axis > THROTTLE_REV) {
   digitalWrite(2, LOW);
   digitalWrite(3, LOW);    
  } else {
   digitalWrite(2, HIGH);
   digitalWrite(3, LOW);
  if (x_axis < STEER_LEFT) {
   digitalWrite(11, LOW);
   digitalWrite(12, HIGH);
  } else if (x_axis > STEER_RIGHT) {
   digitalWrite(11, HIGH);
   digitalWrite(12, LOW);    
  } else {
   digitalWrite(11, HIGH);
   digitalWrite(12, HIGH);

It’s pretty easy to get the accelerometer set up. I just wired in the Vin and Gnd, and then connected the Xout and Yout to different analog pins, which I polled in the code above. If the tilt values from the accelerometer were past threshold, the Arduino’s digital outs would go HIGH, switching the circuits on, and putting the RC car into motion.

Here’s another shot of the completed rig…And here’s a behind the scenes video where I tested the car upside down, just to be sure everything was running smoothly:

The accelerometer is up over at Modern Device, the other parts are over at the Liquidware shop, and the RC Car is from Target.

Thursday, March 4, 2010

Introducing the 3-Axis Accelerometer: Gravitational RC Driving by Arduino

The latest sensor module from the Liquidware and Modern Device collaboration is the 3-Axis Accelerometer.

Last week, Chris and I used the Crash Test Sensor on a radio-controlled car and measured the crash impact in a classic analog way: with a bunch of white LEDs.

This week, the 3-axis accelerometer was ready, so I wanted to create a gravitational based control…kinda like the WiiDuino, except rather than using the WiiMote for sensors, build my own gravitational controller from scratch, and use it to control something else.

This 3-axis accelerometer module uses the MMA7260QT chip from Freescale, but after frying one too many a “low-voltage” IC, I decided to build in some 5V protection to keep it safe from my Arduino. Paul’s posted it over on Modern Device.

The RC car had a two-part remote control- a knob that controlled left-right steering of the front wheels, and then a throttle trigger that controlled the speed and direction of the car (forward/stop/reverse).

It actually worked out nicely that the controls were separated into left-right for steering, and forward-backward for direction. This way, I could tilt my gravitational drive rig left or right to steer (motion in the Y-axis), while tilting toward or away from me controlled the throttle (motion in the Z-axis).

The gravitational drive rig consisted (primarily) of an Arduino Duemilanove, a DoubleWide ExtenderShield with a mini-protoboard attached, a Lithium Backpack, and the 3-axis accelerometer module.The Arduino and accelerometer parts were going to be the sensors, but to control the RC car, I still needed to tap into the existing remote, especially since I wasn’t about to generate my own radio frequencies!

So I cracked open the remote…DSC08298 …and started looking around to see how the controls might work

It was actually a little more complicated than expected, and I measured some of the voltages across non-descript leads to figure out what was actually being modified with each control. So the Arduino and accelerometer’s outputs needed to be connected to the correct contact points to transmit accurate instructions to the car.

I’ll save the science and the circuit diagrams for a “making of” post in the next couple days, but it took a few tries and adding some switches to get the right voltages and resistances at each contact point.

Here’s what the final rig looked like: The accelerometer’s Yout and Zout are wired into the Arduino, which then relayed instructions to the contacts on the remote. The whole gravitational drive remote was powered off a Lithium Backpack.

Controlling it this way was actually pretty intuitive, and my friend Matt got pretty good at driving it. I took a video of him taking the car for a spin:

And just for kicks, I challenged Matt to drive it through a little course of cones, like they do in the car commercials:

I’m still thinking of cool things to do with a 3-axis accelerometer, so I’m open to any ideas. In the meantime, I’ll scribble some notes on how I got the Arduino and remote talking for a “behind the scenes” post :-)