sololinker RV1106 SDK简单实用

一、切换到sololinker/project$目录执行:

./build.sh usage
查看项目配置信息及操作命令

**************************************
Check [OK]: dtc --version
**************************************
Check [OK]: makeinfo --version
**************************************
Check [OK]: gperf --version
**************************************
Check [OK]: dpkg --list |grep g++-.*-multilib
**************************************
Check [OK]: dpkg --list |grep gcc-.*-multilib
**************************************
Check [OK]: make -v
**************************************
Check [OK]: gzip -V
GLOBAL_PARTITIONS: 0x40000@0x0(env),0x100000@0x40000(idblock),0x100000@0x140000(uboot),0x500000@0x240000(boot),0xEB00000@0x740000(rootfs)
[build.sh:info] Partition Filesystem Type Configure: rootfs@IGNORE@ubifs
Usage: build.sh [OPTIONS]
Available options:
lunch -Select Board Configure
env -build env
meta -build meta (optional)
uboot -build uboot
kernel -build kernel
rootfs -build rootfs
driver -build kernel's drivers
sysdrv -build uboot, kernel, rootfs
media -build rockchip media libraries
app -build app
recovery -build recovery
tool -build tool
updateimg -build update image
unpackimg -unpack update image
factory -build factory image
all -build uboot, kernel, rootfs, recovery image
allsave -build all & firmware & save

clean -clean all
clean uboot -clean uboot
clean kernel -clean kernel
clean driver -clean driver
clean rootfs -clean rootfs
clean sysdrv -clean uboot/kernel/rootfs
clean media -clean rockchip media libraries
clean app -clean app
clean recovery -clean recovery

firmware -pack all the image we need to boot up system
ota -pack update_ota.tar
save -save images, patches, commands used to debug
check -check the environment of building
info -see the current board building information

Default option is 'allsave'.
[build.sh:info] Running usage succeeded.

二、配置板及信息
./build.sh lunch

You're building on Linux
Lunch menu...pick a combo:

BoardConfig-*.mk naming rules:
BoardConfig-"启动介质"-"电源方案"-"硬件版本"-"应用场景".mk
BoardConfig-"boot medium"-"power solution"-"hardware version"-"applicaton".mk

----------------------------------------------------------------
0. BoardConfig-EMMC-ALL-2xRK806-HW_V10-IPC_MULTI_SENSOR.mk
boot medium(启动介质): EMMC
power solution(电源方案): 2xRK806
hardware version(硬件版本): HW_V10
applicaton(应用场景): IPC_MULTI_SENSOR
----------------------------------------------------------------

----------------------------------------------------------------
1. BoardConfig-SPI_NAND-ALL-RK806-HW_V10-IPC_SINGLE_SENSOR.mk
boot medium(启动介质): SPI_NAND
power solution(电源方案): RK806
hardware version(硬件版本): HW_V10
applicaton(应用场景): IPC_SINGLE_SENSOR
----------------------------------------------------------------

Which would you like? [0]:

三、系统全编译
  ./build.sh

四、内核配置(切换到sololinker/sysdrv/source/kernel)
  1、make menuconfig           //配置内核
  2、make ARCH=arm savedefconfig    //保存配置
  3、cp defconfig ./arch/arm/configs/rv1106_defconfig 或者 cp defconfig ./arch/arm/configs/rv1106-evb.config (KERNEL_CFG_FRAGMENT)
  4、./build.sh kernel              //编译内核
  5、./build.sh firmware          //命令打包成镜像

五、文件系统(切换到sololinker/sysdrv)
  1、制作ext4文件系统
  ./out/bin/pc/mkfs_ext4.sh <source> <dest image> <partition size>
  例如,制作用于emmc,镜像大小64MB的ext4文件系统镜像命令:
  ./out/bin/pc/mkfs_ext4.sh rootfs_source_dir rootfs.ext4 64*0x100000

  2、制作spi nor启动介质的文件系统镜像
  ./out/bin/pc/mkfs_jffs2.sh <source> <dest image> <partition size>
  例如,制作用于spi nor,镜像大小8MB的jffs2文件系统镜像命令:
  ./out/bin/pc/mkfs_jffs2.sh  rootfs_source_dir  rootfs.jffs2  8*0x100000

  3、制作spi nand或slc nand启动介质的文件系统镜像
  ./out/bin/pc/mkfs_ubi.sh <source dir> <output dir> <partition size> <partition name> <fs type> <fs comp>
  <fs type>: filesystem type on ubi (default ubifs)
  support ubifs or squashfs(readonly)

  <fs comp>: filesystem compression
    <fs type> is ubifs, support lzo|zlib
    <fs type> is squashfs, support lz4|lzo|lzma|xz|gzip

  例如,制作用于spi nand或slc nand,镜像大小64MB的ubifs文件系统镜像命令:
  mkdir rootfs_image_out
  ./out/bin/pc/mkfs_ubi.sh  rootfs_source_dir  rootfs_image_out  64*0x100000  rootfs  ubifs

  ls -l rootfs_image_out
  rootfs.img -> rootfs_2KB_128KB_64MB.ubi
  rootfs_2KB_128KB_64MB.ubi --------------- 镜像用于page size 2KB,block size 128KB的spi nand或slc nand
  rootfs_2KB_256KB_64MB.ubi --------------- 镜像用于page size 2KB,block size 256KB的spi nand或slc nand
  rootfs_4KB_256KB_64MB.ubi --------------- 镜像用于page size 4KB,block size 256KB的spi nand或slc nand

posted @ 2024-05-23 13:08  *^VV^*  阅读(84)  评论(0编辑  收藏  举报