How can I edit a list of allowed Wifi channels for country in custom Android ROM? - Android Q&A, Help & Troubleshooting

I have a problem with Lineage OS unofficial ROM on Xperia Z3 Compact Tablet from this xda thread.
When mobile connection (using SIM card) is established, Android overwrites allowed Wifi channels settings with restrictions, based on countries. This is a well known feature, but for Russia it seems that any 5Ghz channel becomes restricted - even through channnels 34-165 are legally allowed in Russia (I can't see any networks, no matter what channel I use on my access point).
I want to find, where those restrictions are located, and fix them with appropriate values (I suppose there should be some kind of table with those values). I am sure that this is possible because 5Ghz works both on this device with official ROM and on xiaomi device with official and Lineage OS ROMs.
Unfortunately, ROM author is not interested in fixing this bug so I want to do it myself. I managed to get 5Ghz working using Magisk, Xposed Framework and module for fixing region - but that solution is damn unstable to I want to avoid it and make a normal fix.
By the way, setWifiCountryCodeFromMcc is met in this source and it calls "setCountryCode" from here. I just need to go a little bit deeper to find restricted channel options - but I don't know where and how.

Related

[Q] Help me

I've installed this rom but have trouble not connect to wifi though still full wave
http://forum.xda-developers.com/showthread.php?t=2012483
chulsoo said:
I've installed this rom but have trouble not connect to wifi though still full wave
http://forum.xda-developers.com/showthread.php?t=2012483
Click to expand...
Click to collapse
Hmm... CM10 by scritch007 worked for me on my XPERIA X10i when I tried it on an earlier version.
You'll still be using 802.11g, as 802.11n is not supported. Of interest I noted channels 12-13 are supported too, for countries that allows these channels. Maybe even 14 in Japan.
Did you attempt to connect to your AP in the initial connection wizard, before you had a chance to 'modify' your system and/or install additional software?
There is a Scritch007 CM10 forum post in the General section that may be able to assist you with known WiFi issues with a given version of CM10.

[Q] Is it necessary to flash ROW ROM over a Chinese one?

Starting this thread to answer a very simple question.
I find some answers scattered through responses in a lot of other threads, but all the information is too spread out to be useful, so I'm trying to get all that info in a single thread.
Most of us will get their P780 through a Chinese website. Most of them will have an English interface probably, but are still the Chinese models.
The main difference is explained elsewhere, so not going into that. Just wondering, I'm living in Europe, but temporarily in Australia.
I have an Australian SIM1, and my European SIM2. Works just fine. Full reception on SIM2 all the time, SIM1 is kind of unstable, going from full reception to almost nothing and back when on 3G. But apart from that, fast data transfer.
In most countries, 3G on 900Mhz is not that popular anyways.
So, is there any reason to flash an ROW rom to a Chinese phone ?
- 3G 900Mhz band not available on Chinese models : does the ROW change that ? Or can you change it by flashing a different modem image or can't you enable 3G 900Mhz at all on them?
- custom ROM support : but so far I haven't seen a ROM interesting enough to do this. Most of us will want the latest android version, which is only VIBE 1.5 on Chinese ones anyways at this moment. SLX and Life look ok, but I don't see much difference with the VIBE roms (UI wise).
- English interface : you can switch the Chinese models to English without too many issues (some text still in Chinese, but not too annoying)
Do Chinese and ROW models have the same hardware, or are there differences ?
On Russian forums, people try to flash ROW to open up the 3G 900Mhz band, but so far, I couldn't find conclusive information that this actually works.
Taking it even further, is there any reason to go for a ROW(usually more expensive) model instead of a Chinese model ?
And perhaps the most important question of all : can you actually flash a ROW ROM on a Chinese model ?
Most answers I find elsewhere say it should work. But my phone gets stuck and won't even start when I do so. Perhaps I'm doing something wrong, perhaps because it's just not possible.
Update : In recent other posts, users successfully flashed a ROW on a Chinese model, so I'm assuming that is possible.
I invite you all to provide some answers or feedback, because when I was looking into buying this phone, that was my most important question
casaben said:
Starting this thread to answer a very simple question.
I find some answers scattered through responses in a lot of other threads, but all the information is too spread out to be useful, so I'm trying to get all that info in a single thread.
Most of us will get their P780 through a Chinese website. Most of them will have an English interface probably, but are still the Chinese models.
The main difference is explained elsewhere, so not going into that. Just wondering, I'm living in Europe, but temporarily in Australia.
I have an Australian SIM1, and my European SIM2. Works just fine. Full reception on SIM2 all the time, SIM1 is kind of unstable, going from full reception to almost nothing and back when on 3G. But apart from that, fast data transfer.
In most countries, 3G on 900Mhz is not that popular anyways.
So, is there any reason to flash an ROW rom to a Chinese phone ?
- 3G 900Mhz band not available on Chinese models : does the ROW change that ? Or can you change it by flashing a different modem image or can't you enable 3G 900Mhz at all on them?
- custom ROM support : but so far I haven't seen a ROM interesting enough to do this. Most of us will want the latest android version, which is only VIBE 1.5 on Chinese ones anyways at this moment. SLX and Life look ok, but I don't see much difference with the VIBE roms (UI wise).
- English interface : you can switch the Chinese models to English without too many issues (some text still in Chinese, but not too annoying)
Do Chinese and ROW models have the same hardware, or are there differences ?
On Russian forums, people try to flash ROW to open up the 3G 900Mhz band, but so far, I couldn't find conclusive information that this actually works.
Taking it even further, is there any reason to go for a ROW(usually more expensive) model instead of a Chinese model ?
And perhaps the most important question of all : can you actually flash a ROW ROM on a Chinese model ?
Most answers I find elsewhere say it should work. But my phone gets stuck and won't even start when I do so. Perhaps I'm doing something wrong, perhaps because it's just not possible.
I invite you all to provide some answers or feedback, because when I was looking into buying this phone, that was my most important question
Click to expand...
Click to collapse
I have ROW Phone bough and i commandet P780 Chinese version witch is more cheap then my row bought in my country. Half a price. I will not pay shipment because someone i know will bring it from there. I barrely wait to compare and i will tell you all about it.
So some follow up on my testing:
Remember : I'm working on a P780 4Gb Chinese with production date 15/03/14
This means I have to use a different preloader file than the ones included in all roms (at this moment). I that is not done, the phone will not boot (see my other thread http://forum.xda-developers.com/lenovo-p780/help/p780-bricked-flashing-wrong-rom-doesnt-t2749683).
I succesfully installed following ROMS :
- P780_S135_130917_rooted_twrp_gapps : standard Chinese rom, works well, some chinese, but does the job
- VIBEUI_V1.5_1419_5_DEV_P780_rooted_twrp_gapps : KitKat rom, worked very nice but had a huge problem with battery drain. Location services would hang an eat up to 15%/hour. Tried many things, and in the end, I got it more or less stable, but no location services (Google Now, Maps, weather,...). Too many problems with battery performance, so uninstalled
- P780_ROW_S124_140403_rooted_twrp_gapps + SLXROM_v24a-Lenovo_P780 : this combo gave me the purest Android system so far. Good old Android menus and behavior, good battery life, good everything. However, I had a major problem : every reboot, I would get a problem with SIM1 or SIM2 that did not come up. No problem, I could flash a modem like V52 Modem_S920 and the problem would be gone when the phone started up again...only to return on a next reboot. I liked the rom a lot, but that was just not workable.
- P780_ROW_S124_140403_rooted_twrp_gapps : The ROW stock rom, and I must say, I'm liking it. Works well, good battery, and in all honesty I kind of like the Lenovo shell. Nice launcher, nice behavior. I installed XPosed and GravityBox to update some things I didn't like without problems. Oh and the biggest surprise of all : in my SIM1, I see that WCDMA-GSM-900, aka 3G 900Mhz, is enabled, but I'm in a 2100Mhz only area, so I don't know if this is just there but not actually working... Furthermore, I liked the Power and security app from the VIBE 1.5 ROM, so I opened the img file, and extracted the apks, and installed them on this ROM, and it actually works nice without issues.
So for now, the last rom (ROW), gives me a non-Chinese, nice rom that has the 900MHz band enabled (will try to test soon).
casaben said:
So some follow up on my testing:
Remember : I'm working on a P780 4Gb Chinese with production date 15/03/14
This means I have to use a different preloader file than the ones included in all roms (at this moment). I that is not done, the phone will not boot (see my other thread http://forum.xda-developers.com/lenovo-p780/help/p780-bricked-flashing-wrong-rom-doesnt-t2749683).
I succesfully installed following ROMS :
- P780_S135_130917_rooted_twrp_gapps : standard Chinese rom, works well, some chinese, but does the job
- VIBEUI_V1.5_1419_5_DEV_P780_rooted_twrp_gapps : KitKat rom, worked very nice but had a huge problem with battery drain. Location services would hang an eat up to 15%/hour. Tried many things, and in the end, I got it more or less stable, but no location services (Google Now, Maps, weather,...). Too many problems with battery performance, so uninstalled
- P780_ROW_S124_140403_rooted_twrp_gapps + SLXROM_v24a-Lenovo_P780 : this combo gave me the purest Android system so far. Good old Android menus and behavior, good battery life, good everything. However, I had a major problem : every reboot, I would get a problem with SIM1 or SIM2 that did not come up. No problem, I could flash a modem like V52 Modem_S920 and the problem would be gone when the phone started up again...only to return on a next reboot. I liked the rom a lot, but that was just not workable.
- P780_ROW_S124_140403_rooted_twrp_gapps : The ROW stock rom, and I must say, I'm liking it. Works well, good battery, and in all honesty I kind of like the Lenovo shell. Nice launcher, nice behavior. I installed XPosed and GravityBox to update some things I didn't like without problems. Oh and the biggest surprise of all : in my SIM1, I see that WCDMA-GSM-900, aka 3G 900Mhz, is enabled, but I'm in a 2100Mhz only area, so I don't know if this is just there but not actually working... Furthermore, I liked the Power and security app from the VIBE 1.5 ROM, so I opened the img file, and extracted the apks, and installed them on this ROM, and it actually works nice without issues.
So for now, the last rom (ROW), gives me a non-Chinese, nice rom that has the 900MHz band enabled (will try to test soon).
Click to expand...
Click to collapse
Thanks alot for sharing this information with us. Now: can you tell us what are the 2 app original names in system.img?
Found them in the priv-app folder,not app folder (somewhere in system.img,forgot where exactly ?): LenovoPower.apk and LenovoSafeCenter.apk
Lots of other interesting stuff in that folder I must say ?
The power app in vibe 1.5 shows me more accurate timings and has a useful interface to see processes that consume power,especially the keep awake,aka wakelocks, and I like the privacy settings on the security app.but this one seems to crash sometimes because of conflict with the security app of current rom,but still...
Sent from my Lenovo P780_ROW using XDA Free mobile app
casaben said:
Starting this thread to answer a very simple question.
I find some answers scattered through responses in a lot of other threads, but all the information is too spread out to be useful, so I'm trying to get all that info in a single thread.
Most of us will get their P780 through a Chinese website. Most of them will have an English interface probably, but are still the Chinese models.
The main difference is explained elsewhere, so not going into that. Just wondering, I'm living in Europe, but temporarily in Australia.
I have an Australian SIM1, and my European SIM2. Works just fine. Full reception on SIM2 all the time, SIM1 is kind of unstable, going from full reception to almost nothing and back when on 3G. But apart from that, fast data transfer.
In most countries, 3G on 900Mhz is not that popular anyways.
So, is there any reason to flash an ROW rom to a Chinese phone ?
- 3G 900Mhz band not available on Chinese models : does the ROW change that ? Or can you change it by flashing a different modem image or can't you enable 3G 900Mhz at all on them?
- custom ROM support : but so far I haven't seen a ROM interesting enough to do this. Most of us will want the latest android version, which is only VIBE 1.5 on Chinese ones anyways at this moment. SLX and Life look ok, but I don't see much difference with the VIBE roms (UI wise).
- English interface : you can switch the Chinese models to English without too many issues (some text still in Chinese, but not too annoying)
Do Chinese and ROW models have the same hardware, or are there differences ?
On Russian forums, people try to flash ROW to open up the 3G 900Mhz band, but so far, I couldn't find conclusive information that this actually works.
Taking it even further, is there any reason to go for a ROW(usually more expensive) model instead of a Chinese model ?
And perhaps the most important question of all : can you actually flash a ROW ROM on a Chinese model ?
Most answers I find elsewhere say it should work. But my phone gets stuck and won't even start when I do so. Perhaps I'm doing something wrong, perhaps because it's just not possible.
Update : In recent other posts, users successfully flashed a ROW on a Chinese model, so I'm assuming that is possible.
I invite you all to provide some answers or feedback, because when I was looking into buying this phone, that was my most important question
Click to expand...
Click to collapse
Hummm...
Please do backup via spflash tool, i found somewhere on xda, spflash tool can pull a backup file from your rom what you using now. So if something happens you wouldn't worry. You have exactly right rom that always running on your phone.
Do research, 1st of all try flash all file and if ended with bootloop, you can try flash again and avoid to flash BL, preloader, sometimes nvram file.
If you have the right backup file, mediatek is nearly unbrickable, even imei can be write permanently without open your mainboard.
Sent from my Lenovo P780
cupliz said:
Hummm...
Please do backup via spflash tool, i found somewhere on xda, spflash tool can pull a backup file from your rom what you using now. So if something happens you wouldn't worry. You have exactly right rom that always running on your phone.
Do research, 1st of all try flash all file and if ended with bootloop, you can try flash again and avoid to flash BL, preloader, sometimes nvram file.
If you have the right backup file, mediatek is nearly unbrickable, even imei can be write permanently without open your mainboard.
Sent from my Lenovo P780
Click to expand...
Click to collapse
Please post for us a link for SP Flash Tool with backup. Thank you.
Sent from my Lenovo P780
stympy said:
Please post for us a link for SP Flash Tool with backup. Thank you.
Sent from my Lenovo P780
Click to expand...
Click to collapse
Try this bro...
Ive successful on acer liquid e2, this tutorial is very usefully for mtk devices that doesn't have official supports for roms. Should works fine on p780, if fail i think this tuts will never Broke our devices bro..
http://maxed4901note2.blogspot.com/2013/09/installing-clockworkmod-cwm-recovery-on.html?m=1
Sent from my Lenovo P780
cupliz said:
Try this bro...
Ive successful on acer liquid e2, this tutorial is very usefully for mtk devices that doesn't have official supports for roms. Should works fine on p780, if fail i think this tuts will never Broke our devices bro..
http://maxed4901note2.blogspot.com/2013/09/installing-clockworkmod-cwm-recovery-on.html?m=1
Sent from my Lenovo P780
Click to expand...
Click to collapse
Great tutorial on the, well mainly SPFT, thanks!
Problem I had with CWM (and apparently you have to have the right version for Chinese or ROW), is that although it did boot into recovery, I'd get random errors about /system or /data or whatever else could not mount. It would give errors when trying to take a backup, and it just didn't feel reliable.
TWRP on the other hand, works great, no issues (although it says that it needs to fix root permission whenever I exit it, but no problems).
After my experience with a wrong flash, I do believe the MT devices are almost unbrickable, as long as you have the right combination of files to flash onto it.
After trying like 7 ROMS, I decided to stick with the ROW stock on my Chinese model. Great battery, stable, the storage division is a bit small, I'm running out of internal storage although I have plenty left in built-in storage, but my apps don't want to install there, neither can I move them.
Most important indeed is : BACKUP first
Update on my current P780_ROW_S124_140403_rooted_twrp_gapps ROM :
Although it shows 900Mhz band active, the 3G connection was pretty unstable. It works well for 1 second, then goes to nothing, then back to working well.
So I decided to flash the V52 Modem_S920.
Downside : no 900Mhz (but is it still used in a lot of countries ?)
Upside : 3G connection a lot better and stable. Browsing the internet is fast.
Where I would see a download speed of 25Kb/s to 500b/s to 200b/s it now stays well above 10Kb/s, with speeds well above that most of the time(up to 250Kb/s)
Current test done in Jakarta (with local SIM). Will test again in other countries.

[Q] modem not working in CM 12.1 nightly

good day to all,
I've got sony xperia z3 tablet compact; LTE version, SGP621 (scorpion). I've managed to unlock bootloader, install twrp, install cm-12.1-20150704-NIGHTLY-scorpion.zip, with gapps and superSU root.
What I realized after some time - when I was out of reach of my wifi - that cellular network (broadband) is not working. More specifically, there are no entries in main settings menu for "mobile network" and also in "about" section, there is nothing about network or broadband. Could you advise me how to get it working?
I thought I mistook my device for "scorpion_windy" one, and installed cm same version for scorpion windy, but with no luck obviously,
SGP621 should be indeed pure "scorpion"
cyanogenmod's support for this device is for me a little bit misty, I'm not sure if it is official or unofficial, what is supported and what not. Most importantly, how can I get the modem working with it.
Beside missing modem, I see no issues with CM 12.1 nightly on this device so far.
skroslak said:
- that cellular network (broadband) is not working.
Click to expand...
Click to collapse
modem is working in android 5.1 aosp from free xperia project,
I'm gonna try another build of cyanogenmod
btw, I also tried android M preview on this device, however I can't get it out of safe mode. Anyhow, I don't want to run "preview" on my daily device, just wanted to have a look.
Could you post an exact guide how you did this? I am looking for tutorials for weeks now and nothing specific there. A step by step guide would be great...

WI-FI Channels 12-14

Hey,
I try recently to change my ROM of my Honor 5X, but I have a big problem with the WI-FI. My phone can't find the channels higher than 11 and my WI-FI is in 13 channel :/ . I check different post in this forum, with different things to do, but nothing work. (I try to change the region in the build.prop, and i haven't any /data/data/com.android.providers.settings/databases/settings.db in my phone files :/ )If anyone has an idea to change the configuration of the WI-FI channels in android 7.1.1. (If you want, I'm using the Aospextended ROM but I t'y with a lot of more ROM and there is the same problem :/ )
Thank you for your future help
jules552 said:
Hey,
I try recently to change my ROM of my Honor 5X, but I have a big problem with the WI-FI. My phone can't find the channels higher than 11 and my WI-FI is in 13 channel :/ . I check different post in this forum, with different things to do, but nothing work. (I try to change the region in the build.prop, and i haven't any /data/data/com.android.providers.settings/databases/settings.db in my phone files :/ )If anyone has an idea to change the configuration of the WI-FI channels in android 7.1.1. (If you want, I'm using the Aospextended ROM but I t'y with a lot of more ROM and there is the same problem :/ )
Thank you for your future help
Click to expand...
Click to collapse
No one has an idea to fix that ? :crying:

WiFi Calling - Please add support in custom roms

As noted in the other thread WiFi Calling works using the WFC code in the US 16s build "X829_5.8.16s_rooted.zip" (tested with modem 24 and 50) but does not using India 19s or China 23s, both eventually giving Error81. Can someone try integrating the WFC android code from 16s into their custom rom to see if it works? It appears they somehow broke the code after 16s so that it doesn't even try to connect via the GAN/UMA protocol at least from what I could see via tcpdump.
This is not correct section to post! And i think you have already asked same question in Q&A section.

Categories

Resources