Allura.ASM (13112Bytes)
This is 'Allura' - a small synthesiser I built as a platform to test out a few techniques for another project in progress.
Update 21/2/2010 - I've updated the code again with improved button debouncing and a title animation. There's also a new YouTube video to demonstrate the new modes. The first 3 columns in the top LED rows show you which octave you're in, and the 5 columns after that show you which mode is active. I've just signed up for Vimeo, so there will be an alternative video source for those that can't use YouTube shortly.
Update 20/2/2010 - New version of the code uploaded, implementing 4 new modes that work on any octave: falling notes, rising notes, high speed vibrato and low speed vibrato.
Allura uses a 32mm square 8x8 red LED matrix for optical input and visual feedback. A 5mm red LED acts as a high-precision (compared to fingers anyway) stylus pointer, the light from which is detected by the lower 5 rows of the matrix. The top 3 rows are purely for displaying the status of the device.
Allura makes use of the reverse leakage effect of LEDs to detect where the stylus is pointing, and uses this to determine which note to play. It can play a full octave of 'proper' notes, and by pressing the mode button the octave can be changed from the 5th octave down to the 4th, 3rd or 2nd sequentially. The lever switch on the top-left of the device simply enables the piezo speaker when pressed, allowing the user to slide from note to note, or play them discretely.
The large black box at the back contains 3 1.5V AA cells, with a power switch on the back. Running at no more than 20mA, the estimated continuous running time of Allura is 135 hours on a new battery set.
Unlike many of my projects, Allura only took 1 day to design and build, but much longer to program. I probably would've saved myself a bit of time if I'd checked Wikipedia for info on musical notes before trying to write the code to make it sound good, but we all make mistakes =)
Speaking of mistakes, I managed to 'brick' the first PIC16LF628A I used for Allura. I managed to set a cursed combination of config bits while trying to implement a more accurate timing system. Good thing these guys are so cheap.
This little project is finished for now, but in the future I may upgrade the speaker to something a bit louder (the video is only slightly more quiet than the real thing), and improve the code to allow for more interesting mode options that change the actual sound produced. I've only used 3 out of 255 reserved mode options, so there's plenty of space to program in other 'instruments' if I'm not lazy.
Oh yes, and for those wondering about the name: 'Allura Red' is a synthetic red dye, so it seemed the perfect name for a red light-based synthesiser. Kinda lame, but it rolls off the tongue more easily than 'disodium 6-hydroxy-5-((2-methoxy-5-methyl-4-sulfophenyl)azo)-2-naphthalene-sulfonate'.
https://vimeo.com/9611309