Development Environment Setup (I) OK6410A Development Environment 3 Change Environment FAIL

Publisher:HappyExplorerLatest update time:2022-09-28 Source: csdnKeywords:OK6410A  FAIL Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

Boot from u-boot (1.1.6) in nand


u-boot loads the kernel (4.0) from the first partition (formatted as fat16) in the sd card, and then the kernel starts.


The kernel mounts the second partition in the SD card (formatted as ext3) as the root file system and executes /linuxrc


/linuxrc is started as process 1


u-boot and boot mode


uboot(1.1.6) configuration forlinx_nand_ram256_config


sd card partition 1 (starting from 0, 32M), fat16, storage kernel, setenv bootcmd fatload mmc 0:1 0x50008000 zImage; bootm 0x50008000

That is to say, uboot has fat16 file system and mmc driver, and has fatload command

There is mmc driver in uboot, but forlinx_nand_ram256_config does not compile mmc driver. It needs to be transplanted and sorted out.


kernel

Partition 1 (starting from 0, 32M), fat16, storage kernel, setenv bootcmd fatload mmc 0:1 0x50008000 zImage; bootm 0x50008000

That is to say, uboot has fat16 file system and mmc driver, and has fatload command

uboot(1.1.6) configuration forlinx_nand_ram256_config


Partition 2 (starting from 32M, to the first 2M at the end), ext4, store rootfs, setenv bootargs console=ttySAC0 root=/dev/mmcblk0p2 rw rootfstype=ext3 rootwait earlyprintk

That is to say, the kernel has the ext4 file system and the mmc driver


rootfs

---------------------------The following are the changes


rootfs (ext3 format, uncompressed 7.8M, compressed 3.5M), refer to the ok6410-a branch of https://github.com/lisider/busybox

rootfs is in the sd card (the sd card has one primary partition, which is formatted as ext3)

Graphics support in rootfs is NULL


Required command

sudo fdisk -l /dev/sdb //Insert the sd card in ubuntu, it will be displayed as /dev/sdb, and then interactively create partitions

sudo mkfs.ext3 /dev/sdb1 //Format the partition as ext3


sudo mount -t ext3 /dev/sdb1 /mnt // Mount the file system


sudo cp rootfs/* /mnt // Fill the file system with the content required by the root file system. The creation of rootfs content needs to refer to the ok6410-a branch of https://github.com/lisider/busybox


sudo umount /mnt/ Unmount the file system

Keywords:OK6410A  FAIL Reference address:Development Environment Setup (I) OK6410A Development Environment 3 Change Environment FAIL

Previous article:Development Environment Construction (II) OK6410A Development Environment Others
Next article:Development environment setup (I) OK6410A Development environment 2 Change environment OK

Latest Microcontroller Articles
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号