Site icon Circuit Ideas for You

Arduino Text to Speech Voice Generator Circuit

This project make Arduino speak text, as it convert text into speech; in this article we used Arduino UNO board, LM386 audio amplifier, speaker and some components.

Arduino send digital voice data and IC LM386 make sound loud and also Arduino Text to Speech Voice Generator Circuit is small and low cost project.

Arduino Code:

#include <TTS.h>      // include Text To Speech library

TTS tts(3);            // create TTS object on digital pin 3

void setup() {
  tts.begin();         // start TTS engine
}

void loop() {
  tts.say("Alert! Alert! A big thunder storm is on the way."); 
  delay(10000);         // wait 10 seconds before speaking again
}

Coding Explanation:

Circuit Working:

Arduino Text to Speech Voice Generator Circuit Diagram

Parts List:

ComponentsQuantity
Resistors
Resistor 10 ohms 1/4 watt1
10k Potentiometer1
Capacitors
Electrolytic 10uF3
Electrolytic 1000uF1
Ceramic 0.047uF1
Semiconductors
Arduino UNO Board1
LM386 IC1
Speaker 8 ohm1
12 Power supply1

Arduino digital pin 3 produce PWM audio signal when library speaks and this PWM signal go out from pin 3 to potentiometer input.

Then potentiometer wiper send level-adjusted signal through a coupling capacitor 10uF to amplifier input and then coupling capacitor block DC and pass only audio variations.

Now LM386 amplify the small audio signal and then amplified output drive the 8 ohm speaker.

Also, connect the Arduino GND and LM386 GND together, and power the LM386 from a 12V battery or a 12V power supply.

A USB connection or a 5V regulator powers the Arduino.

Note: If require any help go through the same circuit for Simple LM386 Audio Amplifier Circuit

Formula with Calculations:

Gain of LM386 = 20 by default

If 10uF capacitor connect between pin1 and pin8 gain become 200

Power output P = V^2 / R

If LM386 give 1V RMS and speaker is 8 ohm

P = 1*1/8 = 0.125W

Hence, this is enough for small speaker.

How to Build:

To build a Arduino Text to Speech Voice Generator Circuit follow the below steps for connections:

How to Upload Code to Arduino:

Conclusion:

Overall, this project for Arduino Text to Speech Voice Generator Circuit can speak words using Arduino, it is simple and good for beginner.

We can also change text in code to speak different words and we can use this circuit for toys, talking notice board, voice alerts, etc.

Exit mobile version