Jump to content
IGNORED

Creating 5200 16K images


DEBRO

Recommended Posts

I was doing some more experimenting with Dan's code. I was trying to change the cartridge start location to $8000 instead of $4000 to create a 16K image but the emulator didn't like it.

 

Why can't I just change the start location to create a 16K image? Does it have something to do with the vectors?

Link to comment
Share on other sites

Unless I'm mistaken, Atari cartridge ROM's -always- start at $8000. I think that this is a throwback to the way the original cartridge slots on the Atari 800 worked. The left cart slot could contain a 8k rom from $8000 to $9FFF, and the right slot could contain 8k that used addresses $A000 to $BFFF. A cart plugged into the left slot could also contain the full 16k from $8000 to $BFFF (addresses above that were used by the OS & processors). And bankswitching could be used on later hardware to give 32k...but I dunno if those vectors are identical between the console & computer.

Then again, I could be totally wrong (I mainly used disk files, which could be addressed pretty much anywhere in RAM).

post-222-994822980_thumb.jpg

post-222-994822981_thumb.jpg

post-222-994822982_thumb.jpg

post-222-994822983_thumb.jpg

Link to comment
Share on other sites

I have seen 5200 ROMS starting at $4000 (for 32K) and $8000 (for 16K) but I can't get a 16K ROM I created to run on an emulator that's why I'm wondering if I'm missing something. If I need to set a register or something.

 

BTW I disassembled the 5200 ROM and the vectors seem to be fine so that's not the issue.

 

HELP!!!

Link to comment
Share on other sites

  • 1 month later...

I looked into this a little more today.

 

When I disassemble my 16K Joust ROM using DIS6502 it says the cartridge starts at $8000 which I would expect for a 16K ROM. When I run this game in VSS with the debugger option location $BFFE states the cartridge start location is $6000 ??? If I'm not mistaken if the ROM starts at $6000 and ends at $BFFF then that would make a 24K ROM right?

 

I'm confused. How do you get a homebrewed 16K ROM to work? Does anyone have any insight on this?

Link to comment
Share on other sites

I think it has to do with the VSS itself. It always assume that the code starts at $4000.

If you place your code at $8000 and make sure that the jump address (you set at the reset code $BFFD) is correct, it does work on the real console but fails on the VSS emulator.

 

While talking about differences between VSS and a real 5200 console: I've got my keypad code to work on the VSS emulator but it would not work on the real console... have to figure that one out...

Link to comment
Share on other sites

Ok, let me see if I can clear up some of the confusion about 5200 carts and how VSS loads them.

 

First, the 5200 carts have two chip enable pins, one for $4000-$7FFF and one for $8000-$BFFF. Each of those ranges is 16K for a total of 32K. 5200 carts come in a number of sizes, 8K, 16K, 32K, and maybe some others.

 

32K carts are simple, they have 2, 16K ROM chips each using one chip enable line, and filling up the whole address range.

 

8K carts used a single 8K ROM chip on the $8000-$BFFF chip enable line. But since the address range is 16K and the rom is only 8K, the upper address bit is ignored. The result is that the same data will appear at $8000-$9FFF and $A000-$BFFF.

 

16K carts get a little trickier. These are normally implemented using 2, 8K ROMS one on each chip enable line. So the data at $4000-$5FFF will repeat at $6000-$7FFF and the data at $8000-$9FFF will repeat at $A000-$BFFF.

 

VSS always assumes that 16K carts are setup like this, so when they are loaded the first 8K in the image file is loaded to address $4000 and the copied to $6000, and the second 8K in the image file is loaded to address $8000 and then copied to $A000.

 

VSS loads the images strickly based on size, nothing in the cart data is used to determine where the cart starts.

 

I am not sure how you would setup an assembler to build 16K binary images properly.

 

OldGuru:

 

In regards to your keypad code not working on a real 5200. Be sure you are setting bits 0 and 1 of address $E80F (SKCTL in the Pokey), this enables keyboard scanning. The emulator doesn't check for this so it will work, but it won't work on a real 5200. As an interesting side note enabling keyboard scanning also enables POT scanning, so you can read the joysticks. This point is not documented in to many places.

 

Dan

 

Dan

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...