Giter VIP home page Giter VIP logo

u-boot-build's Introduction

u-boot-build

GitHub Actions workflows to build u-boot for a few Rockchip boards.

Build u-boot for RK3328 Build u-boot for RK3399 Build u-boot for RK356x Build u-boot for RK3588

Source repositories

Produced artifacts

  • u-boot-rockchip.bin for use with SD card or eMMC module
  • u-boot-rockchip-spi.bin for use with SPI flash

These files contain idbloader.img and u-boot.itb at their expected offsets.

Flashing

SD card or eMMC module

Write the u-boot-rockchip.bin image to sector 64 of a SD card or eMMC module (assumed to be /dev/mmcblk0):

dd if=u-boot-rockchip.bin of=/dev/mmcblk0 bs=32k seek=1 conv=fsync

eMMC using U-Boot cmdline

  • Put u-boot-rockchip.bin on first partition of a SD card.
  • Run from U-Boot cmdline:
# Read u-boot-rockchip.bin from first partition of a SD card
load mmc 1:1 10000000 u-boot-rockchip.bin

# Change to eMMC
mmc dev 0

# Write 10 MiB (0x5000 blocks) at sector 64 (0x40)
mmc write $fileaddr 40 5000

SPI flash

Write the u-boot-rockchip-spi.bin image to begining of SPI flash (assumed to be /dev/mtd0) using flashcp:

flashcp -v -p u-boot-rockchip-spi.bin /dev/mtd0

Or using U-Boot cmdline:

  • Put u-boot-rockchip-spi.bin on first partition of a SD card.
  • Run from U-Boot cmdline:
# Initialize SPI flash
sf probe

# Read u-boot-rockchip-spi.bin from first partition of a SD card
load mmc 1:1 10000000 u-boot-rockchip-spi.bin

# Write to begining of SPI flash
sf update $fileaddr 0 $filesize

Erase U-Boot from SPI flash (assumed to be /dev/mtd0) using flash_erase:

flash_erase /dev/mtd0 0 16

Or erase using U-Boot cmdline:

# Initialize SPI flash
sf probe

# Erase first 64 KiB (0x10000 bytes) of SPI flash
sf erase 0 +10000

u-boot-build's People

Contributors

kwiboo avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.