Arduino speaks without special hardware

We see many Arduino projects that have audio output, but they tend to require a substantial amount of additional hardware. Audio files take up a lot of storage space and hence require something like an SD card adapter. Audio signals are analog, so they require a DAC (digital-to-analog converter) to get good quality. And then, to make the audio signal strong enough for a loudspeaker, the loudspeaker usually needs amplifiers. But Scott W Harden found a way to make an Arduino UNO Rev3 speak without any additional hardware beyond the speaker.

In this case, the Arduino can speak any number from zero to nine out loud through the speaker. This is possible because they are very short words (most of a single syllable) that are recognizable when the quality is very low. This audio quality would not be suitable for music or even general language, but it is sufficient for a number sequence. By reducing the audio quality as much as possible and making the clips short, Harden was able to create audio files small enough to fit in the 32 KB flash memory of the UNO's ATmega328 microcontroller with free space for the sketch.

Harden started with normal MP3 recordings of spoken numbers. It then performed a 100 Hz to 2.5 kHz tape pass on the clips, resampled them to 5 kHz, then converted the waveforms to unsigned eight-bit values ​​for storage in program memory. . The Arduino can then read these waveforms through PWM (pulse width modulation). A low-pass filter, consisting of a capacitor and a resistor, helps smooth the PWM output to make it more like a true analog waveform. An optional LM386 chip can amplify the output, but Harden found he was able to drive a speaker directly without it.

Arduino speaks without special hardware

We see many Arduino projects that have audio output, but they tend to require a substantial amount of additional hardware. Audio files take up a lot of storage space and hence require something like an SD card adapter. Audio signals are analog, so they require a DAC (digital-to-analog converter) to get good quality. And then, to make the audio signal strong enough for a loudspeaker, the loudspeaker usually needs amplifiers. But Scott W Harden found a way to make an Arduino UNO Rev3 speak without any additional hardware beyond the speaker.

In this case, the Arduino can speak any number from zero to nine out loud through the speaker. This is possible because they are very short words (most of a single syllable) that are recognizable when the quality is very low. This audio quality would not be suitable for music or even general language, but it is sufficient for a number sequence. By reducing the audio quality as much as possible and making the clips short, Harden was able to create audio files small enough to fit in the 32 KB flash memory of the UNO's ATmega328 microcontroller with free space for the sketch.

Harden started with normal MP3 recordings of spoken numbers. It then performed a 100 Hz to 2.5 kHz tape pass on the clips, resampled them to 5 kHz, then converted the waveforms to unsigned eight-bit values ​​for storage in program memory. . The Arduino can then read these waveforms through PWM (pulse width modulation). A low-pass filter, consisting of a capacitor and a resistor, helps smooth the PWM output to make it more like a true analog waveform. An optional LM386 chip can amplify the output, but Harden found he was able to drive a speaker directly without it.

What's Your Reaction?

like

dislike

love

funny

angry

sad

wow