Monday, April 18, 2011

Logic level shifter


The Arduino normally runs at 5 V. The pressure sensor and accelerometer run at 3.3 V. The sensors could be damaged by 5V. What to do? Use a "logic level shifter"! It converts between 3.3V and 5V signals (bi-directional), so it works well with the I2C protocol.

The logic level shifter board hangs off the end of the 17 row mini bread board, hence the cluge of gator clips for this checkout (note to self: if ever make perf board or PCB include at least 20 rows). Also pictured is Arduino and Fritzing running on Ubuntu (an open-source hoe-down!).

Sunday, April 10, 2011

Accelerometer

I have added an ADXL345 accelerometer for the reliable detection of launch. This sensor is over-kill for this simple function, as it has 3 axis sensing, and I am only using one (I might eventually figure out something to do with the other 2 axis). The launch detection criteria is now exceeding 2g (1g acceleration + 1g gravity) in the vertical direction. Since the launch acceleration should exceed 20 g almost instantaneously, launch should be easy to detect. Also, since the unit is intended to be powered up only when on the pad ready for launch, usual handling should not exceed 1g (causing a false launch detection).

The programming was much easier than I had feared, due to the availability of libraries for this sensor. It uses the same I2C bus as the pressure sensor, and the same 3.3 V supply from the Arduino, so it was easy to integrate. The accelerometer and pressure sensor breakout boards fit side by side (although rather snuggly) on the 17 hole row mini-bread board.