Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
These build instructions are for Linux; building on other operating systems is untested.
First make sure you have all build dependencies installed. This includes the standard packages you need to compile (GCC, Make etc) and the libraries "libusb" (package
libusb-1.0-0 on Debian/Ubuntu) and "libconfuse" (package
libconfuse-dev on Debian/Ubuntu), plus their development packages. Also make sure you have the version control system
To fetch the source and build it, run these commands:
git clone git://github.com/gcwnow/ingenic-boot.git cd ingenic-boot make
The script named
ingenic-boot at the top of the source dir is the most convenient way to use ingenic-boot.
The images you can flash are the master boot record
mbr.bin, the boot loader
ubiboot-<hwconf>.bin, the system image
system.bin and the data image
data.bin. The system image is a vfat file system containing the kernel and rootfs. The data image is an ext4 file system containing pre-installed applications and room for user data to be added later.
You can use the tools from the imager repository to create the MBR, system and data images.
Select hardware configuration
There are different hardware variants of the GCW Zero: prototypes (PCB v1.1 with 256MB DDR2 SDRAM) and production units (PCB v2.0 with 512MB MDDR SDRAM). The third type (PCB v1.1 with 512MB DDR2 SDRAM) was not released. You can easily see the difference between a prototype and production unit by turning on the Zero: if the green power LED turns on, it's a production unit.
The production variant is the default one, since eventually there will be many more people with a production unit than with a prototype unit. If you have a prototype unit, you must either add
--config=gcw0_v11_ddr2_256mb to the ingenic-boot command line, or set a new default by changing the symlink
fw/current.cfg to point to
Re-flashing the GCW Zero
NOTE: This process will erase all data on the internal SD card of the Zero. If you have valuable data there, make a backup first!
While powering on or rebooting the Zero, hold the SELECT key. This puts the JZ4770 into USB boot mode.
To perform the flashing, run:
./ingenic-boot --mbr=mbr.bin --boot=ubiboot-v20_mddr_512mb.bin --system=system.bin --data=data.bin
You can also do a partial re-flash by supplying only one or two of these images to
ingenic-boot. However, the data partition is resized on the Zero's first boot after reflashing, such that it spans the entire remainder of the SD card. This means that if you reflash the MBR you must reflash the data partition as well, otherwise the Zero's kernel will refuse to mount the data partition because the file system on it is larger than the partition that contains it.