Attend XDA's Second Annual Developer Conference, XDA:DevCon 2014!
5,806,279 Members 52,128 Now Online
XDA Developers Android and Mobile Development Forum

[Q] Add APNs (access point names) to android system database

Tip us?
 
Nick Hill
Old
#1  
Junior Member - OP
Thanks Meter 7
Posts: 17
Join Date: Dec 2013
Default [Q] Add APNs (access point names) to android system database

I have made a custom ROM based on 4.1.2, but Android misses many APNs, including my network operator. I would like to add it.

Where does Android store APNs?

Is there an updated database with almost every provider that I could integrate into the system?
 
shashivydyula
Old
#2  
shashivydyula's Avatar
Senior Member
Thanks Meter 29
Posts: 171
Join Date: Feb 2013
Location: Hyderabad

 
DONATE TO ME
Quote:
Originally Posted by Nick Hill View Post
I have made a custom ROM based on 4.1.2, but Android misses many APNs, including my network operator. I would like to add it.

Where does Android store APNs?

Is there an updated database with almost every provider that I could integrate into the system?
What is your carrier?

Please elaborate. Actually Android automatically gets all your network settings by default. Give a try by sending SMS to your network operator for network settings.
 
Nick Hill
Old
(Last edited by Nick Hill; 16th January 2014 at 06:06 PM.) Reason: mos spilling
#3  
Junior Member - OP
Thanks Meter 7
Posts: 17
Join Date: Dec 2013
Quote:
Originally Posted by shashivydyula View Post
What is your carrier?

Please elaborate. Actually Android automatically gets all your network settings by default. Give a try by sending SMS to your network operator for network settings.

If I factory reset the phone, I can put a Three or Vodafone SIM card in, the APN will set automatically. If I put a TalkMobile (TalkTalk) SIM in, the APN does not set automatically. There is no apparent SMS information reaching the phone.

I wonder where that APN information is coming from. I presume Android has the APN information in a database somewhere.
 
Nick Hill
Old
#4  
Junior Member - OP
Thanks Meter 7
Posts: 17
Join Date: Dec 2013
Quote:
Originally Posted by Nick Hill View Post
If I factory reset the phone, I can put a Three or Vodafone SIM card in, the APN will set automatically. If I put a TalkMobile (TalkTalk) SIM in, the APN does not set automatically. There is no apparent SMS information reaching the phone.

I wonder where that APN information is coming from. I presume Android has the APN information in a database somewhere.
I have found a source of information for APNs.

See the Android source code here:
https://code.google.com/p/android-so...droid-4.2.2_r1

Now I need to discover where this information is stored, and find a way of changing it!
 
Nick Hill
Old
#5  
Junior Member - OP
Thanks Meter 7
Posts: 17
Join Date: Dec 2013
Default [solved] Add APNs (access point names) to android system database

Quote:
Originally Posted by Nick Hill View Post
I have found a source of information for APNs.

See the Android source code here:
https://code.google.com/p/android-so...droid-4.2.2_r1

Now I need to discover where this information is stored, and find a way of changing it!
The access points database for Android 4.1 is in

/system/etc/apns-conf.xml

Talktalk / talk mobile provide information for APN here:
http://help2.talktalk.co.uk/settings...hone-settings#
However, the information they provide is false. Username and password must be unset.

I added the following before </apns> at the end

<apn carrier="TalkTalk"
mcc="234"
mnc="15"
apn="mobile.talktalk.co.uk"
mmsc="http://mms.talktalk.co.uk/servlets/mms"
mmsproxy="212.183.137.12"
mmsport="8799"
type="default,supl,mms"
/>

The phone will now give an option for TalkTalk APN, which I just need to select.

Now it is a matter of committing this entry to the official android repository. Of course, whilst I was at it, I replaced the whole apn database with the one from the Android repo.
Tags
access point name database, apn
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes