I’ve finished all the wiring. It looks a mess but I’m confident that it will work. Of course it won’t do anything until I write the software. There are four circuit boards here:
- The PIC Board – Contains a PIC 8-bit computer. Handles user input, LED display and generates all the timing (you can’t see the PIC in this photo because it’s on the other side of the board).
- The AMP Board – 0.5W amplifier to drive the speaker.
- The DAC Board – Converts digital data from the ARM into analogue sound waves.
- The ARM Board – Contains a powerful 32-bit ARM computer which is kind of wasted because all it does is shovel audio data into the DAC.
I recorded my audio samples using Audacity and downsampled them all to 8kHz so they will fit in the ARM’s memory. I only had a 64k ARM in my parts box, both the program and the audio samples need to fit into that space. I won’t have time to write an MP3 decoder or anything so it’s going to be 8-bit uncompressed PCM samples. I didn’t need to worry though because I’m only recording the numbers 1, 2, 3, 4 and as it turned out, they all fitted into 4k.
Writing the software had it’s ups and downs. About 80% of the code was recycled from other projects, stuff to boot up the ARM, timer interrupt handlers, RS232 drivers and that sort of thing. The only bit I had to write from scratch was the DAC driver and audio replay code which ran to only about 150 lines of code but for some reason took hours to get working. I had to make a few modifications to the PIC code also to send RS232 commands to the ARM, this was written in assembler which I generally avoid like the plague these days as it always takes longer to get things done in assembler. Anyway it is done and after whacking a couple of bugs, it works reasonably well.
Now to shove it all into a box. The software took most of today and it’s getting late, I’ll leave the box mounting for tomorrow.