Electric Signals


by Rodneyshibu
Tags: electric, signals
Rodneyshibu
Rodneyshibu is offline
#1
Feb20-14, 03:26 AM
P: 6
Hello

Could I use a microprocessor (or anything else for that matter) to send a signal to a DAC that converts the signal to audio. For example, when I close a circuit the microchip sends a signal to the DAC to emit a certain sound.

Thanks in advance for any responses and please inform me if the question is unclear.
Phys.Org News Partner Engineering news on Phys.org
PsiKick's batteryless sensors poised for coming 'Internet of things'
Researcher launches successful tech start-up to help the blind
Researchers propose network-based evaluation tool to assess relief operations feasibility
berkeman
berkeman is offline
#2
Feb20-14, 11:01 AM
Mentor
berkeman's Avatar
P: 39,600
Quote Quote by Rodneyshibu View Post
Hello

Could I use a microprocessor (or anything else for that matter) to send a signal to a DAC that converts the signal to audio. For example, when I close a circuit the microchip sends a signal to the DAC to emit a certain sound.

Thanks in advance for any responses and please inform me if the question is unclear.
Welcome to the PF.

Sure. That is a very common thing to use a microcontroller (uC) for. Do you have a uC in mind? Do you have a uC Evaluation Board?
Rodneyshibu
Rodneyshibu is offline
#3
Feb20-14, 11:27 AM
P: 6
No I don't have any particular micro controller in mind but what I basically want to send an electric signal to an audio device allowing to emit a certain sound (eg. hello). I presumed that using a micro controller and a DAC is the only way to possibly achieve this but if you have anything else in mind that would be great.
Thank you

meBigGuy
meBigGuy is offline
#4
Feb20-14, 12:10 PM
P: 960

Electric Signals


Speech synthesis is common, and many IC's are available to tackle different aspects or appliactions.
Do a google search on "speech synthesis". Come back with questions. There are many answers based on exactly what you really want to do (quality, quantity, flexibility, difficulty, etc).
Rodneyshibu
Rodneyshibu is offline
#5
Feb21-14, 12:45 AM
P: 6
Thank you for your reply but I searched up speech synthesis but that is not exactly what I was looking for. Actually, I am just 14 years old so I am quite new to this stuff. What I want is that when I close a particular circuit (by a switch for example) it will send a signal to any audio DAC to emit a certain sound (eg. hello). What I do not know how to do is to send an electric signal which the audio DAC will understand and I presumed the best way to do this was to use a micro controller but I do not know how to use it.
Averagesupernova
Averagesupernova is offline
#6
Feb21-14, 10:52 AM
P: 2,450
I am glad to see you are taking an interest in this at your age. You have a lot to learn yet. You need to learn about binary, byte, bits, words, how they are stored, what a register is and etc. I am afraid you will get discouraged if you jump into this without doing some simpler things first. Other members on this board are probably better suited to guide you with getting started with programming and controllers. Are you familiar with arduino or basic stamp? I have never used them but I have an idea what they can do.
berkeman
berkeman is offline
#7
Feb21-14, 11:08 AM
Mentor
berkeman's Avatar
P: 39,600
Quote Quote by Rodneyshibu View Post
Thank you for your reply but I searched up speech synthesis but that is not exactly what I was looking for. Actually, I am just 14 years old so I am quite new to this stuff. What I want is that when I close a particular circuit (by a switch for example) it will send a signal to any audio DAC to emit a certain sound (eg. hello). What I do not know how to do is to send an electric signal which the audio DAC will understand and I presumed the best way to do this was to use a micro controller but I do not know how to use it.
Here is a basic intro to digital audio: http://en.wikipedia.org/wiki/Digital_audio

And the simplest format for digital audio files is *.WAV: http://en.wikipedia.org/wiki/WAV

Rodneyshibu
Rodneyshibu is offline
#8
Feb21-14, 11:22 AM
P: 6
Thank you all so much for your help

http://en.wikipedia.org/wiki/File:A-D-A_Flow.svg

What I want to do is to be able to send a signal to the DAC to emit a certain sound but I want the sound to vary. For example, when I send a particular signal is will emit "hello" and when I send another signal it will emit "goodbye". Is there a way to be able to send these varying signals using a processor. And how do I "inform" the processor what signals to send to the DAC
Averagesupernova
Averagesupernova is offline
#9
Feb21-14, 01:04 PM
P: 2,450
This is all part of learning some things I mentioned in my previous post. I get the feeling you know what a DAC is and that an audio signal going to a speaker is analog but I suspect you don't grasp what is all involved in getting it all to come together. I suppose that is a rather obvious statement right? LOL
berkeman
berkeman is offline
#10
Feb21-14, 01:36 PM
Mentor
berkeman's Avatar
P: 39,600
Quote Quote by Rodneyshibu View Post
Thank you all so much for your help

http://en.wikipedia.org/wiki/File:A-D-A_Flow.svg

What I want to do is to be able to send a signal to the DAC to emit a certain sound but I want the sound to vary. For example, when I send a particular signal is will emit "hello" and when I send another signal it will emit "goodbye". Is there a way to be able to send these varying signals using a processor. And how do I "inform" the processor what signals to send to the DAC
You can save various *.WAV files with the sounds/words you want to be able to play. Then when you type a word or number into the microcontroller's (uC's) console your program on the uC selects the *.WAV file in its memory and sends the bytes to the DAC at the correct pace (how many bytes per second). The DAC converts the digital information into the analog waveform that you send through an amplifier to your speakers.

I'll post a link later if I have time...
jim hardy
jim hardy is offline
#11
Feb21-14, 01:44 PM
Sci Advisor
jim hardy's Avatar
P: 3,138
The DAC is little more than an electronic guitar pick , it can make sound if something manipulates it and it has a speaker attached to move the air....

You'll need something, probably a small computer, to sense when the switch has closed and then send to the DAC a series of commands to make it produce the series of sounds that'll result in "Hello".

The vocabulary will reside in the small computer, or in the 'speech synthesizer'.

Electronics is a fun hobby. Google on "electronic hobbyist kits". Check out Ramsey...

Berkeman is way more advanced than i am on digital sound....
meBigGuy
meBigGuy is offline
#12
Feb21-14, 02:25 PM
P: 960
In order to cause a simple DAC to emit a sound, you need to send it a sequence of digital words at a sample rate (say 8000 14 bit words per second for telephone quality speech). Those digital words represent the voltage of the speech waveform at rapid instants in time (the sample rate).

This would be one method of speech synthesis. You need to store 8000 digital words per second of speech and sequence them to the DAC. There are other algorithms for storage and synthesis.

There are a variety of speech synthesis chips that have storage and deal with the sequencing.
FOr example https://www.rutronik.com/news+M574b67028a3.html

Google "Speech Playback IC"
Rodneyshibu
Rodneyshibu is offline
#13
Feb22-14, 10:01 AM
P: 6
@berkeman What exactly is the micro controller's console. Basically, where should I type the number?

@jim hardy How can I make the computer to recognise when the switch has closed and prompt it to send the signal to the DAC
berkeman
berkeman is offline
#14
Feb22-14, 10:13 AM
Mentor
berkeman's Avatar
P: 39,600
Quote Quote by Rodneyshibu View Post
@berkeman What exactly is the micro controller's console. Basically, where should I type the number?

@jim hardy How can I make the computer to recognise when the switch has closed and prompt it to send the signal to the DAC
Take a look at the typical uC evaluation boards, and each will have some way to connect with a keyboard and display (or Ethernet). You would use that human interface to interract with the uC, including writing programs to run on the uC (in C or Basic or Python or some other language), and you can use that interface to interact with your programs when they are running (to type commands, etc.).

Check out Microchip's website for PIC eval boards, and take a look at the Rapsberry Pi and Beagle Bone eval boards. Check out the Make Magazine website as well, as they talk about uC eval boards a lot.

Have fun!
Rodneyshibu
Rodneyshibu is offline
#15
Feb22-14, 10:45 AM
P: 6
@meBigGuy How exactly do we "tell" the chip what words to sequence to the DAC
analogdesign
analogdesign is offline
#16
Feb22-14, 12:50 PM
P: 368
Quote Quote by Rodneyshibu View Post
@meBigGuy How exactly do we "tell" the chip what words to sequence to the DAC
That is what software is for. You need to set up a channel where you can send arbitrary words to the DAC. To decide what words to send and in what order is a job for software.

Building this from the ground up is quite complex. You are better off leveraging existing systems and adapting them to your needs. Even then it's over your head for a beginner.

If electronics sound fun to you, I would strongly suggest going MUCH simpler to start. Instead of it saying "hello" or "goodbye" why don't you have two different tones that correspond to this (like the chime when you turn on a Mac)? For example low-pitch = Hello, high-pitch = goodbye.

The first step is to figure out how to drive a little piezoelectric speaker to make a tone when you push a switch. Baby steps, Rodney, baby steps.
meBigGuy
meBigGuy is offline
#17
Feb22-14, 05:14 PM
P: 960
My recommendation would be to buy an Arduino and a shield (IO board) for audio playback. But, root around on the net for a project that you feel comfortable with before buying anything. For example
http://www.instructables.com/id/Arduino-Audio-Output/ (but this one may be too advanced for a first project)


Register to reply

Related Discussions
Signals and Systems - Power and Energy level signals calculation Engineering, Comp Sci, & Technology Homework 1
RF Signals - Radio waves or electrical signals? Electrical Engineering 1
Signals Energy of 2 signals - Integral limits correct? Calculus & Beyond Homework 3
How Elctric signals are converted into Electormagnetic signals? Electrical Engineering 4
matching partial signals to whole signals Electrical Engineering 0