yashsingh1/xdaforums huggingface dataset:
[Moto G Q&A, Help & Troubleshooting] lost101:
Bummer. I guess that's the end of the story.

Return To Manufacturer (RTM) is the only solution for: fastboot erase all.
[Moto G Q&A, Help & Troubleshooting] rootr:
Hello surfino. As i said earlier PDS is not important. That doesnt help with IMEI 0 problem. You can move on from that. But one thing. Did you "fastboot erase all" your Moto G? Because my IMEI is not displayed in fastboot. You can help by figuring out way to read hob and dhob partitions. They are most suspected to contain IMEI data. HOB and DHOB are at /dev/block/platform/msm_sdcc.1/by-name/hob and /dev/block/platform/msm_sdcc.1/by-name/dhob.

Thankyou.
[Moto G Q&A, Help & Troubleshooting] rootr:
I used BP Tools with QC Diag Driver and read NV partitions. Too bad. I tried to write NV #550 supposedly IMEI field, but to no avail. It seems Moto G does not support writing IMEI like that. Tried same with DFS. It gave BAD_PARAMETER error, meaning NV partition does not support inserting IMEI with that method.
[Moto G Q&A, Help & Troubleshooting] rootr:
Yes bro, i "fastboot erase all" 'd my Moto G. I learnt it the hard way. But i dont think hob and dhob are ram related because as i said earlier radio is chown'ing it in init file. And regarding corrupting PDS partition, my wifi bluetooth and gps are working fine even after formatting PDS completely. Though my WIFI stopped working when i formatted /persist.

PS: i took it to Motorola center. They said to replace the SOC completely! That sucks. And i gotta pay like half the amount i bought it for.
[Moto G Q&A, Help & Troubleshooting] rootr:
So guess thats it. Looks i have to buy a new phone then. I dont understand why Motorola would put such sensitive information to such easy access. Thats really bad on their part. Plus they have not simplfied the IMEI recovery process like samsung has. Anyways, thanks for your help man!
[Moto G Q&A, Help & Troubleshooting] lost101:
You have to remember Motorola don't talk about Fastboot on their site, or even make Firmware Images available to the public. The Motorola Firmware Images linked to on XDA are provided by a third party. Fastboot is intended for use by engineers only. Sorry for your loss.
[Moto G Q&A, Help & Troubleshooting] TeamMex:
hob are symlinked partition only xD
[Moto G Q&A, Help & Troubleshooting] surfino:
Yes I did fastboot erase all

And with fastboot getvar imei it currently display my imei. That's what I don't understand
[Moto G Q&A, Help & Troubleshooting] skyguy126:
Would doing a JTAG dump help at all, since it dumps the entire nand chip? Just a suggestion...

Someone with an intact imei could try this.

---------- Post added at 02:01 AM ---------- Previous post was at 01:35 AM ----------

If it correctly showed imei, reflash stock frimware from fastboot. This might restore it!
[Moto G Q&A, Help & Troubleshooting] betatan:
So, this is the tale:

- Tried to go back to stock (I had CM), but I failed hard.

- Went back to CM, no signal, WTF.

- Did a "fastboot getvar all", doesnt show IMEI

- Boot to CM, of course, *#06# shows an empty IMEI

- Said to myself, you ****ed up pal.

- Read thousand posts, tried almost everything.

- I give up, I have a ****ing tablet.

- Then I read this pal in the forum with similar case, he said "I flashed stock rom without sim card on"

- I thro, why the hell not? this **** is dead anyway.

- I download "exactly" the same stock rom for my phone, before I flashed a different version.

- **** works, my IMEI is back and I cant believe it.

Since then (1 week) has been working as normal.
[Moto G Q&A, Help & Troubleshooting] hunterhere:
I have no problem in giving the mentioned folder but i have done erase all, so will mine be useful? If yes, please tell me how to extract.
[Moto G Q&A, Help & Troubleshooting] skyguy126:
I have hob dhob and fsc. But as I mentioned before hob contains keys to decrypt dhob. And the radio is the only binary that can do this.

I also mentioned the proc/config folder before but someone suggested that that is only used for the barcodes option in the boot loader menu.

---------- Post added at 06:37 AM ---------- Previous post was at 06:35 AM ----------

I used the efs explorer on my moto g from qpst and the folder mot_hob and has a cross going through. I think its read and write protected by the user.
[Moto G Q&A, Help & Troubleshooting] hunterhere:
So here i go...

1. I have executed "erase all" command

2. I tried to write my imei through nv editor.. and here comes a catch, I have attached a SS as we all can see that a variable NV_550 is missing from my phone, because i have done erase all.

3. So the above point is the answer to [MENTION=6122951]rootr[/MENTION] point that moto g doesn't support NV_550 variable, it do supports, but after doing erase all command we have erased it.

4. [MENTION=6036514]skyguy126[/MENTION] you were correct brother flashing fsc hob and dhob will surely work... as flashing these 3 partitions will bring back the NV_550 variable... and then we can write our own IMEI.

5. It is NOT write protected, as far as i can see. See the difference between my SS and [MENTION=6122951]rootr[/MENTION] last SS in rootr's SS the hex checkbox in enable and changing of imei fields is also enable, But in NV_571 variable (my SS) the hex check box and changing of figure in the box is disabled. So here i conclude by this that we can (99.99%) write our own IMEI if we get three above stated partitions.
[Moto G Q&A, Help & Troubleshooting] hunterhere:
Now Please some one show mercy on us.... and provide these 3 partitions... please.. :)
[Moto G Q&A, Help & Troubleshooting] bludotos:
the proc/config might not be just for the fastboot barcodes. cause I see my imei on the fastboot barcodes even though this folder is blank (not empty just blank). It would be good to know the size. My guess is that maybe the dhob is 512kb of a filesystem hence the config folder? Worth a try anyways cause we cant do anything without these partitions.
[Moto G Q&A, Help & Troubleshooting] skyguy126:
Going to try the nv write this evening. I might be able to provide the /proc/config as well. If the proc folder is the location of the imei we can easily manipulate it. Although I feel like it will be reset upon each boot. But to get around this we can init.d the folder.

The one thing I need help on is converting the nv hex into my imei. How do I do that?
[Moto G Q&A, Help & Troubleshooting] hunterhere:
Converting your imei into hex simple

First digit is always 8 and second digit of second row is always "a".

See for example your imei is 345670980200123

Then u should write your imei in nv as-

8

3a

54

76

90

08

02

10

32
[Moto G Q&A, Help & Troubleshooting] Tosgaba:
Buddy aren't 08 and 02 must be only 8 and 2?

AFAIK they must be that way, correct me if i wrong.

BTW i got sick a couple of days and couldn't be here.

I wanna do something about this situation.

Just ask me for something to test, try or anything else.

---------- Post added at 12:49 AM ---------- Previous post was at 12:19 AM ----------

A few minutes ago i dumped those 3 partitions via terminal emulator as .img files.

So what is next ?
[Moto G Q&A, Help & Troubleshooting] skyguy126:
If you have an intact imei then try this. Try and use the NV write tool to set the imei to 123456789 and so on. (If anything goes wrong then restore using the partition dump you made) Once you set the imei, reboot phone. Then send me the modified hob, dhob, and fsc. Also tell me if the new imei was showing in the settings menu.

---------- Post added at 01:12 AM ---------- Previous post was at 12:36 AM ----------

Have't tried NV yet but I'm working on testing /proc/config. Apparently you can't modify it even with superuser. It says "operation not permitted". Tried remounting it with no luck. Tried in twrp and it said the same message. I'll try and modify the files one by one now.

---------- Post added at 01:17 AM ---------- Previous post was at 01:12 AM ----------

Well s*** I think I just blew my imei. I modified /proc/config and now my imei is 00000000000000000 and so on. I do have a couple backups so I'll try and restore.

Although I would like to mention that my imei is still fine in the settings screen... But in the bootloader barcode its 00000000000000. So my phone is still pretty much intact and this experiment proved that /proc/config is only used for the bootloader barcode.

Edit: I popped my sim in and it still works fine. I just screwed up the bootloader imei, and now it wont let me change it back. I'll probably look into it later.... Not that big of a deal.
[Moto G Q&A, Help & Troubleshooting] Tosgaba:
I tried that before but no success :(

but once again i will try it and tell the result.

BTW yesterday i checked hob, dhob and fsc for any sign of imei in hex editor but there was nothing about it.

Then i unpacked an EFS backup and load every file into hex editor and searched for imei one by one.

Only utags and utagsbackup files are holding imei info.

One more thing i realized is, in nv backup imei is written different from the one in utags.

Both of them are in hex format but different ways.

Do you have any idea why they are different?

I did what you said but no chance of writing.

As can be seen on the SS, access is denied :(
[Moto G Q&A, Help & Troubleshooting] rootr:
You need 6 digit SPC unlock code to make permission go away......DFS will generate that 6 digit code....its I guess six 0's

Sent from my XT1033
[Moto G Q&A, Help & Troubleshooting] skyguy126:
Can you explain to me what spc and dfs are. Sons why the code is 6 zeros.

---------- Post added at 05:37 PM ---------- Previous post was at 05:34 PM ----------

Is you look in an efs explorer there's a mot_hob folder which is read and write protected.
[Moto G Q&A, Help & Troubleshooting] rootr:
SPC code kinda PIN required when accessing radio. DFS is a tool like NV reader except DFS does more than just read/write IMEI. It can modify your bandwidth settings, modem settings etc. I am not any expert but when I used DFS all these settings were there. Better not touch them :)

Sent from my XT1033
[Moto G Q&A, Help & Troubleshooting] Tosgaba:
Hi again,

Today I forced myself to recheck the contents of my nv backup and in the end found the imei address in a hex editor.(the nv backup made by qpst)

Then changed the imei in hex then saved the file.But no success of viewing it in nv viewer.

Re-changed the hex value of imei in a different hex editor (set the viewing mode decimal) then saved it and voila !!!!

Nv items viewer recognised it as usual and i controlled the data of imei and yes it was just the same as it should be.

Next i fired up qpst software download plugin but this time phone did not accepted the spc.

detailed info in the attachments.

I think if we can make the phone accept the spc or send it the correct spc, we can make a move forward and see if we can succeed. [MENTION=6122951]rootr[/MENTION]

Ok buddy today i will try to restore that qcn file with the spc that DFS will tell me, and share the results here.
[Moto G Q&A, Help & Troubleshooting] skyguy126:
The spc will probably be an important date for the company. Try the foundation date maybe.
[Moto G Q&A, Help & Troubleshooting] Tosgaba:
Today i will try the restoring process with the spc provided by DFS Tool again.

I hope we can achieve something.
[Moto G Q&A, Help & Troubleshooting] skyguy126:
Keep us updated :)
[Moto G Q&A, Help & Troubleshooting] bludotos:
Just zip up the config folder and send it over. I still had mine after erase all but some how lost it later. Is yours blank too? Please and thank you

---------- Post added at 06:09 PM ---------- Previous post was at 06:07 PM ----------

Doesn't work. Been there done that. Even backed up my current one and tried restoring. Passed checks but failed to write.
[Moto G Q&A, Help & Troubleshooting] skyguy126:
No mine is fine, but it contains device specific information except the imei which is 0000000 now. But my legit imei is fine so I might be able to provide some more information. But tell me what do you seek in this config folder. The SPC?
[Moto G Q&A, Help & Troubleshooting] Tosgaba:
Hi,

Tried to copy the proc/config folder but couldn't succeed.

What should i do to achieve it?

BTW no success with DFS provided SPC.

Nothing changed :(

Any new ideas?
[Moto G Q&A, Help & Troubleshooting] skyguy126:
The spc is determined by your imei. If the imei is blank that the spc will be 000000. And 000000 is not the correct spc. Try this: http://androidforums.com/threads/guide-get-your-spc-msl-code-easy.487850/

And I myself will try the dfs tool of someone can tell me how to use it to get the spc.
[Moto G Q&A, Help & Troubleshooting] Mac112:
imei 0

Hello. At the outset, let me add that I know little English so I use an interpreter. I have a moto g (xt1032) And my question is whether there is already a solution to the IMEI 0 and problems with coverage ?? Because I have such a problem has just that I used the command erase all and after imeiu. I would add that it undetected fastboot
[Moto G Q&A, Help & Troubleshooting] rootr:
Sorry, no solution as of now

Sent from my XT1033
[Moto G Q&A, Help & Troubleshooting] borzakoff:
Status?
[Moto G Q&A, Help & Troubleshooting] skyguy126:
Busy with finals for the next 2 weeks, I'll be back trying to figure this out after that hopefully. In the meantime try and find the spc code for the moto g. Just experiment with important dates for the company etc... Good luck!

---------- Post added at 06:52 AM ---------- Previous post was at 06:49 AM ----------

You need to use the dd command to extract the process/config folder.
[Moto G Q&A, Help & Troubleshooting] :
Hey, just checking in. I'm in this exact position "fastboot erase all". How are things going? Can I contribute in any way?
[Moto G Q&A, Help & Troubleshooting] bludotos:
Yeah. Extract your /proc/config folder, zip it and upload it here please. Progress is a bit slow due to work and school.
[Moto G Q&A, Help & Troubleshooting] :
Sure, I can do that. I've searched this thread and I'm a little confused at how to extract it. Am I in fastboot or booted up using ADB Debug,

Whats the command?
[Moto G Q&A, Help & Troubleshooting] skyguy126:
Start normally then using adb run: "adb pull /proc/config C:\Users\yourusername\Desktop"

Then upload here.
[Moto G Q&A, Help & Troubleshooting] :
Okay I tried to do this, ADB failed with ALOT of lines. The majority said bad address with one or two permission denied

Here is what I managed to pull (zipped up)
[Moto G Q&A, Help & Troubleshooting] alissonchaves:
Same Problem

I'm having the same problem and will perform tests on other xt1033 as root can be reversed.
[Moto G Q&A, Help & Troubleshooting] Sined_:
Same problem for me, I send you the detailed log if it can helps. I'm using XT1039 with lost IMEI (shown as 0).
[Moto G Q&A, Help & Troubleshooting] skyguy126:
Try and use dd command to dump that partition.
[Moto G Q&A, Help & Troubleshooting] Sined_:
How to do it? I have tried:

C:\android-sdk-windows\platform-tools>adb shell dd if=/proc of=/sdcard/a.txt
/proc: read error: Is a directory
0+0 records in
0+0 records out
0 bytes transferred in 0.001 secs (0 bytes/sec)

On proc or proc/ or proc/config I get the same message
[Moto G Q&A, Help & Troubleshooting] lost101:
adb shell

su

dd if=/proc of=/sdcard/proc.img​
[Moto G Q&A, Help & Troubleshooting] skyguy126:
Don't think /proc/config will help much cause I already tried editing it and ended up just corrupting my bootloader barcodes imei. What we need is the spc or an exploit that can boot a modified radio.
[Moto G Q&A, Help & Troubleshooting] :
It's possible to write the IMEI via a modified radio?? Or you're saying android would pickup and use the IMEI from the modded radio file each boot?
[Moto G Q&A, Help & Troubleshooting] skyguy126:
Both those ideas are valid and should work but the issue is I personally do not know how to decompile, build, and recompile and all that stuff. If someone can do all the background work then I might be able to modify the code and have that certain person recompile it. I would also be willing to test it on my moto g test bench.
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
[MENTION=6122951]rootr[/MENTION]

I made a back up of all the partitions minus the /System /Data /Cache /Boot /Recovery. So far Utags and Utags Backup looks promising..

So start hunting the following partitions

MMCBLK0P8 (Utags)

MMCBLK0P15 (Utags Backup)

Was searching IMEI plus my IMEI number and found that info only in them partitions thus var.

Also looking at Aboot partition via winhex it looks at the utags partition to get the IMEI, device serial number etc.
[Moto G Q&A, Help & Troubleshooting] bludotos:
Yes the bootloader does that. I have info about utags but need to find it again. It was a dead end for me. I have my correct imei on the bootloader barcode thing. I changed that one myself. Doesn't solve the overall issue though.
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
[MENTION=5383643]bludotos[/MENTION] [MENTION=6122951]rootr[/MENTION]

I still have all the reset of the partitions to check. As there is a lot of them including a ssd partition do you want me to make a list if partitions I am seeing with the mmcblk parts to see if your missing one.

Edit: Partition Rip from working phone check yours see if one is missing

PM me if you need anything.
[Moto G Q&A, Help & Troubleshooting] skyguy126:
I may be far off but I compared the partitions from hacktrix2006 to my own and the information is definitely different which means the partitions are device specific. I also noticed something, where it says <id>XXXX<id>, those strangely look like NV variable names.... Someone else take a look please as I am really busy with finals.

EDIT: Can someone decompile the radio and post it here.
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
How does one decompile the radio?? let me know and i will give it a shot. Also my Device is the Xt1039.

With what you just pointed out it might just be device specific. Let me know if you need anything though.
[Moto G Q&A, Help & Troubleshooting] bludotos:
If they are nv values, then they don't have the imei in there. Decompiling the radio is no easy task. I am working on it when I have time.
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
Ok i am glad to be of help either way.
[Moto G Q&A, Help & Troubleshooting] skyguy126:
Nv 550 I think contains the imei, and we have proved that already but it is only writable with the spc code. We need to find a way to extract it and the only way I see is through the radio. Also if someone can extract the default.prop from the kernel that would help also. There is a write protect value stored in it and I want to try and modify it.
[Moto G Q&A, Help & Troubleshooting] bludotos:
I tried seeing what is in dhob but it comes totally blank. There is something there but nothing readable. How was the dhob.img extracted? via dd? or cat?
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
By DD, however i have made another copy via EFS Pro if that will be more handy.
[Moto G Q&A, Help & Troubleshooting] RenZ0R:
My imei is showing 0 now after updating to lollipop manually by using the recovery option and holding the volume key and having update.zip on my sd card, fastboot getvar all still lists my imei etc, is my phone dead now until this problem is solved?
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
Downgrading the firmware correctly might get it back but do not hold me to this i think [MENTION=1006674]lost101[/MENTION] might now what to do better then myself.
[Moto G Q&A, Help & Troubleshooting] lost101:
Before messing with fastboot, I would try this Lollipop ROM first: http://xdaforums.com/showthread.php?p=58079603 - TWRP or CWM required.
[Moto G Q&A, Help & Troubleshooting] skyguy126:
I think I already explained this before but HOB contains encryption keys to decrypt DHOB which contains the imei. (99% sure this is the case correct me if I am wrong)
[Moto G Q&A, Help & Troubleshooting] bludotos:
I'm saying the imei is not in dhob. There is no sign of the imei. Has to be somewhere else. The dhob just has cellular data for the bands. I am going to do more testing on a theory I have. Will get a result hopefully tomorrow.
[Moto G Q&A, Help & Troubleshooting] skyguy126:
Good luck! If you need help I am willing to help out on my moto g as well. If its not the imei stored there then its probably the boot loader unlock codes and such. Try looking at fsc... And also try and find the spc if possible.
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
fsc partition is completely blank mate at least on my XT1039, Looking in motoboot.img which has tz rom sdi aboot and sb1 partitions in it. motoboot.img also has serial and imei mentions in it but nothing of importance.

So that leaves the persist pada padb pds misc kpan modem ddr cid ssd partitions left to look at.

Just checked /proc/config/imei and the files are blank (ascii type raw)

However the /proc/config folder has even a barcode folder as well with the same files..

Now all the files are with permissions r-r-r- and owned but root and group root
[Moto G Q&A, Help & Troubleshooting] skyguy126:
I'll go examine the radio to see any mentions of those partitions. Why I said dhob and hob is because the radio chown and chmods it at boot. There is proof of that in the init scripts. There is no mention of the other partitions.
[Moto G Q&A, Help & Troubleshooting] :
Hi guys, just checking in. I know this doesn't fix this issue but I'm wondering if this is significant;

I flashed stock kitkat (except motoboot since I had converted to GPE).

Rooted, Installed Xposed, installed xposed module IMEI Changer.

Wrote my IMEI in, rebooted, now I have an IMEI. I understand this is just a masker but still, using android only I managed to write my imei. The problem still persists however, when I put my SIM card in, I have data but no calls/texts, which confuses me since my IMEI is technically correct
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
Its just a mask hence why its not working. If its like the galaxy s3 it might be as easy as a qcn dump and write it back after fixing the imei.
[Moto G Q&A, Help & Troubleshooting] Tosgaba:
I think we have to find a way to learn the spc which required by QPST, then write changed NV items.
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
You can dump and restore via qcn. You can edit via qcn view too. Just a thought
[Moto G Q&A, Help & Troubleshooting] Tosgaba:
Alreay tried that but dead end :(

QPST rejects default "000000" spc code.It does not allow us writing NV items.
[Moto G Q&A, Help & Troubleshooting] Mac112:
tatus

Status ??? Radio kernel http://xdaforums.com/showthread.php?t=2649763
[Moto G Q&A, Help & Troubleshooting] skyguy126:
I'm starting to think this might not be a software fix but then again software is the one that erased the imei in the first place.
[Moto G Q&A, Help & Troubleshooting] ol_st:
Friends, has some of you communicated with the Motorola Support Service? Whether they were successful with the resolving such kind of an issue without changing the device?
[Moto G Q&A, Help & Troubleshooting] bludotos:
I dont think Motorola will give us information since changing into is illegal.
[Moto G Q&A, Help & Troubleshooting] :
Hey, I did try Motorola Software support a week or so ago, I never posted because they were pretty useless.

I explained the specific problem to the chat guy, and specifically what I needed/ needed to to. He ended up emailing me a link to their bootloader unlocking page ;/
[Moto G Q&A, Help & Troubleshooting] bludotos:
Thats because the motorola unlocking page is public. Motorola allows us to unlock our bootloaders with the understanding that we void our warranty.
[Moto G Q&A, Help & Troubleshooting] hacktrix2006:
Still no wiser. I thought the modem partition was the key but it looks like its not as that is flashed with NON-HLOS.bin so scratch that.

So what we know is motoboot.img (Which has Bootloader partition) is flashed along with also NON-HLOS also the fsg partition gets flashed. Modemst1 and 2 along with cache and userdata gets erased.

Does anyone know how to open NON-HLOS.bin so we can see what partitions are missing in that file?