JuiceBox Boot

From eLinux.org
Jump to: navigation, search

Booting the JuiceBox

This page documents the boot conditions that are supported by the JuiceBox.

Boot Process

The Juice'Box will always boot first from its internal JuiceBox Boot Rom and depending on certain conditions will then either execute the onboard MP3 and Demo modes or continue to boot from an external NAND device on the JuiceBox Slot connector. Normally the external boot device is a JuiceWare cartridge but any NAND with the correct data in the first 0x250 bytes will boot. See JuiceWare Test Image for details of making a boot-able NAND flash. The Juice'Box will not boot from an MMC card. The Mem Test indicates that up to 4 NAND devices are supported. The following table was developed by running the Mem Test with the chip select (nCS) of a boot-able NAND flash connected to each of the "unused" pins on the external connector.

CPU Pin CPU function Cart. pin NAND nCS boot? Comment:
116 GPC2 2 1 Yes
105 GPC11 4 2 No MMC nCS, if an MMC is detected the JB will NOT boot from NAND.
106 GPC10 20 3 No One of the "cartridge detect" bits
107 GPC9 22 4 No One of the "cartridge detect" bits
- VSS 19/21 All Yes If the NAND nCS is always low the Memory Test detects four chips. Each will show the same checksum.This is the behavior seen with a "normal" Juice'Ware Cartridge.

As can be seen from the table above only "Cartridge #1" (GPC2) will be seen as boot-able. Also if a MMC card is found the NAND will be ignored and the Juice'Box will boot to MP3 mode. Below is a simplified high level view of the boot process;

/*JuiceBox boot sequence pseudo code*/
bool checkMMC() {/*If MMC detected with GPC11 low - return TRUE else FALSE*/}
bool validNAND() {/*If Correct data read from NAND interface with GPC2 low - return TRUE else FALSE*/}
bool validMMC() {/*If FAT12/16 detected with at least one file type .mp3 or .jbp in /- return TRUE else FALSE*/}
void runDemo() {/*Play Demo Loop*/}
void mp3Mode() {/*Boot mp3 mode*/}
void bootNAND() {/*Read first pages from NAND - boot accordingly (JuiceWare etc.)*/}
void main()
  if (checkMMC()) 
      if (validMMC()) 
    } elseif (validNAND())