It is currently Sat Feb 17, 2018 11:53 pm

All times are UTC - 7 hours



Forum rules


Related:



Post new topic Reply to topic  [ 50 posts ]  Go to page 1, 2, 3, 4  Next
Author Message
 Post subject: 27C322 to SNES bus?
PostPosted: Fri Feb 20, 2009 10:57 am 
Offline

Joined: Fri Feb 20, 2009 10:07 am
Posts: 40
Hello there!

Glad to have found this forum, where there are so many well-known retrogaming hardware experts around! Having some SNES software and hardware experience myself (translation, ASM, console & cart modding), this is the place I've been looking for. :)

Well, let's head on to business. I recently ventured building a 32 Mbit SNES cart using one 16 bit 27C322 EPROM. I used Siudym's untested schematics.

Here's what the completed thing looks like:

Image

I know it's butt-ugly, but hey, it's my very first beta HiROM 27C322 SNES cartridge. ;)

And unfortunately, it does not work. All I get is a black screen once that baby is powered up.

I tried to e-mail Siudym for a solution, but he didn't reply. Then I asked d4s for help - thanks again, dude! - but to no avail. Even with his suggestions, I wasn't able to get this thing to work.

Here's what I've tried so far:
- the original schematics (Siudym)
- connecting the SNES bus's A0 to pin 2 of the 139 and A1-A21 to A0-A20 of the EPROM respectively in order to avoid having to byte-swap the ROM in any way (d4s)
- not making the EPROM & SNES /OE connection (d4s)
- using HC microchips instead of LS ones to make sure the ROM data gets on to the SNES bus fast enough (d4s)

Nothing works. I even tested it on d4s' Ultra16, which has a memory viewer. The banks C0-FF (which should contain the ROM data since it is a HiROM game) remain empty, just like when no cartridge is inserted at all. Also, I checked the voltages on the 139, the two 245s and on the EPROM itself to make sure I didn't forget to make all the power connections. All VCC pins are at +5V as they should, and VSS is at GND.

Now, does perhaps someone of this forum have any idea what could be wrong? Any help would be greatly appreciated as I really want to finally get this project to work. :)

Thanks in advance!
orwannon

N.B.Please don't bother suggesting alternatives like using 27C801 EPROMs (I have successfully built carts using these), a copier (I indeed own one), or a Tototek flashcart (I'm going to buy one anyway). In this thread, let's just talk about connecting 16 bit EPROMs to the SNES bus. Savvy? :lol:


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 20, 2009 12:09 pm 
Offline

Joined: Mon Apr 16, 2007 10:07 am
Posts: 108
Hmm. I don't get why that schematic is using a bus transceiver. I thought for a few minuets and came up with this: (sorry for the crude MSPaint)
Image

This circuit replaces the transceivers in the design you are using with 3 state transparent octal latches (74xx373). In this schematic the 373s have their latch inputs tied high (transparent mode). The OE/ of the 373s are connected to the nand gates (1 74xx00 quad 2 input nand gate) which decode the upper/lower byte from the A0 and CE/ lines. I can't see why this wouldn't work but it is wholly untested. ^_^


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 20, 2009 5:07 pm 
Offline
User avatar

Joined: Mon Sep 27, 2004 2:13 pm
Posts: 1667
Location: .ma.us
Why use a latch for just the output buffers? I don't think it's wise to ignore the /RD signal anyway. If that were OK, you could then just use two 74257 3-state multiplexers and drop a chip. 257s are also cheaper than 373s and come in a 16 pin package instead of 20.

Image
Edit: note typo that the 27322 doesn't have a A21.. so wire SNES A1-21 to 27322 A0-20.

If you're using 74HC parts, I'd probably ground the ROM's /CE to not float the inputs though this will consume more power.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 20, 2009 9:36 pm 
Offline

Joined: Tue Aug 14, 2007 7:02 am
Posts: 31
The 74257s are definitely a better choice. I used a pair of them in my pcb design a while back. I'm not too sure about ORing /ROMSEL and /RD since SRAM /OE is connected to /ROMSEL. There might be some bus conflicts.

P.S. Thanks kyuusaku. I finished the proof of concept for the 96mbit game (95 mbit technically) with a working prototype. I didn't quite use your design but it put me in the right direction.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 20, 2009 10:24 pm 
Offline
User avatar

Joined: Mon Sep 27, 2004 2:13 pm
Posts: 1667
Location: .ma.us
In the case of SRAM, yeah just use the SRAM decoder's output instead of /ROMSEL, but SRAM /OE shouldn't be connected to /ROMSEL at all though, just to /RD.

It's cool you made a 96M cart, what's on it?


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 20, 2009 10:31 pm 
Offline

Joined: Tue Aug 14, 2007 7:02 am
Posts: 31
Neviksti's version of Star Ocean.

Good catch on the typo. I meant to say that /RD is connected to SRAM /OE.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 20, 2009 10:35 pm 
Offline
User avatar

Joined: Mon Sep 27, 2004 2:13 pm
Posts: 1667
Location: .ma.us
Ah! Much cooler than a test program, how did you decode SRAM? I've wondered if the SRAM area in that circuit I posted was suitable since I think it encompasses the standard HiROM area.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Feb 21, 2009 5:01 am 
Offline

Joined: Fri Feb 20, 2009 10:07 am
Posts: 40
Wow, thank you all for your suggestions and new schematics! :)

shadowkn55 wrote:
There might be some bus conflicts.


So, do you mean /ROMSEL should be connected to the EPROM's /CE directly (and only), and /RD to the 257s' /OE only (while leaving the EPROM's /OE pin at GND as shown on kyuusaku's design)? Also, when using HC parts and thus grounding the EPROM's /CE pin, should I leave /ROMSEL unconnected? (/ROMSEL = SNES's /CE, right?)

BTW, as the SRAM on my PCB got erased during the tests, I presume an SRAM conflict in Siudym's schematics could be the reason for the ROM data not coming through ... This is just an assumption though.

Anyway, thanks for your help! I might put kyuusaku's design to the test shortly. :)

If anybody else should know how to get this done with transceivers as shown on Siudym's schematics, I'd appreciate it (especially because I won't need to buy new parts! :P). His design can't be too wrong because the 16 bit adapter for the Willem EPROM programmer uses two 245s as well ...

orwannon


Top
 Profile  
 
 Post subject:
PostPosted: Sat Feb 21, 2009 12:01 pm 
Offline
User avatar

Joined: Mon Sep 27, 2004 2:13 pm
Posts: 1667
Location: .ma.us
orwannon wrote:
So, do you mean /ROMSEL should be connected to the EPROM's /CE directly (and only), and /RD to the 257s' /OE only (while leaving the EPROM's /OE pin at GND as shown on kyuusaku's design)?

Noooooo, that would CAUSE conflicts as /RD (and thus 257 /OE) would be asserted on every instruction. You need it so only when both /CE and /OE are asserted the buffers output. If you only decode with /CE, then if a game writes to ROM there will be a conflict, /RD OR /CE protects against this.

orwannon wrote:
BTW, as the SRAM on my PCB got erased during the tests, I presume an SRAM conflict in Siudym's schematics could be the reason for the ROM data not coming through ... This is just an assumption though.

Just like my diagram, Siudym's doesn't account for SRAM. This has nothing to do with the design, just how you are not using the proper ROM select from the on board decoder (74139 or MAD-1 etc).

orwannon wrote:
If anybody else should know how to get this done with transceivers as shown on Siudym's schematics, I'd appreciate it (especially because I won't need to buy new parts! :P). His design can't be too wrong because the 16 bit adapter for the Willem EPROM programmer uses two 245s as well ...

Using 245s will "work" but it's not the most elegant way due to logical/electrical glitches. Unrelated but this is NOT a good way of bidirectionally accessing 16-bit memory, the only reason the Willem gets away with it with only two 245 is because EPROM can be programmed as small as a bit at a time due to their construction, this would not work for other 16-bit memories that need a complete word latched.

This is how you would build a working 245 version though:
Image
Siudym's conflicts for the same reason I outlined above, mine WILL work as the 139 also implements /CE OR /RD.


Top
 Profile  
 
 Post subject:
PostPosted: Sun Feb 22, 2009 10:35 am 
Offline

Joined: Fri Feb 20, 2009 10:07 am
Posts: 40
And work it does! You rock, kyuusaku! :D

As your version is not very different from Siudym's design, I just had to alter the /CE and /OE connections accordingly. For the record, I tied pin 1 of the 139 to pin 4 of the MAD-1. Works like a charm! :) Thanks a lot! :lol:

I feel like trying out your "more elegant" design with two 257s next. I guess that when there's SRAM on the cart, I should use the on-board decoder's ROM select instead of /ROMSEL for one of the OR gate's inputs, just like I did now, correct? One last question on this would be whether you'd recommend any microchip type concerning the OR gate? Looking at the 139's datasheet because you mentioned its OR implementation, I guess I could simply use that one (e.g. pins 1 and 3 as the inputs and pin 4 as the output) ...?

Anyway, big thanks again for your efforts and great technical help! I couldn't have done it without you! :D

orwannon


Top
 Profile  
 
 Post subject:
PostPosted: Sun Feb 22, 2009 2:37 pm 
Offline
User avatar

Joined: Mon Sep 27, 2004 2:13 pm
Posts: 1667
Location: .ma.us
Glad you got it working! Now you can try tying the 27322's /CE to the /CE connected to the 139 (the MAD-1 output), this will give you better power efficiency ;)

orwannon wrote:
I feel like trying out your "more elegant" design with two 257s next.

To do that you can still use a 139 to enable the outputs, you just don't want to decode the enable signals with A0, only with /CE and /RD.

orwannon wrote:
I guess that when there's SRAM on the cart, I should use the on-board decoder's ROM select instead of /ROMSEL for one of the OR gate's inputs, just like I did now, correct?

You should always use the on-board decoder's ROM select, it's no different now with a 16-bit ROM than it was with an 8-bit ROM, the ROM must be enabled when the SRAM decoder wishes.

orwannon wrote:
One last question on this would be whether you'd recommend any microchip type concerning the OR gate?

7432 are the typical OR gate IC, but I wouldn't use a discrete chip for only one logic gate... Since you aren't building boards I guess it doesn't matter much but I'd try to integrate the logic into the ROM/SRAM decoder. 74139 are typically more useful to keep around than 7432.

orwannon wrote:
Looking at the 139's datasheet because you mentioned its OR implementation, I guess I could simply use that one (e.g. pins 1 and 3 as the inputs and pin 4 as the output) ...?

The 139 is a decoder, it doesn't really have an OR function, I just chose the outputs which gave an OR condition, and further decoded that with A0 to chose which buffer to enable/two birds with one stone.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Dec 07, 2009 9:27 am 
Offline

Joined: Wed Jun 03, 2009 2:06 am
Posts: 29
Programmed and verified a 27c322. Re-read it with friend's TOP2004 at his setup, and then played the rom on bSnes emulator. Worked perfect.

I do not have 257s and ordered them from Australia (best price, highest amount lol). That is estimated at 5 weeks SeaMail *seller said no AirMail to Canada? Wtf... anywho back on track.

I have an LS139, 2 LS245s, and a programmed 27c322.

http://nintendoallstars.w.interia.pl/ro ... c322_8.png

The only changes I would need to make to siudyM's (link above) instructions are to ground the 3rd pin of the 139 (Kevtris), and ground the 27c322's E (CE) and GVpp (OE). I ran it up, multimetered and checked the wiring. No shorts for sure (checked 3 times) and it did not work.


HELP


edit: tried removing the ground from leg 3 of the 139, did not work


Last edited by lunaris on Wed Dec 09, 2009 5:57 am, edited 1 time in total.

Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 09, 2009 8:54 am 
Offline
User avatar

Joined: Mon Sep 27, 2004 2:13 pm
Posts: 1667
Location: .ma.us
Draw a *complete* diagram of how the cart is wired and I'll correct it.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 09, 2009 9:01 am 
Offline

Joined: Wed Jun 03, 2009 2:06 am
Posts: 29
Image

Permission to rage at my stupidity is granted :lol: . This is maybe too difficult a hobby to have taken up :cry: .

edit: grounds and vcc are all connected correctly too, I check with a multimeter

edit2: "As your version is not very different from Siudym's design, I just had to alter the /CE and /OE connections accordingly. For the record, I tied pin 1 of the 139 to pin 4 of the MAD-1. Works like a charm! Smile Thanks a lot! " - orwannon


Top
 Profile  
 
 Post subject:
PostPosted: Wed Dec 09, 2009 9:41 am 
Offline

Joined: Fri Feb 20, 2009 10:07 am
Posts: 40
Take a look at kyuusaku's diagram:

kyuusaku wrote:
Image


See, you wire SNES A0 to pin 2 of the 139 and then
SNES A1 to EPROM A0
SNES A2 to EPROM A1
...
SNES A20 to EPROM A19
SNES A21 to EPROM A20
and leave SNES A22 unconnected.

Don't ground the 139's pin 3, but instead wire that to pin 24 of the MASK ROM (note that you have to use a PCB with a 36-pin MASK ROM - not only for correct pin numbering). And pin 1 of the 139 should be wired to pin 4 of the MAD-1 (if applicable) or to MASK ROM pin 33.

This works great for me. BTW, kyuusaku's "257 version" works just as well - and is a bit easier to construct. ;)


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 50 posts ]  Go to page 1, 2, 3, 4  Next

All times are UTC - 7 hours


Who is online

Users browsing this forum: Google [Bot] and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group