[Guide] How to flash a modded AMI UEFI BIOS

I doubt, that your previous problem has been caused by the UBU tool. The older UBU versions worked fine as well.

That is fine and the only really important thing.

With ASUS P8H77M-PRO BIOS 1505 it doesnt working.
Modified 1505 BIOS with ATASX (ata-security), but flashing this modified BIOS is not possible.

Tested with 8192 KB BIOS (without first 2048 Byte capsulate) and with 8194 KB BIOS files.

1. AFUDOS/AFUWIN v5.05 does not work, even with /GAN command. /GAN command produce no error message like without, but it does not erase and flash BIOS, at the end of process it writes "flash successful" but it is not true, if i read the BIOS and compare, it is the same like before. Without GAN command, security check fails.

2. ASUS EZ Flash 2 Tool in BIOS/UEFI does not work. Security check of modified BIOS failed.

3. SCEWIN does not work, bring some errors with Hii.db

So i tried to flash the oldest ASUS P8H77M-Pro BIOS i found with afudos, because EZ Flash 2 told me that BIOS is outdated and not supported. Flash with afudos was done without errors. But now mainboard is bricked and doesnt boot anymore (resets every 10 seconds).


So i tried to flash Winbond 25Q64BVAIG in my old Willem LPT Programmer v3.01 (2002), it can read but not flash… i measured about 2Volt on VCC of Winbond, so i put an external voltage of 3,3-3,6V, but still no luck to flash. If i flash 10% and cancel, then read and verify is ok for 10%. If i flash completely to 100%, then Winbond is empty if i read and verify (FF).

So i ordered now a cheap USB Programmer (CH341A) for 3 USD. Maybe more luck with this one.

For restoring the Winbond i maybe can do a hot flash in a second Mainboard. But i want this modified BIOS.

Is it possible to flash a BIOS file from Asus website with external programmer, and it will work? Are mainboard specific data not stored in BIOS, like serial number? I know that in Xbox360 you can not just flash BIOS, you have first put Serial-Number, CPU-key, and other device specific data in BIOS file, before flashing.


No, but you can make a file suitable for flashing from ASUS factory CAP file using FD44Editor.

@ lowicunr:
Welcome at Win-RAID Forum!

That is a really bad result.
I recommend to follow CodeRush’s advice.

Good luck!
Dieter (alias Fernando)

Thank you! Great tool. So it was a good idea to make a bios-backup before flashing :slight_smile:
I will try it, as soon as i got my CH341A USB Programmer. Hope this cheap programmer is working. No matter why my old Willems Programmer do not want to flash, but can read.

Edit:
there is a easy and cheap DIY lpt spi programmer:
http://rayer.g6.cz/elektro/spipgm.htm

But i want no lpt anymore, its too slow… Willem lpt progarmmer need abot 20min to flash the 8MB Winbond. And CH341A USB Programmer costs only 3USD incl. shipping.

You can use a EZP2010 programmer (or JHW2013). I have the JHW2013 USB and it supports both CAP and BIN files.

Thanks, EZP2010 and JHW2013 programmer for 20 USD seems to be the same like the 3 Dollar programmer CH341A USB Programmer (search at Ebay and Amazon). So i will first try with CH341A, because it is much cheaper :slight_smile:

Today i managed my old Willem 3.1 programmer to work and was able to flash Winbond 25Q64.
I had to disconect and connect power after each read and write, and allways click onto ID icon before write, to see if Device ID is recognized correctly.

It works fine now, computer is booting again! And my ASUS P8H77-M Pro now does have ATA-Security support, so i can use self-encripted SSD with ATA-Password.

See also this thread, for ATA Security eXtension (ATASX):
Adding ATA Security Extension to UEFI BIOS via PCI Expansion ROM

Hello World!
I just want to share my experience with flashing a modded BIOS to a ASUS P8H77-I mainboard.

I was using the current newest BIOS version 1102 and wanted to update the Intel RST part of it for RAID usage. In the original BIOS the RST ROM is version 11.x and I modified the BIOS using the great UBU (Uefi Bios Updater) tool described in this thread. Thanks to LS_29/SoniX for this great tool and Fernando for posting infos/guides for it.
So I updated the BIOS file with the Intel RST 13.1.x (recommendation for 7-series chipsets by Fernando) and while I was at it also updated CPU microcodes. Since I don’t overclock on that board (which isn’t designed for that anyway) I chose the latest microcode revision to get the best support for any CPU I might throw at that board.

You might do all that with MMTool too but UBU is way easier.

Good, so I went on and tried to flash the modded BIOS file. Using EZ-Flash rejected the BIOS file as I was expecting. AFU (AFUDOS) with the /P /B /K switches using this guide did not work giving me the “Security verification failed” message.
The /GAN switch didn’t work either telling me that this switch is unknown/does not exist.
So I downloaded an older AFUDOS version found here since the newer versions have the /GAN switch removed as it seems.
With that version I got a sucess reply on all operations. But as I found out on the next reboot the BIOS was still the old one so the AFUDOS /GAN didn’t work.

So I went on to another tool called FTK (FlashToolKit) developed by CodeRush/NikolajSchlej found in that forum thread at hardforum.com. Thanks to CodeRush for that amazing toolkit by the way!
The toolkit enables you to backup and flash parts or the full set of the BIOS as well as the ME part of it. It also copies information from the specific board (serial number/MAC adress/ …) to the new BIOS file you want to flash. Great toolkit, that you have to use carefully.

I renamed the modified BIOS created with UBU to bios.bin and copied it to the FTK folder. I used the DOS version and the FTK8 version. I guess the FTK<version> refers to the ME version used by the current BIOS file because version 7 (that I assumed would be the one I want because of my H77 chipset) told me that it isn’t designed for my system as well as the version 10 and 9 did.
The “reflash” command backed up my BIOS, copied the infos from the backup to the bios.bin and tried to flash it. But ended with a message “Error 280: Failed to disable write protection for the BIOS space”.

I then found out that ASUS seems to have included a write protection in their newer BIOS versions and my version 1102 was one of them. I read an advice to downgrade the BIOS first using the BIOS Flashback function of the mainboard but my mainboard doesn’t have that feature. The other way was to use a hardware flash programmer that I don’t have / didn’t want to buy.

I almost gave up until I just tried to flash a older original BIOS using the EZ-Flash option of the mainboard. It worked! The board let me downgrade to version 0814 (I think that was the version my board shipped with, but it was just a wild guess). Then finally I could flash the modified BIOS with FTK!

Thank you all (Fernando, CodeRush, SoniX, and all people helping by) posting their findings and guides and providing these great tools about BIOS modding and flashing!
Maybe my struggle with my board helps other people too.

@ Bucho:

Thank you very much for your detailed report about how you got the modded BIOS successfully flashed into the BIOS chip of your ASUS P8H77-I mainboard.
This will be a big help for other users, who have a similar problem.

Enjoy your successfully updated BIOS!
Dieter (alias Fernando)

FIY, @plutomaniac has posted the whole package which contains AFUDOS/Win32/Win64 v3.06.01 (latest with “hidden commands” like /GAN) in [Guide] Flashing modified AMI Aptio UEFI using AFU (2)

The latest from AMI seem to be 3.07.01 if you download the tools directly from their website. But I haven’t checked if the /GAN command is still an option.

https://ami.com/ami_downloads/AMIBIOS_an…ate_Utility.zip

No, it isn’t alas (in changelog of v3.07.00 : “disable all hide commands”)
That’s why I made a link to your post cause mediafire links tend to disappear sometimes.

Ah, I see. Thx for the tip, I didn’t know that. Personally I find FPT better for Intel systems either way. I’ll keep a copy of these tools now that I know they were the last with /GAN. CodeRush has said from time to time though that these hidden commands are unreliable or maybe dangerous for some systems. Just pointing that out for future reference.

I went through that AFU story in my post above, but didn’t mention die version numbers.
The latest AFU versions have the /GAN switch removed, and die 3.06.01 has the switch but even tho it states that the flash was sucessful, it didn’t do anything on my P8H77-I with latest BIOS (that seems to have a write protection). Glad that it didn’t do any dangerous stuff to my board.

Will this guide work for the Supermicro X9SAE board, which has a C216 chipset to add NVME? Or does it already support NVME out of the box? Is the X9SAE Aptio 4 or 5? Thanks.

@ guho 2003:
Welcome at Win-RAID Forum!

The guide about how to get full NVMe support for older Intel Chipsets is >here<.

Open the BIOS by using the AMI Aptio UEFI tool named MMTool and look for an NVMe module.

I suspect, that it has an AMI Aptio 4 BIOS.

Regards
Dieter (alias Fernando)


Is it absolutely necessary for the USB flash drive to be empty? What happens if it contains other files along with P9X79.CAP? It will not be flashed or all the data on the usb drive filesystem will be destroyed? Has anyone tried? ASUS official guide doesn’t state this explicitly, it just says we should place the file in the root directory.

It may not be absolutely necessary, but it definitively is the safest method (to avoid flashing a wrong BIOS file).
By the way: Just for this special task (BIOS flashing) I always use the same very small sized USB 2.0 Flash drive.

@Fernando

You should include a tutorial for Gigabyte users. For Gigabyte Skylake motherboards, I had to use @lordkag modded efiflash and format the USB with FreeDOS. Here’s lordkag’s modded efiflash: Flashing Gigabyte while avoiding “Invalid BIOS image”