当前位置:   article > 正文

20240105移远的4G模块EC20在Ubuntu 20.04.6 LTS下使用联通5G卡上网的步骤_ubuntu mobile broadband

ubuntu mobile broadband

20240105移远的4G模块EC20在Ubuntu 20.04.6 LTS下使用联通5G卡上网的步骤
2024/1/5 10:11


缘起:需要在Firefly的AIO-3399J开发板上调试移远的4G模块EC20(Android10/11/12),需要现在先测试EC20的好坏!
陶老板告诉我找一个USB2.0转mini PCIE的转接板接上去,这样就可以直接测试了。

https://item.taobao.com/item.htm?_u=5ju3ku33b5&id=580834633704&spm=a1z09.2.0.0.78122e8d0M24m1&skuId=4045144447321
4G模块转接板开发板迷你minipcie转USB移远EC20华为域格SIM/UIM
已售 2000+
¥23

https://detail.tmall.com/item.htm?_u=5ju3kuc8cc&id=45401367506&spm=a1z09.2.0.0.78122e8d0M24m1&skuId=4274333149921
CY辰阳 MINI PCIE转USB 3G 4G模块 测试开发板NGFF 含SIM UIM卡座
已售 400+
¥32

请【严重注意】注意SIM卡的方向!

【需要2G的大卡,也就是卡套外面还有卡套!】
 

昨晚WIN10上通过USB延长线接上去明显需要驱动程序。
今天在Ubuntu20.04.6下的USB3.0接口【蓝色口】插入【装上底板】EC20。

rootroot@rootroot-X99-Turbo:~$ 
rootroot@rootroot-X99-Turbo:~$ cat /etc/issue
Ubuntu 20.04.6 LTS \n \l

rootroot@rootroot-X99-Turbo:~$ 
rootroot@rootroot-X99-Turbo:~$ uname -r
5.15.0-91-generic
rootroot@rootroot-X99-Turbo:~$ uname -a
Linux rootroot-X99-Turbo 5.15.0-91-generic #101~20.04.1-Ubuntu SMP Thu Nov 16 14:22:28 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux

rootroot@rootroot-X99-Turbo:~$ 
rootroot@rootroot-X99-Turbo:~$ 
 


通过lsusb命令,很容易发现已经找到了EC20了。

插入EC20之前:

Bus 002 Device 002: ID 8087:8000 Intel Corp. 
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 8087:8008 Intel Corp. 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 002: ID 173d:0500 QSENN 
Bus 003 Device 003: ID 1c4f:0002 SiGma Micro Keyboard TRACER Gamma Ivory
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
 

插入EC20之后:

Bus 002 Device 002: ID 8087:8000 Intel Corp. 
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 8087:8008 Intel Corp. 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 002: ID 173d:0500 QSENN 
Bus 003 Device 004: ID 2c7c:0125 Quectel Wireless Solutions Co., Ltd. EC25 LTE modem
Bus 003 Device 003: ID 1c4f:0002 SiGma Micro Keyboard TRACER Gamma Ivory
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub

拔掉EC20之后:

Bus 002 Device 002: ID 8087:8000 Intel Corp. 
Bus 002 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 002: ID 8087:8008 Intel Corp. 
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 004 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub
Bus 003 Device 002: ID 173d:0500 QSENN 
Bus 003 Device 003: ID 1c4f:0002 SiGma Micro Keyboard TRACER Gamma Ivory
Bus 003 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
 

dmesg内核信息:
插入EC20之前:
[   10.146990] rfkill: input handler disabled
[  319.666131] loop12: detected capacity change from 0 to 82800
[  319.965153] audit: type=1400 audit(1704417854.208:40): apparmor="STATUS" operation="profile_load" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine" pid=2597 comm="apparmor_parser"
[  319.966389] audit: type=1400 audit(1704417854.212:41): apparmor="STATUS" operation="profile_load" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine//mount-namespace-capture-helper" pid=2597 comm="apparmor_parser"
[  320.513136] audit: type=1400 audit(1704417854.756:42): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap-update-ns.snap-store" pid=2599 comm="apparmor_parser"
[  320.537680] audit: type=1400 audit(1704417854.784:43): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.hook.configure" pid=2601 comm="apparmor_parser"
[  320.546954] audit: type=1400 audit(1704417854.792:44): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.snap-store" pid=2602 comm="apparmor_parser"
[  320.547870] audit: type=1400 audit(1704417854.792:45): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.ubuntu-software-local-file" pid=2604 comm="apparmor_parser"
[  320.561320] audit: type=1400 audit(1704417854.804:46): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.ubuntu-software" pid=2603 comm="apparmor_parser"
[  321.844676] loop13: detected capacity change from 0 to 8
[  322.196156] audit: type=1400 audit(1704417856.440:47): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine" pid=2708 comm="apparmor_parser"
[  322.225387] audit: type=1400 audit(1704417856.472:48): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine//mount-namespace-capture-helper" pid=2708 comm="apparmor_parser"
[  322.466790] audit: type=1400 audit(1704417856.712:49): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="snap.snap-store.hook.configure" pid=2711 comm="apparmor_parser"


插入EC20之后:
[   10.146990] rfkill: input handler disabled
[  319.666131] loop12: detected capacity change from 0 to 82800
[  319.965153] audit: type=1400 audit(1704417854.208:40): apparmor="STATUS" operation="profile_load" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine" pid=2597 comm="apparmor_parser"
[  319.966389] audit: type=1400 audit(1704417854.212:41): apparmor="STATUS" operation="profile_load" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine//mount-namespace-capture-helper" pid=2597 comm="apparmor_parser"
[  320.513136] audit: type=1400 audit(1704417854.756:42): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap-update-ns.snap-store" pid=2599 comm="apparmor_parser"
[  320.537680] audit: type=1400 audit(1704417854.784:43): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.hook.configure" pid=2601 comm="apparmor_parser"
[  320.546954] audit: type=1400 audit(1704417854.792:44): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.snap-store" pid=2602 comm="apparmor_parser"
[  320.547870] audit: type=1400 audit(1704417854.792:45): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.ubuntu-software-local-file" pid=2604 comm="apparmor_parser"
[  320.561320] audit: type=1400 audit(1704417854.804:46): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.ubuntu-software" pid=2603 comm="apparmor_parser"
[  321.844676] loop13: detected capacity change from 0 to 8
[  322.196156] audit: type=1400 audit(1704417856.440:47): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine" pid=2708 comm="apparmor_parser"
[  322.225387] audit: type=1400 audit(1704417856.472:48): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine//mount-namespace-capture-helper" pid=2708 comm="apparmor_parser"
[  322.466790] audit: type=1400 audit(1704417856.712:49): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="snap.snap-store.hook.configure" pid=2711 comm="apparmor_parser"

[  490.241995] usb 3-2: new high-speed USB device number 4 using xhci_hcd
[  490.399983] usb 3-2: New USB device found, idVendor=2c7c, idProduct=0125, bcdDevice= 3.18
[  490.399992] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[  490.399996] usb 3-2: Product: Android
[  490.399999] usb 3-2: Manufacturer: Android
[  490.441771] usbcore: registered new interface driver usbserial_generic
[  490.441804] usbserial: USB Serial support registered for generic
[  490.444564] usbcore: registered new interface driver cdc_wdm
[  490.447789] usbcore: registered new interface driver option
[  490.447801] usbserial: USB Serial support registered for GSM modem (1-port)
[  490.447909] option 3-2:1.0: GSM modem (1-port) converter detected
[  490.448022] usb 3-2: GSM modem (1-port) converter now attached to ttyUSB0
[  490.448074] option 3-2:1.1: GSM modem (1-port) converter detected
[  490.448166] usb 3-2: GSM modem (1-port) converter now attached to ttyUSB1
[  490.448208] option 3-2:1.2: GSM modem (1-port) converter detected
[  490.448282] usb 3-2: GSM modem (1-port) converter now attached to ttyUSB2
[  490.448315] option 3-2:1.3: GSM modem (1-port) converter detected
[  490.448406] usb 3-2: GSM modem (1-port) converter now attached to ttyUSB3
[  490.448810] qmi_wwan 3-2:1.4: cdc-wdm0: USB WDM device
[  490.449917] qmi_wwan 3-2:1.4 wwan0: register 'qmi_wwan' at usb-0000:00:14.0-2, WWAN/QMI device, d6:49:5d:75:15:67
[  490.449948] usbcore: registered new interface driver qmi_wwan

拔掉EC20之后:
[   10.146990] rfkill: input handler disabled
[  319.666131] loop12: detected capacity change from 0 to 82800
[  319.965153] audit: type=1400 audit(1704417854.208:40): apparmor="STATUS" operation="profile_load" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine" pid=2597 comm="apparmor_parser"
[  319.966389] audit: type=1400 audit(1704417854.212:41): apparmor="STATUS" operation="profile_load" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine//mount-namespace-capture-helper" pid=2597 comm="apparmor_parser"
[  320.513136] audit: type=1400 audit(1704417854.756:42): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap-update-ns.snap-store" pid=2599 comm="apparmor_parser"
[  320.537680] audit: type=1400 audit(1704417854.784:43): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.hook.configure" pid=2601 comm="apparmor_parser"
[  320.546954] audit: type=1400 audit(1704417854.792:44): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.snap-store" pid=2602 comm="apparmor_parser"
[  320.547870] audit: type=1400 audit(1704417854.792:45): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.ubuntu-software-local-file" pid=2604 comm="apparmor_parser"
[  320.561320] audit: type=1400 audit(1704417854.804:46): apparmor="STATUS" operation="profile_replace" info="same as current profile, skipping" profile="unconfined" name="snap.snap-store.ubuntu-software" pid=2603 comm="apparmor_parser"
[  321.844676] loop13: detected capacity change from 0 to 8
[  322.196156] audit: type=1400 audit(1704417856.440:47): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine" pid=2708 comm="apparmor_parser"
[  322.225387] audit: type=1400 audit(1704417856.472:48): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="/snap/snapd/20671/usr/lib/snapd/snap-confine//mount-namespace-capture-helper" pid=2708 comm="apparmor_parser"
[  322.466790] audit: type=1400 audit(1704417856.712:49): apparmor="STATUS" operation="profile_replace" profile="unconfined" name="snap.snap-store.hook.configure" pid=2711 comm="apparmor_parser"
[  490.241995] usb 3-2: new high-speed USB device number 4 using xhci_hcd
[  490.399983] usb 3-2: New USB device found, idVendor=2c7c, idProduct=0125, bcdDevice= 3.18
[  490.399992] usb 3-2: New USB device strings: Mfr=1, Product=2, SerialNumber=0
[  490.399996] usb 3-2: Product: Android
[  490.399999] usb 3-2: Manufacturer: Android
[  490.441771] usbcore: registered new interface driver usbserial_generic
[  490.441804] usbserial: USB Serial support registered for generic
[  490.444564] usbcore: registered new interface driver cdc_wdm
[  490.447789] usbcore: registered new interface driver option
[  490.447801] usbserial: USB Serial support registered for GSM modem (1-port)
[  490.447909] option 3-2:1.0: GSM modem (1-port) converter detected
[  490.448022] usb 3-2: GSM modem (1-port) converter now attached to ttyUSB0
[  490.448074] option 3-2:1.1: GSM modem (1-port) converter detected
[  490.448166] usb 3-2: GSM modem (1-port) converter now attached to ttyUSB1
[  490.448208] option 3-2:1.2: GSM modem (1-port) converter detected
[  490.448282] usb 3-2: GSM modem (1-port) converter now attached to ttyUSB2
[  490.448315] option 3-2:1.3: GSM modem (1-port) converter detected
[  490.448406] usb 3-2: GSM modem (1-port) converter now attached to ttyUSB3
[  490.448810] qmi_wwan 3-2:1.4: cdc-wdm0: USB WDM device
[  490.449917] qmi_wwan 3-2:1.4 wwan0: register 'qmi_wwan' at usb-0000:00:14.0-2, WWAN/QMI device, d6:49:5d:75:15:67
[  490.449948] usbcore: registered new interface driver qmi_wwan

[  588.322914] r8169 0000:07:00.0 enp7s0: Link is Down
[  882.885532] r8169 0000:07:00.0 enp7s0: Link is Up - 1Gbps/Full - flow control rx/tx
[ 1547.093014] r8169 0000:07:00.0 enp7s0: Link is Down
[ 2378.489893] usb 3-2: USB disconnect, device number 4
[ 2378.490192] option1 ttyUSB0: GSM modem (1-port) converter now disconnected from ttyUSB0
[ 2378.490223] option 3-2:1.0: device disconnected
[ 2378.490445] option1 ttyUSB1: GSM modem (1-port) converter now disconnected from ttyUSB1
[ 2378.490467] option 3-2:1.1: device disconnected
[ 2378.490760] option1 ttyUSB2: GSM modem (1-port) converter now disconnected from ttyUSB2
[ 2378.490783] option 3-2:1.2: device disconnected
[ 2378.491122] option1 ttyUSB3: GSM modem (1-port) converter now disconnected from ttyUSB3
[ 2378.491145] option 3-2:1.3: device disconnected
[ 2378.491534] qmi_wwan 3-2:1.4 wwan0: unregister 'qmi_wwan' usb-0000:00:14.0-2, WWAN/QMI device

ifconfig1【插入EC20之前】

enp7s0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether 00:e0:1a:5a:05:21  txqueuelen 1000  (Ethernet)
        RX packets 24262  bytes 35225383 (35.2 MB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 8729  bytes 635358 (635.3 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 210  bytes 19375 (19.3 KB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 210  bytes 19375 (19.3 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0


ifconfig2【插入EC20之后】

enp7s0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether 00:e0:1a:5a:05:21  txqueuelen 1000  (Ethernet)
        RX packets 24859  bytes 35282763 (35.2 MB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 9148  bytes 684019 (684.0 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 279  bytes 25188 (25.1 KB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 279  bytes 25188 (25.1 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

wwan0: flags=4305<UP,POINTOPOINT,RUNNING,NOARP,MULTICAST>  mtu 1500
        inet 10.33.142.10  netmask 255.255.255.252  destination 10.33.142.10
        unspec 00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00  txqueuelen 1000  (UNSPEC)
        RX packets 14  bytes 1568 (1.5 KB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 17  bytes 1214 (1.2 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0


ifconfig5【拔掉EC20之后】

enp7s0: flags=4099<UP,BROADCAST,MULTICAST>  mtu 1500
        ether 00:e0:1a:5a:05:21  txqueuelen 1000  (Ethernet)
        RX packets 24859  bytes 35282763 (35.2 MB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 9148  bytes 684019 (684.0 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0

lo: flags=73<UP,LOOPBACK,RUNNING>  mtu 65536
        inet 127.0.0.1  netmask 255.0.0.0
        inet6 ::1  prefixlen 128  scopeid 0x10<host>
        loop  txqueuelen 1000  (Local Loopback)
        RX packets 1553  bytes 223810 (223.8 KB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 1553  bytes 223810 (223.8 KB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0


根据NEXT点击的上网步骤发一下!


Mobile Broadband off

Mobile Broadband off
Connect
Mobile Broadband Settings

settings
Lock
Power off / Log Out

Cancel
Next
carr
otroot@rootroot-X99-Turbo:~$ifconfig > ifconootroot-X99-Turbo:troot@rootroot-X99-Turbo:~S
Set up a Mobile Broadband ConnectionChoose your Provider's Country or RegionChoose your Provider
This assistant helps you easily set up a mobile broadband connection to a cellular(3G) network.
You will need the following information
Your broadband provider's name
Choose your Billing Plan
D
.Your broadband billing plan name(in some cases) Your broadband billing plan APN (Access Point Name
Confirm Mobile Broadband Settings

Cancel
carrie
Choose your Provider's Country or Region
0
Set up a Mobile Broadband ConnectionChoose your Provider's Country or RegionChoose your Provider
otroot@rootroot-X99-Turbo:~$ifconfig > ifconfrootroot-X99-Turbotroot@rootroot-X99-Turbo;~S
Country or region:
Brunei DarussalamBulgariaBurkina FasoBurundi
Choose your Billing Plan
Confirm Mobile Broadband Settings
0
Cambodia
Cameroon
Canada
Chile
0
chin
4
Colombia
Congo, The Democratic Republic of the

Cancel
R
Set up a Mobile Broadband ConnectionChoose your Provider's Country or RegionChoose your Provider
otroot@rootroot-X99-Turbo:~$ifconfig > ifconfrootroot-X99-Turbotroot@rootroot-X99-Turbo;~S
 Select your provider from a list:
China Mobil
Choose your Billing Plan
China Unicom
Confirm Mobile Broadband Settings
0
4
 I can't find my provider and I wish to set up the connection manually:
My provider uses GSM technology (GPRS, EDGE, UMTS, HSPA)

Cancel
Network
Wired
Cable unplugged
Choose your Billing Plan
o
otroot@rootroot-X99-Turbo:~$ifconfig > ifconfrootroot-X99-Turbotroot@rootroot-X99-Turbo;~S
a
Set up a Mobile Broadband ConnectionChoose your Provider's Country or RegionChoose your Provider
Choose your Billing Plan
Confirm Mobile Broadband Settings
Select your plan:
Default
Selected plan APN (Access Point Name):
3gnet
D
Varning selecting an incorrert plan may result in biling issues for yourid account or may preve
4
f you are unsure of your plan please ask your provider for your plan's APN

CancelBack
Confirm Mobile Broadband Settings
Apply
Set up a Mobile Broadband ConnectionChoose your Provider's Country or RegionChoose your ProviderChoose your Billing Plan
Your mobile broadband connection is configured with the following settings:Your Provider:China unicom, China
8
Your Plan:
p
Confirm Mobile Broadband Settings
Default
APN: 3gnet

Authentication required
A password is recoired era t0mect to "china
Password
Cancel
@
Connect

 Network
Bluetoot
Background
国Appearance
Notifications
Search
:::Applications
Privacy
Online Accounts
sharing
 Sound
Power
Displays
Network
Wired
Cable unplugged
Mobile BroadbandGConnected
Network china Unicom Default
IP Address 10.33.142.10Default Route 10.33.142.9
DNS 120.80.80.80 221.5.88.88
VPN
Not set up
Network Proxy
o
@
off口

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/小小林熬夜学编程/article/detail/602316
推荐阅读
相关标签
  

闽ICP备14008679号