1

I'm looking at the .SNA snapshot file format for Amstrad CPC emulators based on the Multiface Two device.

I'm used to the ZX Spectrum which had 16K ROM and 48K RAM and the 48K .SNA snapshot format is in the simple straightforward order.

I'm not fluent in the 128K Spectrum .SNA snapshot format but I know it has a non-straightforward arrangement of 16K pages.

I'm assuming on the Amstrad even the small (64K) variants already do paging because 64K RAM would be the entire address space if paged in at once.

If it's straightforward then I would suppose the snapshot has $0000 to $ffff that would all be paged into matching address and that some portion is sometimes paged out so the ROM can be paged in. I've written my Ghidra loader on this premise and it looks OK, but I can't be sure.

If it's not straightforward then different parts of the 64K in the snapshot file might be paged into various combinations of the address space.

I'm not trying to do 128K Amstrad .SNA files yet but surely things are more complex, at least with the second 64K?

Unlike the Spectrum Snapshot format the Amstrad one doesn't seem to contain info on which pages are mapped in and out, but there's a very good chance I'm just overlooking it.


(Amstrad info seems to be drying up on the Internet... At least CPCWiki was down for hours while I was researching this and Wayback Machine's most recent captures of pages I was looking for were four years old, making it look dead. But now it's back up... And now it's down again, for me at least:

cpcwiki forbidden)

2
  • Umm thanks for the constructive feedback I guess. At least I know how to improve the question )-: Commented Aug 13 at 12:27
  • 2
    You are (yet again) asking for someone else to read the manual for you and feed it to you with a spoon. CPCWiki explains the format in great detail (cpcwiki.eu/index.php/Format:SNA_snapshot_file_format)
    – tofro
    Commented Aug 13 at 13:48

1 Answer 1

3

The RAM capture is just a linear record of what was in the actual RAM chips, i.e. according to physical address.

So, e.g. according to its paging register:

  • in configuration 0 the first 64kb of SNA-captured RAM will be visible linearly as the 64kb of Z80 address space;
  • whereas in configuration 6, the 16kb from offset 96*1024 will be substituted at $4000.

This I confirmed by checking out the contents of Caprice32, a very long-standing CPC emulator; note the way that pbRAM is mapped to various membank_configs here and the fact that pbRAM is just loaded directly from SNA files here.

1
  • 1
    The Amstrad SNA format also includes the Z80 register values and the Gate Array ports. Commented Aug 15 at 14:47

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .