The following chunks are currently defined:
== CPC+ ==
This chunk is supported by Arnold, WinAPE, No$CPC and ACE. Arnold, WinAPE and ACE will save the block when Plus configuration enabled. No$CPC will save the block if the Plus features have been unlocked.
When creating a snapshot with several chunks, it is usually a good idea to place the CPC+ one in first position, because some (old) tools and emulators are relying on this and will fail if it is not the case.
{|
|-
| ''Offset (Hex)''
| ''Length''
| ''Addr in ASIC register-ram''
| ''Description''
|-
| 000-7FF
| 800
| 4000-4FFF
| Sprite Bitmaps (note 1)
|-
| 800-87F
| 8*16
| 6000-607F
| Sprite Attributes (see below) (note 2)
|-
| 880-8BF
| 32*2
| 6400-643F
| Palettes (note 3)
|-
| 8C0
| 1
| 6800
| Programmable Raster Interrupt (note 4)
|-
| 8C1
| 1
| 6801
| Screen split scan-line (note 4)
|-
| 8C2
| 2
| 6802-6803
| Screen split secondary screen-address (note 4)
|-
| 8C4
| 1
| 6804
| Soft scroll control register (note 4)
|-
| 8C5
| 1
| 6805
| Interrupt vector (note 4)
|-
| 8C6
| 1
| Internal
| gate array A0 register value (note 8a)
|-
| 8C6-8C7
| 1
| -
| unused (0)
|-
| 8C8-8CF
| 8
| 6808-680f
| Analogue input channels 0-7 (note 5)
|-
| 8D0-8DB
| 3*4
| 6C00-6C0B
| Sound DMA channel attributes 0-2 (see below) (note 6)
|-
| 8DC-8DE
| 3
| -
| unused (0)
|-
| 8DF
| 1
| 6C0F
| DMA Control/Status (note 4)
|-
| 8E0-8F4
| 3*7
| Internal
| DMA channel 0-2 internal registers (see below) (note 7)
|-
| 8F5
| 1
| Internal
| gate array A0 register value (note 8b)
|-
| 8F6
| 1
| Internal
| gate array A0 lock: 0 -> locked, !=0 -> unlocked (note 9)
|-
| 8F7
| 1
| Internal
| ASIC unlock sequence state (note 10)
|}
=== Notes ===
1. The sprite data is packed, with two sprite pixels per byte. Bits 7..4 define the first pixel and bits 3..0 define the second pixel.
2. The attributes for each sprite take 8 bytes. Each attribute block has the following format:
{|
|-
| ''Offset (Hex)''
| ''Length''
| ''Description''
|-
| 0
| 2
| Sprite X (see note)
|-
| 2
| 2
| Sprite Y (see note)
|-
| 4
| 1
| Sprite Magnification (see note)
|-
| 5-7
| 3
| unused (0)
|}
Note: the Sprite X, Y and magnification are in the same order as the ASIC registers
3. This is a direct copy of the palette in CPC+ ASIC Ram. There are 32 colours each with 2-bytes per colour.
4. These bytes in the snapshot represent the last value written to these ASIC registers.
5. These bytes represent the inputs to the analogue channels.
6. The attributes for each DMA channel take 4 bytes. Each attribute block has the following format:
{|
|-
| ''Offset (Hex)''
| ''Length''
| ''Description''
|-
| 0
| 2
| DMA Channel address (see note)
|-
| 2
| 1
| DMA Channel prescalar (see note)
|-
| 3
| 1
| unused (0)
|}
Note: the DMA address and prescalar are in the same order as the ASIC registers.
7 These registers are internal to the CPC+ and define the current DMA operation:
{|
|-
| ''Offset (Hex)''
| ''Length''
| ''Description''
|-
| 0
| 2
| loop counter (note a)
|-
| 2
| 2
| loop address (note b)
|-
| 4
| 2
| pause count (note c)
|-
| 6
| 1
| pause prescalar count (note d)
|}
a. This value represents the number of loops remaining. 0 = none. This count is between 0..0FFF. This counter counts down.
b. This is the Amstrad memory address to loop back to. It is a pointer to the DMA instruction after the last REPEAT instruction.
c. This value represents the pause count and the count is between 0...0FFF. (TO BE CHECKED: down counter? what exactly does it represent)
d. This value represents the pause prescalar count and the count is between 0..FF. (TO BE CHECKED: down counter? what exactly does it represent)
8. This value represents the last value written to this I/O port. Winape uses 8a and not 8b. This value has bits 7,6,5 set to 1,0 and 1 respectively. 8b is in the original specification and is written by both ACE and No$CPC.
9. This value represents the lock status of RMR2. If locked, RMR2 can't be accessed otherwise it can.
10. This value represents the current unlock sequence state.
{|
|-
| ''State ID''
| ''Synchronised State''
| ''Note''
|-
| 0
| Not synchronised
| ASIC is waiting for first non-zero byte to be written, this is the first synchronisation byte required
|-
| 1
| Not synchronised
| ASIC is waiting for zero byte to be written, this is the second synchronisation byte required
|-
| 2..10
| synchronised
| ASIC is waiting for byte from unlock sequence. e.g. if "2", ASIC is waiting for &FF, the first byte of the unlock sequence. if "3" ASIC is waiting for &77, the second byte of the unlock sequence.
|}
== DSCA,DSCB ==
DSCB is similar to DSCA but stores the filename of the disc image inserted into drive B.
== TAPE (ACE) ==
This chunk is supported by ACE; it is saved only when the related option is enabled.
The TAPE block contains the filename of the tape image inserted. The filename is stored as 8-bit ASCII (any Unicode characters with codes 0x100 or above will be translated to ? and therefore filenames with these characters can't be stored in Snapshots). The length of the block is the length of the filename in bytes.
NOTE: The selected Multiface ROM is not saved in the snapshot.
== INFO Chunk (No$CPC) ==
This chunk is written by No$CPC. It contains an 8-bit ASCII string with the version information for No$CPC.
== MEM0-8 Chunk ==
The MEM0-8 chunks contain at most 64KB of data. The data may be compressed or stored uncompressed. If the size is exactly 65536 bytes the data is uncompressed, otherwise it is compressed. Up to 512KB additional RAM can be stored in a snapshot.
6. ACE can save additional memory in snapshots (up to 4MB) using the MX?? chunks.
== MX09-40 Chunk (ACE) == This chunk is supported by ACE.
MX?? chunks allow snapshots to store up to 4160KB ram.
Information are stored compressed like in MEM0-8 chunks.
== BRKC Chunk (ACE) ==
This chunk is written by ACE when some breakpoints are set. When loading a snapshot, the breakpoints found in this chunk are added to the one already installed.
The number of stored breakpoints in the chunk is given by the chunk size divided by 216 (the size on of one breakpoint data structure).
{|
* 6: ASIC I/O Page. Map bank and page are ignored (always 0).
== SYMB Chunk (ACE) ==
This chunk is written by ACE when some symbols are declared. When loading a snapshot, the symbols found in this chunk are added to the alreading existing ones.
===Notes===
1. Symbol are (obviously) limited to 255 characters, cannot begin with a number (0-9), and only a limited set of ASCII char is allowed (a-z, A-Z, 0-9, _, .).
2. The map type determines the memory layout for which the symbol is valid. The meaning of the values for map bank and map page depends on the map type value.
Possible values fir map type are:
* 6: ASIC I/O Page. Map bank and page are ignored (always 0).
== CPC+ Chunk BRKS ==
This chunk is supported written by Arnold, older versions of WinAPE when some breakpoints are set. Newer versions of Winape, No$CPC and ACEwrite WABP chunk. Arnold, Winape and ACE will save the block when Plus configuration enabled. No$CPC will save the block if the Plus features have been unlockedcan import breakpoints from this chunk but won't create it (BRKC is used instead).
{||-| The chunk contains 0 or more breakpoints. Each breakpoint's data has the same size so you can determine the number of breakpoints from the chunk'Offset (Hex)''| ''Length''| ''Addr in ASIC register-ram''| ''Description''|-| 000-7FF| 800| 4000-4FFF| Sprite Bitmaps (note 1)|-| 800-87F| 8*16| 6000-607F| Sprite Attributes (see below) (note 2)|-| 880-8BF| 32*2| 6400-643F| Palettes (note 3)|-| 8C0| 1| 6800| Programmable Raster Interrupt (note 4)|-| 8C1| 1| 6801| Screen split scan-line (note 4)|-| 8C2| 2| 6802-6803| Screen split secondary screen-address (note 4)|-| 8C4| 1| 6804| Soft scroll control register (note 4)|-| 8C5| 1| 6805| Interrupt vector (note 4)|-| 8C6| 1| Internal| gate array A0 register value (note 8a) |-| 8C6-8C7| 1| -| unused (0)|-| 8C8-8CF| 8| 6808-680f| Analogue input channels 0-7 (note 5)|-| 8D0-8DB| 3*4| 6C00-6C0B| Sound DMA channel attributes 0-2 (see below) (note 6)|-| 8DC-8DE| 3| -| unused (0)|-| 8DF| 1| 6C0F| DMA Control/Status (note 4)|-| 8E0-8F4| 3*7| Internal| DMA channel 0-2 internal registers (see below) (note 7)|-| 8F5| 1| Internal| gate array A0 register value (note 8b)|-| 8F6| 1| Internal| gate array A0 lock: 0 -> locked, !=0 -> unlocked (note 9)|-| 8F7| 1| Internal| ASIC unlock sequence state (note 10)|}s size.
=== Notes ===Each breakpoint has the form: * 2 bytes: address (LSB first) * 1 byte: location (0: base 64K RAM, 1: extended RAM) * 2 bytes: condition (?)
1. The sprite data is packed, with two sprite pixels per byte. Bits 7..4 define the first pixel and bits 3..0 define the second pixel. == WABP ==
2This chunk is written by WinAPE when one or more breakpoints are set. The attributes for each sprite take 8 bytes. Each attribute block has the following format:
{||-| ''Offset (Hex)''| ''Length''| ''Description''|-| 0| 2| Sprite X (see note)|-| 2| 2| Sprite Y (see note)|-| 4| 1| Sprite Magnification (see note)|-| 5-7| 3| unused (0)|}The chunk contains in this order:
Note: the Sprite X* code breakpoints (program counter)* memory breakpoints (read, Y and magnification are in the same order as the ASIC registers write, read/write)* i/o breakpoints (read, write, read/write)
3. This is Each section begins with a direct copy 4 byte little endian count of the palette number of items in CPC+ ASIC Ramthat section. There are 32 colours This is followed by each with 2-bytes per colouritem.
4. These bytes in the snapshot represent the last value written to these ASIC registers. === Code breakpoints ===
5. These 4 bytes represent the inputs to the analogue channels. 32-bit count - number of code breakpoints (will be 0 if there are no code breakpoints)
6. The attributes for each DMA channel take 4 bytes. Each attribute block has the following formatcode breakpoint:
{||-| ''Offset 1 byte origin (Hexsee note 1)''| ''Length''| ''Description''| 4 bytes 32-| 0| 2| DMA Channel bit winape memory address (see note)|-| 2| 1| DMA Channel prescalar (see note)|-| 3| 1| unused (0)|}
Noteif count is present (see note 2): the DMA address and prescalar are in the same order as the ASIC registers.
7 These registers are internal to the CPC+ and define the current DMA operation: 4 bytes - maximum count 4 bytes - count so far
{||-| ''Offset (Hex)''| ''Length''| ''Description''|-| 0| 2| loop counter if condition is present (see note a)|-| 2| 2| loop address (note b)|-| 4| 2| pause count (note c)|-| 6| 1| pause prescalar count (note d)|}:
a. This value represents the number 4 byte - length of loops remaining. 0 = none. This count is between 0..0FFF. This counter counts down. condition in characters/bytes (note 3) n bytes - characters/bytes of condition (note 4)
bNOTES:* 1. This is the Amstrad memory address to loop back toorigin of the breakpoint: 1 - 'user'. It is a pointer to Added by the user clicking in the left margin of the disassembly view in the debugger. 4 - 'assembler'. Added by the user clicking in the DMA instruction after left margin in the last REPEAT instructionassembler window.
c* 2. This value represents Winape's addressing scheme is 4 bytes. The upper 16-bits effectively define the internal 64KB pages it uses. Bit 31 will be set if the pause 'count ' is used and present in the count file. Bit 30 will be set if the 'condition' is between 0used and present in the file...0FFF. (TO BE CHECKED: down counter? what exactly does it represent)
d. This value represents the pause prescalar count and the count is between 0..FF. (TO BE CHECKED: down counter? what exactly does it represent) === Memory breakpoints ===
8. This value represents the last value written to this I/O port. Winape uses 8a and not 8b. This value has bits 7,6,5 set to 1, 4 bytes 32-bit count - number of memory breakpoints (will be 0 and 1 respectively. 8b is in the original specification and is written by both ACE and No$CPC.if there are no memory breakpoints)
9. This value represents the lock status of RMR2. If locked, RMR2 can't be accessed otherwise it can.Each memory breakpoint:
10. This value represents the current unlock sequence state. 1 byte access (see note 1) 4 bytes 32-bit winape memory address (see note 2)
{||-| ''State ID''| ''Synchronised State''| ''Note''|-| 0| Not synchronised| ASIC is waiting for first non-zero byte to be written, Following this is the first synchronisation byte required|-| 1| Not synchronised| ASIC is waiting for zero byte to will be written, this is the second synchronisation byte required|-| 2..10| synchronised| ASIC is waiting for byte from unlock sequence. e.g. count and condition in that order if "2", ASIC each is waiting for &FF, the first byte of the unlock sequence. if "3" ASIC is waiting for &77, the second byte of the unlock sequencepresent.|}
== BRKS Chunk if count is present (WinAPEsee note 2) ==:
This chunk is written by Winape when some breakpoints are set. 4 bytes - maximum countACE can import breakpoints from this chunk. 4 bytes - count so far
The chunk contains 1 or more breakpoints.if condition is present (see note 2):
Each breakpoint has the form: * 2 4 byte - length of condition in characters/bytes: address (LSB firstnote 3) * 1 byte: location (0: base 64K RAM, 1: extended RAM) * 2 n bytes - characters/bytes: of condition (?note 4)
== WABP Chunk (WinAPE) ==always: 2 bytes - unknown.
NOTES:* 1. bit 7 will be set for write and bit 6 will be set for read. This chunk is written by can therefore represent read only, write only, and read-write* 2. Winape when some breakpoints are 's addressing scheme is 4 bytes. The upper 16-bits effectively define the internal 64KB pages it uses. Bit 31 will be setif the 'count' is used and present in the file. Bit 30 will be set if the 'condition' is used and present in the file. * 3. the condition is a string of ascii characters. This value is the number of characters/bytes.* 4. there is 1 byte per character in the condition. The exact details are begin worked outcondition string is not null terminated.
It seems to be:=== I/O breakpoints ===
4 bytes 32-bit count - number of user I/O breakpoints (will be 0 if there are no i/o breakpoints)
Each user i/o breakpoint:
1 byte type,(see note 1)4 1 byte addressflags (see note 2)
Thenif type is 0, 4 bytes - number of memory breakpointsthen the following is present:
Each memory breakpoint: 2 byte i/o address mask 2 byte i/o address
Then, 4 bytes - number of i/o breakpointsif count is present (see note 2):
Each 4 byte max count 4 byte current count if condition is present (see note 2): 4 byte - length of condition in characters/bytes (note 3) n bytes - characters/bytes of condition (note 4) NOTES:* 1. The type is a value which represents the I/O port: 0 = user (address and address mask are stored in the file) 1 = gate array 2 = palette register select 3 = palette write 4 = interrupt rom and mode 5 = secondary ram mapping 6 = pal 7 = crtc 8 = crtc register select 9 = crtc register write 10 = crtc register read 11 = crtc status read 12 = upper rom 13 = printer 14 = ppi 15 = ppi port a 16 = ppi port b 17 = ppi port b (tape read) 18 = ?? 19 = ppi port b (vsync) 20 = ppi - port c 21 = ppi - tape write 22 = ppi - tape motor 23 = ppi - keyboard 24 = ppi control 25 = psg 26 = psg register select 27 = psg read 28 = psg write 29 = keyboard Where type is not 0, the address mask and address are not stored but can be found in Winape's debugger and they may have a built in condition where specific data or i/o breakpoint:configuration is required. * 2. This byte represents access type and if there is count and condition data stored. Where type is 0, the access bits are set by the user, otherwise they are set defined by the type and can be seen in the winape debugger. bit 7,6 = access where bit 7 = write and bit 6 = read. This allows read only, write only and read/write to be specified. bit 5 = unknown. Always set to 1? bit 4 = unknown. Always set to 0? bit 3 = condition data is stored. bit 2 = count data is stored. bit 1 = unknown. bit 0 = unknown.
2 * 3. the condition is a string of ascii characters. This value is the number of characters/bytes flags? (6000 read, a400 write). 2 bytes port addr mask 2 bytes port addr * 4 bytes counter 4 bytes . there is 1 byte per character in the condition string length, followed by . The condition string (is not null terminated).
== DARS Chunk (WinAPE) ==
This chunk is written by Winape WinAPE when some data areas are set.
The number of stored data areas in the chunk is given by the chunk size divided by 10 (the size of one data area data structure).
|}
===Notes===
1. Winape's addressing scheme is 4 bytes. The upper 16-bits effectively define the internal 64KB pages it uses.
== REMU == This chunk is written RASM and contains information about symbols and breakpoints.ACE will import informations from this chunk but won't write it (SYMB and BRKC are used instead). == RM00-FF Chunk ==
This chunk is supported was introduced by RASM and is supported by ACE; it is saved only when the related option is enabled.
The RM00-FF chunks contain at most 16KB of data representing the contents of the related external upper ROMs number. The data may be compressed or stored uncompressed. If the size is exactly 16384 bytes the data is uncompressed, otherwise it is compressed. Up to 2MB of external upper ROMs can be stored in a snapshot.
The compression scheme is identical to the one from MEM0-7 chunks.
== LOWR Chunk ==
This chunk is supported was introduced by RASM and is supported by ACE; it is saved only when the related option is enabled.
It is similar to the RM00-FF chunks but stored the internal firmware ROM contents.
== BASR Chunk (ACE) ==
This chunk is supported by ACE; it is saved only when the related option is enabled.
It is similar to the RM00-FF chunks but stored the internal Basic ROM contents.
== DOSR Chunk (ACE) ==
This chunk is supported by ACE; it is saved only when the related option is enabled.
It is similar to the RM00-FF chunks but stored the internal AMSDOS ROM contents.
== CART Chunk (ACE) ==
This chunk is supported by ACE; it is saved only when the related option is enabled.
It stores the contents of the inserted cartridge ROM. Extended cartridges are also supported.
|}
== PLUG Chunk (ACE) == This chunk is supported by ACE; it is saved only when the related option is enabled.
This chunk stores the names of the plugins which should be enabled for the snapshot.
The names stored are the actual names of the plugins libraries (e.g. "multiface2.acepansion").
== REMU Chunk == This chunk is written RASM and can be read by ACE. =Links=
[[Snapshot Archive]]
[[Category:Programming]]