Quantcast
Channel: Mining — Ethereum Community Forum
Viewing all articles
Browse latest Browse all 10806

Rom checksum fix

$
0
0
Hi,
these days, finding and reading a lot of info over various forum, i believe i've discovered a simple way to fix the checksum on modded rom.

I searched a lot over the web but at the moment i was unable to find a tools to properly modify and fix the checksum on the rom. (note 1)
In fact, it's often fairly easy to find info of some basic mod to do, but the one big problem you will face when changing anything in the bios is that the checksum changes.
Of course, force flashing the bios is easy with AtiFlash.exe -f option but it's not the right solution (IMO).

The theory

What the bios checksum is and how it is calculated

Some people may think that the checksum value is stored somewhere in the bios file, this is not our case.
The checksum is actually derived from adding all 2 digit HEX codes of the rom file together. (note 2)

After you have changed some values in the bios you will notice that if you recalculate the checksum, it changes too.
Luckily this is easy to fix because the bios has a number of "useless" bytes at the end just for this purpose.
Normally this "useless" pieces of data looks something like this (u can find the last byte of this area at offset 0xE5FF):

FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF
FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF
etc.
or
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
etc.

When changing data in a rom file the resulting checksum will either be lower or higher than original.

The practice

Okay now you know the theory. I will try to explain the way to do it. WARNING, before you make any changes to the bios you should write down the original checksum!

1.) Get the original checksum with HxD or AtiFlash.exe -cf (note 3)
2.) Edit whatever you want to change in the rom
3.) Calculate the new checksum as in step 1
4.) Use the windows calculator in programmer mode set to "HEX" to calculate the difference between the two checksum by subtracting one from another.
5.) Lower or up all necessary HEX codes (in the "useless area") according to the difference you have found. (note 4) (note 5)
6.) Verify if the new checksum match the original one
7.) Save the new file. Done!


Note 1 : PBE fixes the checksum by changing the hex value at offset 0x0021 but if u compare the result with AtiFlash.exe or HxD differs from the original rom checksum
Note 2 : ONLY the first E5FF Hex codes of the rom file are involved in the checksum calc (i don't know why)
Note 3 : with HxD u must select ONLY the block from 0x0000 to 0xE5FF and then calc the 16 bit checksum on that selection
Note 4 : example ->
  • increase the VDDC voltage offset (8D) from 37,5mv (0x06) to 62,5mv (0x0A)
  • original checksum 0x6900
  • write 8D 00 0A 00 instead of 8D 00 06 00 in the correct area
  • new checksum 0x6904
  • difference (in HEX): 6904-6900=4
  • Write FB (FF-4) instead of one FFs at your choice in the "useless" area
Note 5 : If the difference is lower and the "useless area" ends with all the FFs there is no way to correct the checksum using this area (as you know FF is the biggest double digit HEX value). In this case you need to edit another part of the bios.

------------------------------

Do you think I've only discovered the hot water? :p
Are these information correct? Any corrections or suggestions would be greatly appreciated.

A.

Viewing all articles
Browse latest Browse all 10806

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>