Páginas

Friday, September 2, 2016

Arduino simple speaker connection

I have been using a very small speaker salvage from old earphones, as you will expect the volume in those are very low.




I didn't have a buzzer or a bigger speaker, but some transistors and resistor, so I did this impossible simpler amplifier.



I still testing it, some people said that there will be to much DC through the speaker. I will try it for a few weeks and see what happen.

Probably for my next project I will try some a little better like this:






Wednesday, June 15, 2016

Music for All - Playing Melodies in Arduino

Some time ago Brett Hangman did a sample sketch to play melodies using de Arduino Tone Library.

The sketch plays RTTTL songs, this is convenient for micro processors, its simple string with all the information about the melody, tempo, duration and notes. So you don't have a mess with arrays and pointers and also there is thousands of RTTTL songs already made you can download for free, from tv show to popular pop songs.

To make this better we are going to use TimerFreeTone Library from Tim Eckel. This remove the need to use timer1 for tones. That way we can use servos and PWM control for Leds.