Jump to content
IGNORED

High score cart source code


GroovyBee

Recommended Posts

Hi there,

 

This question isn't related to the source code but more around detecting the presence of the HSC.

 

Do we know of anything else that potentially loads up in location $3900? What are the values of these locations when the HSC isn't present? Is it safe to check for the HSC as...

   lda #$38
   eor $3900                        ; a should be 0xFE if HSC present
   eor $3904                        ; a should be 0 if HSC present
   bne NOHSC

 

Link to comment
Share on other sites

There's nothing else that presently uses the $1000 and $3000 HSC locations, AFAIK. If there's no HSC, the bus is floating/undefined at $3900, so any reads will typically echo back the last value on the bus. (ie. the last byte of the opcode) I say typically - the values returned may be corrupted or just FF, with oddball consoles.

 

The other thing you can do is look for the HSC magic signature at $1002. Heads up the bus is floating there too, if HSC isn't plugged in. 7800basic just checks for the first 2 bytes of that signature, which IMO is enough.

 

I think looking at the ROM contents might be problematic, in case there's ever a revision. (not likely, but not impossible)

  • Like 1
Link to comment
Share on other sites

Hi there,

4 hours ago, RevEng said:

The other thing you can do is look for the HSC magic signature at $1002. Heads up the bus is floating there too, if HSC isn't plugged in. 7800basic just checks for the first 2 bytes of that signature, which IMO is enough.

I may not be understanding. Is the "magic signature" unique for each HSC? What is the advantage of checking the signature vs. the $3900 and $3904 locations as GCC implemented? 

Link to comment
Share on other sites

Ok, my bad. I had a look at the disassembly just now and see that $3900 and $3904 are set aside as an HSC rom magic, so those won't change. (the magic at $1002 indicates the presence of formatted HSC write area, and isn't unique.)

 

In my defense I don't use the HSC rom routines, because 7800basic supports high score table saving to both the HSC and Savekey/Atarivox with common routines.

  • Like 1
Link to comment
Share on other sites

Doing a quick manual disassembly on the first few bytes, it looks like that alternate hsc rom has corruption, rather than meaningful code differences.

 

Right near the start I see a 3 byte JSR being changed into a 2 byte LDA # instruction, leaving that 2nd byte of the JSR as the load, and 3rd byte just waiting to being executed. This change occurs right after another LDA, so it's pointless and problematic. A little further on I see a 1 byte opcode being replaced with the first byte of a 2 byte opcode, messing up the alignment of the code that follows.

 

The code alignment doesn't seem to shift either, like I'd expect in a code revision.

Link to comment
Share on other sites

  • 2 months later...
2 hours ago, gambler172 said:

is there a 3600 Asteroids somewhere available?

Do you mean a proto that actually says 3600 on it? I am not sure if they started work on it before the name change to 7800. Maybe Curt has one.

I do have one called 3d Asteroids,  the same as what the catalog shows. It is the same game as regular 7800 Asteroids.

 

Mitch

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