So, I was wrong earlier when I said that boot.pac and boot5.pac are encrypted ... it turns out if you skip the 7-byte header at the beginning of the file, it turns out fine.
I'd be happy to email the disassembled files to anyone who asks, but they weren't so helpful. I've been sitting on this for a couple of days now, in the hopes that I could come up with some better answers, but I've decide I'm going down the wrong path.
I just read the patent that someone else here linked to, and here's my bigger-picture thoughts on the boot sequence of the PhatBox:
There are 5 places on-board the Phatbox that may be programmed:
- 2 flash ROM banks onboard the 8051 -- a 4k "emergency" bank and a 64k normal bank
- a PLD that's part of the IDE interface
- a PLD that's part of the headunit interface
- a 2-mbit (IE 256K) flash ROM chip that presumably contains the BIOS / boot code for the ARM
Here's where I think the code for each of these comes from:
4k bank: boot.pac or boot5.pac
64k bank: firmware.pac
IDE PLD: pre-programmed at factory through JTAG
headunit "glue" PLD: blank.bif/prog.bif
BIOS flash: programmed at factorty through ARM JTAG
Looking through boot5 didn't reveal much useful stuff. It looks like the thing turns on, waits for 51d to boot up, and does some handshaking, eventually sending it a "start_ok" message. It also has the capability to store a resume point, and send it back to 51d when it asks for it. All this occurs over /dev/ttyS1, I'm now certain.
I still haven't been able to disassemble firmware.pac; I think it is encrypted, and that it is written in an encrypted format to the 64 K flash directly.
The Winbond '51 clone datasheet indicates it has the ability to "protect" that area of memory, and that if the protection flag is enabled, any attempts to read out the ROM contents will return "encrypted" data. It doesn't indicate whether or not you could first turn on the "protect" flag and then upload ENCRYPTED data, but it's possible. The only thing is, there's no further documentation about this encryption. My guess is that they're just using a trivial cyclic XOR method. These can be (relatively-speaking) simply cracked, but I don't think it's worth the effort at this point. I think they actually ARE encrypting it to keep the details of the head unit interface proprietary, rather than obfuscating its involvement in the boot process (which doesn't start until 51d runs). Since my interests are in the latter, not the former, I'll let this lie for now.
Ben