This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
library:rk3568:4gmodule [2022/11/21 17:18] lhaosen [1.2 lsusb] |
library:rk3568:4gmodule [2023/07/18 00:37] (current) lhaosen [AT 功能] |
||
---|---|---|---|
Line 2: | Line 2: | ||
连接EC20模块 | 连接EC20模块 | ||
+ | |||
+ | ===== - 主要命令 ===== | ||
+ | lsusb | ||
+ | quectel-CM | ||
+ | mmcli -m 0 | ||
+ | ip address | ||
+ | ping | ||
===== - 基本命令例子 ===== | ===== - 基本命令例子 ===== | ||
Line 21: | Line 28: | ||
</ | </ | ||
- | ==== - lsusb ==== | + | 执行 lsusb 命令,如果出现如下内容则模块已经成功被 Linux 系统识别到。 |
+ | |||
+ | Bus 002 Device 009: ID 2c7c:0125 Quectel Wireless Solutions Co., Ltd. EC25 LTE modem | ||
+ | |||
+ | 其中,0x2C7C 和 0x0125 分别是 Quectel EC25/EC20 R2.0 的 VID 和 PID 编号。 | ||
+ | |||
+ | ==== - AT指令接口 | ||
+ | |||
+ | 当连接模块并加载 USB 驱动成功后,在 /dev 目录下将会创建出几个 tty 设备节点。例如 / | ||
< | < | ||
- | root@firefly:/ | + | root@firefly:/ |
- | [11-03_16:33:19:289] QConnectManager_Linux_V1.6.1 | + | crw-rw---- 1 root dialout 188, 0 Jun 7 16:37 / |
- | [11-03_16:33:19:293] Find / | + | crw-rw---- 1 root dialout 188, 1 Jun 28 2021 / |
- | [11-03_16:33:19:294] Auto find qmichannel = / | + | crw-rw---- 1 root dialout 188, 2 Jun 7 16:37 / |
- | [11-03_16:33:19:294] Auto find usbnet_adapter = wwan0 | + | crw-rw---- 1 root dialout 188, 3 Jun 7 16:36 / |
- | [11-03_16:33:19:295] netcard driver = qmi_wwan_q, driver version = 22-Aug-2005 | + | </ |
- | [11-03_16:33:19:295] Modem works in QMI mode | + | |
- | [11-03_16:33:19:323] cdc_wdm_fd = 7 | + | |
- | [11-03_16:33:19:393] Get clientWDS = 7 | + | 测试AT指令 |
- | [11-03_16:33:19:425] Get clientDMS = 1 | + | < |
- | [11-03_16:33:19:457] Get clientNAS = 2 | + | root@firefly:/ |
- | [11-03_16:33:19:489] Get clientUIM = 1 | + | [13] 1137 |
- | [11-03_16:33:19:521] Get clientWDA = 1 | + | root@firefly:/ |
- | [11-03_16:33:19:553] requestBaseBandVersion EC20CEFILGR06A07M1G | + | |
- | [11-03_16:33:19:681] requestGetSIMStatus SIMStatus: | + | Quectel |
- | [11-03_16:33:19:713] requestGetProfile[1] /// | + | EC20F |
- | [11-03_16:33:19:745] requestRegistrationState2 MCC: 460, MNC: 1, PS: Detached, DataCap: | + | Revision: EC20CEFILGR06A07M1G |
- | [11-03_16:33:19:777] requestQueryDataCall IPv4ConnectionStatus: | + | |
- | [11-03_16:33:19:778] ifconfig wwan0 0.0.0.0 | + | OK |
- | [11-03_16:33:19:792] ifconfig wwan0 | + | root@firefly:/ |
+ | [14] 1138 | ||
+ | root@firefly:/ | ||
+ | root@firefly:/ | ||
+ | OK | ||
+ | |||
+ | |||
+ | root@firefly: | ||
+ | [4] 1065 | ||
+ | root@firefly: | ||
+ | root@firefly: | ||
+ | +QCCID: 89860000191998625782 | ||
+ | |||
+ | OK | ||
+ | |||
+ | </ | ||
+ | |||
+ | ==== - quectel-CM | ||
+ | < | ||
+ | root@firefly: | ||
+ | [1] 1176 | ||
+ | root@firefly: | ||
+ | [11-21_11:52:07:419] Find / | ||
+ | [11-21_11:52:07:420] Auto find qmichannel = / | ||
+ | [11-21_11:52:07:420] Auto find usbnet_adapter = wwan0 | ||
+ | [11-21_11:52:07:420] netcard driver = qmi_wwan_q, driver version = 22-Aug-2005 | ||
+ | [11-21_11:52:07:421] Modem works in QMI mode | ||
+ | [11-21_11:52:07:451] cdc_wdm_fd = 7 | ||
+ | [11-21_11:52:07:539] Get clientWDS = 7 | ||
+ | [11-21_11:52:07:571] Get clientDMS = 1 | ||
+ | [11-21_11:52:07:603] Get clientNAS = 2 | ||
+ | [11-21_11:52:07:635] Get clientUIM = 1 | ||
+ | [11-21_11:52:07:668] Get clientWDA = 1 | ||
+ | [11-21_11:52:07:700] requestBaseBandVersion EC20CEFILGR06A07M1G | ||
+ | [11-21_11:52:07:828] requestGetSIMStatus SIMStatus: | ||
+ | [11-21_11:52:07:859] requestGetProfile[1] | ||
+ | [11-21_11:52:07:891] requestRegistrationState2 MCC: 460, MNC: 0, PS: Attached, DataCap: | ||
+ | [11-21_11:52:07:923] requestQueryDataCall IPv4ConnectionStatus: | ||
+ | [11-21_11:52:07:924] ifconfig wwan0 0.0.0.0 | ||
+ | [11-21_11:52:07:939] ifconfig wwan0 down | ||
+ | [11-21_11: | ||
+ | [11-21_11: | ||
+ | [11-21_11: | ||
+ | [11-21_11: | ||
+ | udhcpc: started, v1.30.1 | ||
+ | udhcpc: sending discover | ||
+ | udhcpc: sending select for 10.22.39.214 | ||
+ | udhcpc: lease of 10.22.39.214 obtained, lease time 7200 | ||
+ | [11-21_11: | ||
+ | [11-21_11: | ||
+ | [11-21_11: | ||
</ | </ | ||
Line 48: | Line 115: | ||
mmcli -m MODEM_INDEX | mmcli -m MODEM_INDEX | ||
< | < | ||
- | root@firefly: | + | root@firefly: |
- | ----------------------------- | + | |
- | General | + | General |
- | | + | |
- | ----------------------------- | + | |
- | Hardware | manufacturer: | + | Hardware | |
- | | + | |
- | | firmware revision: EC20CEFILGR06A07M1G | + | |
- | | + | |
- | | + | |
- | | + | |
- | ----------------------------- | + | |
- | System | + | System |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | | + | |
- | ----------------------------- | + | |
- | Status | + | Status |
- | | + | |
- | | + | |
- | | + | |
- | ----------------------------- | + | |
- | Modes | | + | |
- | | + | Modes | supported: allowed: 2g, 3g, 4g; preferred: none |
- | ----------------------------- | + | |
- | IP | + | |
+ | IP | ||
+ | -------------------------------- | ||
+ | 3GPP | ||
+ | | ||
+ | | ||
+ | | ||
+ | -------------------------------- | ||
+ | 3GPP EPS | ue mode of operation: csps-2 | ||
+ | -------------------------------- | ||
+ | SIM | | ||
</ | </ | ||
+ | |||
+ | ==== - ip address ==== | ||
+ | < | ||
+ | root@firefly: | ||
+ | 1: lo: < | ||
+ | link/ | ||
+ | inet 127.0.0.1/8 scope host lo | ||
+ | | ||
+ | inet6 ::1/128 scope host | ||
+ | | ||
+ | 2: can0: < | ||
+ | link/ | ||
+ | 3: can1: < | ||
+ | link/ | ||
+ | 4: eth0: < | ||
+ | link/ether 4e: | ||
+ | 5: eth1: < | ||
+ | link/ether 4a: | ||
+ | 6: wwan0: < | ||
+ | link/ether 8a: | ||
+ | inet 10.22.91.212/ | ||
+ | | ||
+ | inet6 fe80:: | ||
+ | | ||
+ | 7: enx00e0996fdf14: | ||
+ | link/ether 00: | ||
+ | |||
+ | </ | ||
+ | |||
+ | |||
+ | ==== - 双卡控制 ==== | ||
+ | |||
+ | 信号名: CARD_SEL \\ | ||
+ | 核心模块引脚: 276 \\ | ||
+ | GPIO:GPIO3_C5 | ||
+ | PIN No: 117 = 32 * 3 + 8 * 2 + 5 \\ | ||
+ | 功能: 0 : eSim; 1:卡座 | ||
+ | |||
+ | 默认输出: 1 | ||
+ | |||
+ | |||
+ | rk3568-firefly-core.dtsi 删除 GPIO3_C5的驱动。 | ||
+ | |||
+ | |||
+ |