Skip to content

Commit 17c690b

Browse files
committed
docs: mars add usb boot
1 parent 94ba949 commit 17c690b

File tree

2 files changed

+72
-12
lines changed
  • docs/mars/getting-started
  • i18n/zh/docusaurus-plugin-content-docs/current/mars/getting-started

2 files changed

+72
-12
lines changed

docs/mars/getting-started/boot.md

+36-6
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
sidebar_label: 'Boot the Mars'
33
sidebar_position: 10
44
---
5-
# Boot Mars from microSD card
5+
## Boot Mars from microSD card
66

7-
## Prepare
7+
### Prepare
88

99
- Necessary
1010
- Mars
@@ -14,12 +14,12 @@ sidebar_position: 10
1414
- USB to TTL serial cable
1515
- HDMI cable
1616

17-
## Download images and tools
17+
### Download images and tools
1818

1919
- Download the system image from [Official Image](https://milkv.io/docs/mars/getting-started/images#official-image).
2020
- Download the flash tool, [balenaEtcher](https://etcher.balena.io/) or [Rufus](https://rufus.ie/en/).
2121

22-
## Burn image
22+
### Burn image
2323

2424
Here are the steps for using balenaEtcher.
2525

@@ -35,12 +35,42 @@ Here are the steps for using balenaEtcher.
3535

3636
![etcher-step3](/docs/duo/etcher-step3.png)
3737

38-
## Power on
38+
### Power on
3939

4040
Insert the microSD card with the burned firmware into the Mars microSD card slot. Use an adapter (5V) to connect Mars via a Type-C cable. Mars will automatically power on and the red power LED on the board will light up. After the system starts successfully, the green status LED on the board will flash.
4141

4242
If an HDMI monitor is connected, the Debian desktop will be displayed after booting.
4343

44-
## Troubleshooting
44+
### Troubleshooting
4545

4646
If you have a problem, go to our [community](https://community.milkv.io/) and post to let us know.
47+
48+
49+
## Boot Mars from USB drive
50+
51+
* Note: The USB drive booting process is a bit complicated, it is recommended to use the microSD card to boot Mars. The USB drive can only be plugged into the USB3.0 port.
52+
53+
Use a serial cable to connect to the serial debugging port of Mars. When powering on Mars, press any key to interrupt the boot process and enter the U-Boot command line.
54+
55+
In the U-Boot command line, enter the following commands:
56+
57+
```bash
58+
setenv boot_devs 'mmc nvme usb'
59+
setenv distro_bootenv_usb 'setenv bootdev usb; setenv devnum 0; run usb_boot'
60+
saveenv
61+
```
62+
63+
Download the image and burn it to the USB drive. Use the microSD card to boot Mars, insert the USB drive into Mars, and modify the `extlinux.conf` file on the USB drive.
64+
65+
```bash
66+
sudo mount /dev/sad3 /mnt
67+
sudo nano /mnt/extlinux/extlinux.conf
68+
```
69+
70+
In the `extlinux.conf`, modify the `APPEND` line, change `root=/dev/mmcblk1p4` to `root=/dev/sda4`, as shown below:
71+
72+
```bash
73+
append root=/dev/sda4 rw console=tty0 console=ttyS0,115200 earlycon rootwait stmmaceth=chain_mode:1 selinux=0
74+
```
75+
76+
Save and exit, unmount the USB drive. Power off, remove the microSD card, and power on again.

i18n/zh/docusaurus-plugin-content-docs/current/mars/getting-started/boot.md

+36-6
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,9 @@
22
sidebar_label: '启动 Mars'
33
sidebar_position: 10
44
---
5-
# 从 microSD 卡启动 Mars
5+
## 从 microSD 卡启动 Mars
66

7-
## 准备
7+
### 准备
88

99
- 必要的
1010
- Mars
@@ -14,12 +14,12 @@ sidebar_position: 10
1414
- USB to TTL 串口模块
1515
- HDMI 线
1616

17-
## 下载镜像和工具
17+
### 下载镜像和工具
1818

1919
- 下载 [官方镜像](https://milkv.io/zh/docs/mars/getting-started/images#%E5%AE%98%E6%96%B9%E9%95%9C%E5%83%8F)
2020
- 下载镜像烧录工具 [balenaEtcher](https://etcher.balena.io/)[Rufus](https://rufus.ie/en/)
2121

22-
## 烧录镜像
22+
### 烧录镜像
2323

2424
以下是使用 BalenaEtcher 的步骤。
2525

@@ -35,12 +35,42 @@ sidebar_position: 10
3535

3636
![etcher-step3](/docs/duo/etcher-step3.png)
3737

38-
## 开机
38+
### 开机
3939

4040
将烧录好固件的 microSD 卡插入 Mars 的 microSD 卡槽中。使用适配器 (5V) 通过 Type-C 线连接 Mars,Mars 会自动上电开机,板上的红色电源灯会亮起。待系统启动成功后,板上的绿色状态灯会闪烁。
4141

4242
如果有连接 HDMI 显示器,开机后会显示 Debian 桌面。
4343

44-
## 故障排除
44+
### 故障排除
4545

4646
如果您有问题,请到我们的[社区](https://community.milkv.io/)发帖,让我们知道。
47+
48+
49+
## 从 U 盘启动 Mars
50+
51+
* 注意:U 盘启动步骤有点复杂,建议使用 microSD 卡启动 Mars。U 盘只能插在 USB3.0 口。
52+
53+
使用串口线连接到 Mars 的串口调试口,在 Mars 上电的时候按任意按键打断启动,进入 U-Boot 命令行。
54+
55+
在 U-Boot 命令行中输入以下命令:
56+
57+
```bash
58+
setenv boot_devs 'mmc nvme usb'
59+
setenv distro_bootenv_usb 'setenv bootdev usb; setenv devnum 0; run usb_boot'
60+
saveenv
61+
```
62+
63+
下载镜像烧录到 U 盘。使用 microSD 卡启动 Mars,把 U 盘插入 Mars 中,修改 U 盘里的 extlinux.conf 文件。
64+
65+
```bash
66+
sudo mount /dev/sad3 /mnt
67+
sudo nano /mnt/extlinux/extlinux.conf
68+
```
69+
70+
`extlinux.conf` 中修改 `APPEND` 行,把 `root=/dev/mmcblk1p4` 改成 `root=/dev/sda4`,如下所示:
71+
72+
```bash
73+
append root=/dev/sda4 rw console=tty0 console=ttyS0,115200 earlycon rootwait stmmaceth=chain_mode:1 selinux=0
74+
```
75+
76+
保存并退出,卸载 U 盘。关机,拔掉 microSD 卡,重新上电开机。

0 commit comments

Comments
 (0)