• Our software update is now concluded. You will need to reset your password to log in. In order to do this, you will have to click "Log in" in the top right corner and then "Forgot your password?".
  • Welcome to PokéCommunity! Register now and join one of the best fan communities on the 'net to talk Pokémon and more! We are not affiliated with The Pokémon Company or Nintendo.

Research: AT7 Archive Format - Pokémon Mystery Dungeon Adventure Squad (WiiWare)

Platinum Lucario

The Legendary Master of [color=#D8D48C]Light[/colo
1,607
Posts
16
Years
AT7 Archive Format - Pok?mon Mystery Dungeon Adventure Squad (WiiWare)

AT7 File Format Research


As far as I've been looking into the WiiWare Pok?mon Mystery Dungeon games code, I have come across an archival file format which I have never seen before. It's the AT7 Archive Format.

So, what is currently known about it? Well from what I've gathered from examining it's data, it is file format that contains files, folders and uses it's very own compression format in which is completely different from LZ77 or even YAZ0 compression. These files have currently only been found in Pok?mon Mystery Dungeon: Blazing/Stormy/Light Adventure Squad WiiWare games. There's a possibility that it could be found in other Wii games that Chunsoft has developed. If so, please post about it here in this thread.

And if there's anything else you can find in it's code or even how the compression style works, please post it here in this thread.

Also, you'll need a program called "ShowMiiWads" in order to extract the contents from a .wad file and you will need to unpack the largest .app file (which is in a U8 archive format) using ShowMiiWads too.

Researched so far:
  • Empty data inside the file is indicated by the multiple "45" hexadecimal bytes.


Data found so far:
Code:
0x0-2 - Header ID "AT7"

Documentation:

AT7 File Container Format
Documentation for...
Pok?mon Mystery Dungeon: Keep Going! Blazing Adventure Squad
Pok?mon Mystery Dungeon: Let's Go! Stormy Adventure Squad
Pok?mon Mystery Dungeon: Go For It! Light Adventure Squad
Or by it's other names...
Pok?mon Mystery Dungeon: Forward! Adventurers of Flame
Pok?mon Mystery Dungeon: Let's Go! Adventurers of Storm
Pok?mon Mystery Dungeon: Aspire! Adventurers of Light
All on WiiWare~
Hello everyone, I've actually been making some progress with the research into the AT7 File Container format, here's what I have currently documented:
As of now, I've done some huge research into the AT7 Container format
and I have made some progress (finally). The AT7 format is split into
multiple segments and blocks. Each segment has a 6-byte long header, both which
indicate it's ID and size of the segment. AT7P counts the header, where as
AT7X does not. Unlike AT4PX or PKDPX, the segments don't have control flags in
it's header, it uses a different kind of format (which needs to be further
examined).
Now here's some examples of where you can find the AT7 Segments for data2_WPAJ.bin:
Address Type Segment Size 0x0 - 42F8 AT7P 42F9 bytes (Dec: 17,145 bytes) 0x42F9 - 87C1 AT7P 44C8 bytes (Dec: 17,608 bytes) 0x11589 - 1D58E AT7X C006 bytes (Dec: 49,158 bytes) 0x1D58F - 29594 AT7X C006 bytes (Dec: 49,158 bytes) 0x29595 - 3559A AT7X C006 bytes (Dec: 49,158 bytes) 0x3559B - 415A0 AT7X C006 bytes (Dec: 49,158 bytes) .. 0x14AAD78-14BFFF0 AT7E 15288 (Dec: 86,664 bytes)
(This would keep going on and on, can't post all of the offsets
since it would take too long, but I am posting about AT7E though)
Segments

AT7P segments can be any size! The size of the segment is always stated
at offsets 0x4-5 in little endian. Where as AT7X is always at a fixed size,
therefore meaning that offsets 0x4-5 will only count the compressed data, but
not the header. The entire AT7 file container is split into blocks, containing
131,072 bytes (20000h) each. The AT7E segment always indicates the end of the
archived files and then the free space comes after the AT7E header.

AT7P Segment Info
Offset Name Type Endianness Size 0x0-3 Text (AT7P) - Big Endian 4 bytes 0x4-5 AT7P Length* uint16 Little Endian 2 bytes 0x6 Compressed data begins - - - * - These bytes count both the header and compressed data

AT7X Segment Info**
Offset Name Type Endianness Size 0x0-3 Text (AT7X) - Big Endian 4 bytes 0x4-5 Compressed data size*** uint16 Little Endian 2 bytes 0x6-C006 Compressed data - - 49,152 bytes (fixed size) ** - It always has a fixed length of 49,158 bytes (C006h) each
*** - The bytes are always 00 C0 (C000h), which means it is always 49,152 bytes long in decimal. Unlike AT7P, these bytes only count the compressed data, but not the header

AT7E Segment Info****
Offset Name Type Endianness Size 0x0-3 Text (AT7E) - Big Endian 4 bytes 0x4 Free space***** - - - **** - This segment always indicates the end of the AT7 container, before the free space
***** - These bytes can be any size, the entire AT7 container is made of blocks that are 131,072 bytes (20000h) each, and all free space bytes have a value of "45". The size of the free space will depend on how much space the last block has left over. For example, the last block of data2_WPAJ.bin only has AD7C (44,412 bytes) of data left in it 20000h - AD7Ch = 15284h (86,660 bytes), which means data2_WPAJ.bin only has 86,660 bytes of free space with each byte value of "45"

Blocks
Blocks are sections of the container that make up the file, like how sectors work on a Hard Disk Drive. Each block is 131,072 bytes long (20000h). There can be multiple blocks within an AT7 container, for example, data2_WPAJ.bin contains 166 blocks (A6 in hexadecimal). But some contain as little as just 1 block (such as data1_WPAJ.bin). If the last block of the AT7 container has free space, the end of the data will be flagged with the AT7E segment, beginning the start of the free space.
 
Last edited:
Back
Top