Adafruit is open and shipping! Let's build back better, together!
0

Fona 3G audio problems
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Re: Fona 3G audio problems

by adafruit_support_rick on Wed Jul 20, 2016 12:00 pm

Audio noise is a difficult thing. Try twisting your speaker leads. Twist pairs of logic and power as well.

adafruit_support_rick
 
Posts: 35095
Joined: Tue Mar 15, 2011 11:42 am
Location: Buffalo, NY

Re: Fona 3G audio problems

by jules999999 on Mon Jul 25, 2016 5:05 am

Hi
I've now put a put a microphone and speaker in an old handset body and connected it to the FONA with four feet of unscreened, 1950s plaited cable and the whole thing works perfectly with no interference (I'm putting the FONA in an old rotary dial phone). All I can think is that my previous wiring was at fault although I had already rewired it completely and checked it as carefully as I could.
Anyway, thanks for your offer of a replacement FONA. It looks like I shan't be needing it!
Thanks again for you support.

jules999999
 
Posts: 58
Joined: Sun Mar 13, 2016 6:13 am

Re: Fona 3G audio problems

by adafruit_support_rick on Mon Jul 25, 2016 7:59 am

Glad to hear it's working for you!

Did you do the rotary dialing as well?

Pictures?

adafruit_support_rick
 
Posts: 35095
Joined: Tue Mar 15, 2011 11:42 am
Location: Buffalo, NY

Re: Fona 3G audio problems

by jules999999 on Wed Jul 27, 2016 5:51 pm

fona10.jpg
Starting the final version with FONA, Mega, Music Maker etc. Getting all this to work together will be tougher!
fona10.jpg (593.62 KiB) Viewed 594 times
fona9.jpg
The test arrangement with the FONA and Arduino etc.
fona9.jpg (414.27 KiB) Viewed 594 times
fona8.jpg
Connections to the dialler, the cradle switch and the call switch.
fona8.jpg (565.64 KiB) Viewed 594 times

Hi
Yes, I've managed to get the dialler working with the FONA. The dialler basically consists of a pulse switch and a switch to indicate the end of a pulse train. Also there is a switch which opens when the handset is off the cradle. With these as Arduino inputs, it is relatively straightforward to count the pulses and add them to an array. I had to add a button to call the number when the dialling was completed. When this is pressed, the stored number is fed into the FONA library call routine. Pressing the cradle switch disconnects the call.
At this stage I have found that the speaker is much too loud to be held to the ear (even at volume'1') so I need a series resistor. Conversely, the microphone does not seem sensitive enough so I have ordered an Adafruit amplified microphone. I am assuming that I will just connect the microphone '+' on the FONA to the output of the amplifier via a capacitor (which way round, polarity-wise, needs to be determined) and use the ground as a common connection, leaving the microphone '–' pin unconnected.
I am now on the next stage using an Arduino Mega with an Adafruit Music Maker. I have been trying to avoid devices such as LCD screens or LEDs to retain the vintage feel of the phone. Instead, I am hoping to use audio cues to indicate the status of the system, for example, a dialling tone to indicate whether the FONA is connected to a network when the handset is picked up off the cradle. The SD card can store pre-set numbers and audio cues. At the very least, I should be able to incorporate a dial operated MP3 player!
I am documenting this project at http://www.mr-r.co.uk/oldphone1.html if anyone is interested.

jules999999
 
Posts: 58
Joined: Sun Mar 13, 2016 6:13 am

Re: Fona 3G audio problems

by adafruit2 on Thu Jul 28, 2016 3:49 pm

for the microphone you need just a plain electret mic - like https://www.adafruit.com/products/1064 or similar - the 3G circuitry probably can't work with amplified mics (we haven't tried it but its probably not going to work)

adafruit2
Site Admin
 
Posts: 19494
Joined: Fri Mar 11, 2005 7:36 pm

Re: Fona 3G audio problems

by jules999999 on Mon Aug 01, 2016 9:55 am

Hi
The amplified mic did work but was apparently no louder than the unamplified mic. Then I had a d'oh moment when I realised there is an AT command available to increase the gain of the on-board mic amp. The default seems to be 0dB but this can be increased to 24dB which has solved my volume problem!
There are other audio parameters, TX and RX gain. It would be interesting to know what they do.

jules999999
 
Posts: 58
Joined: Sun Mar 13, 2016 6:13 am

Re: Fona 3G audio problems

by adafruit_support_rick on Mon Aug 01, 2016 3:20 pm

jules999999 wrote:There are other audio parameters, TX and RX gain. It would be interesting to know what they do.

Don't have any solid information on that. The datasheet says to look at the Hardware Design document. Hardware Design says look at the Audio App Note. the Audio App note says to look at the Hardware Design Document.

adafruit_support_rick
 
Posts: 35095
Joined: Tue Mar 15, 2011 11:42 am
Location: Buffalo, NY

Re: Fona 3G audio problems

by jules999999 on Sun Sep 18, 2016 4:30 pm

trace1.jpg
This is the signal which seems to be present in the audio circuit when attempting to make a call.
trace1.jpg (343.06 KiB) Viewed 490 times
I hate to admit defeat but I seem to have hit a brick wall with my Fona 3G project. I felt I was getting the upper hand with combating noise pick up but for no apparent reason the problem seems to have got worse! It's almost as if some parameter on the Fona has been changed. However, I have reset the Fona to factory defaults (apart from the baud rate and the audio pathway) so that can't be it. There are a lot of parameters and, I suppose, some might improve matters if only one knew what they were for!

I have tried two different Fona modules in my rotary dial project (which involves an Arduino Mega and the Adafruit Musicmaker). Everything more or less works as it should (the dialling, the stored numbers and the audio cues etc.) other than the noise on the audio. This appears to have a wide range of frequencies and I assume it results from radio-frequency pick up. A headset plugged into the Fona jack socket gives a usable performance but there is still noise (much much more than you would hear in a standard cell phone).

I have tried various filters, involving capacitors and inductors, to no avail. I've also gone back to the original Fona and Arduino Uno combination, working with the Adafruit test software but the noise is still there. In this case the connections to the microphone and speaker are about half an inch so I can't see how they could be any shorter.

Any suggestions as to how I can make progress with this project would be very gratefully received!

jules999999
 
Posts: 58
Joined: Sun Mar 13, 2016 6:13 am

Re: Fona 3G audio problems

by adafruit_support_rick on Mon Sep 19, 2016 8:17 am

It's probably a grounding problem. Did you change the wiring at all before the problem got worse? Maybe drop or bump something that would shake loose a cold solder joint? You may want to try bringing each individual ground wire out to a single bolt on the chassis.

adafruit_support_rick
 
Posts: 35095
Joined: Tue Mar 15, 2011 11:42 am
Location: Buffalo, NY

Re: Fona 3G audio problems

by jules999999 on Tue Sep 20, 2016 8:59 am

Hi

Thanks for your response. I have tested two different Fona 3G modules each in two completely different configurations. The basic Uno/Fona test configuration is very simple. Essentially there is one ground connection shared between the Fona and the Uno. (plus the Key pin is connected to ground). The connections to the speaker and microphone are differential (see section 3.42 in SIM5320_Hardware+Design_V1.07.pdf ).

The second configuration involves an Arduino Mega and no wiring or component is shared between this and the Uno test configuration (other than the two Fonas which I have swapped around).

I am familiar with the need to avoid earth loops and, although I have forgotten most of the theory I learned at college many years ago, I am pretty good at soldering and spotting dry joints (although I say so myself!) Having said that, I know that the most likely explanation is that I have done something stupid. It's just that I seem to have done the same stupid thing twice and after over a month of trying to spot what it is, I have failed miserably!

jules999999
 
Posts: 58
Joined: Sun Mar 13, 2016 6:13 am

Re: Fona 3G audio problems

by adafruit_support_rick on Tue Sep 20, 2016 11:43 am

Hmm... I'm sure you've tried this, but does the noise change if you touch/move the antenna?

adafruit_support_rick
 
Posts: 35095
Joined: Tue Mar 15, 2011 11:42 am
Location: Buffalo, NY

Re: Fona 3G audio problems

by jules999999 on Tue Sep 20, 2016 3:01 pm

Yes. If the speaker and microphone are on longer wires, it's possible to get them into a position where the noise cancels out pretty much. (Which is probably why I thought I was getting on top of the situation!) Also by positioning my body, touching any part of the kit, the pick up varies. By the way, I have used both the sticker and the quad band antennae. Sounds like you may have an idea of what I'm doing wrong? (I hope!)
Thanks for your continuing help.

jules999999
 
Posts: 58
Joined: Sun Mar 13, 2016 6:13 am

Re: Fona 3G audio problems

by jules999999 on Tue Sep 20, 2016 5:51 pm

Just a thought and I know very little about class D amplifiers but is the Bitscope trace I posted related to the high frequency switching in the amplifier? It looks about the right frequency. I had thought this might be related to the noise but perhaps not. I have recorded the audio component of the noise and, by eye, there seems to be a component at about 2800Hz which is amplitude modulated by a component at about 300Hz.
There are many parameters related to the audio path (see section 3.4.3 in the Hardware+Design pdf and section 11 in the AT command set pdf.) I wonder if any adjustment would help. However, it would take a long time to experiment with all of these!

jules999999
 
Posts: 58
Joined: Sun Mar 13, 2016 6:13 am

Re: Fona 3G audio problems

by adafruit_support_rick on Wed Sep 21, 2016 9:10 am

I couldn't tell from the picture what the horizontal divisions were. I was thinking that the fundamental was running at 125kHz. That might make sense for the amp.
Do you have your audio leads in twisted pairs? That might also help.

adafruit_support_rick
 
Posts: 35095
Joined: Tue Mar 15, 2011 11:42 am
Location: Buffalo, NY

Re: Fona 3G audio problems

by adafruit2 on Wed Sep 21, 2016 2:26 pm

not sure what it is but the RF noise from the antenna is going to be *intense* and you may need to make sure that the antenna is far from your audio. doing things like split power supplies, ferrite beads, capacitors, can help.

adafruit2
Site Admin
 
Posts: 19494
Joined: Fri Mar 11, 2005 7:36 pm

Please be positive and constructive with your questions and comments.