Skip to content

Commit bdc81cb

Browse files
committed
* update imu doc
1 parent e7e1a8d commit bdc81cb

File tree

3 files changed

+10
-9
lines changed

3 files changed

+10
-9
lines changed

docs/doc/en/modules/ahrs.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,15 +49,16 @@ Some devices have a built-in IMU, as shown below:
4949
| Device Name | Sensor Model | Accelerometer | Gyroscope | Magnetometer | Interface | Features |
5050
| ----------- | ------------ | ------------- | --------- | ------------ | -------------------- | ----------------------------------------------- |
5151
| MaixCAM-Pro | QMI8658 |||| IIC4<br>Address 0x6B | Low power<br>High stability<br>High sensitivity |
52-
| MaixCAM | None ❌ |||| | |
52+
| MaixCAM | None ❌ |||| | |
53+
| MaixCAM2 | LSM6DSOWTR |||| Built-in driver | Low power<br>High stability<br>High sensitivity |
5354

5455
Besides using the built-in IMU, you can also connect an external IMU sensor, such as the classic `MPU6050/MPU9150`. Search for the latest and suitable sensors yourself.
5556

5657
In MaixPy, attitude estimation and IMU drivers are separated, so you can use your own driver for external sensors and still call the attitude estimation algorithm.
5758

5859
## MaixPy Read IMU Data
5960

60-
Using the built-in `QMI8658` of MaixCAM-Pro as an example, use `maix.imu.IMU` to read:
61+
Using MaixCAM-Pro as an example, use `maix.imu.IMU` to read:
6162

6263
```python
6364
from maix.ext_dev import imu
@@ -66,7 +67,7 @@ from maix.ext_dev import imu
6667
calibrate_first = False
6768

6869
# default config: acc +-2g 1KHz, gyro +-256rad/s 8KHz
69-
sensor = imu.IMU("qmi8658", mode=imu.Mode.DUAL,
70+
sensor = imu.IMU("default", mode=imu.Mode.DUAL,
7071
acc_scale=imu.AccScale.ACC_SCALE_2G,
7172
acc_odr=imu.AccOdr.ACC_ODR_1000,
7273
gyro_scale=imu.GyroScale.GYRO_SCALE_256DPS,
@@ -93,7 +94,7 @@ while True:
9394
```
9495

9596
Here, an `IMU` object is constructed, then `read_all` is called to read and print the data.
96-
Since `qmi8658` has no magnetometer, it's not printed.
97+
Since the onboard IMU has no magnetometer, it's not printed.
9798

9899
However, note that calibration is needed, as explained below.
99100

docs/doc/zh/modules/ahrs.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ IMU(Inertial Measurement Unit),即 惯性测量单元,通常由几部分
5050
| ----- | ----- | ------- | ----- | ---- | ---- | --- |
5151
| MaixCAM-Pro | QMI8658 |||| IIC4<br>地址 0x6B | 低功耗<br>高稳定性<br>高灵敏度 |
5252
| MaixCAM | 无板载 ❌ |||| | | |
53-
53+
| MaixCAM2 | LSM6DSOWTR |||| 内置驱动 | 低功耗<br>高稳定性<br>高灵敏度 |
5454

5555
除了使用内置的,你也可以自己外接一个 IMU 传感器,比如经典的`MPU6050/MPU9150`等,可自行查找最新和合适的传感器。
5656

@@ -60,7 +60,7 @@ MaixPy 中姿态解算和 IMU 驱动是分开的,所以你可以自己外接
6060

6161
## MaixPy 读取 IMU 数据
6262

63-
以 MaixCAM-Pro 自带的`QMI8658` 为例,使用 `maix.imu.IMU` 读取:
63+
以 MaixCAM-Pro 为例,使用 `maix.imu.IMU` 读取:
6464

6565
```python
6666
from maix.ext_dev import imu
@@ -69,7 +69,7 @@ from maix.ext_dev import imu
6969
calibrate_first = False
7070

7171
# default config: acc +-2g 1KHz, gyro +-256rad/s 8KHz
72-
sensor = imu.IMU("qmi8658", mode=imu.Mode.DUAL,
72+
sensor = imu.IMU("default", mode=imu.Mode.DUAL,
7373
acc_scale=imu.AccScale.ACC_SCALE_2G,
7474
acc_odr=imu.AccOdr.ACC_ODR_1000,
7575
gyro_scale=imu.GyroScale.GYRO_SCALE_256DPS,
@@ -97,7 +97,7 @@ while True:
9797
```
9898

9999
这里构造了一个`IMU`对象,然后调用`read_all`读取数据,再打印。
100-
由于`qmi8658` 没有 磁力计,这里没有打印。
100+
由于板载IMU没有 磁力计,这里没有打印。
101101

102102

103103

examples/ext_dev/sensors/imu/imu_read_data.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
calibrate_first = False
55

66
# default config: acc +-2g 1KHz, gyro +-256rad/s 8KHz
7-
sensor = imu.IMU("qmi8658", mode=imu.Mode.DUAL,
7+
sensor = imu.IMU("default", mode=imu.Mode.DUAL,
88
acc_scale=imu.AccScale.ACC_SCALE_2G,
99
acc_odr=imu.AccOdr.ACC_ODR_1000,
1010
gyro_scale=imu.GyroScale.GYRO_SCALE_256DPS,

0 commit comments

Comments
 (0)