[CART360] Arduino Hardware timer + Multichannel synthesis code

joN jonnygexter at gmail.com
Sat Nov 28 19:54:25 EST 2009


Hi.

I remember a few people mentioning sound in their projects... if someone is
interested, I rewrote the code our group used for design brief 2 to be more
user-friendly. You can use it to output multiple frequencies to different
channels at the same time, with one bit of resolution (square wave). The
output is not perfect, but it is a very simple way of synthesizing
multi-channel output with the Arduino. It's posted here: _arduino polyphony
code <http://wilansky.com/jon/cart360/other/ArduinoPolyphony.zip>

Also, I am researching implementing a version that uses the low level
hardware timers on the Arduino. I'm told it would improve the accuracy of
the output (though I don't understand why). I'm having trouble and seeking
help.

This seems like the simplest example:
http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1208192843
but I need some help on identifying those weird variables/functions and
calculating the real time value from timer ticks. Anyone know of good
examples or explanations? I looked in the Atmel datasheet, but I find it
hard to understand.

And Vincent went over this last week:
http://www.arduino.cc/playground/Main/MsTimer2
- Is this just an abstraction/higher-level way to use the hardware timers (
Timer2)? Will it work for audio synthesis?

Jonathan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://uttermatter.com/pipermail/cart360_uttermatter.com/attachments/20091128/c9dbce2b/attachment.html>


More information about the CART360 mailing list