SNES Checksum calculation.

General area for talk about ZSNES. The best place to ask for related questions as well as troubleshooting.

Moderator: ZSNES Mods

Post Reply
KingMike
Rookie
Posts: 41
Joined: Mon Jun 02, 2008 6:38 am

SNES Checksum calculation.

Post by KingMike »

So, out of curiousity, I dumped my Slapstick cart with a tototek dumper. It dumped a 2MB ROM. I noticed it had a different CRC (FDF11B50) than the existing GoodSNES CRC (53FB163B).
So I read Slapstick/Robotrek's proper size is 1.5MB.
I cut off the last 512KB, then it results in the same CRC as the existing dump.
So, 16mbit is just a sum of all bytes in the ROM.
12 mbit is a sum of (first 8mbit) + ( (last 4mbit) x 2 ).
If the last 4mbit (0x180000-0x1FFFFF) of a 16mbit ROM is physically identical to the preceeding 4mbit (0x100000-0x17FFFF), shouldn't that 16mbit sum produce the same CRC as the 12mbit?
Deathlike2
ZSNES Developer
ZSNES Developer
Posts: 6747
Joined: Tue Dec 28, 2004 6:47 am

Post by Deathlike2 »

Think about it. The answer is no. Even if that data is padded, it's factored into the CRC check. That's why it fails.
Continuing [url=http://slickproductions.org/forum/index.php?board=13.0]FF4[/url] Research...
grinvader
ZSNES Shake Shake Prinny
Posts: 5632
Joined: Wed Jul 28, 2004 4:15 pm
Location: PAL50, dood !

Post by grinvader »

Calculate it manually with a 16-byte example similar to your data, i.e.

AaaaaaaaBbbbBbbb

8 + 4 (mirrored to 16).

and compare with

AaaaaaaaBbbb
皆黙って俺について来い!!

Code: Select all

<jmr> bsnes has the most accurate wiki page but it takes forever to load (or something)
Pantheon: Gideon Zhi | CaitSith2 | Nach | kode54
Post Reply