Need help dumping SA1 Chip games

Discussion of hardware and software development for Super NES and Super Famicom. See the SNESdev wiki for more information.

Moderator: Moderators

Forum rules
  • For making cartridges of your Super NES games, see Reproduction.
Tamanegi_taro
Posts: 25
Joined: Sat Dec 12, 2015 3:47 am

Need help dumping SA1 Chip games

Post by Tamanegi_taro »

Hi all,
Thanks for looking at this post.
I'm trying to find way to dump SA1 chip SNES cartridge as easy as possible.

Long time ago, I found way to dump SNES games using Arduino in this website(http://hongkongarduino.web.fc2.com/).
Finally finished soldering of this Arduino shield today and successfully dumped some games.
Image
This is very similar to CART_ROM_Reader which I can find it here:http://forum.arduino.cc/index.php?topic=158974.0

But I have one problem. I cannot dump any of SA1 chip games because this dumper do not support any of special chip games.
Searched through websites and I think I found way to dump SA1 games by using SuperCIC or SnesCIC and 21.477MHz clock to pin 1 according to these articles by skaman http://forum.arduino.cc/index.php?topic=158974.30
viewtopic.php?f=12&t=8617&start=15
Unfortunately, I do not have PIC writer nor any chip compatible with SuperCIC or SnesCIC.

So my questions is, is it possible to dump SA1 games by pulling out cables from actual SNES console and connect GND, pin 1(21.477MHz clock), pin 24(CIC out data p1), pin 25(CIC in data p7), pin 55(CIC out data p2), and pin 56(CIC in clock p6) to dumper's corresponding pins?
I think this will work by power up dumper+cartridge first than console next to unlock CIC...
Or should I buy PIC writer and make SuperCIC or SnesCIC?

Thanks,
Tamanegi
User avatar
whicker
Posts: 228
Joined: Sun Dec 13, 2009 11:37 am
Location: Wisconsin

Re: Need help dumping SA1 Chip games

Post by whicker »

Buy the writer and chip, or buy a pre-programmed chip from someone else, I guess.
Tamanegi_taro
Posts: 25
Joined: Sat Dec 12, 2015 3:47 am

Re: Need help dumping SA1 Chip games

Post by Tamanegi_taro »

Thanks!!!!
I'll go buy PIC programmer and clock generator.
User avatar
bazz
Posts: 476
Joined: Fri Sep 02, 2011 8:34 pm
Contact:

Re: Need help dumping SA1 Chip games

Post by bazz »

SNES Tutorials (WLA DX)
SNES Memory Mapping Tutorial (Universal / LoROM) -- By Universal I introduce how memory mapping works, rather than just provide a LoROM map.
SNES Tracker (WIP) - Music/SFX composition tool / SPC Debugger
Near
Founder of higan project
Posts: 1553
Joined: Mon Mar 27, 2006 5:23 pm

Re: Need help dumping SA1 Chip games

Post by Near »

It definitely can, but for now you'll have to make it yourself, or find someone who can, based on all the source and schematics that are freely available.

I'll be posting my dumper software for it online once it's ready. It'll also be the only dumper in the world to extract real memory mapping information for each game, as well as firmware whenever possible (no SGB boot ROM or NEC uPD program ROMs.)
Tamanegi_taro
Posts: 25
Joined: Sat Dec 12, 2015 3:47 am

Re: Need help dumping SA1 Chip games

Post by Tamanegi_taro »

Hi byuu!!

I guess you are developer of super awesome bsnes(Higan) emulator!

Anyway, I successfully added snesCIC and 10MHz/3MHz clock generator to this hongkong dumper.
Successfully unlocked CIC but...

I'm trying to dump Super MARIO RPG and Kirby super delux.(Both are Japanese snes games with SA1 chip + LoROM inside)
I can see its unlocked because I can dump first 2MB of game.
But if I try to dump last 2MB of game, its always getting corrupted.

Extracted some codes from hongkong dumper developed by Taniyama.
This will read out 4MB of data.

Code: Select all

      for (unsigned long i = 0; i < datasize; i++, address++) {
        setAddress(address, isLoROM);
        readData();
      }
and to set address and read data:

Code: Select all


void setAddress(unsigned long address, int isLoROM)
{
  if (isLoROM) {
    unsigned long upper = address / 0x8000;
    unsigned long lower = address % 0x8000;
    address = upper * 2 * 0x8000 + lower + 0x8000;
  }

  byte a[3];

  a[0] = (byte)(address >> (8*0));
  a[1] = (byte)(address >> (8*1));
  a[2] = (byte)(address >> (8*2));
  
  outCh(0, a[0]);
  outCh(1, a[1]);
  outCh(2, a[2]);
}

void readData()
{
  setDataDir(INPUT);
  digitalWrite(GD, LOW); // Ch Enable

  byte b = 0;
  for (int i = 0; i < 8; i++) {
    if (digitalRead(DATA0 + i) == HIGH) {
      b |= (1 << i);
    }
  }

  digitalWrite(GD, HIGH); // Ch Disable
  setDataDir(OUTPUT);
  
  Serial.write(b);
}

LoROM bank/address calculation seems correct.
I dont know what else to do.
I would be very appreciated if you could provide some advice.

Thanks,
Tamanegi
Tamanegi_taro
Posts: 25
Joined: Sat Dec 12, 2015 3:47 am

Re: Need help dumping SA1 Chip games

Post by Tamanegi_taro »

Hi bazz,

Thanks for comment!
That 21FX look good too but i dont know if I can get one of those.
Tamanegi_taro
Posts: 25
Joined: Sat Dec 12, 2015 3:47 am

Re: Need help dumping SA1 Chip games

Post by Tamanegi_taro »

Thanks!
These games were HiROM and HiROM start from C0 bank!
Successfully dumped SA1 games.
skaman
Posts: 88
Joined: Fri Oct 24, 2014 1:56 am

Re: Need help dumping SA1 Chip games

Post by skaman »

Congratulations!
Tamanegi_taro
Posts: 25
Joined: Sat Dec 12, 2015 3:47 am

Re: Need help dumping SA1 Chip games

Post by Tamanegi_taro »

Hi skaman,

Your article about snesCIC in Arduino forum helped me a lot!
Successfully dumped all my SA1 games but my Kirby super deluxe only gets recognized once in 100 times.

I first added 1ms wait between supplying clocks from clockgen and releasing snesCIC reset just to make sure clock is supplied to sneaCIC out of reset but some game do not unlock CIC but some game do.
Removed delay and found that most of games got recognized.
One game, Kirby super deluxe only got recognized after 100 tries althogh snes console boot the game 100% of the time.

I'll try your arduino mega 2560 rom dumper to get more stable dumper and to dump my NP cart.
Planning to make arduino dumper shield using universal boards so need to solder lot of cables...


Thanks,
Tamanegi
skaman
Posts: 88
Joined: Fri Oct 24, 2014 1:56 am

Re: Need help dumping SA1 Chip games

Post by skaman »

I have one cart, PGA Tour 96, that does the same thing. I've dumped it multiple times but it is a hard cart to get locked. What is interesting is that I have multiples of that cart both Rev 1.0 and Rev 1.1 and all of the other carts work.

Check your dumps because you might find a new revision of an SA-1 cart since they were so hard to dump. My dump of PGA Tour 96 Rev 1.1 was a previously unknown dump.

Good Luck!
Tamanegi_taro
Posts: 25
Joined: Sat Dec 12, 2015 3:47 am

Re: Need help dumping SA1 Chip games

Post by Tamanegi_taro »

Hi skaman,

My Kirby super deluxe game has version 1.2 in its header.
I guess this is very new one compared to other SA1 games.
I have 4 SA1 games and other 3 gets recognized almost 100%.

Will be trying again with new MEGA2560 dumper once I get soldering done.

Thanks,
Tamanegi
Tamanegi_taro
Posts: 25
Joined: Sat Dec 12, 2015 3:47 am

Re: Need help dumping SA1 Chip games

Post by Tamanegi_taro »

Finished soldering of MEGA2560 Nintendo dumper.
Successfully dumped normal games without SA1 chip and Nintendo Power cart but unable to get CIC to unlock for all SA1 games.
Hongkong + snesCIC do unlock Super Mario RPG almost 100% but MEGA2560 cannot unlock it.

Trying to find out what is wrong. I confirmed that all wires from snesCIC and Clock GEN are connected correctly.
What else should confirm?

Edit:
I had 5V connected to clock gen so I modified my circuit and replaced clock gen to new one. still do not work...

Thanks,
Tamanegi
skaman
Posts: 88
Joined: Fri Oct 24, 2014 1:56 am

Re: Need help dumping SA1 Chip games

Post by skaman »

It is probably some type of timing issue.

What version of the reader and which sketch are you using?
Tamanegi_taro
Posts: 25
Joined: Sat Dec 12, 2015 3:47 am

Re: Need help dumping SA1 Chip games

Post by Tamanegi_taro »

Hi skaman,

I'm using sanni's Nintendo Cart Reader for Arduino Mega2560.
https://github.com/sanni/cartreader/

Since I don't have SD card reader, Arduino fruit clock generator, nor graphical display, I modified code around so I can use dumper without 3 modules.
To remove SD card reader and Graphical display, I modified the code so all the dumps and messages are sent by Serial with baud rate of 115200.
To remove Arduino fruit clock generator, I used Si5351 clock gen https://strawberry-linux.com/catalog/items?code=15351 and I2C level conversion modulehttp://akizukidenshi.com/catalog/g/gM-05452/.
Here is manual for clock gen:https://strawberry-linux.com/pub/si5351a-manual.pdf but I don't know if you can read it becaus e it is all in Japanese.

Si5351 requires two VDD supply as VDD and VDDO, I connected 3.3V to both of them with two 0.47uF capacitors each between each sources and GND.

What I did so far is:
Disable BOD of snesCIC - Didn't work because BOD voltage is like 2.1V typical and 4.90V - 5.00 is supplied into snesCIC.
Check connections between snesCIC/ClockGen and socket/Arduino - Connections are identical to hongkong+CIC but still didn't work.
Check voltage applied to snesCIC and ClockGen - Fixed circuit. I can also see some waveform coming out from CLK0 and CLK2.
Replace clock gen source code to original ClockBuilder Desktop - didn't work.
Replace clock gen module and snesCIC IC to one used in hongkong+CIC - didn't work.

Todo:
Look into CLK0 and CLK2 waveform using oscilloscope. - There might be difference between hongkong+CIC dumper and Arduino MEGA dumper.
I attached one 0.47uF capacitor between ClockGEN VDD/VDDO and GND for hongkong+CIC dumper but attached two 0.47uF capacitors for Arduino MEGA dumper so there might be difference in waveform shape.
Check pin status difference between hongkong+CIC dumper and Arduino MEGA dumper - There might be slight difference.

Thanks!
Tamanegi
Post Reply