Landline phone as input interface to Arduino

Hi, my friend wants to make an art project in public space. Basically he wants to have a telephone, which can play different songs after dialing different numbers, and to place it in old phonebox.
I have two possible solutions for this idea in my head:

  1. Placing an arduino to phone, directly interfacing phone's number buttons and speaker. The problem is that there's high possibility that somebody will damage or steal the device.
  2. My second plan is to place arduino to safe box and to interface whole phone. Nice thing about this is that old phones are pretty cheap and we could buy one new every day. So it's pretty vandal-proof.

My question is, is there a possibility to transform arduino into a fake "phone central" which can read called numbers from phone and to play sounds back? (over landline standards, without adding something into phone?)

I was looking for answer for 2 days but I can't find anything.
Thank you!

Need to add DTMF decoder to interpret tone sounds (beeps & boops) from the phone.

(over landline standards, without adding something into phone?)

The old style land line phones are powered by the line, which carries about 48 volts DC when "on hook", but the voltage drops to 3-9 VDC, while supplying up to about 70 mA when the phone is taken "off hook".

To produce audio, you would need an amplifier capable of providing a few volts and a proper impedance matching circuit that would superimpose the audio on the DC line voltage.

There is plenty of info on the web, for example HOW TELEPHONES WORK but I do not think this would be an easy project, even for someone pretty good at analog electronics design.

You should probably start with one of these then add an MP3 Player shield. These guys are great for parts and also do a really great cheap custom PC board if you are not in a hurry. :slight_smile:

The interface to the phone line should be pretty simple. I would start with something like the following circuit to interface all the parts. The 470 and 100uf and isolation transformer are probably optional, but the 1k might be nice to limit the volume. I think the off hook dial tone is typically 400hz. You could inject this tone when you detected a voltage change on the analog in due to the phone going off hook. Listen for a dial tone sequence with the MT8870 and then turn the tone off and play the song indicated by the tone sequence.

Good Luck...

FYI...

I used the SimpleSDAudio code with some mono converted wav files via their tools, replace the 8 ohm resistor with a 150 ohm and removed the other components from the circuit. The music played very nicely through a standard wall phone with just that 150 ohm resistor.

If you are interested in just playing 8bit mono wav files to save space on your SD card you might want to seriously consider this option. That quality is plenty for phone level fidelity.

http://www.hackerspace-ffm.de/wiki/index.php?title=SimpleSDAudio