From 57f2833322b1d28b73e8a8c588630dc2de9042a6 Mon Sep 17 00:00:00 2001 From: sanni Date: Sun, 16 Oct 2022 14:51:15 +0200 Subject: [PATCH] Update MD.ino --- Cart_Reader/MD.ino | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Cart_Reader/MD.ino b/Cart_Reader/MD.ino index 3498fcf..82464f1 100644 --- a/Cart_Reader/MD.ino +++ b/Cart_Reader/MD.ino @@ -12,6 +12,7 @@ int eepSize; word addrhi; word addrlo; word chksum; +boolean is32x = 0; //*********************************************** // EEPROM SAVE TYPES @@ -673,6 +674,11 @@ void getCartInfo_MD() { cartSize = ((long(readWord_MD(0xD2)) << 16) | readWord_MD(0xD3)) + 1; + if ((readWord_MD(0x104 / 2) == 0x2033) && (readWord_MD(0x106 / 2) == 0x3258)) + is32x = 1; + else + is32x = 0; + // Cart Checksum chksum = readWord_MD(0xC7); @@ -1372,7 +1378,7 @@ void readROM_MD() { } // Calculate and compare CRC32 with nointro - if (readWord_MD(0x105) == 0x3332) + if (is32x) //database, crcString, renamerom, offset compareCRC("32x.txt", 0, 1, 0); else