Tuesday, February 26, 2008

PC10 misc

The PC10 apparently uses a standard edge connector, in particular a 3x32 male eurocard connector. This means I don't need to murder any more game paks to make a batch of adapters, and as a bonus, a footprint pattern already exists for it in pcb123, 41612 din eurocard. For some reason it calls it a 98 pin connector, but it's not. I guess the artist couldn't count right - or maybe counted the screw holes?

Sourcing NES connectors isn't quite so easy. The pads on a aren't *quite* .100 on center, but I think I'll order a couple of those and see how they fly. Murdering game genies and famicom adapters isn't that odious a concept, though. The wraparound crazy units that the consoles used, and the modern chinese knockoffs aren't really a good idea, they're expensive, and bulky. I think soldered on connectors would just let 10 nes carts squeeze onto one of those boards, but I'll have too measure. If not, maybe I'll design it as a left/right type deal, so the carts themselves would be staggered. Maybe famicom connectors are easier to source.

As for my 'prototype', I'm still having the following problems: I can't run other PC10 boards with my adapter in place, I'll try and address that this weekend. A few games are giving strange glitches, I believe this has more to do with my hacktastic wiring, and games with some very demanding timing, or maybe a lot of DMA transfers from CHR to PRG. I'll try and clean that up a bit when I get a chance and see if it helps.

I'd also really like to crack the nut of the instruction rom and security chip, being able to customize that would be excellent. The chip itself is documented somewhat, and from the schematics it appears to screw around with a couple of the data lines from the eprom. I think it performs a simple on-the-fly decryption of the instruction rom, and maybe sniffing the bus could net me an unencrypted rom, which I could try to burn back (sans chip). This is maybe biting off a little more than I have time to chew, though. Maybe not, we'll see.

I'll try to post something by way of pics / schematic this weekend for anybody who wants one.

Non-inverted video from the PC10

The PC10s PPU, the 2C03B, outputs regular RGB. It is inverted on-board en-route to the monitor.

Since my monitor is on it's last legs, and old Nintendo monitors are selling for as much as a new one from Happ, I'd really like to get regular non-inverted video straight from the board. Inverting it twice is hardly ideal, and surely some signal is lost.

I'm eyeballing the PCH1-CPU Schematic sheet 4 and there's some crazy crap going on, like everything Nintendo did back then this looks a little bit over engineered.

I get out of my depth pretty quick when it comes to looking at a drawing of some op-amps, capacitors, and transistors, and figuring out "what it does", but I think I can tap one of the legs of each 'gain' pot with a small resistor 50-100 ohms and have a usable signal. If all else fails, I can tap the unamplified RGB signals, and build my own amp, following the instructions of folks who've mounted the PPU into a regular old NES.

Also, I think I need to tap the NES's reset line on the PC10 board, to get some games to work properly. I'm thinking that the bus is not initialized the same way it is on a real NES, and on-cart RAM's suffer as a result. Being able to "start" the NES, then reset it, may be the key to all that.

I have a little perfboard leftover, so tonight I'll figure out how I'll mount it, and which signals I want to bring off of the PC10's board. I'll have two NES controller ports, non-inverted RGB video, and reset line. That's 15 pins so far, sounds like a mess in the making.

Monday, February 25, 2008

PC10 NES adapter update

After a nights sleep and fresh attention, the rule of elimination told me which pin was wrong. Castlevania III was working perfectly, and as an MMC5 game it makes good use of CIRAM /CE and CIRAM /A10, so I knew it couldn't be them. Likewise, MMC3 games (SMB3) were working fine, as were most others.

The games not working were all old(er) UNROM games, that use on-cart WRAM, disabling the NES's WRAM. They were all drawing squigglies where the tiles should be, and Duck Tales was actually drawing sprites properly. Suddenly it dawned on me, it can read WRAM, but not write the proper graphics to it, thereby displaying whatever random electrons happened to be stuck in there. Sure enough, CHR /WR wasn't hooked up.

Now everything is working great, for the most part. I'm seeing the odd bit of static, or a line here or there on certain games, but at this point I know it's simply dirty cartridges. All of MY games (the ones I've had since I was a kid) play great, because if I take care of nothing else, I take care of my games.

As a matter of fact, get this, my Adventures of Link cart still has my save game on it! Those batteries have a 5-10 year lifetime, and this sucker is 20+ and goin' strong! I was so clever at 12, to name my character "FARTSO".

Now, if I could only crack that security/instruction EPROM, so the game didn't have to display as Pro Wrestling, with Pro Wrestling instructions. Having it display as "Nintendo", with some sort of Nintendo instruction screen would be cool.

I need some sort of data analyser, I think, even if it's homebrewed. If I could just sniff the "unencrypted" data coming out of it, program that onto a new eprom, and remove the security chip altogether.. it's just crazy enough to work.

It's also probably time to start drawing up some prototypes and see if I can get some pro quality boards fabbed. I'm also thinking a dedicated 60 pin slot for famicom games is in order, so I'm not running some crazy daisy-chain of adapters.

I also ran pin 54 from the expansion port to the PC10s audio line, hoping maybe Castlevania III had buried within it the extra sound hardware the japanese version carries.. It doesn't seem to. Oh well, would have been a neat 20 year old easter egg if I'd found it. It has a pin there, and its wired up internally.. Maybe the PC10 doesn't work right, I should try wiring that up in one of my real NES's.

I got lazy working out the bugs, and wired PRG /CE, CHR /A13 and VRAM /CE straight to the connector, not to the bus driver. Right now it wont work with other game paks on the board (since it's always active on the bus, wackiness ensues when you try to play two games at once). I'll try and fix that tomorrow. Then I can write up a proper howto for other budding hackers, once I'm sure that works.

Sunday, February 24, 2008

NES on Playchoice 10 Update

It works! (mostly)

After much trial and error I believe I've found that CHR A13 and CHR /A13 are marked backwards on the Playchoice schematic I have.

So far I've been able to play Super Mario Bros, SMB 3, Castlevania 3, Blaster Master, and others. However, Cobra Triangle, Duck Tales, TMNT and Gauntlet display some graphical hoo-haw. I believe the common denominator is that these carts use their own onboard VRAM, and disable the system's VRAM, which would tell me there's a problem with the VRAM /CE line, or perhaps VRAM A10. They both seem to be wired "correct", but they may not be right on the schematic.

I won't rule out that these cartridges are simply filthy and not making a proper connection, I'll stop at harbor freight tomorrow and see if I can't find a set of bottlecap bits to open them up for a good and proper cleaning.

I'm pretty jazzed with the results so far, and even wired in a power switch to the adapter. If I select another channel on the PC10, I can safely switch carts, reselect the channel and be off to the races.

ITS ALIVEEEEE!!!!

A weeks worth of late night soldering and puzzling and puzzling until my puzzler was sore has finally come to fruition!

Can you hear it? It is the sound of the Pro Wrestling NES title screen music, playing through my PC10! My kooky scheme worked! Well, at least the PRG rom bus is working, as its running the code correctly. The graphics are all wonky, but I'm sure I have something backwards on the CHR bus, that wont be too tough to track down. Probably A10/A11, since Nintendo backwardseded them up from the famicom pinout, you know, for region protection.

I'll post details, pictures, and schematics later.. Until then, here's a teaser of how a PC10 cart is "activated" when /CS is enabled by pulling it low. Basically, it enables a ls367, dual hex bus driver, which routes chip enable signals to the "cartridge", as well as enabling the instruction rom.

This is a true hack, as in, I hacked up a game genie with a box cutter to make this happen.

Here's what I discovered after much desoldering and tracing PCB lines..

I still think I'm going to need to pull PRG /CE, CHR /A13 (CHR /CE for all intents) and VRAM /CE high with some 5k resistors, to make sure they are disabled when the game pak is not selected.

I'm jazzed and am ready for my next 'tendo hack project. PC10 game paks are just begging to be modified into reprogrammable carts, since they have solder pads for various rom types, etc. What I'm getting at, is my SMB3 PC10 board is much more generic than an SMB3 cart. If I hacked a Game Pak of each type (MMC1, MMC2, MMC3, UNROM, etc) in this matter, my PC10 could be the ultimate programmable uber-nintendo from hell. Though I think I'm going to work on the VS a bit first, and see if I cant make a bankswitching VS Super Mario Bros / VS Duck Hunt.

Wiring of 74ls367 on PC10 pro wrestling cart


/chsel |1 /G1 Vcc 16|
(Conn) Chr A13 |2 1A1 /G2 15| /chsel
+5 pullup |3 1y1 2A1 14| CHR /A13 (PC10 Connector)
(Conn) PRG /CE |4 1A2 2Y1 13| CIRAM /CE (PC10 Connector)
+5 pullup |5 1Y2 2A2 12| /CSel INST ROM (PC10 Conn)
(Brd) CIRAM A10 |6 1A3 2Y2 11| Pin 20 U4

(Conn)CIRAM A10 |7 1Y3 2A3 10| N/C
GND |8 GND 2Y3 9| N/C

^^Crap this wont display right

rewiring:

lift pin 2, connect pcb hole to Chr A13 on nes connector
lift pin 3
lift pin 5, connect pin to PRG /CE on nes connector
lift pin 6, connect pin 7to CIRAM A10 on nes connector

lift pin 13, wire pcb hole 13 to pin 10,
connect pin 13 to CHR /A13 on nes connector (with 5k pullup (!?))

lift pin 9, connect to CIRAM /CE on NES connector (with 5k pullup (!?))


unwired pins on connector = chr a10, m2, /irq, prg r/w


Wednesday, February 20, 2008

Blech

The NES I picked up as a donor for parts is a bit of a donkey, it's cart connector has been replaced with a cheap chinese knock-off of the original, it grabs cartridges with this grip of death, and basically breaks itself when you force them back out (the contacts bend and slide out).

Blech, there's not much I can do with it, but I've decided to take the connector off an old game genie instead, it's absolutely perfect for the task, it's already got eyelets to solder to and everything.

I mentioned before I hope to pull this off without BIOS modification of the PC10, since I want this thing to still behave like an arcade machine, and the hacked BIOS' out there disable this functionality. If I can't I'll have to work on my own BIOS, and Z80 assembler isn't something I've had experience with, though I guess it's about time I tried.

Also, despite an overwhelming abundance of 27C64 EPROMS, I presently have no way to erase them. I guess I should be googling around for some source of UVB light. The avon toothbrush-sanitizer hack works decently with little EPROMS like the 2764, but didn't seem to be able to clear the bigger 16 bit 27C1024, so I guess I need a real one. I have a Neo Geo and Taito f3 to be modifying (to cheat on the former, and to play in english on the latter).

I think when I get my EPROM eraser I'll throw Ice Climber onto my VS board, since it uses the same PPU as Super Mario Bros. My kid knows Ice Climber only as a character in Smash Bros, so it could be a little history lesson right there.

And that's the news. It's time to crack out the soldering iron and start doin', I suppose.

Monday, February 18, 2008

Also

Until further notice, this blog is about 8 bit Nintendo hacks. Whining about .net is tedious and boring.

Here's news: I picked up an old PSOne screen for 20 bucks, since it's well published how easy it is to tap on it RGBS internally, so eventually I'll be able to build myself a proper test rig for fixing my PCBs.

First up will be Donkey Kong, and I've made a decision that once I get it working, I'm going to sell it and the whole kit (PCB, marquee, screen bezel, and NOS bezel stickers) and use the cabinet to house my VS Super Mario / Duck Hunt project.

Yeah, Donkey Kong is more "classic", but I'm not running a museum here, and I don't wax nostalgic for games that suck. I'd even prefer Popeye to Kong, that's just how I am. It'll fetch me mighty bucks on eBay, bucks I can use for more important things.

Playchoice 10 and NES Cartridge Musings

So I'm well on my way to building my NES adaptor for PC10. I've bought a sacrificial NES for the cart connector, and I'll chop up the original motherboard for something to solder to.

I plan to likewise sacrifice a PC10 cart (Pro Wrestling, I suppose) since I have no idea where in the world one would get those connectors. I'll leave the security chip on the cart and wired, and cut the remainder of the traces - it should work without BIOS modification.

One weird thing I ran into mapping it out, is the presence of a 21.47727mhz clock signal on the 72 pin NES connector, which doesn't exist on the 60 pin famicom, nor on the PC10. This is strange, and I've been puzzling over what it could possibly be for.

My theories boil down to this: it's likely used by the CIC lockout chip, which is only present in NES. I thought maybe for expansion, but then why isn't it present on the expansion port?

Another hurdle in NES->PC10 will be the lack of player 2 start/select buttons. I've solved this, I plan to attach a fully intact NES control port assembly to the board, I've located where to solder it in, I'll draw up a schematic one day maybe. The only game I can think of that requires player 2 to be able to hit start is Battletoads, but that's surely a game worth playing on a real arcade machine.

My plan is to build a new control panel with two brand new NES Advantage sticks. I bought them years ago, and have never used them. They still have protective plastic film and everything.

I still haven't thought what I want to do for light gun games. I could always plug in a zapper, but I want to hardwire a holstered PC10/VS lightgun, probably with a switch next to the cartridge slot.

Also, the countdown timer is installed. It took me forever to crimp on all those tiny pins and get the ring working, but there it is. This is another motivation for not wanting to use a hacked BIOS, I don't want it forced into free play mode - I like the idea of timed NES challenges.

I also found this site, which has some cool NES hacks, most notably his VS-in-a-NES box. His code to remap the color pallette for VS Super Mario is exactly what I was looking to do to remap VS Duck Hunt's pallete to work with VS Super Mario. My dream of a arcade version of a VS Super Mario Bros / Duck Hunt is that much closer. (for those who dont know, arcade Super Mario is much harder with different levels, and in arcade Duck Hunt, YOU CAN SHOOT THAT SMUG DOG!)

But I'm way too tired to do anything about it now.