Skip to content

Commit e865d55

Browse files
authored
Merge pull request #108 from wychlw/duo_rts
DuoS/RT-Thread,RT-Smart: Add results
2 parents 2d569af + d38d1b4 commit e865d55

File tree

4 files changed

+558
-0
lines changed

4 files changed

+558
-0
lines changed

Duo_S/RT-Thread/README.md

Lines changed: 124 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,124 @@
1+
---
2+
sys: rtthread
3+
sys_ver: 5.2.0
4+
sys_var: standard
5+
6+
status: basic
7+
last_update: 2024-11-28
8+
---
9+
10+
# RT-Thread Milk-V DuoS Test Report
11+
12+
## Test Environment
13+
14+
### Operating System Information
15+
16+
- Source Code Link: https://github.com/RT-Thread/rt-thread
17+
- Reference Installation Document: https://github.com/RT-Thread/rt-thread/tree/master/bsp/cvitek
18+
- Toolchain: https://occ-oss-prod.oss-cn-hangzhou.aliyuncs.com/resource//1705395512373/Xuantie-900-gcc-elf-newlib-x86_64-V2.8.1-20240115.tar.gz
19+
20+
### Hardware Information
21+
22+
- Milk-V DuoS
23+
- A USB-A to C or USB C to C Cable
24+
- A microSD Card
25+
- A USB to UART Debugger (e.g., CH340, CH341, FT2232, etc.)
26+
27+
## Installation Steps
28+
29+
The following steps are tested on Arch Linux, but should be applicable to all major Linux distributions.
30+
31+
### Fetch Source Code and Compile Firmware
32+
33+
Obtain the toolchain and configure it:
34+
```bash
35+
wget https://occ-oss-prod.oss-cn-hangzhou.aliyuncs.com/resource//1705395512373/Xuantie-900-gcc-elf-newlib-x86_64-V2.8.1-20240115.tar.gz
36+
37+
tar -xzvf Xuantie-900-gcc-elf-newlib-x86_64-V2.8.1-20240115.tar.gz
38+
```
39+
40+
Update the following paths as needed:
41+
```bash
42+
export RTT_CC_PREFIX=riscv64-unknown-elf-
43+
export RTT_EXEC_PATH=/opt/Xuantie-900-gcc-elf-newlib-x86_64-V2.8.1/bin
44+
```
45+
46+
Fetch dependencies:
47+
```bash
48+
sudo apt install -y scons libncurses5-dev device-tree-compiler
49+
# or on Arch Linux: sudo pacman -S scons dtc ncurses
50+
```
51+
52+
```shell
53+
git clone --depth=1 https://github.com/RT-Thread/rt-thread
54+
cd rt-thread/bsp/cvitek/cv18xx_risc-v
55+
# Generate configuration
56+
scons --menuconfig
57+
source ~/.env/env.sh
58+
pkgs --update
59+
scons -j$(nproc) --verbose
60+
cd ../
61+
./combine-fip.sh $(pwd)/cv18xx_risc-v Image
62+
```
63+
64+
Please select `milkv-duos` under the `Board Type` option in menuconfig.
65+
66+
`boot.sd` and `fip.bin` files will be generated in the `cvitek/output/milkv-duos-sd` directory upon completion.
67+
68+
### Prepare microSD Card
69+
70+
Clear the microSD card and create a FAT32 partition:
71+
```shell
72+
wipefs -af /path/to/your-card
73+
mkfs.fat /path/to/your-card
74+
```
75+
76+
Copy the generated `boot.sd` and `fip.bin` files onto the microSD card. The storage card is now ready to boot RT-Thread on the DuoS.
77+
78+
### Logging into the System
79+
80+
Log into the system via the serial port.
81+
82+
## Expected Results
83+
84+
The system boots up normally and allows access through the serial port.
85+
86+
## Actual Results
87+
88+
The system boots up normally and allows access through the serial port.
89+
90+
### Boot Log
91+
92+
Screencast (from compile to boot):
93+
[![asciicast](https://asciinema.org/a/i7ZhlS8WrHBRPIkIVUffXN64a.svg)](https://asciinema.org/a/i7ZhlS8WrHBRPIkIVUffXN64a)
94+
95+
```log
96+
Starting kernel ...
97+
98+
[I/drv.pinmux] Pin Name = "UART0_RX", Func Type = 281, selected Func [0]
99+
100+
[I/drv.pinmux] Pin Name = "UART0_TX", Func Type = 282, selected Func [0]
101+
102+
heap: [0x0x000000008029a810 - 0x0x0000000080a9a810]
103+
104+
\ | /
105+
- RT - Thread Operating System
106+
/ | \ 5.2.0 build Nov 28 2024 11:45:48
107+
2006 - 2024 Copyright by RT-Thread team
108+
lwIP-2.1.2 initialized!
109+
[I/sal.skt] Socket Abstraction Layer initialize success.
110+
Hello RISC-V!
111+
msh />
112+
113+
114+
```
115+
116+
## Test Criteria
117+
118+
Successful: The actual result matches the expected result.
119+
120+
Failed: The actual result does not match the expected result.
121+
122+
## Test Conclusion
123+
124+
Test successful.

Duo_S/RT-Thread/README_RTSmart.md

Lines changed: 152 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,152 @@
1+
---
2+
sys: rtthread
3+
sys_ver: 5.2.0
4+
sys_var: smart
5+
6+
status: basic
7+
last_update: 2024-11-28
8+
---
9+
10+
# RT-Thread Milk-V DuoS Test Report
11+
12+
## Test Environment
13+
14+
### Operating System Information
15+
16+
- Source Code Link:
17+
- https://github.com/RT-Thread/rt-thread
18+
- https://github.com/RT-Thread/userapps
19+
- Reference Installation Document: https://github.com/RT-Thread/rt-thread/tree/master/bsp/cvitek
20+
- Toolchain: https://github.com/RT-Thread/toolchains-ci/releases/download/v1.7/riscv64-linux-musleabi_for_x86_64-pc-linux-gnu_latest.tar.bz2
21+
22+
### Hardware Information
23+
24+
- Milk-V DuoS
25+
- A USB-A to C or USB C to C Cable
26+
- A microSD Card
27+
- A USB to UART Debugger (e.g., CH340, CH341, FT2232, etc.)
28+
29+
## Installation Steps
30+
31+
The following steps are tested on Arch Linux, but should be applicable to all major Linux distributions.
32+
33+
### Fetch Source Code and Compile Firmware
34+
35+
Obtain the toolchain and configure it:
36+
```bash
37+
wget https://github.com/RT-Thread/toolchains-ci/releases/download/v1.7/riscv64-linux-musleabi_for_x86_64-pc-linux-gnu_latest.tar.bz2
38+
39+
tar -xjvf riscv64-linux-musleabi_for_x86_64-pc-linux-gnu_latest.tar.bz2
40+
```
41+
42+
Update the following paths as needed:
43+
```bash
44+
export RTT_CC_PREFIX=riscv64-unknown-linux-musl-
45+
export RTT_EXEC_PATH=/opt/riscv64-linux-musleabi_for_x86_64-pc-linux-gnu/bin
46+
```
47+
48+
Fetch dependencies:
49+
```bash
50+
sudo apt install -y scons libncurses5-dev device-tree-compiler
51+
# or on Arch Linux: sudo pacman -S scons dtc ncurses
52+
```
53+
54+
```bash
55+
git clone --depth=1 https://github.com/RT-Thread/rt-thread
56+
cd rt-thread/bsp/cvitek/cv18xx_risc-v
57+
# Generate configuration
58+
scons --menuconfig
59+
```
60+
61+
In menuconfig, please select `milkv-duos` under the `Board Type` option. Enter `RT-Thread Kernel` submenu ---> Select `Enable RT-Thread Smart (microkernel on kernel/userland)` to enable the RT-Smart kernel.
62+
63+
```bash
64+
source ~/.env/env.sh
65+
pkgs --update
66+
scons -j$(nproc) --verbose
67+
cd ../
68+
./combine-fip.sh $(pwd)/cv18xx_risc-v Image
69+
```
70+
71+
`boot.sd` and `fip.bin` files will be generated in the `cvitek/output/milkv-duos-sd` directory upon completion.
72+
73+
### Fetch Source Code and Compile RT-Smart userapps
74+
75+
Fetch dependencies:
76+
```bash
77+
sudo apt install -y unzip xmake
78+
```
79+
80+
Compile:
81+
```bash
82+
git clone https://github.com/RT-Thread/userapps.git
83+
cd userapps
84+
source env.sh
85+
cd apps
86+
xmake f -a riscv64gc
87+
xmake -j$(nproc)
88+
```
89+
90+
Build Image:
91+
```bash
92+
xmake smart-rootfs
93+
xmake smart-image -f ext4
94+
```
95+
The userapp image would be generated at `userapps/apps/build/ext4.img`.
96+
97+
### Prepare microSD Card
98+
99+
Clear the microSD card and create a FAT32 partition:
100+
```shell
101+
wipefs -af /path/to/your-card
102+
mkfs.fat /path/to/your-card
103+
```
104+
105+
Copy the generated `boot.sd` and `fip.bin` files onto the microSD card. The storage card is now ready to boot RT-Smart on the DuoS.
106+
107+
### Logging into the System
108+
109+
Log into the system via the serial port.
110+
111+
## Expected Results
112+
113+
The system boots up normally and allows access through the serial port.
114+
115+
## Actual Results
116+
117+
The system boots up normally and allows access through the serial port.
118+
119+
### Boot Log
120+
121+
Screencast (from compile to boot):
122+
[![asciicast](https://asciinema.org/a/WF4Ves2YpwbHHUMLnmQPtPtBb.svg)](https://asciinema.org/a/WF4Ves2YpwbHHUMLnmQPtPtBb)
123+
124+
```log
125+
Starting kernel ...
126+
127+
[I/drv.pinmux] Pin Name = "UART0_RX", Func Type = 281, selected Func [0]
128+
129+
[I/drv.pinmux] Pin Name = "UART0_TX", Func Type = 282, selected Func [0]
130+
131+
heap: [0x0xffffffc0002fb110 - 0x0xffffffc000afb110]
132+
133+
\ | /
134+
- RT - Thread Smart Operating System
135+
/ | \ 5.2.0 build Nov 28 2024 11:29:57
136+
2006 - 2024 Copyright by RT-Thread team
137+
lwIP-2.1.2 initialized!
138+
[I/sal.skt] Socket Abstraction Layer initialize success.
139+
[I/drivers.serial] Using /dev/ttyS0 as default console
140+
Hello RT-Smart!
141+
142+
```
143+
144+
## Test Criteria
145+
146+
Successful: The actual result matches the expected result.
147+
148+
Failed: The actual result does not match the expected result.
149+
150+
## Test Conclusion
151+
152+
Test successful.

0 commit comments

Comments
 (0)