QEMU_DOARMPI是个人学习而搭建,基于QEMU官方源码,定制开发的ARM架构的多核异构开发板。其根本目的是为方便开发人员能够在QEMU虚拟环境下模拟多核异构开发环境从而进行相关开发学习。
QEMU_DOARMPI是个人学习而搭建,基于QEMU官方源码,定制开发的ARM架构的多核异构开发板。其根本目的是为方便开发人员能够在QEMU虚拟环境下模拟多核异构开发环境从而进行相关开发学习。
QEMU_DOARMPI理论上可用于移植任意操作系统(例如:Linux、RT-Thread、HarmonyOS、FreeRTOS、uCOS等),并模拟各类硬件开发相关驱动程序和应用程序,现已支持的硬件外设有:LCD、以太网卡、I2C设备、触摸屏、SD卡、SPI设备、CAN设备、LED、BUTTON、SWITCH_KEY等一系列外设资源。
由于该项目的代码参考各类开源项目,由本人移植、编写、构建,其功可能会存在一些问题,希望通过对应联系和沟通方式友好交流,谢谢各位支持!
QEMU_DOARMPI目录结构如下图所示(git repo同步相关代码后):
| 名称 | 描述 |
|---|---|
| QEMU_VirtualBoard | 基于QEMU源码定制开发的ARM相关内容支持GUI界面 |
| Software | qemu软件目录和开发环境 |
| SYSTEM_DOARMPI | 各类操作系统源码 |
目前QEMU_DOARMPI已经移植RT-Thread、RT-Nano、Linux、FreeRTOS操作系统。
EmDevTool是Windows X64平台嵌入式开发工具,基于ConEmu终端程序,集成了ARM交叉编译工具,包含:FreeRTOS、RT-Thread、RT-Smart系统、QEMU、Linux应用、RT-Thread动态模块和RT-Smart用户态程序的编译环境等。
下载部署EmDevTool工具则无需执行2、3相关操作,但需要完整功能可在工具命令行执行repoconfig.exe,详情参考README.md文件。后续相关操作基本都是在这个工具执行命令。
打开Git - Install for Windows下载x64版的git,并安装
打开下载 – 阿里git客户端工具下载x64版的git-repo,并将其放在XXX\Git\bin目录下
将XXX\Git\bin目录加入环境变量
打开msys2官网下载x64版的msys2,安装到目录D:\msys64
参考QMEU Windows环境搭建的Native builds with MSYS2,网址为:Hosts/W32 - QEMU
msys2增加国内源
# 进入目录D:\msys64\etc\pacman.d
# 在mirrorlist.msys的前面插入
Server = https://mirrors.tuna.tsinghua.edu.cn/msys2/msys/$arch/
Server = http://mirrors.ustc.edu.cn/msys2/msys/$arch/
Server = http://mirror.bit.edu.cn/msys2/msys/$arch/
# 在mirrorlist.mingw32的前面插入
Server = https://mirrors.tuna.tsinghua.edu.cn/msys2/mingw/i686/
Server = http://mirrors.ustc.edu.cn/msys2/mingw/i686/
Server = http://mirror.bit.edu.cn/msys2/mingw/i686/
# 在mirrorlist.mingw64的前面插入
Server = https://mirrors.tuna.tsinghua.edu.cn/msys2/mingw/x86_64/
Server = http://mirrors.ustc.edu.cn/msys2/mingw/x86_64/
Server = http://mirror.bit.edu.cn/msys2/mingw/x86_64/
msys2更新源
# 双击运行D:\msys64\msys2.exe
$ pacman -Syu
$ pacman -Su
msys2安装mingw,并安装mingw和相关库
$ pacman -S base-devel mingw-w64-x86_64-toolchain git python ninja
$ pacman -S mingw-w64-x86_64-glib2 mingw-w64-x86_64-pixman python-setuptools
$ pacman -S mingw-w64-x86_64-gtk3 mingw-w64-x86_64-SDL2 mingw-w64-x86_64-libslirp
# 切换到软件目录下
$ cd Software
$ qemu-doarmpi.bat
QEMU-DOARMPI Information
System:
Display:
Serial:
Debug:
"help: qemu-doarmpi.bat [baremetal_r|baremetal_m|freertos_r|freertos_m|rtthread_r|rtthread_m|rnano_r|rnano_m|linux|linux_rtt_freertos] [gui|nogui] [stdio|telnet]"
CORTEX-R裸机(qemu-doarmpi.bat baremetal_r nogui stdio):
$ qemu-doarmpi.bat baremetal_r nogui stdio
QEMU-DOARMPI Information
System: baremetal_r
Display: nogui
Serial: stdio
Debug:
Run Cmd:F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\bin\qemu-system-aarch64.exe -M doarmpi -cpu cortex-r52 -smp 1 -m 128M -kernel F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\baremetal\baremetal-doarmpi-cortex-r.elf -append "console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr" -serial mon:telnet::4444,server,nowait -serial mon:stdio -serial mon:telnet::5555,server,nowait -monitor telnet::2222,server,nowait -nographic -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\baremetal\sd_r.bin,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\baremetal\sd_r.bin,format=raw -net nic,model=lan9118,netdev=hub0port0 -netdev hubport,id=hub0port0,hubid=0 -net nic,model=lan9118,netdev=hub0port1 -netdev hubport,id=hub0port1,hubid=0 -net nic,model=lan9118,netdev=hub0port2 -netdev hubport,id=hub0port2,hubid=0 -net user -readconfig F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\etc\cortex_r.conf -s
___ ___ ___ ______ ________________ __
/ _ )/ _ | / _ \/ __/ |/ / __/_ __/ _ | / /
/ _ / __ |/ , _/ _// /|_/ / _/ / / / __ |/ /__
/____/_/ |_/_/|_/___/_/ /_/___/ /_/ /_/ |_/____/
Build: Oct 29 2025 15:20:12
CPU Type: cortex-r
SDK Version: 1.0.0
[E/SDK][main.c:27][main]: This is error print
[W/SDK][main.c:28][main]: This is warn print
[I/SDK][main.c:29][main]: This is info print
[D/SDK][main.c:30][main]: This is debug print
DataType:
[I/SDK][main.c:33][main]: float:3.140000
[I/SDK][main.c:34][main]: uint32_t:4294967295
[I/SDK][main.c:35][main]: uint64_t:9223372036854775807
driver test menu:
t: test timer driver
r: test rtc driver
g: test gpio driver
i: test i2c driver
s: test spi driver
e: test enet driver
c: test can driver
m: test mci driver
l: test lcd driver
o: test ts driver
v: show version
q: quit test
input test driver:
CORTEX-M裸机(qemu-doarmpi.bat baremetal_m nogui stdio):
$ qemu-doarmpi.bat baremetal_m nogui stdio
QEMU-DOARMPI Information
System: baremetal_m
Display: nogui
Serial: stdio
Debug:
Run Cmd:F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\bin\qemu-system-aarch64.exe -M doarmpi -cpu cortex-m33 -smp 1 -m 2M -kernel F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\baremetal\baremetal-doarmpi-cortex-m.elf -append "console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr" -serial mon:telnet::5555,server,nowait -serial mon:telnet::4444,server,nowait -serial mon:stdio -monitor telnet::2222,server,nowait -nographic -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\baremetal\sd_m.bin,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\baremetal\sd_m.bin,format=raw -net nic,model=lan9118,netdev=hub0port0 -netdev hubport,id=hub0port0,hubid=0 -net nic,model=lan9118,netdev=hub0port1 -netdev hubport,id=hub0port1,hubid=0 -net nic,model=lan9118,netdev=hub0port2 -netdev hubport,id=hub0port2,hubid=0 -net user -readconfig F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\etc\cortex_m.conf -s
___ ___ ___ ______ ________________ __
/ _ )/ _ | / _ \/ __/ |/ / __/_ __/ _ | / /
/ _ / __ |/ , _/ _// /|_/ / _/ / / / __ |/ /__
/____/_/ |_/_/|_/___/_/ /_/___/ /_/ /_/ |_/____/
Build: Oct 29 2025 15:20:59
CPU Type: cortex-m
SDK Version: 1.0.0
[E/SDK][main.c:27][main]: This is error print
[W/SDK][main.c:28][main]: This is warn print
[I/SDK][main.c:29][main]: This is info print
[D/SDK][main.c:30][main]: This is debug print
DataType:
[I/SDK][main.c:33][main]: float:3.140000
[I/SDK][main.c:34][main]: uint32_t:4294967295
[I/SDK][main.c:35][main]: uint64_t:9223372036854775807
driver test menu:
t: test timer driver
r: test rtc driver
g: test gpio driver
i: test i2c driver
s: test spi driver
e: test enet driver
c: test can driver
m: test mci driver
l: test lcd driver
o: test ts driver
v: show version
q: quit test
input test driver:
CORTEX-R FreeRTOS操作系统(qemu-doarmpi.bat freertos_r nogui stdio):
$ qemu-doarmpi.bat freertos_r nogui stdio
QEMU-DOARMPI Information
System: freertos_r
Display: nogui
Serial: stdio
Debug:
Run Cmd:F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\bin\qemu-system-aarch64.exe -M doarmpi -cpu cortex-r52 -smp 1 -m 128M -kernel F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\freertos\freertos-doarmpi-cortex-r.elf -append "console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr" -serial mon:telnet::4444,server,nowait -serial mon:stdio -serial mon:telnet::5555,server,nowait -monitor telnet::2222,server,nowait -nographic -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\freertos\sd_r.bin,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\freertos\sd_r.bin,format=raw -net nic,model=lan9118,netdev=hub0port0 -netdev hubport,id=hub0port0,hubid=0 -net nic,model=lan9118,netdev=hub0port1 -netdev hubport,id=hub0port1,hubid=0 -net nic,model=lan9118,netdev=hub0port2 -netdev hubport,id=hub0port2,hubid=0 -net user -readconfig F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\etc\cortex_r.conf -s
____ ___ __________ ____
/ __/______ ___ / _ \/_ __/ __ \/ __/
/ _// __/ -_) -_) , _/ / / / /_/ /\ \
/_/ /_/ \__/\__/_/|_| /_/ \____/___/
Build: Oct 31 2025 15:48:20
CPU Type: cortex-r
System Version: 1.0.0
SDK Version: 1.0.0
HAL Version: 1.0.0
Shell Version: 3.1.2
LWIP Version: 2.1.3
LVGL Version: 8.3.11
Copyright: (c) 2023-2025 David
2025-11-03 17:14:21 [I/DRV][drv_rtc.c:145][DrvRtcInit]: Register rtc device succeed!
2025-11-03 17:14:21 [I/DRV][drv_gpio.c:428][DrvGpioInit]: Register pin device succeed!
2025-11-03 17:14:21 [I/DRV][drv_i2c.c:130][DrvI2cInit]: Register i2c0 bus succeed!
2025-11-03 17:14:21 [I/DRV][drv_spi.c:152][DrvSpiInit]: Register spi0 bus succeed!
2025-11-03 17:14:21 [I/DRV][drv_can.c:572][DrvCANInit]: Register can0 device succeed!
2025-11-03 17:14:21 [I/DRV][drv_enet.c:220][DrvENETInit]: Register en0 device success!
2025-11-03 17:14:21 [I/DRV][drv_mci.c:365][DrvMCIInit]: Register mci0 device succeed!
2025-11-03 17:14:21 [I/DEV][led.c:139][LedInit]: Register led device succeed!
2025-11-03 17:14:21 [I/DEV][button.c:137][ButtonInit]: Register button device succeed!
2025-11-03 17:14:21 [I/DEV][switch_key.c:74][SwitchKeyInit]: Register switch-key device succeed!
2025-11-03 17:14:21 [I/DEV][at24cxx.c:50][At24cXXInit]: Register at24cxx device succeed!
2025-11-03 17:14:21 [I/DEV][qemu_spi.c:38][QemuSpiInit]: Register qemu-spidev device succeed!
2025-11-03 17:14:21 [I/DEV][lan9118.c:217][Lan9118Init]: Initialize e0 device succeed!
2025-11-03 17:14:21 [I/DEV][lan9118.c:262][Lan9118NetLwipInit]: Initialize e0 lwip device succeed!
2025-11-03 17:14:21 [I/DEV][dev_lcd.c:73][LcdInit]: Register lcd device succeed!
2025-11-03 17:14:21 [I/DEV][dev_lcd.c:88][LcdInit]: Initialize lcd device succeed!
2025-11-03 17:14:21 [I/DEV][sd.c:229][SDInit]: Register sd0 device succeed!
2025-11-03 17:14:21 [I/APP][user_app.c:152][UserAppStart]: User application start!
2025-11-03 17:14:22 [I/APP][user_app.c:111][MntInit]: f_mount succeeded!
freertos-doarmpi(cortex-r):/$
CORTEX-M FreeRTOS操作系统(qemu-doarmpi.bat freertos_m nogui stdio):
$ qemu-doarmpi.bat freertos_m nogui stdio
QEMU-DOARMPI Information
System: freertos_m
Display: nogui
Serial: stdio
Debug:
Run Cmd:F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\bin\qemu-system-aarch64.exe -M doarmpi -cpu cortex-m33 -smp 1 -m 2M -kernel F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\freertos\freertos-doarmpi-cortex-m.elf -append "console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr" -serial mon:telnet::5555,server,nowait -serial mon:telnet::4444,server,nowait -serial mon:stdio -monitor telnet::2222,server,nowait -nographic -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\freertos\sd_m.bin,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\freertos\sd_m.bin,format=raw -net nic,model=lan9118,netdev=hub0port0 -netdev hubport,id=hub0port0,hubid=0 -net nic,model=lan9118,netdev=hub0port1 -netdev hubport,id=hub0port1,hubid=0 -net nic,model=lan9118,netdev=hub0port2 -netdev hubport,id=hub0port2,hubid=0 -net user -readconfig F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\etc\cortex_m.conf -s
____ ___ __________ ____
/ __/______ ___ / _ \/_ __/ __ \/ __/
/ _// __/ -_) -_) , _/ / / / /_/ /\ \
/_/ /_/ \__/\__/_/|_| /_/ \____/___/
Build: Oct 31 2025 15:40:41
CPU Type: cortex-m
System Version: 1.0.0
SDK Version: 1.0.0
HAL Version: 1.0.0
Shell Version: 3.1.2
LWIP Version: 2.1.3
LVGL Version: 8.3.11
Copyright: (c) 2023-2025 David
2025-11-03 17:15:56 [I/DRV][drv_rtc.c:145][DrvRtcInit]: Register rtc device succeed!
2025-11-03 17:15:56 [I/DRV][drv_gpio.c:428][DrvGpioInit]: Register pin device succeed!
2025-11-03 17:15:56 [I/DRV][drv_i2c.c:130][DrvI2cInit]: Register i2c0 bus succeed!
2025-11-03 17:15:56 [I/DRV][drv_spi.c:152][DrvSpiInit]: Register spi0 bus succeed!
2025-11-03 17:15:56 [I/DRV][drv_can.c:572][DrvCANInit]: Register can0 device succeed!
2025-11-03 17:15:56 [I/DRV][drv_enet.c:220][DrvENETInit]: Register en0 device success!
2025-11-03 17:15:56 [I/DRV][drv_mci.c:365][DrvMCIInit]: Register mci0 device succeed!
2025-11-03 17:15:56 [I/DEV][led.c:139][LedInit]: Register led device succeed!
2025-11-03 17:15:56 [I/DEV][button.c:137][ButtonInit]: Register button device succeed!
2025-11-03 17:15:56 [I/DEV][switch_key.c:74][SwitchKeyInit]: Register switch-key device succeed!
2025-11-03 17:15:56 [I/DEV][at24cxx.c:50][At24cXXInit]: Register at24cxx device succeed!
2025-11-03 17:15:56 [I/DEV][qemu_spi.c:38][QemuSpiInit]: Register qemu-spidev device succeed!
2025-11-03 17:15:56 [I/DEV][lan9118.c:217][Lan9118Init]: Initialize e0 device succeed!
2025-11-03 17:15:56 [I/DEV][lan9118.c:262][Lan9118NetLwipInit]: Initialize e0 lwip device succeed!
2025-11-03 17:15:56 [I/DEV][dev_lcd.c:73][LcdInit]: Register lcd device succeed!
2025-11-03 17:15:56 [I/DEV][dev_lcd.c:88][LcdInit]: Initialize lcd device succeed!
2025-11-03 17:15:56 [I/DEV][sd.c:229][SDInit]: Register sd0 device succeed!
2025-11-03 17:15:56 [I/APP][user_app.c:152][UserAppStart]: User application start!
2025-11-03 17:15:56 [I/APP][user_app.c:111][MntInit]: f_mount succeeded!
freertos-doarmpi(cortex-m):/$
CORTEX-R RTThread操作系统(qemu-doarmpi.bat rtthread_r nogui stdio):
$ qemu-doarmpi.bat rtthread_r nogui stdio
QEMU-DOARMPI Information
System: rtthread_r
Display: nogui
Serial: stdio
Debug:
Run Cmd:F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\bin\qemu-system-aarch64.exe -M doarmpi -cpu cortex-r52 -smp 1 -m 128M -kernel F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtthread\rtthread-doarmpi-cortex-r.elf -append "console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr" -serial mon:telnet::4444,server,nowait -serial mon:stdio -serial mon:telnet::5555,server,nowait -monitor telnet::2222,server,nowait -nographic -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtthread\sd_r.bin,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtthread\sd_r.bin,format=raw -net nic,model=lan9118,netdev=hub0port0 -netdev hubport,id=hub0port0,hubid=0 -net nic,model=lan9118,netdev=hub0port1 -netdev hubport,id=hub0port1,hubid=0 -net nic,model=lan9118,netdev=hub0port2 -netdev hubport,id=hub0port2,hubid=0 -net user -readconfig F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\etc\cortex_r.conf -s
\ | /
- RT - Thread Operating System
/ | \ 5.2.1 build Oct 31 2025 15:18:46
2006 - 2024 Copyright by RT-Thread team
lwIP-2.1.2 initialized!
2025-11-03 17:17:11 [I/DRV][drv_i2c.c:111][rt_hw_drv_i2c_init]: Register i2c0 bus succeed!
2025-11-03 17:17:11 [I/DRV][drv_spi.c:130][rt_hw_drv_spi_init]: Register spi0 bus succeed!
2025-11-03 17:17:11 [I/DRV][drv_gpio.c:474][rt_hw_drv_pin_init]: Register pin device succeed!
2025-11-03 17:17:11 [I/DRV][drv_mci.c:412][rt_hw_drv_mci_init]: Register mci0 device succeed!
2025-11-03 17:17:11 [I/DRV][drv_can.c:635][rt_hw_drv_can_init]: Register can0 device succeed!
2025-11-03 17:17:11 [I/DRV][drv_enet.c:196][rt_hw_drv_enet_init]: Register en0 device succeed!
2025-11-03 17:17:11 [I/DEV][button.c:146][rt_hw_dev_button_init]: Register button device succeed!
2025-11-03 17:17:11 [I/DEV][at24cxx.c:229][rt_hw_dev_at24cxx_init]: Register at24cxx device succeed!
2025-11-03 17:17:11 [I/DEV][dev_lcd.c:160][rt_hw_dev_lcd_init]: Register lcd device succeed!
2025-11-03 17:17:11 [I/DEV][dev_lcd.c:169][rt_hw_dev_lcd_init]: Initialize lcd device succeed!
2025-11-03 17:17:11 [I/DEV][led.c:142][rt_hw_dev_led_init]: Register led device succeed!
2025-11-03 17:17:11 [I/DEV][pl181.c:240][rt_hw_dev_pl181_init]: Initialize sd0 device succeed!
2025-11-03 17:17:11 [I/DEV][qemu_spi.c:24][rt_hw_dev_qemu_spi_init]: Register qemu-spidev device succeed!
2025-11-03 17:17:11 [I/DEV][switch_key.c:101][rt_hw_dev_switch_key_init]: Register switch-key device succeed!
[I/touch] rt_touch init success
2025-11-03 17:17:11 [I/DEV][dev_ts.c:221][rt_hw_dev_ts_init]: Register ts device succeed!
[I/sal.skt] Socket Abstraction Layer initialize success.
2025-11-03 17:17:11 [E/DRV][drv_mci.c:169][rt_hw_mci_transfer_cmd]: MCI_SendCmdNoBlocking timeout!
[I/SDIO] SD card capacity 65536 KB.
[I/SDIO] sd: switch to High Speed / SDR25 mode
2025-11-03 17:17:12 [I/APP][mnt.c:33][mnt_init]: File system initialization done!
2025-11-03 17:17:12 [I/DEV][lan9118.c:184][rt_hw_dev_lan9118_init]: Initialize e0 device succeed!
RTThread main function!
rtthread-doarmpi(cortex-r):/>
CORTEX-M RTThread操作系统(qemu-doarmpi.bat rtthread_m nogui stdio):
$ qemu-doarmpi.bat rtthread_m nogui stdio
QEMU-DOARMPI Information
System: rtthread_m
Display: nogui
Serial: stdio
Debug:
Run Cmd:F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\bin\qemu-system-aarch64.exe -M doarmpi -cpu cortex-m33 -smp 1 -m 2M -kernel F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtthread\rtthread-doarmpi-cortex-m.elf -append "console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr" -serial mon:telnet::5555,server,nowait -serial mon:telnet::4444,server,nowait -serial mon:stdio -monitor telnet::2222,server,nowait -nographic -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtthread\sd_m.bin,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtthread\sd_m.bin,format=raw -net nic,model=lan9118,netdev=hub0port0 -netdev hubport,id=hub0port0,hubid=0 -net nic,model=lan9118,netdev=hub0port1 -netdev hubport,id=hub0port1,hubid=0 -net nic,model=lan9118,netdev=hub0port2 -netdev hubport,id=hub0port2,hubid=0 -net user -readconfig F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\etc\cortex_m.conf -s
\ | /
- RT - Thread Operating System
/ | \ 5.2.1 build Oct 31 2025 15:21:11
2006 - 2024 Copyright by RT-Thread team
lwIP-2.1.2 initialized!
2025-11-03 17:18:19 [I/DRV][drv_i2c.c:111][rt_hw_drv_i2c_init]: Register i2c0 bus succeed!
2025-11-03 17:18:19 [I/DRV][drv_spi.c:130][rt_hw_drv_spi_init]: Register spi0 bus succeed!
2025-11-03 17:18:19 [I/DRV][drv_gpio.c:474][rt_hw_drv_pin_init]: Register pin device succeed!
2025-11-03 17:18:19 [I/DRV][drv_mci.c:412][rt_hw_drv_mci_init]: Register mci0 device succeed!
2025-11-03 17:18:19 [I/DRV][drv_can.c:635][rt_hw_drv_can_init]: Register can0 device succeed!
2025-11-03 17:18:19 [I/DRV][drv_enet.c:196][rt_hw_drv_enet_init]: Register en0 device succeed!
2025-11-03 17:18:19 [I/DEV][button.c:146][rt_hw_dev_button_init]: Register button device succeed!
2025-11-03 17:18:19 [I/DEV][at24cxx.c:229][rt_hw_dev_at24cxx_init]: Register at24cxx device succeed!
2025-11-03 17:18:19 [I/DEV][dev_lcd.c:160][rt_hw_dev_lcd_init]: Register lcd device succeed!
2025-11-03 17:18:19 [I/DEV][dev_lcd.c:169][rt_hw_dev_lcd_init]: Initialize lcd device succeed!
2025-11-03 17:18:19 [I/DEV][led.c:142][rt_hw_dev_led_init]: Register led device succeed!
2025-11-03 17:18:19 [I/DEV][pl181.c:240][rt_hw_dev_pl181_init]: Initialize sd0 device succeed!
2025-11-03 17:18:19 [I/DEV][qemu_spi.c:24][rt_hw_dev_qemu_spi_init]: Register qemu-spidev device succeed!
2025-11-03 17:18:19 [I/DEV][switch_key.c:101][rt_hw_dev_switch_key_init]: Register switch-key device succeed!
[I/touch] rt_touch init success
2025-11-03 17:18:19 [I/DEV][dev_ts.c:221][rt_hw_dev_ts_init]: Register ts device succeed!
[I/sal.skt] Socket Abstraction Layer initialize success.
[I/SDIO] SD card capacity 65536 KB.
[I/SDIO] sd: switch to High Speed / SDR25 mode
2025-11-03 17:18:20 [I/APP][mnt.c:33][mnt_init]: File system initialization done!
2025-11-03 17:18:20 [I/DEV][lan9118.c:184][rt_hw_dev_lan9118_init]: Initialize e0 device succeed!
RTThread main function!
rtthread-doarmpi(cortex-m):/>
CORTEX-R RTNano操作系统(qemu-doarmpi.bat rtnano_r nogui stdio):
$ qemu-doarmpi.bat rtnano_r nogui stdio
QEMU-DOARMPI Information
System: rtnano_r
Display: nogui
Serial: stdio
Debug:
Run Cmd:F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\bin\qemu-system-aarch64.exe -M doarmpi -cpu cortex-r52 -smp 1 -m 128M -kernel F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtnano\rtnano-doarmpi-cortex-r.elf -append "console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr" -serial mon:telnet::4444,server,nowait -serial mon:stdio -serial mon:telnet::5555,server,nowait -monitor telnet::2222,server,nowait -nographic -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtnano\sd_r.bin,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtnano\sd_r.bin,format=raw -net nic,model=lan9118,netdev=hub0port0 -netdev hubport,id=hub0port0,hubid=0 -net nic,model=lan9118,netdev=hub0port1 -netdev hubport,id=hub0port1,hubid=0 -net nic,model=lan9118,netdev=hub0port2 -netdev hubport,id=hub0port2,hubid=0 -net user -readconfig F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\etc\cortex_r.conf -s
2025-11-03 17:19:12 [I/DRV][drv_rtc.c:324][rt_hw_drv_rtc_init]: Register rtc device succeed!
\ | /
- RT - Thread Nano Operating System
/ | \ 5.2.1 build Oct 31 2025 15:15:58
2006 - 2024 Copyright by RT-Thread team
2025-11-03 17:19:12 [I/DRV][drv_i2c.c:205][rt_hw_drv_i2c_init]: Register i2c0 bus succeed!
2025-11-03 17:19:12 [I/DRV][drv_spi.c:249][rt_hw_drv_spi_init]: Register spi0 bus succeed!
2025-11-03 17:19:12 [I/DRV][drv_gpio.c:957][rt_hw_drv_pin_init]: Register pin device succeed!
2025-11-03 17:19:12 [I/DRV][drv_mci.c:753][rt_hw_drv_mci_init]: Register mci0 device succeed!
2025-11-03 17:19:12 [I/DRV][drv_can.c:1197][rt_hw_drv_can_init]: Register can0 device succeed!
2025-11-03 17:19:12 [I/DRV][drv_enet.c:406][rt_hw_drv_enet_init]: Register en0 device success!
2025-11-03 17:19:12 [I/DEV][button.c:265][rt_hw_dev_button_init]: Register button device succeed!
2025-11-03 17:19:12 [I/DEV][at24cxx.c:262][rt_hw_dev_at24cxx_init]: Register at24cxx device succeed!
2025-11-03 17:19:12 [I/DEV][dev_lcd.c:196][rt_hw_dev_lcd_init]: Register lcd device succeed!
2025-11-03 17:19:12 [I/DEV][dev_lcd.c:211][rt_hw_dev_lcd_init]: Initialize lcd device succeed!
2025-11-03 17:19:12 [I/DEV][led.c:263][rt_hw_dev_led_init]: Register led device succeed!
2025-11-03 17:19:12 [I/DEV][pl181.c:460][rt_hw_dev_pl181_init]: Register sd0 device succeed!
2025-11-03 17:19:12 [I/DEV][qemu_spi.c:45][rt_hw_dev_qemu_spi_init]: Register qemu-spidev device succeed!
2025-11-03 17:19:12 [I/DEV][switch_key.c:166][rt_hw_dev_switch_key_init]: Register switch-key device succeed!
2025-11-03 17:19:12 [I/DEV][dev_ts.c:387][rt_hw_dev_ts_init]: Register ts device succeed!
2025-11-03 17:19:12 [I/APP][mnt.c:86][mnt_init]: f_mount succeeded!
2025-11-03 17:19:12 [I/DEV][lan9118.c:404][rt_hw_dev_lan9118_init]: Initialize e0 device succeed!
RTNano main function!
rtnano-doarmpi(cortex-r):>
CORTEX-M RTNano操作系统(qemu-doarmpi.bat rtnano_m nogui stdio):
$ qemu-doarmpi.bat rtnano_m nogui stdio
QEMU-DOARMPI Information
System: rtnano_m
Display: nogui
Serial: stdio
Debug:
Run Cmd:F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\bin\qemu-system-aarch64.exe -M doarmpi -cpu cortex-m33 -smp 1 -m 2M -kernel F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtnano\rtnano-doarmpi-cortex-m.elf -append "console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr" -serial mon:telnet::5555,server,nowait -serial mon:telnet::4444,server,nowait -serial mon:stdio -monitor telnet::2222,server,nowait -nographic -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtnano\sd_m.bin,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtnano\sd_m.bin,format=raw -net nic,model=lan9118,netdev=hub0port0 -netdev hubport,id=hub0port0,hubid=0 -net nic,model=lan9118,netdev=hub0port1 -netdev hubport,id=hub0port1,hubid=0 -net nic,model=lan9118,netdev=hub0port2 -netdev hubport,id=hub0port2,hubid=0 -net user -readconfig F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\etc\cortex_m.conf -s
2025-11-03 17:19:52 [I/DRV][drv_rtc.c:324][rt_hw_drv_rtc_init]: Register rtc device succeed!
\ | /
- RT - Thread Nano Operating System
/ | \ 5.2.1 build Oct 31 2025 15:28:45
2006 - 2024 Copyright by RT-Thread team
2025-11-03 17:19:52 [I/DRV][drv_i2c.c:205][rt_hw_drv_i2c_init]: Register i2c0 bus succeed!
2025-11-03 17:19:52 [I/DRV][drv_spi.c:249][rt_hw_drv_spi_init]: Register spi0 bus succeed!
2025-11-03 17:19:52 [I/DRV][drv_gpio.c:957][rt_hw_drv_pin_init]: Register pin device succeed!
2025-11-03 17:19:52 [I/DRV][drv_mci.c:753][rt_hw_drv_mci_init]: Register mci0 device succeed!
2025-11-03 17:19:52 [I/DRV][drv_can.c:1197][rt_hw_drv_can_init]: Register can0 device succeed!
2025-11-03 17:19:52 [I/DRV][drv_enet.c:406][rt_hw_drv_enet_init]: Register en0 device success!
2025-11-03 17:19:52 [I/DEV][button.c:265][rt_hw_dev_button_init]: Register button device succeed!
2025-11-03 17:19:52 [I/DEV][at24cxx.c:262][rt_hw_dev_at24cxx_init]: Register at24cxx device succeed!
2025-11-03 17:19:52 [I/DEV][dev_lcd.c:196][rt_hw_dev_lcd_init]: Register lcd device succeed!
2025-11-03 17:19:52 [I/DEV][dev_lcd.c:211][rt_hw_dev_lcd_init]: Initialize lcd device succeed!
2025-11-03 17:19:52 [I/DEV][led.c:263][rt_hw_dev_led_init]: Register led device succeed!
2025-11-03 17:19:52 [I/DEV][pl181.c:460][rt_hw_dev_pl181_init]: Register sd0 device succeed!
2025-11-03 17:19:52 [I/DEV][qemu_spi.c:45][rt_hw_dev_qemu_spi_init]: Register qemu-spidev device succeed!
2025-11-03 17:19:52 [I/DEV][switch_key.c:166][rt_hw_dev_switch_key_init]: Register switch-key device succeed!
2025-11-03 17:19:52 [I/DEV][dev_ts.c:387][rt_hw_dev_ts_init]: Register ts device succeed!
2025-11-03 17:19:52 [I/APP][mnt.c:86][mnt_init]: f_mount succeeded!
2025-11-03 17:19:52 [I/DEV][lan9118.c:404][rt_hw_dev_lan9118_init]: Initialize e0 device succeed!
RTNano main function!
rtnano-doarmpi(cortex-m):>
Linux Kernel启动Linux系统(qemu-doarmpi.bat linux nogui stdio):
# username:root
# password:123456
$ qemu-doarmpi.bat linux nogui stdio
QEMU-DOARMPI Information
System: linux
Display: nogui
Serial: stdio
Debug:
Run Cmd:F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\bin\qemu-system-aarch64.exe -M doarmpi -smp 2 -m 2048M -kernel F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\Image -append "console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr" -serial mon:stdio -serial mon:telnet::4444,server,nowait -serial mon:telnet::5555,server,nowait -monitor telnet::2222,server,nowait -nographic -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -net nic,model=lan9118,netdev=hub0port0 -netdev hubport,id=hub0port0,hubid=0 -net nic,model=lan9118,netdev=hub0port1 -netdev hubport,id=hub0port1,hubid=0 -net nic,model=lan9118,netdev=hub0port2 -netdev hubport,id=hub0port2,hubid=0 -net user,hostfwd=tcp::23-:22 -readconfig F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\etc\cortex_a.conf -s
[ 0.000000] Booting Linux on physical CPU 0x0000000000 [0x412fd471]
[ 0.000000] Linux version 6.6.44 (work@95fdfbed1d58) (aarch64-linux-gcc.br_real (Buildroot 2024.02.6) 12.4.0, GNU ld (GNU Binutils) 2.40) #18 SMP PREEMPT Wed Dec 25 10:21:08 CST 2024
[ 0.000000] Machine model: linux,doarmpi-board
[ 0.000000] efi: UEFI not found.
[ 0.000000] NUMA: No NUMA configuration found
[ 0.000000] NUMA: Faking a node at [mem 0x00000000a0000000-0x000000011fffffff]
[ 0.000000] NUMA: NODE_DATA [mem 0x11fbee9c0-0x11fbf0fff]
[ 0.000000] Zone ranges:
[ 0.000000] DMA [mem 0x00000000a0000000-0x00000000ffffffff]
[ 0.000000] DMA32 empty
[ 0.000000] Normal [mem 0x0000000100000000-0x000000011fffffff]
[ 0.000000] Movable zone start for each node
[ 0.000000] Early memory node ranges
[ 0.000000] node 0: [mem 0x00000000a0000000-0x000000011fffffff]
[ 0.000000] Initmem setup node 0 [mem 0x00000000a0000000-0x000000011fffffff]
[ 0.000000] cma: Reserved 32 MiB at 0x00000000fe000000 on node -1
[ 0.000000] psci: probing for conduit method from DT.
[ 0.000000] psci: PSCIv1.1 detected in firmware.
[ 0.000000] psci: Using standard PSCI v0.2 function IDs
[ 0.000000] psci: Trusted OS migration not required
[ 0.000000] psci: SMC Calling Convention v1.0
[ 0.000000] percpu: Embedded 22 pages/cpu s50792 r8192 d31128 u90112
[ 0.000000] pcpu-alloc: s50792 r8192 d31128 u90112 alloc=22*4096
[ 0.000000] pcpu-alloc: [0] 0 [0] 1
[ 0.000000] Detected PIPT I-cache on CPU0
[ 0.000000] CPU features: detected: Address authentication (architected QARMA5 algorithm)
[ 0.000000] CPU features: detected: GIC system register CPU interface
[ 0.000000] CPU features: detected: Hardware dirty bit management
[ 0.000000] CPU features: detected: Spectre-v4
[ 0.000000] CPU features: detected: Spectre-BHB
[ 0.000000] CPU features: detected: ARM erratum 2067961 or 2054223
[ 0.000000] alternatives: applying boot alternatives
[ 0.000000] Kernel command line: console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr
[ 0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes, linear)
[ 0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes, linear)
[ 0.000000] Fallback order for Node 0: 0
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 516096
[ 0.000000] Policy zone: Normal
[ 0.000000] mem auto-init: stack:all(zero), heap alloc:off, heap free:off
[ 0.000000] software IO TLB: area num 2.
[ 0.000000] software IO TLB: mapped [mem 0x00000000fa000000-0x00000000fe000000] (64MB)
[ 0.000000] Memory: 1915208K/2097152K available (16832K kernel code, 4282K rwdata, 10616K rodata, 9152K init, 605K bss, 149176K reserved, 32768K cma-reserved)
[ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
[ 0.000000] rcu: Preemptible hierarchical RCU implementation.
[ 0.000000] rcu: RCU event tracing is enabled.
[ 0.000000] rcu: RCU restricting CPUs from NR_CPUS=256 to nr_cpu_ids=2.
[ 0.000000] Trampoline variant of Tasks RCU enabled.
[ 0.000000] Tracing variant of Tasks RCU enabled.
[ 0.000000] rcu: RCU calculated value of scheduler-enlistment delay is 25 jiffies.
[ 0.000000] rcu: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=2
[ 0.000000] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0
[ 0.000000] GICv3: 160 SPIs implemented
[ 0.000000] GICv3: 0 Extended SPIs implemented
[ 0.000000] Root IRQ handler: gic_handle_irq
[ 0.000000] GICv3: GICv3 features: 16 PPIs
[ 0.000000] GICv3: CPU0: found redistributor 0 region 0:0x0000000009020000
[ 0.000000] ITS [mem 0x0d021000-0x0d220fff]
[ 0.000000] ITS@0x000000000d021000: allocated 8192 Devices @100040000 (indirect, esz 8, psz 64K, shr 1)
[ 0.000000] ITS@0x000000000d021000: allocated 8192 Interrupt Collections @100050000 (flat, esz 8, psz 64K, shr 1)
[ 0.000000] GICv3: using LPI property table @0x0000000100060000
[ 0.000000] GICv3: CPU0: using allocated LPI pending table @0x0000000100070000
[ 0.000000] rcu: srcu_init: Setting srcu_struct sizes based on contention.
[ 0.000000] clocksource: arm,sp804: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns [ 0.000006] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 89478484971ns
[ 0.000170] arch_timer: cp15 timer(s) running at 62.50MHz (virt).
[ 0.000179] clocksource: arch_sys_counter: mask: 0x1ffffffffffffff max_cycles: 0x1cd42e208c, max_idle_ns: 881590405314 ns
[ 0.000192] sched_clock: 57 bits at 63MHz, resolution 16ns, wraps every 4398046511096ns
[ 0.028867] Console: colour dummy device 80x25
[ 0.036924] Calibrating delay loop (skipped), value calculated using timer frequency.. 125.00 BogoMIPS (lpj=250000)
[ 0.038405] pid_max: default: 32768 minimum: 301
[ 0.042383] LSM: initializing lsm=capability,integrity
[ 0.048418] Mount-cache hash table entries: 4096 (order: 3, 32768 bytes, linear)
[ 0.048650] Mountpoint-cache hash table entries: 4096 (order: 3, 32768 bytes, linear)
[ 0.129224] RCU Tasks: Setting shift to 1 and lim to 1 rcu_task_cb_adjust=1.
[ 0.130772] RCU Tasks Trace: Setting shift to 1 and lim to 1 rcu_task_cb_adjust=1.
[ 0.136640] rcu: Hierarchical SRCU implementation.
[ 0.136747] rcu: Max phase no-delay instances is 1000.
[ 0.146878] Platform MSI: msi-controller@d021000 domain created
[ 0.149539] PCI/MSI: /interrupt-controller@9000000/msi-controller@d021000 domain created
[ 0.150849] fsl-mc MSI: msi-controller@d021000 domain created
[ 0.165244] EFI services will not be available.
[ 0.168984] smp: Bringing up secondary CPUs ...
[ 0.182140] Detected PIPT I-cache on CPU1
[ 0.188987] GICv3: CPU1: found redistributor 1 region 0:0x0000000009040000
[ 0.190958] GICv3: CPU1: using allocated LPI pending table @0x0000000100080000
[ 0.195672] CPU1: Booted secondary processor 0x0000000001 [0x412fd471]
[ 0.203343] smp: Brought up 1 node, 2 CPUs
[ 0.203504] SMP: Total of 2 processors activated.
[ 0.203753] CPU features: detected: Branch Target Identification
[ 0.203888] CPU features: detected: 32-bit EL0 Support
[ 0.203964] CPU features: detected: ARMv8.4 Translation Table Level
[ 0.204058] CPU features: detected: Data cache clean to the PoU not required for I/D coherence
[ 0.204180] CPU features: detected: Common not Private translations
[ 0.204242] CPU features: detected: CRC32 instructions
[ 0.204300] CPU features: detected: Data independent timing control (DIT)
[ 0.204356] CPU features: detected: E0PD
[ 0.204426] CPU features: detected: Enhanced Virtualization Traps
[ 0.204586] CPU features: detected: Generic authentication (architected QARMA5 algorithm)
[ 0.204651] CPU features: detected: RCpc load-acquire (LDAPR)
[ 0.204707] CPU features: detected: LSE atomic instructions
[ 0.204844] CPU features: detected: Privileged Access Never
[ 0.204905] CPU features: detected: RAS Extension Support
[ 0.204967] CPU features: detected: Speculation barrier (SB)
[ 0.205023] CPU features: detected: Stage-2 Force Write-Back
[ 0.205088] CPU features: detected: TLB range maintenance instructions
[ 0.205220] CPU features: detected: Speculative Store Bypassing Safe (SSBS)
[ 0.205279] CPU features: detected: Scalable Vector Extension
[ 0.225158] SVE: maximum available vector length 16 bytes per vector
[ 0.234037] SVE: default vector length 16 bytes per vector
[ 0.240880] CPU: All CPU(s) started at EL1
[ 0.241317] alternatives: applying system-wide alternatives
[ 0.326082] devtmpfs: initialized
[ 0.412440] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 7645041785100000 ns
[ 0.413465] futex hash table entries: 512 (order: 3, 32768 bytes, linear)
[ 0.423243] pinctrl core: initialized pinctrl subsystem
[ 0.457056] DMI not present or invalid.
[ 0.479849] NET: Registered PF_NETLINK/PF_ROUTE protocol family
[ 0.509432] DMA: preallocated 256 KiB GFP_KERNEL pool for atomic allocations
[ 0.510791] DMA: preallocated 256 KiB GFP_KERNEL|GFP_DMA pool for atomic allocations
[ 0.511942] DMA: preallocated 256 KiB GFP_KERNEL|GFP_DMA32 pool for atomic allocations
[ 0.512731] audit: initializing netlink subsys (disabled)
[ 0.516572] audit: type=2000 audit(0.416:1): state=initialized audit_enabled=0 res=1
[ 0.537883] thermal_sys: Registered thermal governor 'step_wise'
[ 0.538072] thermal_sys: Registered thermal governor 'power_allocator'
[ 0.541064] cpuidle: using governor menu
[ 0.545354] hw-breakpoint: found 6 breakpoint and 4 watchpoint registers.
[ 0.546750] ASID allocator initialised with 65536 entries
[ 0.584191] Serial: AMBA PL011 UART driver
[ 0.631477] 2000000.pl011: ttyAMA0 at MMIO 0x2000000 (irq = 14, base_baud = 0) is a PL011 rev1
[ 0.633925] printk: console [ttyAMA0] enabled
[ 1.170128] 2001000.pl011: ttyAMA1 at MMIO 0x2001000 (irq = 15, base_baud = 0) is a PL011 rev1
[ 1.188476] 2002000.pl011: ttyAMA2 at MMIO 0x2002000 (irq = 16, base_baud = 0) is a PL011 rev1
[ 1.208704] 2003000.pl011: ttyAMA3 at MMIO 0x2003000 (irq = 17, base_baud = 0) is a PL011 rev1
[ 1.375147] Modules: 22352 pages in range for non-PLT usage
[ 1.375274] Modules: 513872 pages in range for PLT usage
[ 1.391113] HugeTLB: registered 1.00 GiB page size, pre-allocated 0 pages
[ 1.401233] HugeTLB: 0 KiB vmemmap can be freed for a 1.00 GiB page
[ 1.405048] HugeTLB: registered 32.0 MiB page size, pre-allocated 0 pages
[ 1.409855] HugeTLB: 0 KiB vmemmap can be freed for a 32.0 MiB page
[ 1.414269] HugeTLB: registered 2.00 MiB page size, pre-allocated 0 pages
[ 1.420742] HugeTLB: 0 KiB vmemmap can be freed for a 2.00 MiB page
[ 1.424496] HugeTLB: registered 64.0 KiB page size, pre-allocated 0 pages
[ 1.430602] HugeTLB: 0 KiB vmemmap can be freed for a 64.0 KiB page
[ 1.466804] ACPI: Interpreter disabled.
[ 1.504572] iommu: Default domain type: Translated
[ 1.507824] iommu: DMA domain TLB invalidation policy: strict mode
[ 1.516965] SCSI subsystem initialized
[ 1.523454] libata version 3.00 loaded.
[ 1.528448] ssp-pl022 2040000.spi0: ARM PL022 driver, device ID: 0x00041022
[ 1.536169] ssp-pl022 2040000.spi0: mapped registers from 0x0000000002040000 to (____ptrval____)
[ 1.558606] ssp-pl022 2044000.spi1: ARM PL022 driver, device ID: 0x00041022
[ 1.564613] ssp-pl022 2044000.spi1: mapped registers from 0x0000000002044000 to (____ptrval____)
[ 1.581784] ssp-pl022 2048000.spi2: ARM PL022 driver, device ID: 0x00041022
[ 1.588481] ssp-pl022 2048000.spi2: mapped registers from 0x0000000002048000 to (____ptrval____)
[ 1.607127] usbcore: registered new interface driver usbfs
[ 1.610870] usbcore: registered new interface driver hub
[ 1.615090] usbcore: registered new device driver usb
[ 1.625665] imx-i2c 2030000.i2c0: can't get pinctrl, bus recovery not supported
[ 1.635147] i2c i2c-0: IMX I2C adapter registered
[ 1.641470] imx-i2c 2034000.i2c1: can't get pinctrl, bus recovery not supported
[ 1.648940] i2c i2c-1: IMX I2C adapter registered
[ 1.654863] imx-i2c 2038000.i2c2: can't get pinctrl, bus recovery not supported
[ 1.662596] i2c i2c-2: IMX I2C adapter registered
[ 1.672163] pps_core: LinuxPPS API ver. 1 registered
[ 1.675177] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[ 1.682350] PTP clock support registered
[ 1.686756] EDAC MC: Ver: 3.0.0
[ 1.698873] scmi_core: SCMI protocol bus registered
[ 1.712623] FPGA manager framework
[ 1.717822] Advanced Linux Sound Architecture Driver Initialized.
[ 1.749646] vgaarb: loaded
[ 1.759788] clocksource: Switched to clocksource arch_sys_counter
[ 1.770945] VFS: Disk quotas dquot_6.6.0
[ 1.774922] VFS: Dquot-cache hash table entries: 512 (order 0, 4096 bytes)
[ 1.782740] pnp: PnP ACPI: disabled
[ 1.922472] NET: Registered PF_INET protocol family
[ 1.928324] IP idents hash table entries: 32768 (order: 6, 262144 bytes, linear)
[ 1.946010] tcp_listen_portaddr_hash hash table entries: 1024 (order: 2, 16384 bytes, linear)
[ 1.952302] Table-perturb hash table entries: 65536 (order: 6, 262144 bytes, linear)
[ 1.957197] TCP established hash table entries: 16384 (order: 5, 131072 bytes, linear)
[ 1.962812] TCP bind hash table entries: 16384 (order: 7, 524288 bytes, linear)
[ 1.968274] TCP: Hash tables configured (established 16384 bind 16384)
[ 1.974422] UDP hash table entries: 1024 (order: 3, 32768 bytes, linear)
[ 1.979978] UDP-Lite hash table entries: 1024 (order: 3, 32768 bytes, linear)
[ 1.986710] NET: Registered PF_UNIX/PF_LOCAL protocol family
[ 1.998910] RPC: Registered named UNIX socket transport module.
[ 2.004227] RPC: Registered udp transport module.
[ 2.007305] RPC: Registered tcp transport module.
[ 2.010548] RPC: Registered tcp-with-tls transport module.
[ 2.014009] RPC: Registered tcp NFSv4.1 backchannel transport module.
[ 2.017846] PCI: CLS 0 bytes, default 64
[ 2.023587] kvm [1]: HYP mode not available
[ 2.041915] Initialise system trusted keyrings
[ 2.049210] workingset: timestamp_bits=42 max_order=19 bucket_order=0
[ 2.060845] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[ 2.070179] NFS: Registering the id_resolver key type
[ 2.074458] Key type id_resolver registered
[ 2.076958] Key type id_legacy registered
[ 2.080359] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[ 2.085473] nfs4flexfilelayout_init: NFSv4 Flexfile Layout Driver Registering...
[ 2.092255] 9p: Installing v9fs 9p2000 file system support
[ 2.545229] Key type asymmetric registered
[ 2.548656] Asymmetric key parser 'x509' registered
[ 2.553314] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 245)
[ 2.557933] io scheduler mq-deadline registered
[ 2.562371] io scheduler kyber registered
[ 2.566139] io scheduler bfq registered
[ 2.669994] pl061_gpio 2020000.gpio0: PL061 GPIO chip registered
[ 2.678883] pl061_gpio 2021000.gpio1: PL061 GPIO chip registered
[ 2.690077] pl061_gpio 2022000.gpio2: PL061 GPIO chip registered
[ 2.700659] pl061_gpio 2023000.gpio3: PL061 GPIO chip registered
[ 2.741950] drivers/video/fbdev/qemu_custom_lcdcfb.c qemu_lcd_fb_probe 68 qemu lcd init
[ 2.804314] Console: switching to colour frame buffer device 77x43
[ 2.818820] EINJ: ACPI disabled.
[ 3.103850] Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
[ 3.152906] SuperH (H)SCI(F) driver initialized
[ 3.160080] msm_serial: driver initialized
[ 3.169410] STM32 USART driver initialized
[ 3.329274] brd: module loaded
[ 3.430221] loop: module loaded
[ 3.445201] megasas: 07.725.01.00-rc1
[ 3.470234] SPI driver spidev has no spi_device_id for rohm,bh2228fv
[ 3.551145] tun: Universal TUN/TAP device driver, 1.6
[ 3.557425] CAN device driver interface
[ 3.599812] thunder_xcv, ver 1.0
[ 3.603136] thunder_bgx, ver 1.0
[ 3.606161] nicpf, ver 1.0
[ 3.620788] hns3: Hisilicon Ethernet Network Driver for Hip08 Family - version
[ 3.626251] hns3: Copyright (c) 2017 Huawei Corporation.
[ 3.630912] hclge is initializing
[ 3.633225] e1000: Intel(R) PRO/1000 Network Driver
[ 3.636094] e1000: Copyright (c) 1999-2006 Intel Corporation.
[ 3.639942] e1000e: Intel(R) PRO/1000 Network Driver
[ 3.642546] e1000e: Copyright(c) 1999 - 2015 Intel Corporation.
[ 3.647036] igb: Intel(R) Gigabit Ethernet Network Driver
[ 3.650494] igb: Copyright (c) 2007-2014 Intel Corporation.
[ 3.654276] igbvf: Intel(R) Gigabit Virtual Function Network Driver
[ 3.657908] igbvf: Copyright (c) 2009 - 2012 Intel Corporation.
[ 3.665002] sky2: driver version 1.30
[ 3.744774] smsc911x 2050000.ethernet eth0: MAC Address: 52:54:00:12:34:56
[ 3.797288] smsc911x 2054000.ethernet eth1: MAC Address: 52:54:00:12:34:57
[ 3.849987] smsc911x 2058000.ethernet eth2: MAC Address: 52:54:00:12:34:58
[ 3.865596] VFIO - User Level meta-driver version: 0.3
[ 3.902894] usbcore: registered new interface driver usb-storage
[ 3.932119] input: Qemu Touchscreen Controller as /devices/platform/2090000.ts/input/input0
[ 3.968237] rtc-pl031 201a000.pl031: registered as rtc0
[ 3.973490] rtc-pl031 201a000.pl031: setting system clock to 2025-11-03T09:22:44 UTC (1762161764)
[ 3.986557] rtc-pl031 201b000.pl031: registered as rtc1
[ 3.997888] rtc-pl031 201c000.pl031: registered as rtc2
[ 4.012268] i2c_dev: i2c /dev entries driver
[ 4.103259] sdhci: Secure Digital Host Controller Interface driver
[ 4.107572] sdhci: Copyright(c) Pierre Ossman
[ 4.118641] Synopsys Designware Multimedia Card Interface Driver
[ 4.130681] mmci-pl18x 2070000.mci: mmc1: PL181 manf 41 rev0 at 0x02070000 irq 38,39 (pio)
[ 4.139070] sdhci-pltfm: SDHCI platform and OF driver helper
[ 4.144432] mmci-pl18x 2071000.mci: mmc0: PL181 manf 41 rev0 at 0x02071000 irq 40,41 (pio)
[ 4.167382] ledtrig-cpu: registered to indicate activity on CPUs
[ 4.209661] usbcore: registered new interface driver usbhid
[ 4.213876] usbhid: USB HID core driver
[ 4.223202] mmc0: host does not support reading read-only switch, assuming write-enable
[ 4.229191] mmc1: host does not support reading read-only switch, assuming write-enable
[ 4.236504] mmc0: new SD card at address 4567
[ 4.240728] mmc1: new SD card at address 4567
[ 4.255833] mmcblk0: mmc0:4567 QEMU! 64.0 MiB
[ 4.260682] mmcblk1: mmc1:4567 QEMU! 64.0 MiB
[ 4.346680] NET: Registered PF_PACKET protocol family
[ 4.350167] can: controller area network core
[ 4.353827] NET: Registered PF_CAN protocol family
[ 4.357028] can: raw protocol
[ 4.359541] can: broadcast manager protocol
[ 4.362327] can: netlink gateway - max_hops=1
[ 4.369430] 9pnet: Installing 9P2000 support
[ 4.373874] Key type dns_resolver registered
[ 4.590373] registered taskstats version 1
[ 4.595956] Loading compiled-in X.509 certificates
[ 4.803614] clk: Disabling unused clocks
[ 4.806878] ALSA device list:
[ 4.808751] No soundcards found.
[ 4.816839] uart-pl011 2000000.pl011: no DMA platform data
[ 5.282667] EXT4-fs (mmcblk0): recovery complete
[ 5.292219] EXT4-fs (mmcblk0): mounted filesystem ee84d967-a012-46a2-b795-4f4e92b7d530 r/w with ordered data mode. Quota mode: none.
[ 5.301956] VFS: Mounted root (ext4 filesystem) on device 179:32.
[ 5.311845] devtmpfs: mounted
[ 5.386726] Freeing unused kernel memory: 9152K
[ 5.391338] Run /linuxrc as init process
[ 5.393546] with arguments:
[ 5.395460] /linuxrc
[ 5.397565] with environment:
[ 5.400192] HOME=/
[ 5.401966] TERM=linux
[ 7.167150] random: crng init done
[ 10.021929] EXT4-fs (mmcblk0): re-mounted ee84d967-a012-46a2-b795-4f4e92b7d530 r/w. Quota mode: none.
Seeding 256 bits without crediting
Saving 256 bits of creditable seed for next boot
Starting syslogd: OK
Starting klogd: OK
Running sysctl: OK
Starting network: [ 12.893224] Generic PHY 2050000.ethernet-ffffffff:01: attached PHY driver (mii_bus:phy_addr=2050000.ethernet-ffffffff:01, irq=POLL)
[ 12.917114] smsc911x 2050000.ethernet eth0: SMSC911x/921x identified at 0xffff800084914000, IRQ: 31
udhcpc: started, v1.36.1
udhcpc: broadcasting discover
udhcpc: broadcasting select for 10.0.2.15, server 10.0.2.2
udhcpc: lease of 10.0.2.15 obtained from 10.0.2.2, lease time 86400
deleting routers
adding dns 10.0.2.3
OK
Starting dropbear sshd: OK
Welcome to Buildroot
buildroot login: [ 14.878324] amba 2072000.mci: deferred probe pending
[ 14.882252] amba 2088000.clcd2: deferred probe pending
[ 14.885218] amba 2084000.clcd1: deferred probe pending
Welcome to Buildroot
buildroot login: root
Password:
#
多核启动操作系统需要多个串口,采用telnet方式可以将三个串口分别映射到不同端口上交互,telnet ip:port对应操作系统表如下:
| Telnet(ip:port) | 操作系统 | 架构 |
|---|---|---|
| 127.0.0.1:3333 | Linux操作系统 | CORTEX-A |
| 127.0.0.1:4444 | RTThread操作系统 | CORTEX-R |
| 127.0.0.1:5555 | FreeRTOS操作系统 | CORTEX-M |
$ qemu-doarmpi.bat linux_rtt_freertos nogui telnet
QEMU-DOARMPI Information
System: linux_rtt_freertos
Display: nogui
Serial: telnet
Debug:
Run Cmd:F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\bin\qemu-system-aarch64.exe -M doarmpi -smp 5 -m 2048M -kernel F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\Image -device loader,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtthread\rtthread-doarmpi-cortex-r.elf -device loader,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\freertos\freertos-doarmpi-cortex-m.elf -append "console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr" -serial mon:telnet::3333,server,wait -serial mon:telnet::4444,server,nowait -serial mon:telnet::5555,server,nowait -monitor telnet::2222,server,nowait -nographic -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\linux\rootfs.ext4,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\rtthread\sd_r.bin,format=raw -drive if=sd,file=F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\freertos\sd_m.bin,format=raw -net nic,model=lan9118,netdev=hub0port0 -netdev hubport,id=hub0port0,hubid=0 -net nic,model=lan9118,netdev=hub0port1 -netdev hubport,id=hub0port1,hubid=0 -net nic,model=lan9118,netdev=hub0port2 -netdev hubport,id=hub0port2,hubid=0 -net user,hostfwd=tcp::23-10.0.2.16:22 -readconfig F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\etc\default.conf -s
F:\Gitee\DOARMPI\QEMU_DOARMPI\Software\\bin\qemu-system-aarch64.exe: -serial mon:telnet::3333,server,wait: info: QEMU waiting for connection on: disconnected:telnet::::3333,server=on
Linux操作系统终端(CORTEX-A):
$ telnet 127.0.0.1 3333
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
[ 0.000000] Booting Linux on physical CPU 0x0000000000 [0x412fd471]
[ 0.000000] Linux version 6.6.44 (work@95fdfbed1d58) (aarch64-linux-gcc.br_real (Buildroot 2024.02.6) 12.4.0, GNU ld (GNU Binutils) 2.40) #18 SMP PREEMPT Wed Dec 25 10:21:08 CST 2024
[ 0.000000] Machine model: linux,doarmpi-board
[ 0.000000] efi: UEFI not found.
[ 0.000000] NUMA: No NUMA configuration found
[ 0.000000] NUMA: Faking a node at [mem 0x00000000a0000000-0x000000011fffffff]
[ 0.000000] NUMA: NODE_DATA [mem 0x11fbf39c0-0x11fbf5fff]
[ 0.000000] Zone ranges:
[ 0.000000] DMA [mem 0x00000000a0000000-0x00000000ffffffff]
[ 0.000000] DMA32 empty
[ 0.000000] Normal [mem 0x0000000100000000-0x000000011fffffff]
[ 0.000000] Movable zone start for each node
[ 0.000000] Early memory node ranges
[ 0.000000] node 0: [mem 0x00000000a0000000-0x000000011fffffff]
[ 0.000000] Initmem setup node 0 [mem 0x00000000a0000000-0x000000011fffffff]
[ 0.000000] cma: Reserved 32 MiB at 0x00000000fe000000 on node -1
[ 0.000000] psci: probing for conduit method from DT.
[ 0.000000] psci: PSCIv1.1 detected in firmware.
[ 0.000000] psci: Using standard PSCI v0.2 function IDs
[ 0.000000] psci: Trusted OS migration not required
[ 0.000000] psci: SMC Calling Convention v1.0
[ 0.000000] percpu: Embedded 22 pages/cpu s50792 r8192 d31128 u90112
[ 0.000000] pcpu-alloc: s50792 r8192 d31128 u90112 alloc=22*4096
[ 0.000000] pcpu-alloc: [0] 0 [0] 1
[ 0.000000] Detected PIPT I-cache on CPU0
[ 0.000000] CPU features: detected: Address authentication (architected QARMA5 algorithm)
[ 0.000000] CPU features: detected: GIC system register CPU interface
[ 0.000000] CPU features: detected: Hardware dirty bit management
[ 0.000000] CPU features: detected: Spectre-v4
[ 0.000000] CPU features: detected: Spectre-BHB
[ 0.000000] CPU features: detected: ARM erratum 2067961 or 2054223
[ 0.000000] alternatives: applying boot alternatives
[ 0.000000] Kernel command line: console=ttyAMA0,115200 rootfstype=ext4 root=/dev/mmcblk0 rw rootwait init=/linuxrc loglevel=8 nokaslr
[ 0.000000] Dentry cache hash table entries: 262144 (order: 9, 2097152 bytes, linear)
[ 0.000000] Inode-cache hash table entries: 131072 (order: 8, 1048576 bytes, linear)
[ 0.000000] Fallback order for Node 0: 0
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 516096
[ 0.000000] Policy zone: Normal
[ 0.000000] mem auto-init: stack:all(zero), heap alloc:off, heap free:off
[ 0.000000] software IO TLB: area num 2.
[ 0.000000] software IO TLB: mapped [mem 0x00000000fa000000-0x00000000fe000000] (64MB)
[ 0.000000] Memory: 1915224K/2097152K available (16832K kernel code, 4282K rwdata, 10616K rodata, 9152K init, 605K bss, 149160K reserved, 32768K cma-reserved)
[ 0.000000] SLUB: HWalign=64, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
[ 0.000000] rcu: Preemptible hierarchical RCU implementation.
[ 0.000000] rcu: RCU event tracing is enabled.
[ 0.000000] rcu: RCU restricting CPUs from NR_CPUS=256 to nr_cpu_ids=2.
[ 0.000000] Trampoline variant of Tasks RCU enabled.
[ 0.000000] Tracing variant of Tasks RCU enabled.
[ 0.000000] rcu: RCU calculated value of scheduler-enlistment delay is 25 jiffies.
[ 0.000000] rcu: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=2
[ 0.000000] NR_IRQS: 64, nr_irqs: 64, preallocated irqs: 0
[ 0.000000] GICv3: 160 SPIs implemented
[ 0.000000] GICv3: 0 Extended SPIs implemented
[ 0.000000] Root IRQ handler: gic_handle_irq
[ 0.000000] GICv3: GICv3 features: 16 PPIs
[ 0.000000] GICv3: CPU0: found redistributor 0 region 0:0x0000000009020000
[ 0.000000] ITS [mem 0x0d021000-0x0d220fff]
[ 0.000000] ITS@0x000000000d021000: allocated 8192 Devices @100040000 (indirect, esz 8, psz 64K, shr 1)
[ 0.000000] ITS@0x000000000d021000: allocated 8192 Interrupt Collections @100050000 (flat, esz 8, psz 64K, shr 1)
[ 0.000000] GICv3: using LPI property table @0x0000000100060000
[ 0.000000] GICv3: CPU0: using allocated LPI pending table @0x0000000100070000
[ 0.000000] rcu: srcu_init: Setting srcu_struct sizes based on contention.
[ 0.000000] clocksource: arm,sp804: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 79635851949 ns
[ 0.000006] sched_clock: 32 bits at 24MHz, resolution 41ns, wraps every 89478484971ns
[ 0.000167] arch_timer: cp15 timer(s) running at 62.50MHz (virt).
[ 0.000178] clocksource: arch_sys_counter: mask: 0x1ffffffffffffff max_cycles: 0x1cd42e208c, max_idle_ns: 881590405314 ns
[ 0.000192] sched_clock: 57 bits at 63MHz, resolution 16ns, wraps every 4398046511096ns
[ 0.041022] Console: colour dummy device 80x25
[ 0.052314] Calibrating delay loop (skipped), value calculated using timer frequency.. 125.00 BogoMIPS (lpj=250000)
[ 0.054716] pid_max: default: 32768 minimum: 301
[ 0.060391] LSM: initializing lsm=capability,integrity
[ 0.070160] Mount-cache hash table entries: 4096 (order: 3, 32768 bytes, linear)
[ 0.070476] Mountpoint-cache hash table entries: 4096 (order: 3, 32768 bytes, linear)
[ 0.178192] RCU Tasks: Setting shift to 1 and lim to 1 rcu_task_cb_adjust=1.
[ 0.180298] RCU Tasks Trace: Setting shift to 1 and lim to 1 rcu_task_cb_adjust=1.
[ 0.185440] rcu: Hierarchical SRCU implementation.
[ 0.185549] rcu: Max phase no-delay instances is 1000.
[ 0.198701] Platform MSI: msi-controller@d021000 domain created
[ 0.199871] PCI/MSI: /interrupt-controller@9000000/msi-controller@d021000 domain created
[ 0.201057] fsl-mc MSI: msi-controller@d021000 domain created
[ 0.210130] EFI services will not be available.
[ 0.213948] smp: Bringing up secondary CPUs ...
[ 0.228550] Detected PIPT I-cache on CPU1
[ 0.234633] GICv3: CPU1: found redistributor 1 region 0:0x0000000009040000
[ 0.236668] GICv3: CPU1: using allocated LPI pending table @0x0000000100080000
[ 0.241082] CPU1: Booted secondary processor 0x0000000001 [0x412fd471]
[ 0.248302] smp: Brought up 1 node, 2 CPUs
[ 0.248442] SMP: Total of 2 processors activated.
[ 0.248689] CPU features: detected: Branch Target Identification
[ 0.248822] CPU features: detected: 32-bit EL0 Support
[ 0.248915] CPU features: detected: ARMv8.4 Translation Table Level
[ 0.249009] CPU features: detected: Data cache clean to the PoU not required for I/D coherence
[ 0.249131] CPU features: detected: Common not Private translations
[ 0.249193] CPU features: detected: CRC32 instructions
[ 0.249251] CPU features: detected: Data independent timing control (DIT)
[ 0.249307] CPU features: detected: E0PD
[ 0.249383] CPU features: detected: Enhanced Virtualization Traps
[ 0.249540] CPU features: detected: Generic authentication (architected QARMA5 algorithm)
[ 0.249605] CPU features: detected: RCpc load-acquire (LDAPR)
[ 0.249661] CPU features: detected: LSE atomic instructions
[ 0.249802] CPU features: detected: Privileged Access Never
[ 0.249864] CPU features: detected: RAS Extension Support
[ 0.249925] CPU features: detected: Speculation barrier (SB)
[ 0.249981] CPU features: detected: Stage-2 Force Write-Back
[ 0.250050] CPU features: detected: TLB range maintenance instructions
[ 0.250182] CPU features: detected: Speculative Store Bypassing Safe (SSBS)
[ 0.250242] CPU features: detected: Scalable Vector Extension
[ 0.274729] SVE: maximum available vector length 16 bytes per vector
[ 0.280667] SVE: default vector length 16 bytes per vector
[ 0.283872] CPU: All CPU(s) started at EL1
[ 0.284231] alternatives: applying system-wide alternatives
[ 0.378074] devtmpfs: initialized
[ 0.464958] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 7645041785100000 ns
[ 0.466200] futex hash table entries: 512 (order: 3, 32768 bytes, linear)
[ 0.476401] pinctrl core: initialized pinctrl subsystem
[ 0.509681] DMI not present or invalid.
[ 0.535115] NET: Registered PF_NETLINK/PF_ROUTE protocol family
[ 0.564489] DMA: preallocated 256 KiB GFP_KERNEL pool for atomic allocations
[ 0.566062] DMA: preallocated 256 KiB GFP_KERNEL|GFP_DMA pool for atomic allocations
[ 0.567888] DMA: preallocated 256 KiB GFP_KERNEL|GFP_DMA32 pool for atomic allocations
[ 0.568815] audit: initializing netlink subsys (disabled)
[ 0.573200] audit: type=2000 audit(0.408:1): state=initialized audit_enabled=0 res=1
[ 0.595357] thermal_sys: Registered thermal governor 'step_wise'
[ 0.595553] thermal_sys: Registered thermal governor 'power_allocator'
[ 0.599575] cpuidle: using governor menu
[ 0.604433] hw-breakpoint: found 6 breakpoint and 4 watchpoint registers.
[ 0.605945] ASID allocator initialised with 65536 entries
[ 0.645339] Serial: AMBA PL011 UART driver
[ 0.699589] 2000000.pl011: ttyAMA0 at MMIO 0x2000000 (irq = 14, base_baud = 0) is a PL011 rev1
[ 0.702509] printk: console [ttyAMA0] enabled
[ 0.898340] 2003000.pl011: ttyAMA1 at MMIO 0x2003000 (irq = 15, base_baud = 0) is a PL011 rev1
[ 0.991495] Modules: 22352 pages in range for non-PLT usage
[ 0.991625] Modules: 513872 pages in range for PLT usage
[ 1.009611] HugeTLB: registered 1.00 GiB page size, pre-allocated 0 pages
[ 1.012273] HugeTLB: 0 KiB vmemmap can be freed for a 1.00 GiB page
[ 1.013511] HugeTLB: registered 32.0 MiB page size, pre-allocated 0 pages
[ 1.015070] HugeTLB: 0 KiB vmemmap can be freed for a 32.0 MiB page
[ 1.016285] HugeTLB: registered 2.00 MiB page size, pre-allocated 0 pages
[ 1.017908] HugeTLB: 0 KiB vmemmap can be freed for a 2.00 MiB page
[ 1.019366] HugeTLB: registered 64.0 KiB page size, pre-allocated 0 pages
[ 1.020650] HugeTLB: 0 KiB vmemmap can be freed for a 64.0 KiB page
[ 1.055289] ACPI: Interpreter disabled.
[ 1.084018] iommu: Default domain type: Translated
[ 1.085270] iommu: DMA domain TLB invalidation policy: strict mode
[ 1.092555] SCSI subsystem initialized
[ 1.096628] libata version 3.00 loaded.
[ 1.102047] ssp-pl022 2040000.spi0: ARM PL022 driver, device ID: 0x00041022
[ 1.105033] ssp-pl022 2040000.spi0: mapped registers from 0x0000000002040000 to (____ptrval____)
[ 1.128591] usbcore: registered new interface driver usbfs
[ 1.131018] usbcore: registered new interface driver hub
[ 1.132837] usbcore: registered new device driver usb
[ 1.142209] imx-i2c 2030000.i2c0: can't get pinctrl, bus recovery not supported
[ 1.148528] i2c i2c-0: IMX I2C adapter registered
[ 1.154471] pps_core: LinuxPPS API ver. 1 registered
[ 1.155756] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[ 1.158237] PTP clock support registered
[ 1.161777] EDAC MC: Ver: 3.0.0
[ 1.173048] scmi_core: SCMI protocol bus registered
[ 1.184390] FPGA manager framework
[ 1.188182] Advanced Linux Sound Architecture Driver Initialized.
[ 1.220671] vgaarb: loaded
[ 1.231098] clocksource: Switched to clocksource arch_sys_counter
[ 1.238207] VFS: Disk quotas dquot_6.6.0
[ 1.239544] VFS: Dquot-cache hash table entries: 512 (order 0, 4096 bytes)
[ 1.246134] pnp: PnP ACPI: disabled
[ 1.400578] NET: Registered PF_INET protocol family
[ 1.406258] IP idents hash table entries: 32768 (order: 6, 262144 bytes, linear)
[ 1.423120] tcp_listen_portaddr_hash hash table entries: 1024 (order: 2, 16384 bytes, linear)
[ 1.425745] Table-perturb hash table entries: 65536 (order: 6, 262144 bytes, linear)
[ 1.428160] TCP established hash table entries: 16384 (order: 5, 131072 bytes, linear)
[ 1.430171] TCP bind hash table entries: 16384 (order: 7, 524288 bytes, linear)
[ 1.432440] TCP: Hash tables configured (established 16384 bind 16384)
[ 1.436445] UDP hash table entries: 1024 (order: 3, 32768 bytes, linear)
[ 1.438470] UDP-Lite hash table entries: 1024 (order: 3, 32768 bytes, linear)
[ 1.442944] NET: Registered PF_UNIX/PF_LOCAL protocol family
[ 1.453189] RPC: Registered named UNIX socket transport module.
[ 1.455381] RPC: Registered udp transport module.
[ 1.456508] RPC: Registered tcp transport module.
[ 1.457685] RPC: Registered tcp-with-tls transport module.
[ 1.458803] RPC: Registered tcp NFSv4.1 backchannel transport module.
[ 1.460525] PCI: CLS 0 bytes, default 64
[ 1.464901] kvm [1]: HYP mode not available
[ 1.483074] Initialise system trusted keyrings
[ 1.488183] workingset: timestamp_bits=42 max_order=19 bucket_order=0
[ 1.496374] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[ 1.502693] NFS: Registering the id_resolver key type
[ 1.504744] Key type id_resolver registered
[ 1.506404] Key type id_legacy registered
[ 1.508240] nfs4filelayout_init: NFSv4 File Layout Driver Registering...
[ 1.509786] nfs4flexfilelayout_init: NFSv4 Flexfile Layout Driver Registering...
[ 1.514143] 9p: Installing v9fs 9p2000 file system support
[ 2.016282] Key type asymmetric registered
[ 2.018243] Asymmetric key parser 'x509' registered
[ 2.021633] Block layer SCSI generic (bsg) driver version 0.4 loaded (major 245)
[ 2.023868] io scheduler mq-deadline registered
[ 2.025136] io scheduler kyber registered
[ 2.027340] io scheduler bfq registered
[ 2.135670] pl061_gpio 2020000.gpio0: PL061 GPIO chip registered
[ 2.144631] pl061_gpio 2021000.gpio1: PL061 GPIO chip registered
[ 2.154025] pl061_gpio 2022000.gpio2: PL061 GPIO chip registered
[ 2.165003] pl061_gpio 2023000.gpio3: PL061 GPIO chip registered
[ 2.212850] drivers/video/fbdev/qemu_custom_lcdcfb.c qemu_lcd_fb_probe 68 qemu lcd init
[ 2.290891] Console: switching to colour frame buffer device 77x43
[ 2.304041] EINJ: ACPI disabled.
[ 2.562448] Serial: 8250/16550 driver, 4 ports, IRQ sharing enabled
[ 2.610372] SuperH (H)SCI(F) driver initialized
[ 2.616521] msm_serial: driver initialized
[ 2.622406] STM32 USART driver initialized
[ 2.801167] brd: module loaded
[ 2.898888] loop: module loaded
[ 2.916110] megasas: 07.725.01.00-rc1
[ 2.941939] SPI driver spidev has no spi_device_id for rohm,bh2228fv
[ 3.020852] tun: Universal TUN/TAP device driver, 1.6
[ 3.026393] CAN device driver interface
[ 3.053463] thunder_xcv, ver 1.0
[ 3.055610] thunder_bgx, ver 1.0
[ 3.057413] nicpf, ver 1.0
[ 3.071823] hns3: Hisilicon Ethernet Network Driver for Hip08 Family - version
[ 3.073627] hns3: Copyright (c) 2017 Huawei Corporation.
[ 3.076146] hclge is initializing
[ 3.077749] e1000: Intel(R) PRO/1000 Network Driver
[ 3.078736] e1000: Copyright (c) 1999-2006 Intel Corporation.
[ 3.081296] e1000e: Intel(R) PRO/1000 Network Driver
[ 3.082919] e1000e: Copyright(c) 1999 - 2015 Intel Corporation.
[ 3.085219] igb: Intel(R) Gigabit Ethernet Network Driver
[ 3.086490] igb: Copyright (c) 2007-2014 Intel Corporation.
[ 3.088789] igbvf: Intel(R) Gigabit Virtual Function Network Driver
[ 3.090057] igbvf: Copyright (c) 2009 - 2012 Intel Corporation.
[ 3.094838] sky2: driver version 1.30
[ 3.180511] smsc911x 2050000.ethernet eth0: MAC Address: 52:54:00:12:34:56
[ 3.196081] VFIO - User Level meta-driver version: 0.3
[ 3.225582] usbcore: registered new interface driver usb-storage
[ 3.250466] input: Qemu Touchscreen Controller as /devices/platform/2090000.ts/input/input0
[ 3.285517] rtc-pl031 201a000.pl031: registered as rtc0
[ 3.288039] rtc-pl031 201a000.pl031: setting system clock to 2025-11-03T09:33:55 UTC (1762162435)
[ 3.297728] i2c_dev: i2c /dev entries driver
[ 3.370149] sdhci: Secure Digital Host Controller Interface driver
[ 3.371815] sdhci: Copyright(c) Pierre Ossman
[ 3.379946] Synopsys Designware Multimedia Card Interface Driver
[ 3.389301] mmci-pl18x 2070000.mci: mmc0: PL181 manf 41 rev0 at 0x02070000 irq 26,27 (pio)
[ 3.392311] sdhci-pltfm: SDHCI platform and OF driver helper
[ 3.413813] ledtrig-cpu: registered to indicate activity on CPUs
[ 3.447548] usbcore: registered new interface driver usbhid
[ 3.449347] usbhid: USB HID core driver
[ 3.459042] mmc0: host does not support reading read-only switch, assuming write-enable
[ 3.462868] mmc0: new SD card at address 4567
[ 3.473021] mmcblk0: mmc0:4567 QEMU! 64.0 MiB
[ 3.526502] NET: Registered PF_PACKET protocol family
[ 3.527814] can: controller area network core
[ 3.530191] NET: Registered PF_CAN protocol family
[ 3.531266] can: raw protocol
[ 3.532626] can: broadcast manager protocol
[ 3.533950] can: netlink gateway - max_hops=1
[ 3.538388] 9pnet: Installing 9P2000 support
[ 3.540932] Key type dns_resolver registered
[ 3.778179] registered taskstats version 1
[ 3.784504] Loading compiled-in X.509 certificates
[ 4.009407] clk: Disabling unused clocks
[ 4.012241] ALSA device list:
[ 4.013579] No soundcards found.
[ 4.021370] uart-pl011 2000000.pl011: no DMA platform data
[ 4.603424] EXT4-fs (mmcblk0): recovery complete
[ 4.610126] EXT4-fs (mmcblk0): mounted filesystem ee84d967-a012-46a2-b795-4f4e92b7d530 r/w with ordered data mode. Quota mode: none.
[ 4.614203] VFS: Mounted root (ext4 filesystem) on device 179:0.
[ 4.622055] devtmpfs: mounted
[ 4.761583] Freeing unused kernel memory: 9152K
[ 4.765289] Run /linuxrc as init process
[ 4.766400] with arguments:
[ 4.767708] /linuxrc
[ 4.768549] with environment:
[ 4.769374] HOME=/
[ 4.769948] TERM=linux
[ 6.857219] random: crng init done
[ 10.686550] EXT4-fs (mmcblk0): re-mounted ee84d967-a012-46a2-b795-4f4e92b7d530 r/w. Quota mode: none.
Seeding 256 bits and crediting
Saving 256 bits of creditable seed for next boot
Starting syslogd: OK
Starting klogd: OK
Running sysctl: OK
Starting network: [ 14.116560] Generic PHY 2050000.ethernet-ffffffff:01: attached PHY driver (mii_bus:phy_addr=2050000.ethernet-ffffffff:01, irq=POLL)
[ 14.132149] smsc911x 2050000.ethernet eth0: SMSC911x/921x identified at 0xffff800084874000, IRQ: 23
udhcpc: started, v1.36.1
udhcpc: broadcasting discover
udhcpc: broadcasting select for 10.0.2.17, server 10.0.2.2
udhcpc: lease of 10.0.2.17 obtained from 10.0.2.2, lease time 86400
deleting routers
adding dns 10.0.2.3
OK
Starting dropbear sshd: OK
Welcome to Buildroot
buildroot login:
RTThread操作系统终端(CORTEX-R):
$ telnet 127.0.0.1 4444
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
\ | /
- RT - Thread Operating System
/ | \ 5.2.1 build Oct 31 2025 15:18:46
2006 - 2024 Copyright by RT-Thread team
lwIP-2.1.2 initialized!
2025-11-03 17:33:51 [I/DRV][drv_i2c.c:111][rt_hw_drv_i2c_init]: Register i2c0 bus succeed!
2025-11-03 17:33:51 [I/DRV][drv_spi.c:130][rt_hw_drv_spi_init]: Register spi0 bus succeed!
2025-11-03 17:33:51 [I/DRV][drv_gpio.c:474][rt_hw_drv_pin_init]: Register pin device succeed!
2025-11-03 17:33:51 [I/DRV][drv_mci.c:412][rt_hw_drv_mci_init]: Register mci0 device succeed!
2025-11-03 17:33:51 [I/DRV][drv_can.c:635][rt_hw_drv_can_init]: Register can0 device succeed!
2025-11-03 17:33:51 [I/DRV][drv_enet.c:196][rt_hw_drv_enet_init]: Register en0 device succeed!
2025-11-03 17:33:51 [I/DEV][button.c:146][rt_hw_dev_button_init]: Register button device succeed!
2025-11-03 17:33:51 [I/DEV][at24cxx.c:229][rt_hw_dev_at24cxx_init]: Register at24cxx device succeed!
2025-11-03 17:33:51 [I/DEV][dev_lcd.c:160][rt_hw_dev_lcd_init]: Register lcd device succeed!
2025-11-03 17:33:51 [I/DEV][dev_lcd.c:169][rt_hw_dev_lcd_init]: Initialize lcd device succeed!
2025-11-03 17:33:51 [I/DEV][led.c:142][rt_hw_dev_led_init]: Register led device succeed!
2025-11-03 17:33:51 [I/DEV][pl181.c:240][rt_hw_dev_pl181_init]: Initialize sd0 device succeed!
2025-11-03 17:33:51 [I/DEV][qemu_spi.c:24][rt_hw_dev_qemu_spi_init]: Register qemu-spidev device succeed!
2025-11-03 17:33:51 [I/DEV][switch_key.c:101][rt_hw_dev_switch_key_init]: Register switch-key device succeed!
[I/touch] rt_touch init success
2025-11-03 17:33:51 [I/DEV][dev_ts.c:221][rt_hw_dev_ts_init]: Register ts device succeed!
[I/sal.skt] Socket Abstraction Layer initialize success.
2025-11-03 17:33:51 [E/DRV][drv_mci.c:169][rt_hw_mci_transfer_cmd]: MCI_SendCmdNoBlocking timeout!
[I/SDIO] SD card capacity 65536 KB.
[I/SDIO] sd: switch to High Speed / SDR25 mode
2025-11-03 17:33:52 [I/APP][mnt.c:33][mnt_init]: File system initialization done!
2025-11-03 17:33:52 [I/DEV][lan9118.c:184][rt_hw_dev_lan9118_init]: Initialize e0 device succeed!
RTThread main function!
rtthread-doarmpi(cortex-r):/>
FreeRTOS操作系统终端(CORTEX-M):
$ telnet 127.0.0.1 5555
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
____ ___ __________ ____
/ __/______ ___ / _ \/_ __/ __ \/ __/
/ _// __/ -_) -_) , _/ / / / /_/ /\ \
/_/ /_/ \__/\__/_/|_| /_/ \____/___/
Build: Oct 31 2025 15:40:41
CPU Type: cortex-m
System Version: 1.0.0
SDK Version: 1.0.0
HAL Version: 1.0.0
Shell Version: 3.1.2
LWIP Version: 2.1.3
LVGL Version: 8.3.11
Copyright: (c) 2023-2025 David
2025-11-03 17:33:51 [I/DRV][drv_rtc.c:145][DrvRtcInit]: Register rtc device succeed!
2025-11-03 17:33:51 [I/DRV][drv_gpio.c:428][DrvGpioInit]: Register pin device succeed!
2025-11-03 17:33:51 [I/DRV][drv_i2c.c:130][DrvI2cInit]: Register i2c0 bus succeed!
2025-11-03 17:33:51 [I/DRV][drv_spi.c:152][DrvSpiInit]: Register spi0 bus succeed!
2025-11-03 17:33:51 [I/DRV][drv_can.c:572][DrvCANInit]: Register can0 device succeed!
2025-11-03 17:33:51 [I/DRV][drv_enet.c:220][DrvENETInit]: Register en0 device success!
2025-11-03 17:33:51 [I/DRV][drv_mci.c:365][DrvMCIInit]: Register mci0 device succeed!
2025-11-03 17:33:51 [I/DEV][led.c:139][LedInit]: Register led device succeed!
2025-11-03 17:33:51 [I/DEV][button.c:137][ButtonInit]: Register button device succeed!
2025-11-03 17:33:51 [I/DEV][switch_key.c:74][SwitchKeyInit]: Register switch-key device succeed!
2025-11-03 17:33:51 [I/DEV][at24cxx.c:50][At24cXXInit]: Register at24cxx device succeed!
2025-11-03 17:33:51 [I/DEV][qemu_spi.c:38][QemuSpiInit]: Register qemu-spidev device succeed!
2025-11-03 17:33:51 [I/DEV][lan9118.c:217][Lan9118Init]: Initialize e0 device succeed!
2025-11-03 17:33:51 [I/DEV][lan9118.c:262][Lan9118NetLwipInit]: Initialize e0 lwip device succeed!
2025-11-03 17:33:51 [I/DEV][dev_lcd.c:73][LcdInit]: Register lcd device succeed!
2025-11-03 17:33:51 [I/DEV][dev_lcd.c:88][LcdInit]: Initialize lcd device succeed!
2025-11-03 17:33:51 [I/DEV][sd.c:229][SDInit]: Register sd0 device succeed!
2025-11-03 17:33:51 [I/APP][user_app.c:152][UserAppStart]: User application start!
2025-11-03 17:33:51 [I/APP][user_app.c:111][MntInit]: f_mount succeeded!
freertos-doarmpi(cortex-m):/$
| 硬件 | 基地址 | 大小 | 描述 |
|---|---|---|---|
| DDR | 0xa0000000 | 16GB | CORTEX-A核内存 |
| RAM1 | 0x60000000 | 128MB | CORTEX-R核内存 |
| RAM2 | 0x20000000 | 4MB | CORTEX-M核内存 |
| FLASH | 0x08000000 | 4MB | CORTEX-M核FLASH |
| GIC1 | 0x09000000(DIST) 0x09020000(REDIST) 0x0d021000(ITS) |
0x00010000(DIST) 0x00200000(REDIST) 0x00200000(ITS) |
CORTEX-A核GICv3中断控制器 |
| GIC2 | 0x19000000(DIST) 0x19020000(REDIST) 0x1d021000(ITS) |
0x00010000(DIST) 0x00200000(REDIST) 0x00200000(ITS) |
CORTEX-R核GICv3中断控制器 |
| 硬件 | 基地址 | 中断号 | 控制器 |
|---|---|---|---|
| UART | 0x02000000(UART1) 0x02001000(UART2) 0x02002000(UART3) 0x02003000(UART4) |
20(UART1) 21(UART2) 22(UART3) 23(UART4) |
pl011 |
| TIMER | 0x02010000(TIMER01) 0x02011000(TIMER23) 0x02012000(TIMER45) |
30(TIMER01) 31(TIMER23) 32(TIMER45) |
sp804 |
| RTC | 0x0201a000(RTC1) 0x0201b000(RTC2) 0x0201c000(RTC3) |
37(RTC1) 38(RTC2) 39(RTC3) |
pl031 |
| GPIO | 0x02020000(GPIO1) 0x02021000(GPIO2) 0x02022000(GPIO3) 0x02023000(GPIO4) |
40(GPIO1) 41(GPIO2) 42(GPIO3) 43(GPIO4) |
pl061 |
| I2C | 0x02030000(I2C1) 0x02034000(I2C2) 0x02038000(I2C3) |
50(I2C1) 51(I2C2) 52(I2C3) |
imx-i2c |
| SPI | 0x02040000(SPI1) 0x02044000(SPI2) 0x02048000(SPI3) |
60(SPI1) 61(SPI2) 62(SPI3) |
pl022 |
| ENET | 0x02050000(ENET1) 0x02054000(ENET2) 0x02058000(ENET3) |
70(ENET1) 71(ENET2) 72(ENET3) |
lan9118 |
| CAN | 0x02060000(CAN1) 0x02064000(CAN2) 0x02068000(CAN3) |
80(CAN1) 81(CAN2) 82(CAN3) |
imx-flexcan |
| MCI | 0x02070000(MCI1) 0x02071000(MCI2) 0x02072000(MCI3) |
90、91(MCI1) 92、93(MCI2) 94、95(MCI3) |
pl181 |
| LCD | 0x02080000(LCD1) 0x02084000(LCD2) 0x02088000(LCD3) |
100(LCD1) 101(LCD2) 102(LCD3) |
custom-fb(LCD1) pl111(LCD2、LCD3) |
| TS | 0x02090000(TS) | 110(TS) | custom-ts |
| 硬件 | 引脚/控制器 | 备注 |
|---|---|---|
| LED | GPIO1_0(LED1) GPIO1_1(LED2) GPIO1_2(LED3) GPIO1_3(LED4) |
4个LED灯 |
| BUTTON | GPIO2_0(BUTTON1) GPIO2_1(BUTTON2) GPIO2_2(BUTTON3) GPIO2_3(BUTTON4) |
4个BUTTON按键 |
| SWITCH_KEY | GPIO2_4 | 1个开关 |
| LCD1 | custom-fb | custom-fb虚拟物理设备 宽x高:620x348 寄存器: 0x00: BASE_PHYS 0x04: XRES 0x08: YRES 0x0c: BPP 0x10: LCDW 0x14: LCDH 0x18:BPP_DEF |
| LCD2、LCD3 | pl111 | PL111 是一款由 ARM 设计的彩色 LCD 控制器 IP 核 |
| AT24C-EEPROM | I2C1(0x03) I2C2(0x03) I2C3(0x03) |
AT24C-EEPROM挂载在I2C1、I2C2、I2C3的0x03地址上 AT24C-EEPROM大小为:256字节 |
| SPI | SPI1(loopback) SPI2(loopback) SPI3(loopback |
SPI1、SPI2、SPI3为回环模式 |
| ETH | lan9118 | LAN9118 是一款由 Microchip Technology(收购 SMSC 后继承)生产的高性能、 单芯片 10/100 Mbps 以太网控制器,主要面向嵌入式应用 |
| CAN | imx-flexcan | CAN1、CAN2和CAN3互相连接,可接收到其他CAN设备数据,并且支持上海同星 TSMaster的虚拟硬件TS Virtual Device收发 CAN硬件连接关系: CAN1<-->CAN2 CAN1<-->CAN3 CAN2<-->CAN3 TSMaster的虚拟硬件TS Virtual Device与CAN硬件连接关系: CAN1<-->通道1 CAN2<-->通道2 |
| eMMC/SD | pl181 | 存储设备 |
| TS | custom-ts | custom-fb虚拟物理设备 宽x高:620x348 寄存器: 0x00: PRESS(Touch Points register) 0x04: X(Touch X register) 0x08: Y(Touch Y register) 0x0c: IMSC(Interrupt mask and set register) 0x10: RIS(Raw interrupt status register) 0x14: MIS(Masked interrupt status register) 0x18: ICR(Interrupt clear register) |
# 下载qemu源码
$ git repo init -u https://gitee.com/CustomQemu/mainfest.git -m QEMU.xml
remote: Enumerating objects: 18, done.
remote: Counting objects: 100% (6/6), done.
remote: Compressing objects: 100% (6/6), done.
remote: Total 18 (delta 1), reused 0 (delta 0), pack-reused 12 (from 1)
Unpacking objects: 100% (18/18), 2.23 KiB | 2.00 KiB/s, done.
From https://gitee.com/CustomQemu/mainfest
* [new branch] master -> origin/master
Note: switching to 'XXX'.
...
Switched to a new branch 'default'
NOTE: Your identity is: XXX <XXX>
NOTE: If you want to change this, please re-run 'git repo init' with --config-name
NOTE: repo has been initialized in XXX\QEMU_DOARMPI
$ git repo sync
remote: Enumerating objects: 77404, done.
remote: Total 77404 (delta 0), reused 0 (delta 0), pack-reused 77404 (from 1)
Receiving objects: 100% (77404/77404), 155.10 MiB | 7.58 MiB/s, done.
Resolving deltas: 100% (10792/10792), done.
From https://gitee.com/CustomQemu/QEMU_VirtualBoard
* [new branch] master -> origin/master
Updating files: 100% (73850/73850), done.
...
Turn off this advice by setting config variable advice.detachedHead to false
HEAD is now at XXX XXX
# 编译qemu源码,打开msys2或EmDevTool工具选择{Bash}->{Msys2}
$ cd QEMU_VirtualBoard
$ mkdir build
$ cd build
$ ../configure --prefix=$PWD/exe/ --target-list="aarch64-softmmu" --disable-debug-info --enable-sdl --disable-docs
python determined to be '/mingw64/bin/python3'
python version: Python 3.10.8
mkvenv: Creating non-isolated virtual environment at 'pyvenv'
...
$ make -j8
ninja: no work to do.
/f/Gitee/DOARMPI/QEMU_DOARMPI/QEMU_VirtualBoard/build/pyvenv/bin/meson introspect --targets --tests --benchmarks | F:/Gitee/DOARMPI/QEMU_DOARMPI/QEMU_VirtualBoard/build/pyvenv/bin/python3.exe -B scripts/mtest2make.py > Makefile.mtest
[1/2416] Generating version.rc with a custom command
...
[2414/2416] Linking target tests/qtest/qos-test.exe
[2415/2416] Linking target tests/qtest/readconfig-test.exe
[2416/2416] Linking target tests/qtest/netdev-socket.exe
$ make -j8 install
[1/51] Generating tests/include/QAPI test (include) with a custom command
[2/19] Generating qemu-version.h with a custom command (wrapped by meson to capture output)
[3/4] Generating subprojects/dtc/version_gen.h with a custom command
[3/4] Installing files.
...
Installing F:/Gitee/DOARMPI/QEMU_DOARMPI/QEMU_VirtualBoard/pc-bios/keymaps/sl to F:/Gitee/DOARMPI/QEMU_DOARMPI/QEMU_VirtualBoard/build/exe/share/keymaps
Installing F:/Gitee/DOARMPI/QEMU_DOARMPI/QEMU_VirtualBoard/pc-bios/keymaps/sv to F:/Gitee/DOARMPI/QEMU_DOARMPI/QEMU_VirtualBoard/build/exe/share/keymaps
$ ls exe/
include qemu-edid.exe qemu-img.exe qemu-nbd.exe qemu-system-aarch64.exe share
lib qemu-ga.exe qemu-io.exe qemu-storage-daemon.exe qemu-system-aarch64w.exe
# 更新qemu-system-aarch64.exe,XXX为项目QEMU_DOARMPI存放目录,注意msys2环境下,磁盘C可以用/c/代替
# 绝对路径拷贝和执行命令
$ cp XXX/QEMU_VirtualBoard/build/exe/qemu-system-aarch64.exe XXX/Software/bin/qemu-system-aarch64.exe
$ XXX/Software/bin/qemu-system-aarch64.exe --version
QEMU emulator version 9.0.2
Copyright (c) 2003-2024 Fabrice Bellard and the QEMU Project developers
# 相对路径拷贝和执行命令
$ cp exe/qemu-system-aarch64.exe ../../Software/bin/qemu-system-aarch64.exe
$ $ ../../Software/bin/qemu-system-aarch64.exe --version
QEMU emulator version 9.0.2
Copyright (c) 2003-2024 Fabrice Bellard and the QEMU Project developers
# 下载裸机源码
$ git repo init -u https://gitee.com/CustomQemu/mainfest.git -m Baremetal.xml
remote: Enumerating objects: 18, done.
remote: Counting objects: 100% (6/6), done.
remote: Compressing objects: 100% (6/6), done.
remote: Total 18 (delta 1), reused 0 (delta 0), pack-reused 12 (from 1)
Unpacking objects: 100% (18/18), 2.23 KiB | 2.00 KiB/s, done.
From https://gitee.com/CustomQemu/mainfest
* [new branch] master -> origin/master
Note: switching to 'XXX'.
...
Switched to a new branch 'default'
NOTE: Your identity is: XXX <XXX>
NOTE: If you want to change this, please re-run 'git repo init' with --config-name
NOTE: repo has been initialized in XXX\QEMU_DOARMPI
$ git repo sync
remote: Enumerating objects: 573, done.
remote: Total 573 (delta 0), reused 0 (delta 0), pack-reused 573 (from 1)
Receiving objects: 87% (499/573), 12.01 MiB | 2.35 MiB/s
Receiving objects: 100% (573/573), 13.44 MiB | 2.04 MiB/s, done.
Resolving deltas: 100% (305/305), done.
...
Turn off this advice by setting config variable advice.detachedHead to false
HEAD is now at XXX XXX
编译参考裸机源码的README文档。
# 下载FreeRTOS源码
$ git repo init -u https://gitee.com/CustomQemu/mainfest.git -m FreeRTOS.xml
remote: Enumerating objects: 18, done.
remote: Counting objects: 100% (6/6), done.
remote: Compressing objects: 100% (6/6), done.
remote: Total 18 (delta 1), reused 0 (delta 0), pack-reused 12 (from 1)
Unpacking objects: 100% (18/18), 2.23 KiB | 2.00 KiB/s, done.
From https://gitee.com/CustomQemu/mainfest
* [new branch] master -> origin/master
Note: switching to 'XXX'.
...
Switched to a new branch 'default'
NOTE: Your identity is: XXX <XXX>
NOTE: If you want to change this, please re-run 'git repo init' with --config-name
NOTE: repo has been initialized in XXX\QEMU_DOARMPI
$ git repo sync
remote: Enumerating objects: 850, done.
remote: Enumerating objects: 573, done.
remote: Enumerating objects: 753, done.
...
Turn off this advice by setting config variable advice.detachedHead to false
HEAD is now at XXX XXX
# 下载RTThread源码
$ git repo init -u https://gitee.com/CustomQemu/mainfest.git -m FreeRTOS.xml
remote: Enumerating objects: 18, done.
remote: Counting objects: 100% (6/6), done.
remote: Compressing objects: 100% (6/6), done.
remote: Total 18 (delta 1), reused 0 (delta 0), pack-reused 12 (from 1)
Unpacking objects: 100% (18/18), 2.23 KiB | 2.00 KiB/s, done.
From https://gitee.com/CustomQemu/mainfest
* [new branch] master -> origin/master
Note: switching to 'XXX'.
...
Switched to a new branch 'default'
NOTE: Your identity is: XXX <XXX>
NOTE: If you want to change this, please re-run 'git repo init' with --config-name
NOTE: repo has been initialized in XXX\QEMU_DOARMPI
$ git repo sync
remote: Enumerating objects: 6438, done.
remote: Counting objects: 100% (53/53), done.
remote: Compressing objects: 100% (48/48), done.
...
Turn off this advice by setting config variable advice.detachedHead to false
HEAD is now at XXX XXX
待补充