Electronics


Electronics& Front Page13 May 2008 06:16 pm

For dorkbotpdx last night, I made this little toy:

WiiMatrix

It’s an 8×8 red+green LED Matrix, driven by three shift registers driven by a Bare Bones Board Freeduino by Modern Device Company.

Before the meeting I just had it flashing fun patterns based on odd bit-math equations. During the meeting, I was urged to add some code to make it controllable by the Wii Nunchuk. So, I wrote a simple program that takes the X and Y of accelerometer and plots it on the matrix.

I drove the LED Matrix with three shift registers: One 74HC595 8-bit register gave power to the rows of the display, and one Maxim-IC MAX6969 sank current for the columns to the display. To turn on row 1, column one, you shift “B10000000” into the row register, and “B10000000” into the column register:

  1 0 0 0 0 0 0 0  
1 x o o o o o o o
0 o o o o o o o o
0 o o o o o o o o 
0 o o o o o o o o 
0 o o o o o o o o 
0 o o o o o o o o 
0 o o o o o o o o 
0 o o o o o o o o 

Altogether, it was about 30 lines of code to drive the matrix with some fun patterns.

Electronics06 May 2008 10:21 pm

Analog pins 0-5 on the Arduino can be accessed as digital IO pins. They’re numbered 14-19.

Electronics& Front Page23 Apr 2008 08:57 pm

I just received this set of prototyping boards from ucHobby and their sponsor Wright Hobbies!! Hooray!

Prototyping boards

I’m psyched. I have some projects I want to do that these boards will be perfect for.

Electronics& Front Page21 Mar 2008 03:19 pm

In order to encourage us to play with electronics more, JWA and I have begun doing monthly challenges. For our inaugural challenge, we decided upon an LED Birthday Candle. This is my entry to that challenge.

LED Birthday Candle

You blow the center pole towards one side, and the LED shuts off. To turn it back on again, blow it the other direction. It’s a circuit known as a bistable multivibrator, or “flip-flop”.

I do like that it’s so simple and cheap, though.

My parts list is simply:

2 – 10k ohm resistors
1 – 1k ohm resistor
1 – 220 ohm resistor
2 – 2n3904 NPN Transistors
1 – LED
3 – AAA batteries (this thing’ll last forever!)

Not including the batteries, this thing costs less than 15 cents in parts. If I could work out the “blow” mechanism a little better, I think this would be a marketable product.

Okay, now for some photos:

On the breadboard:
LED Birthday Candle

Before being shoved in the pill bottle:
LED Birthday Candle

I had originally wanted to be able to shove this thing into a fat straw, like you get with a bubble tea, so I made it as small as possible, and soldered the pieces together straight rather than using protoboard:
LED Birthday Candle

Next: Brighter LEDs!

Electronics03 Mar 2008 11:31 pm

My Wiichuck adaptor arrived a couple of days ago, and I just hooked it up.  As my first project, I’ve written this, which uses the Wii nunchuck as a musical instrument.

Source code: Freqin’ Wii

Hook a speaker to the output pin (defined below, 13 by default), and hook the Wii adapter up to analog pins 2-5, preferably using the Wiichuck adapter. Tilt the wii from side to side to adjust the tone, and tilt forward and back to adjust  the octave.  Push the joystick forward and back to adjust the length of the note.  Push the Z button to play the note.

I’m trying to think of what else I could do with this.  There’s just not a lot of data out there that can use three dimensions of acceleration data and two dimensions of joystick data.

Electronics& Front Page& Photography02 Mar 2008 11:52 pm

Awed By The Beauty Of The Light The electronic man holds his joy aloft.  He loves it, because he was built to love it.  It shines with the energy that courses through his body.  He wants to share his Light with the world, but fears that if he lets it go, he’ll never know it’s glow again. 

Electronics& Front Page01 Jan 2008 02:37 pm

I’ve recently become enraptured with a little microcontroller development board called the Arduino (pronounced “Arr-dwee-no”).

Arduino Diecimila

This little thing is a great way to get started with electronics. You hook some electronic component to it, write a little bit of C, upload it to the board, and “tada!”, you’ve invented some new Gizmo.