介紹
RT-Thread-Smart
RT-Thread Smart(以下簡稱 Smart) 是基于 RT-Thread 操作系統(tǒng)上的混合操作系統(tǒng),簡稱為 rt-smart,它把應(yīng)用從內(nèi)核中獨(dú)立出來,形成獨(dú)立的用戶態(tài)應(yīng)用程序,并具備獨(dú)立的地址空間(32 位系統(tǒng)上是 4G 的獨(dú)立地址空間)。
Xmake
xmake 是一個基于 Lua 的輕量級跨平臺構(gòu)建工具,使用 xmake.lua 維護(hù)項目構(gòu)建,相比 makefile/CMakeLists.txt,配置語法更加簡潔直觀,對新手非常友好,短時間內(nèi)就能快速入門,能夠讓用戶把更多的精力集中在實(shí)際的項目開發(fā)上。
快速入門
此次以 qemu-virt64-aarch64 為例講解
克隆倉庫
將 Smart 的 userapps 倉庫克隆下來
安裝 xmake
請根據(jù)xmake 官方文檔進(jìn)行安裝
以下為 ubuntu 安裝方式
sudo add-apt-repository ppa:xmake-io/xmake
sudo apt update
sudo apt install xmake
安裝 qemu
userapps 已提供 qemu 7.1.0 的安裝包,位于目錄 tools/qemu/qemu_7.1.0-2022111713_amd64.deb
sudo apt-get install -y libglib2.0-dev libpixman-1-dev
sudo dpkg -i ./qemu_7.1.0-2022111713_amd64.deb
如若想安裝最新版本,請自行下載 qemu 源碼進(jìn)行編譯安裝
編譯
由于 smart 采用 xmake 編譯用戶態(tài)環(huán)境,因此 smart 的編譯方式非常簡單。
首先運(yùn)行 env.sh 添加一下環(huán)境變量
source env.sh
進(jìn)入 apps 目錄進(jìn)行編譯
cd apps
xmake f -a aarch64 # 配置為 aarch64平臺
xmake -j8
鏡像制作
運(yùn)行 xmake smart-rootfs 制作 rootfs ,運(yùn)行 xmake smart-image 制作鏡像
xmake smart-rootfs
xmake smart-image -o ../prebuilt/qemu-virt64-aarch64-ext4/ext4.img # 將鏡像輸出至 qemu-virt64-aarch64-ext4 目錄
運(yùn)行 qemu
進(jìn)入 userapp/prebuilt/qemu-virt64-aarch64-ext4,運(yùn)行 qemu.sh 腳本啟動 qemu
cd prebuilt/qemu-virt64-aarch64-ext4/
./qemu.sh
在 qemu 中 輸入 ctrl+a 抬起后,再輸入 x 即可退出 qemu。
-
RT-Thread
+關(guān)注
關(guān)注
32文章
1367瀏覽量
41485 -
Lua語言
+關(guān)注
關(guān)注
0文章
9瀏覽量
1567 -
Ubuntu系統(tǒng)
+關(guān)注
關(guān)注
0文章
91瀏覽量
4230 -
qemu
+關(guān)注
關(guān)注
0文章
57瀏覽量
5611
發(fā)布評論請先 登錄
RT-Thread記錄(一、版本開發(fā)環(huán)境及配合CubeMX)

RT-Thread Smart 入門指南
RT-Thread的smart之imx6ull用戶態(tài)點(diǎn)燈操作過程分享
如何使用xmake工具來編譯rt-thread工程
ART Pi Smart基于RT-Thread Smart系統(tǒng)的LVGL移植簡介
RT-Thread Smart快速上手
RT-Thread用戶手冊
RT-Thread Smart已正式上線,源代碼可下載,采用Apache License 2.0
RT-Thread Smart已正式上線
RT-Thread Smart 上手指南

RT-Thread全球技術(shù)大會:RT-Thread Smart更好的兼容Linux生態(tài)

絲滑的在RT-Smart用戶態(tài)運(yùn)行LVGL
基于xmake的RT-Thread Smart用戶態(tài)開發(fā)教程

評論