[HOWTO] [ROOT] Reset Flash Counter [Confirmed VZW, Assumes others are the same]

Search This thread

minmongoblin

Senior Member
Jun 15, 2010
274
35
I'm probably woefully ignorant, but what's the harm in tripping the counter? What happens if I don't reset it?
 

eschelon

Retired Recognized Developer
Jun 20, 2009
1,388
8,954
I'm probably woefully ignorant, but what's the harm in tripping the counter? What happens if I don't reset it?

Because any count over 0 voids your warranty.

This is helpful for when your phone has suffered some form of hardware failure (say, for example, the volume rocker becomes defective). This was obviously not caused by a custom ROM, but Samsung would refuse to repair it if you took your phone into them and they saw you had a positive flash count.

It's a fine line to walk, but it's helpful for times when there is legitimate hardware failure that should be replaced under a warranty claim that would otherwise be denied if you had a flash count >0.

Does this clear the Samsumg Custom bootscreen with the white unlocked padlock?

Possible, although unlikely as the custom "unlocked" icon comes from flashing a custom recovery.
 

eschelon

Retired Recognized Developer
Jun 20, 2009
1,388
8,954
ODINing the stock ROM package clears that away, though, right? (Of course it means losing custom recovery...)

As far as I understand, a flag is being flipped in the bootloader which causes the "unlocked" padlock to appear. By flashing the tars we have now via odin, it does not flash the bootloader, only /system/ so the flag remains.

That "unlocked" icon will likely be there until the smart guys in the room figure out a way around the locked bootloader.
 

Jiggity Janx

Senior Member
Feb 19, 2010
1,397
286
As far as I understand, a flag is being tripped in the bootloader which causes the "unlocked" padlock to appear. By flashing the tars we have now via odin, it does not flash the bootloader, only /system/ so the flag remains.

That "unlocked" icon will likely be there until the smart guys in the room figure out a way around the locked bootloader.

In Adam's OP are the bootloader and pda to flash. After flashing these and performing a data/cache wipe you will not have the Custom unlock showing. Performed this just last night.

*Just for FYI. He added them yesterday afternoon I believe.
 

preusstang

Senior Member
Jan 13, 2011
276
97
Possible, although unlikely as the custom "unlocked" icon comes from flashing a custom recovery.

Hmm. Idk. I had the unlocked icon when I was running rooted stock rom with cwr touch, but it went away after flashing the kexec cwr and the one kernel with b00stedass gov.

Strangely, I get the unlock icon - even if the phone is completely stock - anytime I boot into download mode (I think). I've done it on accident a few times.. never noticed the counter before tho.
 

SQFreak

Member
Apr 17, 2008
39
10
Rockville, Maryland
In Adam's OP are the bootloader and pda to flash. After flashing these and performing a data/cache wipe you will not have the Custom unlock showing. Performed this just last night.
Is the bootloader dump separate from the stock ROM at http://xdaforums.com/showthread.php?t=1755386, or will flashing that stock ROM also take the bootloader back? I had a custom recovery and flashed a different one, and suddenly I have an unlocked icon. The flash counter is still at 0 though. I tried flashing back to stock recovery and that didn't work.
 

Hypnosis4U2NV

Senior Member
Nov 23, 2010
465
196
New York City
Possible, although unlikely as the custom "unlocked" icon comes from flashing a custom recovery.

I ran the app and nothing happened, either after running it and after I rebooted.. Unlocked icon still remains, which is why I asked if it would work..

I think that's more important than the flash counter for us Verizon users since most of us aren't flashing any custom ROMs yet other than stock ones which are rooted and/or debloated/deodexed and zipaligned.. Imagine returning a phone with that custom screen boot screen.. Yikes..

Sent from my Commodore 64..
READY.
load"*", 8,1
 

Noxious Ninja

Senior Member
Jul 9, 2010
650
425
Dallas, TX
Is the bootloader dump separate from the stock ROM at http://xdaforums.com/showthread.php?t=1755386, or will flashing that stock ROM also take the bootloader back? I had a custom recovery and flashed a different one, and suddenly I have an unlocked icon. The flash counter is still at 0 though. I tried flashing back to stock recovery and that didn't work.

I think the bootloader dump is separate from the boot.img in the ROM. The PDA package in Adam's post is the ROM from the stock ROMs thread. I believe they're meant to be used together if you really, really need to wipe everything.
 
Last edited:

Jiggity Janx

Senior Member
Feb 19, 2010
1,397
286
Strangely, I get the unlock icon - even if the phone is completely stock - anytime I boot into download mode (I think). I've done it on accident a few times.. never noticed the counter before tho.

I tried flashing back to stock recovery and that didn't work.

I ran the app and nothing happened, either after running it and after I rebooted.. Unlocked icon still remains, which is why I asked if it would work

From what I understand you MUST wipe data/cache after flashing to clear the unlock icon. Someone mentioned it in one of the posts (will credit if/when I find).
 

mybook4

Senior Member
Apr 3, 2011
445
267
QUOTE=Noxious Ninja;28991583]I think the bootloader dump is separate from the boot.img in the ROM. The PDA package in Adam's post is the ROM from the stock ROMs thread. I believe they're meant to be used together if you really, really need to wipe everything.[/QUOTE]

Yes, boot.img is the kernel. Contains a 2KB header, the kernel, then a gzipped ramdisk (initialization files). In our case the boot.img also contains a signature that is checked by the bootloader (the reason we can't run custom kernels from the default boot.img partition (mmcblk0p7). For anyone interested in learning more, I recommend googling mkbootimg.c and bootimg.h. This is the C program used to package a kernel/ramdisk into the boot.img form. I recommend reading this small program while having the stock boot.img open in a text editor (to follow along).

The bootloader consists of several partitions on the gs3. I forget all of them, but opening Adam's bootloader tar will show what partitions belong to the bootloader on the gs3. The first page of Adam's post also has each mmcblk listed with a name associated (for most of them). The list of the files in the bootloader tar can be matched to the mmcblk locations.

Note: We may be able to flash the bootloader tar in Odin if your phone is working (haven't tried it), BUT if your phone isn't booting correctly (i.e. you messed around with one of the bootloader partitions) it may never get to a state that would allow Odin to work. I'm not positive about this, but better to be safe.

Sent from my SCH-I535 using xda app-developers app
 

cortland1998

Senior Member
Jan 2, 2008
409
26
What is this Flash Counter I am reading about in forums? I've been on iOS for a few years, until this sexy S3 came out. I'm not familiar with Flash Counter... Thanks
 

Top Liked Posts

  • There are no posts matching your filters.
  • 35
    So, you managed to trip the flash counter.

    Here are the commands to reset the flash counter. This works on my VZW rooted phone. Since all of the other variants have a very similar (same?) partition setup, this "might" work for them as well ("might" is the key word).

    I take no responsibility for you voiding warranty.

    I used this post as the basis for my theory and then used my phone as the test for said theory: http://xdaforums.com/showpost.php?p=28953690&postcount=67

    The "'\x00'" portion tells it what resets it to 0. If you wanted to be funny, you could set it to a different number.

    adb shell
    su
    echo -n '\x01' | dd obs=1 count=1 seek=4193796 of=/dev/block/mmcblk0

    I can only confirm that this works on the VZW variant. Until I get some dumps of the other variants, I can only assume it will work for them.

    TRY AT YOUR OWN RISK!!!!
    3
    Confirmed it works on AT&T. Counter from 1 to 0.
    2
    As far as I understand, a flag is being tripped in the bootloader which causes the "unlocked" padlock to appear. By flashing the tars we have now via odin, it does not flash the bootloader, only /system/ so the flag remains.

    That "unlocked" icon will likely be there until the smart guys in the room figure out a way around the locked bootloader.

    In Adam's OP are the bootloader and pda to flash. After flashing these and performing a data/cache wipe you will not have the Custom unlock showing. Performed this just last night.

    *Just for FYI. He added them yesterday afternoon I believe.
    2
    Actually Chainfire just released v1.70 of Triangle Away today that resets the counter on the US/Canadian variants. Not sure if he used the same method as the OP here, but thanks for your research into this as well!