Guide to avoid registering a new GSF android_id at each clean install - Xiaomi Mi 6 Guides, News, & Discussion

As you may noticed since last week google wants us, the custom rom users to manually register our android_id to the link https://www.google.com/android/uncertified/
It looks simple isn't it?
But there's a catch. Each google account can register up to 100 ids. So if you keep registering new ids after every clean install you'll more likely to hit that 100 ids limit soon. That's even worse for fhe rom developers as they may flash up to 20-30 roms a day.
I'm figuring out that in a different way though. The procedure I'm following is:
A. BEFORE ANYTHING
If you're doing this first time:
1) Copy this database from /data/data/com.google.android.gsf/databases/gservices.db
2.1) Open the database with a sql editor or from adb shell or a terminal emulator in sqlite3, see android_id with this sql command:
SELECT *
FROM main
WHERE name="android_id";
2.2) OR from adb shell:
$ adb root
$ adb shell 'sqlite3 /data/data/com.google.android.gsf/databases/gservices.db "SELECT * FROM main WHERE name = \"android_id\";"'
3) Then save the value you're seeing to somewhere else, and register to your account at https://www.google.com/android/uncertified/
B. THEN FOR EVERY CLEAN INSTALL
1) Backups and wipes.
2) Flash rom (pt roms with vendors have the firmware included).
3) Flash gapps.
4) Optionally flash a custom kernel.
5) Reboot and configure your device.
6) Flash magisk, reboot.
THEN THIS PART IS IMPORTANT:
7.1) Again copy this database /data/data/com.google.android.gsf/databases/gservices.db and open in a sql editor (or with sqlite3 in terminal emulator, or adb shell) and execute this sql command:
UPDATE main
SET value=XXXXXXXXXXXXXXXXXXX
WHERE name="android_id";
7.2) OR from adb shell:
$ adb root
$ adb shell 'sqlite3 /data/data/com.google.android.gsf/databases/gservices.db "UPDATE main SET value=XXXXXXXXXXXXXXXXXXX WHERE name = \"android_id\";"'
Note: XXXXXXXXXXXXXXXXXXX is your android_id as you've learned and registered to your account before (You can see the android_id s you've registered at the same google link).

I just registered my IMEI, that one stays the same across factory resets.
Also, Titanium backup has an option to restore a previously used android ID.

Deleted

Deleted

muff99 said:
I just registered my IMEI, that one stays the same across factory resets.
Also, Titanium backup has an option to restore a previously used android ID.
Click to expand...
Click to collapse
Yes that works too but this is the manual method for the gsf android_id. Wifi only devices doesn't have IMEI for example.

https://www.xda-developers.com/google-removes-100-device-registration-limit-uncertified-device-page/

G4B33 said:
https://www.xda-developers.com/google-removes-100-device-registration-limit-uncertified-device-page/
Click to expand...
Click to collapse
Yes so now we don't have to do that much of hacky-wacky stuff just to get gsf certified status anymore. #YayGoogle? ?

What if you don't do that?

seems not working. After rebooting, it went back to previous id

You know I've just realized that doing exactly what's written on Google's page (that I've shared link of it) doesn't change my status too. My id is exactly what I've registered on the id registration page but no it stays uncertified so you can ignore this post too... I hope we can find a solution soon :/

ccelik97 said:
You know I've just realized that doing exactly what's written on Google's page (that I've shared link of it) doesn't change my status too. My id is exactly what I've registered on the id registration page but no it stays uncertified so you can ignore this post too... I hope we can find a solution soon :/
Click to expand...
Click to collapse
I think the display will always stay on "not certified", but you are atill able to use the Google services (which unregistered custom ROM users are not any more, if I understood correctly).
This is just a guess on my side, I have not tested this (and I can't since I added all kinds of IDs to that registration page ...).
All in all the information flow from Google on this topic has been spectacularly bad, imho.

When I register my GSF id, its not saved or a different number is display, see my correct I'd in the enter field vs ones registered.

image45 said:
When I register my GSF id, its not saved or a different number is display, see my correct I'd in the enter field vs ones registered.
Click to expand...
Click to collapse
That's because you entered it in hex format, it gets converted into decimal.
Also, don't post your id here ... Not sure what happens if other people register your id with their Google account.

muff99 said:
That's because you entered it in hex format, it gets converted into decimal.
Also, don't post your id here ... Not sure what happens if other people register your id with their Google account.
Click to expand...
Click to collapse
Do I need to convert it or is that an accepted way to submit the information please?
If I try to resubmit it advises already registered.

Related

HTC Stocks currency problem

The HTC Stocks app has the best widget of all other currency apps, so I was using it on my 1.5 Hero for displaying the EURO/GBP (EURGBP=X) rate.
After the 2.1 rom update I have a strange problem. When I try to add a new ticker for "eurgbp=x", I get the error message: "Unable to recognize the company name or stock symbol you typed. Please try again." However, this worked in the past like a charm. I have to note that adding "gbp=x" or "usd=x" works fine, with no problem at all.
Maybe this problem is related to an updated version of the Stocks app in the new rom. Is anyone experiencing the same problem? I haven't found a similar thread for a Sense Android phone. The same problem exists in the latest rom of HD2, but people have figured a work-around, by changing a file under "Application Data\HTC\", but this file doesn't exist on Android.
Any help would be more than welcome!
I experience the same problem (although I'm on VillainRom12). Previously adding currencies (EURUSD=X etc) was working, but right now I am unable to find it. This could be HTC problem as it was working fine on 1.5, but this could be also some Yahoo search glitch (I am unable to search for that quotes on mobile version of the Yahoo Finance page, while the desktop version works fine). The only workaround to that was to edit manually SQLite database of Stocks application (but this may require root - I can provide details if necessary). Once I added appropriate entries to the list of stocks, it seems to be working fine (it is displaying my currencies, but the search still does not work).
One other deficiency I found was the fact that graphs are not cached anymore - If I open the application and check for example a daily graph, I need to update it in order to see any chart - each time, even if I switch from 1D to 5D and back. It is also automatically updated each time I visit given tab, if I enable the automatic updates. Previously this app displayed previously cached graph. I'm not sure whether this happens also on stock 2.1 ROM.
Now that you mention it, I have the same problem with the graphs in the 2.1, too. It worked (showed the cashed graph) in the 1.5, but not any more. Blank graph until it updates.
Can you provide me some guidance about how to edit the Stocks' database? At least a link to something similar would be much appreciated. Can I access the phone's system folder without rooting it, through my PC (Win, Linux, whatever)?
eeVoskos said:
Can you provide me some guidance about how to edit the Stocks' database? At least a link to something similar would be much appreciated. Can I access the phone's system folder without rooting it, through my PC (Win, Linux, whatever)?
Click to expand...
Click to collapse
I'm new in the business, so I'm not sure if the root is necessary. You can try it, anyway to see if you will be able to push and pull files from the directory where Stocks stores its database.
Here's what I did:
Enable USB Debugging in Settings -> Applications -> Development -> USB Debugging
Download Android SDK from http://developer.android.com/sdk/index.html
In command line go to subdirectory tools of Android SDK
Close Stocks app and remove Stocks widget from the screen
Connect Phone via USB
... (Beginning of the optional part) ...
Go to Android shell
Code:
adb shell
List any processes to see if there's a com.htc.android.Stock process (like in this case)...
Code:
ps | grep Stock
7605 10007 130m S com.htc.android.Stock
7619 0 2156 S grep Stock
Kill any Stock processes (using the value in the first column):
Code:
kill 7605
Exit to command line
Code:
exit
... (End of the optional part) ...
Pull the Stock database:
Code:
adb pull /data/data/com.htc.dcs.service.stock/databases/stock.db stock.db
Sample output:
Code:
d:\Projects\Android\tools>adb pull /data/data/com.htc.dcs.service.stock/databases/stock.db stock.db
568 KB/s (5120 bytes in 0.008s)
Backup, just in case:
Code:
copy stock.db stock_backup.db
Run sqlite3
Code:
sqlite3 stock.db
Enable headers in sqlite:
Code:
.headers on
List contents of quotes table:
Code:
select * from quotes;
Sample output:
Code:
sqlite> select * from quotes;
_id|_name|_symbol|_price|_change|_percent|_open|_high|_low|_volume|_link|_type|_sequence|_updatetime
2|CHF/PLN|CHFPLN=X|3.08299994468689|0.0116999996826053|0.381900012493134|3.07209992408752|3.08550000190735|3.07010006904602|0|http://m.yahoo.com/htcwf/search?p=CHFPLN=X||0.0|1278490511305
3|USD/PLN|USDPLN=X|3.27649998664856|0.0200999993830919|0.617200016975403|3.25550007820129|3.27959990501404|3.24499988555908|0|http://m.yahoo.com/htcwf/search?p=USDPLN=X||100.0|1278490511305
4|EUR/PLN|EURPLN=X|4.1217999458313|0.0151000004261732|0.367700010538101|4.11250019073486|4.12349987030029|4.10799980163574|0|http://m.yahoo.com/htcwf/search?p=EURPLN=X||200.0|1278490511305
5|EUR/USD|EURUSD=X|1.25789999961853|-0.00469999993219972|-0.376199990510941|1.26170003414154|1.26259994506836|1.25689995288849|0|http://m.yahoo.com/htcwf/search?p=EURUSD=X||300.0|1278490511305
6|EUR/CHF|EURCHF=X|1.33689999580383|-0.000899999984540045|-0.0710000023245811|1.33879995346069|1.33910000324249|1.33609998226166|0|http://m.yahoo.com/htcwf/search?p=EURCHF=X||400.0|1278490511305
sqlite>
Note the last _id (here 6) and add new currency with _id higher by 1 (so here, 7):
Code:
insert into quotes (_id, _name, _symbol) values (7, "EUR/GBP", "EURGBP=X");
Check if it has been added:
Code:
select * from quotes;
Sample output:
Code:
sqlite> select * from quotes;
_id|_name|_symbol|_price|_change|_percent|_open|_high|_low|_volume|_link|_type|_sequence|_updatetime
2|CHF/PLN|CHFPLN=X|3.08299994468689|0.0116999996826053|0.381900012493134|3.07209992408752|3.08550000190735|3.07010006904602|0|http://m.yahoo.com/htcwf/search?p=CHFPLN=X||0.0|1278490511305
3|USD/PLN|USDPLN=X|3.27649998664856|0.0200999993830919|0.617200016975403|3.25550007820129|3.27959990501404|3.24499988555908|0|http://m.yahoo.com/htcwf/search?p=USDPLN=X||100.0|1278490511305
4|EUR/PLN|EURPLN=X|4.1217999458313|0.0151000004261732|0.367700010538101|4.11250019073486|4.12349987030029|4.10799980163574|0|http://m.yahoo.com/htcwf/search?p=EURPLN=X||200.0|1278490511305
5|EUR/USD|EURUSD=X|1.25789999961853|-0.00469999993219972|-0.376199990510941|1.26170003414154|1.26259994506836|1.25689995288849|0|http://m.yahoo.com/htcwf/search?p=EURUSD=X||300.0|1278490511305
6|EUR/CHF|EURCHF=X|1.33689999580383|-0.000899999984540045|-0.0710000023245811|1.33879995346069|1.33910000324249|1.33609998226166|0|http://m.yahoo.com/htcwf/search?p=EURCHF=X||400.0|1278490511305
7|EUR/GBP|EURGBP=X|||||||||||
sqlite>
Quit sqlite:
Code:
.quit
Push the file back to the phone:
Code:
adb push stock.db /data/data/com.htc.dcs.service.stock/databases/stock.db
Sample output:
Code:
d:\Projects\Android\tools>adb push stock.db /data/data/com.htc.dcs.service.stock/databases/stock.db
341 KB/s (5120 bytes in 0.014s)
Restart phone.
See if that worked
I hope HTC (or Yahoo) will be able to fix that, because the above is really a long process...
Anyway, I can't make it work. Entering "ps | grep Stock" gives me a "grep: permission denied" error message. I did some searching and I believe this is what people mean by saying "you need root access", right? I'll come back when I'm rooted (i.e. when I find a decent guide for rooting 2.1).
Thanks for your time & effort man. I really appreciate it.
eeVoskos said:
Anyway, I can't make it work. Entering "ps | grep Stock" gives me a "grep: permission denied" error message.
Click to expand...
Click to collapse
You can try to omit the "optional" part (steps 6-9) - the ps thing was just to make sure that Stock isn't running. But I noticed anyway that it never ran in the background when I closed it on the phone. Try to adb pull and adb push and see if you'll get any permission issues. If you do, then you indeed need a root (sorry I can't check that as I'm rooted)
A couple of days ago I updated the ROM of my HTC TD2, with the most recent one of HTC (WM6.5, Sense 2.5.20113030.0). Afterwards I noticed that I also could not get the stock app to accept the code EURUSD=X.
You mention the following
The same problem exists in the latest rom of HD2, but people have figured a work-around, by changing a file under "Application Data\HTC\", but this file doesn't exist on Android.
Click to expand...
Click to collapse
Can you tell me what that work-around is or point me to it? Hopefully this can help me.
Thank you in advance.
Check this thread:
http://forum.xda-developers.com/showthread.php?t=706732
eeVoskos said:
Check this thread:
Click to expand...
Click to collapse
Thank you for the link (which I am not allowed to repost ).
Last Monday I wrote an e-mail to HTC about this problem and a couple of days later I got a reply. They told me they tried to search for the currency rate (eurusd) and that they got a result. So I tried again and lo and behold I got a result as well. Searching for eurusd=x gave me a result while last weekend it was not working.
So I tried several other currency rates and they all rendered a result, also eurgbp=x. Perhaps it is also fixed for the Android app.
[Extra information added below]
Tried again and nothing
I was connected with a data connection to my carrier, so I switched to my wifi connection. Tried again and... result.
So it seems to be a difference in communication between an ordinary data connection and a wifi connection. Maybe this will help someone
Wird problem. I tried it too on both UK and Greek carriers and on WiFi, but nothing. No result for either of them: "eurgbp=x", "eurgbp", "eurusd=x", "eurusd". I have been trying occasioanly more than one month now.
I think I should drop them an email too...
Why don't you do a soft (temporary) root and make the database entries as described in here? I did it and now I got all the stuff I need, and no trace of root on the device.

Vocera Application on CM10 or AOSP ROMs

I am required to use an application for hospital communication - it is a messaging app that takes the place of pagers. It is called Vocera -- it is available on the Playstore.
The problem that I'm having is that the app installs fine on both Sammy based and CM10 or AOSP ROMs but then you have to enter a server ip address and a registration key. The keys are one time use apparently so every time I try a new install our Sys Admin gets frustrated (they don;t care for rooted devices anyway).
On the CM10 or AOSP based ROMs the IP address for the server and Registration key seem to be accepted but don't "take" in that after they are entered and I press OK then the screen flashes and goes right back to the Registration page.
I have attached the log that was recorded during install of Vocera or VMP app and then the subsequent entry of the Registration.
Can anyone help with troubleshooting this app for use on AOSP based ROM's (or point me in the right direction)??
Also the other interesting thing is that if I do a Titanium Backup of the app then restore to a different ROM it doesn't maintain the Registration information -- I have to get a new key from the Sys Admin and re register the device. Does anyone know how to copy that registration information? Is there a hidden registry for Android OS's?
I have attached log and the files that are in the Titanium Backup folder for this app

Install Android Apps on Windows 10 Mobile (Bonus: Clash of Clans on Lumia)

Project Astoria BETA​
Minimum Required:
Windows 10 Mobile build 10166
!!IMPORTANT!!
After you done installed an apps. Do this: | or you get crash developer mode setting.
- Disconnect wconnect (cmd: wconnect disconnect emulator-5554)*
- Turn Off device discovery
*number of your emulator must match​
#List of supported devices:
- Lumia 1520
- Lumia 930
- Lumia 929 (icon)
- Lumia 928
- Lumia 925
- Lumia 920
- Lumia 830
- Lumia 820
- Lumia 730
- Lumia 635 (1GB RAM variant)
#How to?
Download Project_Astoria.zip
1. Extract Project_Astoria.zip to a folder
2. Open the folder Windows Connect, then install IpOverUsbInstaller.msi and vcredist_x86.exe
3. Go to your Windows 10 Mobile’s Settings > Update & Security > For Developers and enable Developers Mode, as well as Device Discovery
4. Now go to the Windows Connect folder, then open an elevated command prompt (Shift + right click > Open command window here)
5. After that, you’ll need to connect to the phone — and there’s two way of doing that (Wi-Fi or USB | USB method is recommended):
- If you want to connect using USB, type on cmd:
wconnect usb
ENTER
- And if you want to connect over Wi-Fi, type on cmd:
wconnect [your IP]
ENTER
e.g: wconnect 192.168.123.123
6. Then it’ll ask for the pairing code, just type the pairing code and hit enter (see your pair code on phone at pair button)
7. After that, navigate to the adb folder and open an elevated command prompt
8. To make sure that your device is connected, type adb devices and press ENTER to show the list of devices that are connected
9. place the APK file that you want to install on the adb folder or somewhere you known, and type:
adb install APKNAME.apk (replace APKNAME with the APK file’s name)
ENTER
if your apk on your own folder, type the path. e.g:
adb install D:/MyAPK/APKNAME.APK
ENTER
Just wait it and if the app installation done will notice you : Success.
#Additional tools
Use GMAPS Patcher to remove any google service build-in on apk's
(some app may not work)
BONUS: Clash of Clans (ALPHA)​If you wanna play Clash of Clans in your Lumia/Windows Phone. Using this patching apk of CoC game.
com.supercell.clashofclans-patched.apk
* - I have removed sign by Google account and any google service and you can using facebook account to play
- You still can play the game normally without losted any saved game because now you synched to facebook
* please note: if you found some bugs , you must know this is my ALPHA Repacked APK
Thanks :good:
@T4ufik_Hidayat,
TFK Project
Uhm.... but why? I already posted 3 methods on how to do this.
I patched CoC myself, but while it removes the sign-in, it still doesn't let you sync with your current iOS/Android town. So what was the point of patching it? Just so it doesn't say you can't sign in when you click the button?
XDRdaniel said:
Uhm.... but why? I already posted 3 methods on how to do this.
Click to expand...
Click to collapse
Sorry if you're ready to make the thread first. Actually my point is Clash of Clans, not How to Install android app.
drearyworlds said:
I patched CoC myself, but while it removes the sign-in, it still doesn't let you sync with your current iOS/Android town. So what was the point of patching it? Just so it doesn't say you can't sign in when you click the button?
Click to expand...
Click to collapse
There's two way to login on CoC, Google or Facebook. We have removed the google option and just using facebook. I'm trying to "How to syncs between device?" On another device also connected to same facebook account.
When I'm wrong. Just correct me or make it work together.
I'm also working to try make implementation Google Service on Lumia.
Logging onto Facebook tells me the FB acct is already linked to a CoC acct and asks if I want to link it to this town instead. But at any rate, the Google Sign In error doesn't inhibit the ability to play at all, unless I'm missing something.
Anyone get snapchat to work yet?
Hello,
I tested your apk file as I was having issue with mine (get using apk extractor on my android device).
I have the same : missing textures on trees, buildings, etc...see screenshot attached
Also connecting Facebook account is not getting saved games : it's just here for finding friends... see attached image, it's just asking you if you wants to link this game to your account.
If I find a way to get back saved games, I will post here
About texture missing, any idea?
Failure [INSTALL_FAILED_(-2147009263)]
I'm getting this error ( Failure [INSTALL_FAILED_(-2147009263)] ) when installing com.google.android.gms.apk, and for Google Plus, Keep, Docs, Sheets, Slides, and Hangout. Any idea what's going on?
DarkAngelFR said:
Hello,
I tested your apk file as I was having issue with mine (get using apk extractor on my android device).
I have the same : missing textures on trees, buildings, etc...see screenshot attached
Also connecting Facebook account is not getting saved games : it's just here for finding friends... see attached image, it's just asking you if you wants to link this game to your account.
If I find a way to get back saved games, I will post here
About texture missing, any idea?
Click to expand...
Click to collapse
I'm getting the same missing textures error. Also unable to sign in at all. Clicked on the button and nothing happened. Testing on Lumia 925.
Can anyone here tell me where to place the obb files of games..... + an advice to others who cant use this COC not working. Just restore the PhoneManufactureModelName and other things back to default
Restart your phone and reinstall the game...... This sometimes solves the keyboard not showing up problem which I faced while entering my name for first time in COC
Those who having (error -217.......) just re download the file this error showed up when I tried to install facebook but re downloading solved the problem
I have the Lumia 640 with the latest build (10512 I think?) And I am trying to get the dev enhancements for this to work for my phone, your list says my phone is not supported, but according to other lists on XDA in this forum, my phone should be if I install the DE update (Which for some reason I cannot get?) Please let me know a way I can get this to work, thanks!
Sandix you need to go back to Win 8.1, then with registry editor change your product ID to Lumia 930, then upgrade to windows 10 a Astoria will be working for you.
tickmaster said:
Sandix you need to go back to Win 8.1, then with registry editor change your product ID to Lumia 930, then upgrade to windows 10 a Astoria will be working for you.
Click to expand...
Click to collapse
Damn that is a lot of work. hahaa
Does the Developer enhancement update include the Android stuff? and would it be possible to get the DE update by doing a similar method in the registry and then checking for updates?
But thank you for your answer!
If you are on 10166 build yes.
augustinionut said:
If you are on 10166 build yes.
Click to expand...
Click to collapse
Damn can't get the update on the 10512 build?
Tryed today with lumia 1520 registry from wp8.1 to 10166, no enhancement awailable...
tickmaster said:
Sandix you need to go back to Win 8.1, then with registry editor change your product ID to Lumia 930, then upgrade to windows 10 a Astoria will be working for you.
Click to expand...
Click to collapse
Where in the registry can I change the Product ID and where can I get the product ID for the 930?
EDIT: Found it, the RM-1045 (I hope) we are about to see i guess lmao
Where and How to place obb game files needed for some games
Why not Lumia 640XL?

[Q] How to change GSF and Andoid ID (of a cloned phone)

sm-a500fu, rooted, 4.4.4
My wife got a new sm-a500fu like our daugther has. To save work (after rooting) I restored the data and systems partitions (with Flashfire) of my daughters a5.
I deleted all my duaghters accounts and logged into google with my wifes account.
Still both phones have the same GSF and Androide ID.
I know that the Androide ID can be set like this:
Code:
adb shell ettings put secure android_id nnnn
- But which should I use ? Can I use the one of here old phone ?
- And what about the GSFid ?
Hoping for help now ...
What I found out so far:
android_id: *#*#8255#*#*
/data/data/com.android.providers.settings/databases/settings.db
its name in the database is android_id, value is HEX
gsf id: *#*#GCM#*#*
/data/data/com.google.android.gsf.gservices/databases/gservices.db
its name in the database is android_id too, value is decimal
Theese questions remain:
1 Is it necessary to change both or would GSFid be enough ?
2 If I change the IDs in the databases of the cloned phone to its original, what apps do I have to reinstall ?
3 Or is it cleaner to reinstall GSF and GAPPs ?
3a But would I get another ID this way ?
I realize this is an old thread which I found by searching for more information on changing the GSF-ID, where I'll just point people who may come here to a new method I found which changes the GSF_ID using basic Windows tools on a non-rooted Android phone without having to Factory Reset the darn thing (which is kind of nice indeed).

[GUIDE][SN_Writer]Restore IMEI, WiFi/Bluetooth Mac, Serial No.[Lenovo_K8_Note]

If you flashed the Stock ROM using “Download All + Format” option in SP Flash Tool or you wiped NVRAM partition accidently then you probably lost IMEIs, WiFi/Bluetooth Mac Address and Serial No.
Disclaimer:
Code:
/*
*Your Warranty is now void.
*Neither me nor the developers of tools are responsible.
*You are doing this at your own risk and will
*solely be responsible if something happens to the device.
*Make sure you only use the original “IMEI_1, IMEI_2,
*WiFi/Bluetooth Address, Serial Number” that came with your phone.
*/
Note:
Although, I have tried to keep this guide as simple as possible, I am assuming that you have already flashed Stock ROM using this thread/guide:
https://forum.xda-developers.com/k8-note/how-to/lenovo-k8-note-xt1902-3-fix-dead-hard-t3791839
Which also means the required drivers i.e. “MTK (USB DA COM, Preloader USB VCOM, USB Port, USB VCOM) Driver” and “Lenovo USB Driver” in the thread mentioned above are also installed.
Requirements:
Lenovo K8 Note with Stock ROM.
Original IMEI_1, IMEI_2, WiFi/Bluetooth Mac Address, Serial Number. (Find on Phone’s box)
SN Write Tool (Download)
Database Files
ADB Tools (Inside SN_Write_Tool\Android)
Basic ADB know-how.
And a PC. (obviously)
USB Debugging:
Before we proceed, make sure “USB Debugging” is enabled on phone:
Navigate to, Settings > System > About Phone > Build Number (Tap 7 times) to enable “Developer Options”.
Now, Enable “USB Debugging” in Settings > System > Developer Options.
Flashing Procedure:
Extract SN Write. (For Example, Location: “E:\ SN_Write_Tool_v1.1916.00”)
Open SN Write Tool (SN_Writer.exe).
Make sure all the Preliminary steps mentioned in below sections have been performed – Obtaining DB files, Configuring SN Write Tool, Understanding Barcode.
Switch off the phone, while keeping the cable unplugged
Click “Start”.
Enter Original IMEI_1, IMEI_2, WiFi/Bluetooth Mac Address, Barcode and press “Ok”
Connect your phone.
Now your phone will automatically boot in Meta Mode.
Wait for the Process to finish.
Now you will see “Pass” message if everything completes successfully.
Now it will again ask to enter the details. Click “Cancel”
The phone will now switch off. Then boot it manually.
That’s it. Your phone is now back to normal. Now, you can see Serial No. in adb too.
Obtaining Database(DB) files:
In order to restore everything we need 2 Database files, which can be obtained by following the procedure below:
Extract SN_Write Tool. (For Example, Location: “E:\ SN_Write_Tool_v1.1916.00”)
Navigate to “Android” folder inside SN_Write_Tool folder.
Keep Shift Key Pressed and Right Click inside the folder. Select “Open Command / PowerShell window here”.
Type
Code:
adb devices
You will receive a prompt on your phone. Select “Ok”. The device will appear in the list. (Something like “0123456 device”)
Now, type these commands:
Code:
adb pull /vendor/etc/mddb Database
adb pull /system/etc/apdb Database
Now, navigate to “E:\ SN_Write_Tool_v1.1916.00\Android\Database”. There will be around 23 Files. We only Need 2 files from that.
APDB_MT6797_S01_alps-trunk-o0.tk_W19.10 (Approx. size 145kb)
MDDB_InfoCustomAppSrcP_MT6797_S00_MANNING_O_Vxx_x_ulwctg_n.EDB (Approx. size 59mb)
Note: Name and size may slightly vary depending upon your firmware.
Copy the above two files to some other destination (optional).
Note: If you are using PowerShell then, instead of “adb” type “./adb”
Configuring SN Writer Tool:
Open “SN_Writer.exe” inside “E:\ SN_Write_Tool_v1.1916.00”.
Now Click “System Config”.
Check “Dual IMEI” (Do not check “Dual IMEI Same” under that).
In Write options select Barcode, IMEI, BT Address, WiFi Address. (If you don’t have WiFi/BT Address then don’t check/select them).
Check “Load AP DP from DUT” and “Load Modem DB from DUT”.
Click “MD1_DB” and select the file that you pulled using ADB i.e.
“MDDB_InfoCustomAppSrcP_MT6797_S00_MANNING_O_Vxx_x_ulwctg_n.EDB”
Click “AP_DB” and select the file that you pulled using ADB i.e.
“APDB_MT6797_S01_alps-trunk-o0.tk_W19.10”
Now click “Save”.
{
"lightbox_close": "Close",
"lightbox_next": "Next",
"lightbox_previous": "Previous",
"lightbox_error": "The requested content cannot be loaded. Please try again later.",
"lightbox_start_slideshow": "Start slideshow",
"lightbox_stop_slideshow": "Stop slideshow",
"lightbox_full_screen": "Full screen",
"lightbox_thumbnails": "Thumbnails",
"lightbox_download": "Download",
"lightbox_share": "Share",
"lightbox_zoom": "Zoom",
"lightbox_new_window": "New window",
"lightbox_toggle_sidebar": "Toggle sidebar"
}
​
Understanding Barcode:
It took me lots n lots of trial & error and googling before finding the correct (probably) Barcode format that we need to use in SN Writer. Trust me, it was not an easy task. Below are three iterations of barcode, use any:
First Iteration (recommended):
The Barcode field consists if two parts, call them Spaces and Serial No.​
​
Total Length(33 Characters) = (25 Spaces) + SN(8)​
​
For Example,​
If my SN written on the box is “XYZ1223W”, my barcode will be (without quotes):​
Code:
“ XYZ1223W”
​
​
or
Second Iteration (recommended 2):
In this iteration, we'll assume that the Barcode field in SN Write Tool is a combination of three parts. Lets call it First (PN), Second and Third Part (SN). You can find PN & SN on the box of phone. I am not sure about the second part with 15 characters. You can leave the second part, just give 15 Spaces.​
​
Total Length(33 Characters) = PN(10) + (15 Spaces) + SN(8)​
​
For Example,​
If my PN written on the box is “AB1D1112IN” and SN is “XYZ1223W”, my barcode will be (without quotes):​
Code:
“AB1D1112IN XYZ1223W”
​
or
Third Iteration:
There can also be a third iteration for barcode, though I am not sure about this and is completely based on my assumption. In the second part, as mentioned above we are leaving 15 spaces, but in this, we will use the product barcode of 13 characters (Refer Barcode No. 2 in the attached image below) instead of 15 spaces​
​
​
​
For Example,​
If my barcode (no. 2 in image above) of 13 charcters is “0123456789012”, then in SN Writer we will write (without quotes):​
​
Total Length(33 Characters) = PN(10) + (Space) + (13) + (Space)+ SN(8)​
​
Code:
“AB1D1112IN 0123456789012 XYZ1223W”
​
Note the space after each part, which makes up for two characters that we require.​
As you can see in the Screenshot attached in this post, “Lenovo Help” app recognizes the device as it is meant to be recognized.
​
WiFi/Bluetooth Mac Address:
Though, it is not a big deal if you lost WiFi/Bluetooth Mac Addresses. They will still work fine even without it.
If you didn’t backup nvram before or didn’t note down WiFi/Bluetooth Mac address then you can’t get it back. But, if you did TWRP backup of nvram then you can restore it and get back both the original Mac addresses.
FAQs:
SN Writer not booting phone into Meta Mode automatically.
Make sure drivers are installed ​
or​
Boot Manually in Meta Mode using Power Button + Volume Down. Check Already in Meta Mode.​
​
Do I need to be on Stock ROM?
Yes.​
Changelog:
27 September 2020:
Update post.
Added one more iteration of barcode.
Added more Screenshots.
Correct minor typos.
thanks alot man
I managed to get apdb files but when i try your command to get mddb i get that error
adb: error: failed to copy '/etc/mddb' to 'Database\mddb': read failed: Is a directory
any help?
and how to know if my bluetooth or wifi mac address is missing and where to find them because nothing of that is written on the phone box
softmaster3 said:
thanks alot man
I managed to get apdb files but when i try your command to get mddb i get that error
adb: error: failed to copy '/etc/mddb' to 'Database\mddb': read failed: Is a directory
any help?
and how to know if my bluetooth or wifi mac address is missing and where to find them because nothing of that is written on the phone box
Click to expand...
Click to collapse
Edit: Solved
Android will automatically generate Wi-Fi / Bluetooth address if not found. No need to worry about that. Thats why I I have mentioned in the post that it will still work fine even without it.
You mentioned wrong paths, /etc/apdb is fine but /etc/mddb doesn't exist(empty folder was created in latest update but still no contents in it). mddb is under /vendor/etc/mddb. Just to avoid confusion and even to make this guide suitable for users who pull the file from TWRP make the /etc/apdb to /system/etc/apdb
---------- Post added at 01:03 PM ---------- Previous post was at 01:00 PM ----------
softmaster3 said:
thanks alot man
I managed to get apdb files but when i try your command to get mddb i get that error
adb: error: failed to copy '/etc/mddb' to 'Database\mddb': read failed: Is a directory
any help?
and how to know if my bluetooth or wifi mac address is missing and where to find them because nothing of that is written on the phone box
Click to expand...
Click to collapse
instead of "adb pull /etc/mddb" use "adb pull /vendor/etc/mddb"
M.A.P said:
You mentioned wrong paths, /etc/apdb is fine but /etc/mddb doesn't exist(empty folder was created in latest update but still no contents in it). mddb is under /vendor/etc/mddb. Just to avoid confusion and even to make this guide suitable for users who pull the file from TWRP make the /etc/apdb to /system/etc/apdb
---------- Post added at 01:03 PM ---------- Previous post was at 01:00 PM ----------
instead of "adb pull /etc/mddb" use "adb pull /vendor/etc/mddb"
Click to expand...
Click to collapse
thanks a lot guys
u two just made my day
and M.A.P u r a life saver i cant thank you enough for ur work on treble for k8 note and ur help here
M.A.P said:
You mentioned wrong paths, /etc/apdb is fine but /etc/mddb doesn't exist(empty folder was created in latest update but still no contents in it). mddb is under /vendor/etc/mddb. Just to avoid confusion and even to make this guide suitable for users who pull the file from TWRP make the /etc/apdb to /system/etc/apdb
Click to expand...
Click to collapse
Done. Thanks for suggestion.
i did write the serial, check warranty and its good
but noticed that the serial written on phone box is 12 Character long not just 8 and sn writer did write 8 only not the whole 12
is that correct??
softmaster3 said:
i did write the serial, check warranty and its good
but noticed that the serial written on phone box is 12 Character long not just 8 and sn writer did write 8 only not the whole 12
is that correct??
Click to expand...
Click to collapse
May I see the image of your box. PM me the image.
done
softmaster3 said:
thanks a lot guys
u two just made my day
and M.A.P u r a life saver i cant thank you enough for ur work on treble for k8 note and ur help here
Click to expand...
Click to collapse
Your welcome, I'm always ready to help
Hi, with the help of your guide, i have recovered my phone. But the problem is still same as it restarts repeatedly,sometimes it worked for 1 day but then again rewstarting. Is there any permanent solution for this?
psbtheone said:
Hi, with the help of your guide, i have recovered my phone. But the problem is still same as it restarts repeatedly,sometimes it worked for 1 day but then again rewstarting. Is there any permanent solution for this?
Click to expand...
Click to collapse
Show your phone to a technician. It may be due to battery or some other reason.
Im getting remote object does not exist error for both commands
WP7 Barcode
Hi,
I was wondering how did you find the correct Barcode format? I have spent 2 days trying with different combinations and I still have not succeeded in restoring the serial number in my Oukitel WP7. It still gives me the generic serial number 123456789ABCDEF.
oxord said:
Hi,
I was wondering how did you find the correct Barcode format? I have spent 2 days trying with different combinations and I still have not succeeded in restoring the serial number in my Oukitel WP7. It still gives me the generic serial number 123456789ABCDEF.
Click to expand...
Click to collapse
Did some Trial and Error to figure out correct (probably) barcode format. In addition to this, you'll also need specific database files for your phone in order restore it.
kk9999gada said:
Did some Trial and Error to figure out correct (probably) barcode format. In addition to this, you'll also need specific database files for your phone in order restore it.
Click to expand...
Click to collapse
Man this thing is driving me crazy. I have tried every single combinations and did so many googling and there are not a lot of information about this. The other problem is that the Oukitel WP7 does not have a Product Number written on the box or on the back of the device, there is only a serial number and a barcode with 13 numbers under it. I even tried the FCC ID that is written at the top. I have been spending few days trying. I think the only way to know the correct format is to ask someone who has the same device to view it using Maui Meta by viewing the hex format or exporting the NVRAM to an ini file. I doubt anyone would help me with this though. I have the database files from the stock image. Anyways thanks man
oxord said:
Man this thing is driving me crazy. I have tried every single combinations and did so many googling and there are not a lot of information about this. The other problem is that the Oukitel WP7 does not have a Product Number written on the box or on the back of the device, there is only a serial number and a barcode with 13 numbers under it. I even tried the FCC ID that is written at the top. I have been spending few days trying. I think the only way to know the correct format is to ask someone who has the same device to view it using Maui Meta by viewing the hex format or exporting the NVRAM to an ini file. I doubt anyone would help me with this though. I have the database files from the stock image. Anyways thanks man
Click to expand...
Click to collapse
That would be better.
There is no need for Part No. or Barcode (both can be replaced with spaces). The only thing required is Serial No.
kk9999gada said:
That would be better.
There is no need for Part No. or Barcode (both can be replaced with spaces). The only thing required is Serial No.
Click to expand...
Click to collapse
I tried that as well with so many different ways and with spaces and without. I guess the length also matters. I even filled all 63 characters to see if anything changed in settings but it still showed the generic serial number. I am starting to wonder if sn tool is writing the data in the correct location. I am sure I am using the correct database files because I got them from the factory image from the official website and I am able to write the IMEIs correctly.
I am thinking now to go through the serial number which is 16 characters from left to right. Each time I add a space on the left and no spaces after the serial so first try would be only the serial then a 1 space before it then two spaces before it until I reach the 63 characters. This is like 50 restarts and if that does not work I will try in a same manner but this time full up spaces after the serial and do the same by adding one space on the left each time so first try would be the serial number and the remaining will be spaces up to 63 characters the second time will be one space before the serial and remaining spaces after it up to 63 and so one. I know it's crazy but if all that does not work I am not sure what else to do.
Hi
This happened to me with this dangerous spflash tool. WIPED everything. I followed this guide , It PASSES without any errors but doesnt write anything to my phone. Box has a code bar like this 6 970502 270581 then MEID code of 14 characters , than IMEI1 code and a IMEI2 code and finaly a S/N code of 15 characters.
As i said it PASS but doesnt show IMEI, version base band , bluetooth address, Serial number ,
Thank you very much spflash tool. Had to get another phone.
Phone is a MEDIATEK mt6763T.
Only thing that i dont understand from guide is how to enter Serial number in sn writer. Did it many ways. 33 characters and 64 characters with spaces.
If anyone has any idea , please show me the way. thx.

Categories

Resources