Jump to content
IGNORED

MegaCart+ modification (3 wires + PLD magic)


CPUWIZ

Recommended Posts

Considering that there recently was discussion of how much RAM the 7800 could address, and looking at the addresses you are changing in your code example, I guess you've been experimenting with mapping cartridge RAM into every bit of unused address space below address $8000. Since the area below $1000 is mostly used for mirrors of the MARIA and TIA registers and the zero page RAM, and since there is 7800 system RAM between $1800 and $27FF, that would make 28K of continuously addressable RAM of which the Megacart+ provides 24K. So the demo program is probably testing if you got all the free address blocks without colliding with the used ones. Is that what we are seeing in your video?

  • Like 1
Link to comment
Share on other sites

So we've hit the upper limit now, if I'm reading this correctly? Interesting - from the looks of it, though, we can hit anything from the NES and below in terms of RAM use. That's a lot to play with in classic design.

 

Now let's get CPUWIZ to make a SID-capable cart? :)

Link to comment
Share on other sites

Since I am sick today, I just had a little bit of time to mess with it some more. The culprit is $2800-$2FFF, mapping $1000-$17FF and $3000-$7FFF works on all 5 of my 7800's. And yes, I don't care if this works with the HSC or XM, it's about figuring out how far you can push the stock 7800 with a cart.

  • Like 5
Link to comment
Share on other sites

It would be a shame, if you couldn't get this memory configuration to work. Even though the zero page and stack RAM are mirrored in the system RAM, it would be really nice to have so much continuously addressable RAM.

 

The 7800 programming manual mentions that $2800-$3FFF are the same as $2000-$27FF, but since it clearly isn't the case in one of your 7800s, I don't think that it's true. Maybe it's a timing issue. Didn't Atari add a special circuit to later models of the 7800 that changes the timing of the address bus in order to fix issues with 2600 games that use superchip RAM? IIRC, this circuit breaks compatibility with bankswitching schemes that rely on counting address bus changes, like FE bankswitching or the Supercharger.

 

I think it had something to do with pulling all address bus lines low once per cycle in order to make sure that the superchip RAM wouldn't react to incorrect addresses before the address bus was stable. Maybe the internal 7800 RAM is affected by this too. Could something like this cause the problems you are experiencing with your Megacart?

Link to comment
Share on other sites

I don't think that it's a timing issue, on most of my 7800's it actually writes to the stock RAM, when $2800-$2FFF are written to. So I lose 2K, not the end of the world. But yeah, it's strange that one of my systems does not.

Link to comment
Share on other sites

I find it suspicious that Atari Corp would add a timing circuit just to allow rare SuperCharger games to run on later 7800s. More likely, they had to add it due to some other cost revision made to the system to maintain existing compatibility and performance...

Link to comment
Share on other sites

  • 2 weeks later...

Funny you bumped this today, in my spare time, I experimented with more than just a PIC driving LED's via software. I actually figured out how to have the PLD monitor an address range for access, then tell the PIC to do something AND this is the important part:

 

I figured out how the cartridge interrupt works (with a little help from Eckhard Stolberg, Dan Boris never even read the PM I sent him weeks ago - LOL)! The PIC can now talk to the cartridge IRQ pin and trigger a software interrupt within the 7800, in other words, I have figured out how to do a handshake. More possibilities! :cool:

 

I'll post a boring video of it, maybe later. :ponder:

  • Like 1
Link to comment
Share on other sites

Boring video, as promised...

 

 

Joystick tells 7800 to write to $1000, PLD tells PIC that it happened, PIC tells LED to go on, stay there for 'N' milliseconds, then pull the IRQ line on the cart low for a period of 'N' cycles (been too lazy to figure out the MHz ratio, so far). What happens then, is the BRK interrupt vector gets executed by the CPU and I simply pointed the interrupt vector at a small routine, that just increments a number, which is displayed every frame, by the main loop.

 

So:

 

JoyUP -> PLD -> PIC -> 7800

 

Could be interesting, right? ;)

 

 

CARTIRQ:
        INC DEBUG_NUMBER
        RTI
  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...