3G Dongle RIL Source Code and Kernel Versions
In various kernel versions, the ttyUSB devices for USB-to-serial conversion may differ. This implies that the same 3G dongle might be associated with different /dev/ttyUSB paths on machines running different kernel versions. In such cases, adjustments are required in the Android upper layer to adapt to these interfaces, particularly modifying the AT port and modem port for 3G dongles. The relevant modification is located in hardware/ril-rk29-dataonly/modem_list.h. Taking the Huawei DONGLE with PID 0X14AC as an example, under the 3.10 kernel, the USB-to-serial driver call results in the following serial devices: /dev/ttyUSB2 corresponds to the AT port, /dev/ttyUSB1 corresponds to the USER DIAG port, and /dev/ttyUSB0 corresponds to the Modem port. For data internet services, both AT and modem ports are needed. Therefore, the s_support_modem_lists support list must include TTYUSB2 and TTYUSB0 for PID 0x14AC: { {0x12D1, 0x14AC, "E1820"}, "E1820", RADIO_TYPE_WCDMA, TTYUSB2, TTYUSB0, 115200.