56.2 EC20 4G 模块配置
56.2.1 添加 USB 设备信息
要使用 EC20 4G 模块首先需要在 Linux 内核中添加 EC20 的 USB 信息,这样内核启动后,才能正确识别
EC20 4G 模块。打开 Linux 内核下的 drivers/u***/serial/option.c 文件,添加如下信息:
1809 /* add support EC220 4G Module */
1810 { USB_DEVICE(0x05C6, 0x9090) }, /* Quectel UC15 */
1811 { USB_DEVICE(0x05C6, 0x9003) }, /* Quectel UC20 */
1812 { USB_DEVICE(0x05C6, 0x9215) }, /* Quectel EC20 */
1813 { USB_DEVICE(0x2C7C, 0x0125) }, /* Quectel EC25/EC20 R2.0 */
1814 { USB_DEVICE(0x2C7C, 0x0121) }, /* Quectel EC21 */
1815 /* end add */
其中第 1813 行是 EC20 4G 模块的 USB 信息。
56.2.2 Linux 内核配置
添加完 EC20 4G 模块的 USB 信息后,需要修改 Linux 内核配置来支持 USBNET 功能。具体配置如下:
Device Drivers ---> Network device support --->
USB Network Adapters --->
Multi-purpose USB Networking Framework
配置如图 56.2.2.1 所示:
接下来我们还需要使能 USB 串口 GSM、CDMA 驱动,配置路径如下:
Device Drivers ---> USB support --->
USB Serial Converter support --->
USB driver for GSM and CDMA modems
配置如图 56.2.2.2 所示:
然后配置 ppp,配置路径如下:
Device Drivers ---> Network device support --->
PPP (point-to-point protocol) support
PPP BSD-Compress compression
PPP Deflate compression PPP filtering
PPP MPPE compression (encryption) PPP multilink support
PPP over Ethernet
PPP support for async serial ports
PPP support for sync tty ports
配置如图 56.2.2.3 所示:
56.2 EC20 4G 模块配置
56.2.1 添加 USB 设备信息
要使用 EC20 4G 模块首先需要在 Linux 内核中添加 EC20 的 USB 信息,这样内核启动后,才能正确识别
EC20 4G 模块。打开 Linux 内核下的 drivers/u***/serial/option.c 文件,添加如下信息:
1809 /* add support EC220 4G Module */
1810 { USB_DEVICE(0x05C6, 0x9090) }, /* Quectel UC15 */
1811 { USB_DEVICE(0x05C6, 0x9003) }, /* Quectel UC20 */
1812 { USB_DEVICE(0x05C6, 0x9215) }, /* Quectel EC20 */
1813 { USB_DEVICE(0x2C7C, 0x0125) }, /* Quectel EC25/EC20 R2.0 */
1814 { USB_DEVICE(0x2C7C, 0x0121) }, /* Quectel EC21 */
1815 /* end add */
其中第 1813 行是 EC20 4G 模块的 USB 信息。
56.2.2 Linux 内核配置
添加完 EC20 4G 模块的 USB 信息后,需要修改 Linux 内核配置来支持 USBNET 功能。具体配置如下:
Device Drivers ---> Network device support --->
USB Network Adapters --->
Multi-purpose USB Networking Framework
配置如图 56.2.2.1 所示:
接下来我们还需要使能 USB 串口 GSM、CDMA 驱动,配置路径如下:
Device Drivers ---> USB support --->
USB Serial Converter support --->
USB driver for GSM and CDMA modems
配置如图 56.2.2.2 所示:
然后配置 ppp,配置路径如下:
Device Drivers ---> Network device support --->
PPP (point-to-point protocol) support
PPP BSD-Compress compression
PPP Deflate compression PPP filtering
PPP MPPE compression (encryption) PPP multilink support
PPP over Ethernet
PPP support for async serial ports
PPP support for sync tty ports
配置如图 56.2.2.3 所示: