I set three functions for different range of distance as fallowing:
1.about 50-80cm: Play
2.about 15-50cm: Play and fwd
3.about under 15cm: Play and change volume
Here's the video where I use three leds to test if the code works first.
LED + IR from Hsiang Ju Hung on Vimeo.
The left led is Play, the middle one is Fwd, and the right one is Vol.
So, it works fine with pin high and low/led on and off.
And here is the code.Download ir_recorder.rtf
Then I put the connectors to the recorder.
Here is what happen on level 1 and 2.
Level First to Second from Hsiang Ju Hung on Vimeo.
Level 3, which will keep changing volume on the same sound file if you stay longer.
Level Third: keeps changing volume from Hsiang Ju Hung on Vimeo.
Comments
You can follow this conversation by subscribing to the comment feed for this post.