Friday, 19 December 2014

audio - Mobile phone TRS output to microcontroller digital input?


How should a mobile phone headphone audio output (such as the headset jack on top or bottom of an iPhone) be interfaced to a microcontroller digital input? (3.3V controller. Assume no audio frequency capable A/D is available.)


Assume a modulation scheme such as FSK or similar at appropriate frequencies.



Answer



If you make sure to put out a single clean frequency at a time, then a zero crossing detector is all you need. Audio can always be AC coupled, so a comparator or opamp acting as a comparator is all you need. One input gets filtered 1/2 supply voltage. The other gets that as DC bias but also gets the AC coupled audio. This will make a square wave at the audio frequency. A micro can measure this frequency and interpret its meaning in the context of a higher level protocol.


Note that this won't work for multiple frequencies sent at the same time, like DTMF for example.


No comments:

Post a Comment

arduino - Can I use TI's cc2541 BLE as micro controller to perform operations/ processing instead of ATmega328P AU to save cost?

I am using arduino pro mini (which contains Atmega328p AU ) along with cc2541(HM-10) to process and transfer data over BLE to smartphone. I...