Superboot

From ARMWorks
Jump to: navigation, search

SuperBoot is the latest bootloader used by FriendlyARM for all its boards. The nice features of SuperBoot, is it allows updating the firmware, and in some cases booting the Operating System from an SD card. It can also be set up for updating by USB.

Useful Links

SD Card

The SD Card method has two basic requirements, a basic file structure, and the FriendlyARM.ini file, which holds all of the configuration data on what actions should be taken.

Format SD Card

For all variations, the SD Card should be formatted as FAT32.

Depending on your board, you may need to also add a copy of the relevant SuperBoot.bin file to the SD Card. This process can be done on Windows with the respective SD-Flasher app found in SD Card Tools Repo. If you use Linux, you will need to manually burn SuperBoot to a specific address on the SD Card. Note this is a different process than just copying the file to the disk, this process puts SuperBoot.bin at a specific address, where the SoC can find it during bootup.

  • Mini2440: No need to put SuperBoot.bin to the SD Card.
  • Mini2451: SuperBoot.bin goes near end of SD Card.
  • Mini210: SuperBoot.bin at address 512.

SD Card Structure

SuperBoot will look for the FriendlyARM.ini file in a directory called images in the root of the SD Card. The rest of your files will reside inside this images directory also. You are allowed to organize your files in directories if so desired, only FriendlyARM.ini is required to be a direct decedent of images.

  • SD Card/
    • images/
      • FriendlyARM.ini
      • Firmware/kernel/files/directories/etc

FriendlyARM.ini Options

Once you've got your SD Card directory structure, you'll need to configure the FriendlyARM.ini file.

There are several parameters and values available, you will mostly be concerned with the General Commands and the OS or UserBin you are dealing with.

General Options
Option Value Description
CheckOneButton Yes Button press needed to resume booting
No System reboots completely after reset
Action Install Install files from SD Card
Run Run files from SD Card
OS Linux Linux OS
WindowsCE6 WinCE 6 OS
Ubuntu Ubuntu Linux OS
Android Android OS
UserBin single file image ex uCos2 or Rt-thread
VeryifyNandWrite yes Verify NAND after writing
no Do not verify NAND after writing
LowFormat yes Perform low level format
no No low level format
StatusType LED to for both
Beeper Beeper
USB-Mode yes Allow booting through USB
no Disable booting through USB


UserBin Options
Option Value Description
UserBin-Bootloader /file Bootloader file
UserBin-StartAddress Hex Location of user binary
UserBin-Image /file File to load


Android Options
Option Value Description
Android-BootLoader /file Bootloader file
Android-Kernel /file Kernel file
Android-CommandLine various Boot arguments
Android-RootFS-InstallImage /file File system image


Linux Options
Option Value Description
Linux-BootLoader /file Bootloader file
Linux-Kernel /file Kernel file
Linux-CommandLine various Boot arguments
Linux-RootFS-InstallImage /file File system image
Linux-RootFS-RunImage /file Depends on CPIO/img type, (ext3)


WinCE 6 Options
Option Value Description
WindowsCE6-BootLoader /file Bootloader file
WindowsCE6-BootLogo /file Boot Logo BMP 24 bit color
WindowsCE6-InstallImage /file Install image
WindowsCE6-RunImage /file Running image



Cmdline Options
Option Value Description
ctp 2 Cap touch screen, leave off for resistive.
skipcali y/n Skips touchscreen calibration

FriendlyARM.ini Example

#This line cannot be removed. by FriendlyARM(www.arm9.net)

CheckOneButton=No
Action = Install
OS = Android

LCD-Mode = No
LCD-Type = S70 

LowFormat = No
VerifyNandWrite = No
CheckCRC32=No

StatusType = Beeper | LED

################### Android 4.0.3 ####################
Android-BootLoader = Superboot210.bin
Android-Kernel = Android/zImage
Android-CommandLine = root=/dev/mtdblock4 rootfstype=yaffs2 console=ttySAC0,115200 init=/linuxrc  androidboot.console=ttySAC0
Android-RootFs-InstallImage = Android/rootfs_android-mlc2.img

################### Android 2.3.1 ####################
#Android-BootLoader = Superboot210.bin
#Android-Kernel = Android2.3.1/zImage
#Android-CommandLine = root=/dev/mtdblock4 rootfstype=yaffs2 console=ttySAC0,115200 init=/linuxrc  androidboot.console=s3c2410_serial0
#Android-RootFs-InstallImage = Android2.3.1/rootfs_android-mlc2.img

################### Linux ####################
Linux-BootLoader = Superboot210.bin
Linux-Kernel = Linux/zImage
Linux-CommandLine = root=/dev/mtdblock4 rootfstype=yaffs2 console=ttySAC0,115200 init=/linuxrc
Linux-RootFs-InstallImage = Linux/rootfs_qtopia_qt4-mlc2.img 

################### Windows CE6.0 ####################
WindowsCE6-Bootloader = Superboot210.bin
WindowsCE6-BootLogo = WindowsCE6\bootlogo.bmp
WindowsCE6-InstallImage = WindowsCE6\NK.bin
WindowsCE6-RunImage = WindowsCE6\NK.bin

The most important information here is to note that the Option OS is the prefix of one of the lower sections of this file. In this case it is Android.

Next you will want to configure where your bootloader, kernel, and rootfs firmware is located. This is relative to the image directory. So if you put your kernel in SD Card/images/myfiles/kernel you would set Android-Kernel = myfiles/kernel.

If there is a file you do not want to load, preface that line with a #, to comment it out. so

#Android-Kernel = Android/zImage

Would prevent SuperBoot from flashing the kernel to the device.

USB Flashing

If updating your device over USB connected to your computer fits your needs better, you can set USB-Mode = yes, note this is only available on SuperBoots built around the beginning of the year 2014. Now when you try and boot from the SD Card, it'll instead wait for files to be sent over USB.

MiniTools

In the provided sources, there is a program, one for Linux and one for Windows, called MiniTools. This is a rather basic program to use, which will autodetect your connected device. Then all you have to do is select the type of OS you want and pick the files you want to flash and it sends it over USB, see above.

Convert Mini2440

To SuperVivi

Some times your Mini2440 application may require the abilities of SuperBoot's predecessor SuperVivi, in that case, FriendlyARM has provided a solution, that you can find at Utils/mini2440_superboot_to_supervivi.zip in the SD Card Tools Repo

This is used just like a normal SuperBoot SD Card update, extract contents to a directory called images/ on a formatted SD Card. Then set your board to boot from SD, it will then flash SuperVivi to the NOR, and you will be all set to use it.

Remember, SuperVivi uses DNW, a Windows program, that uses USB and Serial to interact, SuperBoot does not.