Jump to content
IGNORED

Technical Question about 2600+ emulation


GameGrumpy

Recommended Posts

I'm wondering if someone can clarify something for me. My understanding is that the 2600+ uses the Stella emulator. Stella runs pretty much everything, including games like QYX by Champ Games. So why is it that the 2600+ can't play the game if dumping it off a physical cart?

 

This isn't a "it's so simple why doesn't it work?" question. It's really me just trying to understand why one will run a game and the other will not.

Link to comment
Share on other sites

1 hour ago, GameGrumpy said:

I'm wondering if someone can clarify something for me. My understanding is that the 2600+ uses the Stella emulator. Stella runs pretty much everything, including games like QYX by Champ Games. So why is it that the 2600+ can't play the game if dumping it off a physical cart?

 

This isn't a "it's so simple why doesn't it work?" question. It's really me just trying to understand why one will run a game and the other will not.

https://www.ebay.com/itm/395098498249?hash=item5bfdb4a4c9:g:t9UAAOSwUwVlj2j3&amdata=enc%3AAQAIAAAAwHbvgq6OhUVRvv%2FMzdNV6Gk4pNj1IUYPREmqLbS%2B0hfPqyIuizA3719jyHZBTyRUZVmS7bXhagI2cXw9Ol26HtsXxm8DpQIDt7ME0IaWeuWvk1nWW4FsVo4gjI9mET8l4MM7MClXd4CLesfcJ2AdmTHk9GkaO9TFXiygHR4ZUz4WgKpYpDZ%2FSTYI90%2FJ0TqPbYrBmzlbACLVynHtkBishNHaEwyCpb3sD1Ol7noZegs4eJtxTgPe%2B1U2Ybmv3OlYrg%3D%3D|tkp%3ABk9SR5aG386XYw

  • Sad 1
Link to comment
Share on other sites

I had trouble finding this answer as well (I've read most of the threads but only in a cursory manner and there is a lot to weed through).

 

My guess is that with the ARM-assisted games, the ROM contains both 6502 code (at least one bank but possibly several banks) and ARM thumb code. This ARM thumb code is not seen/addressed by the Atari/6502 CPU and is never directly presented through the cart connector. Therefore, a dump, at best, would be able to grab the banks of 6502 code but not the ARM code which would make emulation of the game impossible.

  • Like 1
Link to comment
Share on other sites

The answer is buried in the 'Atari 2600+ is live for preorders' thread... not really easy to find, even when searching.   Even then, the answer requires putting together a few replies to get all the information necessary to understand why.

 

1 hour ago, GameGrumpy said:

Stella runs pretty much everything, including games like QYX by Champ Games. So why is it that the 2600+ can't play the game if dumping it off a physical cart?

I'll start with the simple answer first:  Because it's unable to dump the full cartridge.

 

Why can't it dump the full cartridge?

 

QYX by Champ Games uses cartridge hardware, the Melody board, that includes an ARM-chip.  The ARM chip works as both a 'cartridge emulator' and a 'co-processor'.  The ROM data on the cartridge is accessed thru the ARM chip... but not all of the data is exposed in a way that is easily accessible.  Without all of the data, you can't run the game.

 

Pitfall 2 currently doesn't run either... because it also has a special processor chip that doesn't expose all of the data to the Atari.

 

So those games will never run on the 2600+?

 

Never say never.  It's possible that a future firmware update will improve the Cartridge Dumper.  There have been signs that this is being investigated.

  • Like 5
  • Thanks 2
Link to comment
Share on other sites

9 hours ago, splendidnut said:

The answer is buried in the 'Atari 2600+ is live for preorders' thread... not really easy to find, even when searching.   Even then, the answer requires putting together a few replies to get all the information necessary to understand why.

 

I'll start with the simple answer first:  Because it's unable to dump the full cartridge.

 

Why can't it dump the full cartridge?

 

QYX by Champ Games uses cartridge hardware, the Melody board, that includes an ARM-chip.  The ARM chip works as both a 'cartridge emulator' and a 'co-processor'.  The ROM data on the cartridge is accessed thru the ARM chip... but not all of the data is exposed in a way that is easily accessible.  Without all of the data, you can't run the game.

 

Pitfall 2 currently doesn't run either... because it also has a special processor chip that doesn't expose all of the data to the Atari.

 

So those games will never run on the 2600+?

 

Never say never.  It's possible that a future firmware update will improve the Cartridge Dumper.  There have been signs that this is being investigated.

Thank you for actually answering with useful information. When a cart is put into the 2600+, the rom dumper reads what is on the cart, creates a file, and then feeds that file to the emulator (I think that is the way it works). It sounds like you are saying that due to the extra hardware, the 2600+ doesn't know how to make that file as it doesn't understand extra hardware. That makes sense. Where this breaks down is if rom file is already created on say a harmony cart. In that case the dumper doesn't need to read the additional hardware as it's already in the rom file. In this case the 2600+ sees the file, and feeds it to the emulator. Yet the emulator can't run the file. So I guess my question is why can Stella on PC run a rom file, but when Stella on the 2600+ sees the same file it can't do anything with it?

Link to comment
Share on other sites

10 hours ago, llabnip said:

I had trouble finding this answer as well (I've read most of the threads but only in a cursory manner and there is a lot to weed through).

 

My guess is that with the ARM-assisted games, the ROM contains both 6502 code (at least one bank but possibly several banks) and ARM thumb code. This ARM thumb code is not seen/addressed by the Atari/6502 CPU and is never directly presented through the cart connector. Therefore, a dump, at best, would be able to grab the banks of 6502 code but not the ARM code which would make emulation of the game impossible.

So are you saying that the 2600+ can't read parts of a rom file that relate to the ARM part of a cart? On PC Stella can read those additional code parts. Does that mean Stella on the 2600+ is actually missing things that it has on PC?

Link to comment
Share on other sites

5 hours ago, GameGrumpy said:

So are you saying that the 2600+ can't read parts of a rom file that relate to the ARM part of a cart? On PC Stella can read those additional code parts. Does that mean Stella on the 2600+ is actually missing things that it has on PC?

On a PC Stella has the whole ROM available. There are no carts dumped.

Link to comment
Share on other sites

6 hours ago, GameGrumpy said:

So are you saying that the 2600+ can't read parts of a rom file that relate to the ARM part of a cart? On PC Stella can read those additional code parts. Does that mean Stella on the 2600+ is actually missing things that it has on PC?

Think of it like this: the cart contains the full binary (say 32K or 64K or whatever) but only part of that is ever exposed to the Atari.

 

The Atari (in this case the 2600+) can only read out a 4K chunk at a time and only a 4K chunk that the cart presents to the system.  Of that 32K (or 64K or whatever), only a smaller number of 4K banks are 6502 (Atari) code and only those banks can be banked/read out via the cartridge dumper.  The cart dumper can't overcome the limitation of the 6502 and related cartridge architecture with limited address lines. The remaining binary that is ARM code/data never directly presents itself as a 4K bank to the Atari as it's intended to be run on the ARM co-processor within the cart and not on the 6502 CPU.

 

So although Stella on the 2600+ can perfectly emulate the ARM co-processor (or the Pitfall II DPC co-processor) - the 2600+ cart dumper can't retrieve the full binary ROM from the cart. For a game like QYX, I believe only 1 or 2 banks are used for 6502 code... the rest is ARM code/data. So at most only 8K (assuming 2 banks) of the 32K can be dumped into the 2600+ resulting in incomplete binary data to emulate the game.

 

If there was a way to get the whole binary into the 2600+, there is little doubt the version of Stella they are using would render it perfectly.  But incomplete binary dumps won't run.

 

EDIT: Much of what I wrote above is wrong :) From splendidnut's explanation below, it sounds like most of the ARM code (for 32K and smaller games) could be read by the cart dumper but there is still some missing parts that render the binary incomplete.

  • Like 3
Link to comment
Share on other sites

9 minutes ago, wavemotion said:

So only 8K of the 32K can be dumped into the 2600+ resulting in incomplete binary data to emulate the game.

For the ARM-based bankswitching schemes, the majority of banks (but not all) are easily accessible by the 6502:

  - DPC+, 24k (6 banks)

  - CDFx, 28k (7 banks)

 

For DPC+, there's an extra 5k beyond the 24k that has potentially necessary game data.  4k of that is accessible thru the data fetchers... which would need special code written in the cartridge dumper to dump.  Not sure how easy it would be to grab the last 1k... or if it's even necessary since it's music frequency data, which is probably the same across any DPC+ project.

 

In either case, the ARM driver is not accessible.  It would be nice to have access to the driver for identifying which scheme is used.

 

  • Like 2
Link to comment
Share on other sites

Ah! Okay... so ARM code that sits where a 6502 bank would be is readable - simply swap in the bank using the normal bank selection hotspot and read the 4K data. Even though it might not be 6502 code, that doesn't matter to the dumper since it just triggers the bank swap and reads the 4K chunk of data out. It's really the driver and first 2K of C code/data that would be a problem for CDFJ+ (Qyx - which is the theoretical example we've been using)

image.thumb.png.7f3c7badbd889aae3eb15f557a65c5b8.png

And for the latest games that are > 32K... sounds like that expanded ARM code/data would be inaccessible.

image.thumb.png.82428720d40d9c40cb90a3228bdd2c21.png

 

That indirect fetch of display data is coming from the ARM RAM.  The Driver is also, to my understanding, copied from the ROM binary into RAM for execution but not sure it's any more accessible there.

 

For DPC+, it looks like the the display data is in the ROM and copied into RAM so, in theory, that part could be fetched out via indirect access (assuming the 'dumper' software could be McGuyvered into doing such a thing). In this sense, DPC+ seems more realistic to dump than, say, CDF/J/+ ... especially if the DPC+ driver could be guessed and provided by the emulator... but I'm still learning as this thread expands so thanks for the clarifications. I find this stuff fascinating!

image.thumb.png.770b1d4fd4a8566f78ca0c9b3d165893.png

  • Like 3
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...