Adafruit Industries, Essential service and business: NYC – Executive Order 202.6 - Read more.
0

Connect external microphone and speaker using 3 wires - Adaf
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Connect external microphone and speaker using 3 wires - Adaf

by FredrikLofgren on Sat Feb 22, 2020 5:13 am

I have an Adafruit Feather 32u4 FONA. I have mounted the Fona into an old phone (Ericsson Dialog – rotary dial phone https://sv.wikipedia.org/wiki/Dialog_(telefon)).

I have replaced the original microphone and speaker. My problem is that there are only 3 wires going to the handset (I want to preserve the original handset cable). Is there a way to connect external microphone and speaker using only 3 wires?

FredrikLofgren
 
Posts: 2
Joined: Sat Feb 22, 2020 4:57 am

Re: Connect external microphone and speaker using 3 wires -

by adafruit_support_mike on Wed Feb 26, 2020 6:16 am

Hmm.. that would be tricky.

The standard way to carry two signals on three wires is to make one wire GND, and use the remaining wires for an unbalanced version of each signal (one signal measured relative to GND, rather than two opposing signals centered around 0V). It's fairly simple to do that from the handset to the body of the phone: use a microphone amplifier that produces unbalanced output, and use a speaker amplifier that can accept unbalanced input.

The PAM8302 can easily drive the speaker, can accept unbalanced input, and is small enough to fit in a handset:

https://www.adafruit.com/product/2130

The MAX4466 microphone amplifier puts out an unbalanced signal:

https://www.adafruit.com/product/1063

and it's useful to send the signal through the wire at a relatively high voltage (compared to the +/-5mV that comes directly out of a mic). It reduces the effects of noise.

The tricky part will be to convert the unbalanced signal from the MAX4466 back into something that will work for the FONA.

The SIM800's mic input is designed to work with an electret microphone. An electret is basically a JFET controlled by sound, and behaves like a 2k resistor whose value changes +/-20 Ohms or so. That's enough to produce a +/-5mV signal when you put the electret in series with a normal 2k resistor.

To mimic that, you'd need a floating transconductance amplifier.

I think this circuit will work:

mic-input.jpg
mic-input.jpg (46.04 KiB) Viewed 26 times


The BJT takes the place of the JFET inside an electret mic. The 1k resistor below the BJT (call it the output 1k) make it possible to measure the current through the BJT and/or its effective resistance.

The lower op amp buffers the voltage at the bottom of the output 1k without drawing current from the path between MIC+ and MIC-.

The upper op amp controls the BJT to keep the voltage across the output 1k the same as the voltage across the other 1k resistor (call that one the input 1k).

Input voltage Vref and resistor Rb set the DC voltage across both 1k resistors. Adjust Vref so the voltage across the output 1k is half the voltage between MIC+ and MIC- when the circuit is connected to the FONA. That will set the BJT's resistance to 1k, and the resistance between MIC+ and MIC- to 2k.. about the same as the JFET in an electret.

The capacitor between Vmic (the signal from the MAX4466) and resistor Ra gets rid of any DC voltage from the unbalanced signal. Only the AC part of the signal from the MAX4466 will reach the op amp. That AC component will pass through resistor Ra, changing the voltage across the input 1k. Then the op amp will adjust the BJT to make the voltage across the output 1k change by the same amount.

Start with a value for Ra around 47k, then adjust the MAX4466's gain so the voltage across the 1k resistors only changes by about +/-2mV. That should make the path from MIC+ to MIC- look pretty much like an electret. From there you can fine-tune the value of Ra and the MAX4466's gain to get the mic volume you want.

adafruit_support_mike
 
Posts: 60992
Joined: Thu Feb 11, 2010 2:51 pm

Re: Connect external microphone and speaker using 3 wires -

by FredrikLofgren on Wed Feb 26, 2020 12:00 pm

Thanks for the answer :-)

FredrikLofgren
 
Posts: 2
Joined: Sat Feb 22, 2020 4:57 am

Please be positive and constructive with your questions and comments.