Gabriella Levine

ongoing and past work

crankshaft music

things i’m learning from the mp3 trigger that i forgot:
>>power it using usb or 5V? extension
>>Status light:
1 long blink – No formatted microSD media found.
1 long blink, followed by 1 short blink – microSD media found, no MP3 files located.
Constant short blinks – Hardware problem with MP3 Decoder.
3 short blinks – microSD media found, at least 1 MP3 file located.

NAMING
–>Track names have to be as followed:
TRACK001.MP3
TRACK002.MP3

and so on

LIMITATIONS TO THE MP3 FORMAT?
—>IT Supports a bit rate of up to 192 kB

Initially I think my problem is the SD card, if I remember correctly:
What I’m trying to set up now :

–>spin an crank shaft that is somehow attached to an encoder, when the encoder recognizes motion, trigger a song. To trigger a song, this should happen when jumping one of the “mp3 tracks” to ground on the mp3 trigger, ie writing low to one pin that is connected to the mp3 trigger track pins.

using any encoder code: http://bildr.org/2012/08/rotary-encoder-arduino/

and this schematic:http://www.hobbytronics.co.uk/arduino-tutorial6-rotary-encoder

— > Step 1. Only if there is a change in state of encoder position, write LOW to the pin.
Let’s start with pin 13, just to see if I can have this happen with the light.
AND , once the state changing stops, write HIGH (ie don’t play the song)


Simply, this takes an arduino input (ie the encoder) but then outputs a DIGITAL signal to trigger a track. So here, D13 triggers a track to play when written LOW.
The outer strip on the mp3 trigger pins are GND; the inner pins are what D13 should be connected to;

———–
After a while this proved not to be so simple:
https://forum.sparkfun.com/viewtopic.php?f=14&t=32647#p145292
https://forum.sparkfun.com/viewtopic.php?f=14&t=34282#p152976
things learned: use a pull up resistor for triggering clean, LOW output. ; if any of the pins are “pulled high” none of the pins will work…

eventual code:


Leave a Reply