HomePage RecentChanges Instrument2

Instrument Two (2)

An idea for a basic instrument for kids. It is a cube with 6 different coloured sides with a light.

Need to get:

Have already:

Status / Update

Basic code with Knock to volume and LED is done.

The basic play code is working, but the music is terrible. Using no new hardware I am going to be stuck with some pretty simple output.

The first full coloured side knock sensor is built and yet to be tested.


The idea is to be able to replace the program occasionally with something new as Teha grows.

Hit and Watch

The first and basic is hit and watch. Each side that is hit plays a sound at the volume / pitch hit (could be a good variation) and a light is played on that panel.

Teha Says

Like the old Simon game - where a song will play on a few sides and then you have to play it back at the same sides, gets faster and harder.


Idea copied straight from Make Magazine 2008 (March I think) of having a sequence (e.g. 8 beats) played in a cycle, where the note you hit at the beat time is remembered and played next time. So you can make basic sequences.

More Hardware

Some simple additions like a PIR (Passive infra-red motion sensor) can help it be more interactive.

Example code for reading Knock sensors

 * Ardrumo sketch
 * Use with the Ardrumo software here:
 * http://code.google.com/p/ardrumo/
 * This is designed to let an Arduino act as a drum machine
 * in GarageBand (sorry, Mac OS X only).

#define LEDPIN     13     // status LED pin
#define PIEZOTHRESHOLD 5  // analog threshold for piezo sensing
#define PADNUM 6          // number of pads

int val;

void setup() {
  pinMode(LEDPIN, OUTPUT);
  Serial.begin(57600);   // set serial output rate

void loop() {

  // Loop through each piezo and send data
  // on the serial output if the force exceeds
  // the piezo threshold
  for(int i = 0; i < PADNUM; i++) {
    val = analogRead(i);
    if( val >= PIEZOTHRESHOLD ) {
      digitalWrite(LEDPIN,HIGH);  // indicate we're sending MIDI data

Software error:

Can't locate object method "endform" via package "CGI" at /data/scott.dd.com.au/wiki/modules/search.pl line 15.

For help, please send mail to the webmaster (webmaster@dd.com.au), giving this error message and the time and date of the error.