Home | History | Annotate | Download | only in ev3
      1 Summary
      2 =======
      3 
      4 LEGO MINDSTORMS EV3 is a toy robot produced by the LEGO Group. It is based
      5 on the davinci da850 evm. The EV3 has a 16MB spi flash and a SDHC microSD card
      6 reader.
      7 
      8 Booting
      9 =======
     10 
     11 The EV3 contains a bootloader in EEPROM that loads u-boot.bin from address 0x0
     12 of the SPI flash memory (with a size of 256KiB!). Because the EEPROM is read-
     13 only and it takes care of low level configuration (PLL and DDR), we don't use
     14 U-Boot to produce an SPL image.
     15 
     16 Using the default configuration, U-Boot had a boot scrips that works as follows:
     17 
     18 * Check to see if microSD card is present
     19 * If it is, try to load boot.scr from the first FAT partition
     20 * If loading boot.scr was successful, run it
     21 * Otherwise, try loading uEnv.txt
     22 * If loading uEnv.txt was successful, import it
     23 * If there is a uenvcmd variable (from uEnv.txt), run it
     24 * Try to load uImage from the first FAT partition
     25 * If it was successful, try to load da850-lego-ev3.dtb
     26 * If loading uImage was successful, boot it (DT is optional)
     27 * If none of the above was successful, try booting from flash
     28 
     29 Suggested Flash Memory Layout
     30 =============================
     31 
     32 The following is based on the default U-Boot configuration:
     33 
     34 | Image (file)       | Start Addr. | Max. Size         |
     35 +--------------------+-------------+-------------------+
     36 | u-boot.bin         |         0x0 |  0x40000 (256KiB) |
     37 | da850-lego-ev3.dtb |     0x40000 |  0x10000 (64KiB)  |
     38 | uImage             |     0x50000 | 0x400000 (4MiB)   |
     39 | rootfs (squashfs)  |    0x450000 | 0xa00000 (10MiB)  |
     40 
     41 Writing image to flash
     42 ======================
     43 
     44 The EEPROM contains a program for uploading an image file to the flash memory.
     45 The program is started by holding down the right button on the EV3 when powering
     46 it on. You can also `run fwupdateboot` in the u-boot shell to reboot into this
     47 mode. The image can then be uploaded using the official LEGO MINDSTORMS EV3
     48 software or a 3rd party program capable of uploading a firmware file.
     49 
     50 If you are booting from the microSD card, it is enough to just write uboot.bin
     51 to the flash. If you are not using a microSD card, you will need to create an
     52 image file using the layout described above.
     53