1006 RPi0 4G MiniPCIe EN
Keywords
Raspberry Pi Zero, Zero W, Zero WH, Zero 2W, miniPCIe Cat4 4G LTE, USB2.0-A, Ethernet, Expansion Board, SSH
I. Introduction
This expansion board is based on the Raspberry Pi Zero series boards and extends MiniPCIe 4G functionality. It utilizes the gold-plated test points for USB and power on the back of the Raspberry Pi Zero board for peripheral expansion. This expansion board essentially acts as a USB HUB, connecting the expansion board to the Zero's USB port via pogo pins, eliminating the need for external USB cables, saving space, and enhancing aesthetics. It expands to four USB ports via USB, including one USB-to-100Mbps wired Ethernet, one USB connected to a MiniPCIe 4G Cat4 module, and two USB2.0-A host interfaces.
The expansion board supports Raspberry Pi Zero, Zero W, Zero WH, and Zero 2W, as well as the Orange Pi Zero 2W.
The 4G LTE module is a high-cost-performance module aimed at medium-speed IoT applications, capable of meeting the majority of connectivity and transmission needs. The multiple 4G LTE modules we provide are driver-free on the Raspberry Pi OS, Ubuntu OS and OpenWrt OS, meaning they are automatically recognized without the need for you to install additional drivers. Similarly, on the Ubuntu system for the Orange Pi, the 4G modules are also driver-free. The 4G LTE module supports Qualcomm 4G/GPS, NL668-EU/EAU/AM and EG25-G.
Choosing a 4G module requires that the Bands of the local SIM card operator match those of the 4G module. If the Bands do not match, the system can recognize the 4G model but will not be able to connect to the internet. Therefore, please choose carefully before purchasing.
(Note: When using this expansion board, the Raspberry Pi Zero development board cannot utilize the OTG function. If you need to use the OTG function, all interfaces on the expansion board will become unavailable.)
II. Hardware Spec
1. Four gold-plated pogo pins are used separately for powering the expansion board and for USB communication.
2. One USB-C power supply, or you can power it from the Raspberry Pi's own micro port(choose one of the two options), and the Raspberry Pi's micro USB port should not be connected to any other devices.
3. One USB2.0 MiniPCIe interface is used for connecting the 4G LTE module.
4. One Nano SIM card slot.
5. One 100Mbps Ethernet port.
6. Two USB2.0-A ports, each capable of ensuring a 2A current output.
7. Three LED indicators: PWR/MODE/ACT LED.
8. Onboard reset button for 4G module.
9. Size: 85*70mm.
10. The PCB board uses an ENIG process, is lead-free, and the material has passed UL and RoHS certification with a fire resistance rating of 94V-0.
11. An optional aluminum alloy enclosure is available.
Note 1: After connecting this expansion board, the Micro USB port on the Zero will no longer be usable.
Note 2: In some systems, it is necessary to disable the OTG function and set the USB mode to Host mode.
III. Work with Raspberry Pi OS
This document uses the Raspberry Pi OS and OpenWrt system for testing.
The version of the Raspberry Pi OS is: 2024-07-04-raspios-bookworm-arm64.img.xz
You can download the Raspberry Pi OS in:
https://www.raspberrypi.com/software/operating-systems/#raspberry-pi-os-64-bit
(If using the first-generation Raspberry Pi Zero board, which only supports 32-bit systems, please pay attention to the version you download.)
The version of the OpenWrt is: openwrt-bcm27xx-bcm2709-rpi-2-squashfs-sysupgrade-linux-6.1.98-20240723.img.gz
Different versions of Raspberry Pi OS have varying strategies for 4G network management. Based on the 64-bit OS version, the results are as follows:
▶ Qualcomm 4G/GPS and NL668-EU/EAU/AM, CAT4 4G:
| OS version | Test results |
| 2023-02-21-bullseye | Auto-identification, plug and play, automatic internet connection. |
| 2023-05-03-bullseye | |
| 2023-12-05-bookworm | |
| 2024-07-04-bookworm | |
| 2024-11-19-bookworm | |
| 2025-05-13-bookworm | |
| 2025-10-01-trixie |
▶ EG25-G:
| OS version | Test results |
| 2023-02-21-bullseye | Auto-identification, plug and play, automatic internet connection. |
| 2023-05-03-bullseye | |
| 2023-12-05-bookworm | Auto-identification, but there may be instances of network connection failure,
and the OS requires the installation of DNS software. |
| 2024-07-04-bookworm | |
| 2024-11-19-bookworm | |
| 2025-05-13-bookworm | |
| 2025-10-01-trixie |
The Raspberry Pi Zero series boards only support 32-bit OS. The test results are as follows:
▶ Qualcomm 4G/GPS and NL668-EU/EAU/AM, CAT4 4G, EG25-G:
| OS version | Test results |
| 2023-02-21-bullseye | Auto-identification, plug and play, automatic internet connection. |
| 2023-05-03-bullseye | |
| 2023-12-05-bookworm | |
| 2024-07-04-bookworm | |
| 2024-11-19-bookworm | |
| 2025-05-13-bookworm | |
| 2025-10-01-trixie |
3.1 View hardware devices
3.1.1 View USB devices
Open the terminal in Raspberry Pi OS and enter the command lsusb, as shown in the image below:
Device 002:External USB Hub;
Device 003:USB to 100Mbps Ethernet adapter;
Device 004:USB2.0-A Interface;
Device 005:4G module;
Device 006:USB2.0-A Interface;
If no device is connected to the USB port, then after executing lsusb, Device 006 and 004 will not appear.
If the system stop at the Raspberry Pi logo and fails to boot:
or if after booting, the keyboard, mouse, and 4G module cannot be used, please carefully check whether the pogo pins are aligned with the gold-plated contacts. Additionally, on the PC, open the config.txt file located in the root directory of the TF card to check the USB initialization script:
You need to confirm that the three red-boxed areas in the following image are all configured completely. If not, please manually add the missing parts and save the file:
# otg_mode=1 (It is recommended to comment out as follow)
dtoverlay=dwc2,dr_mode=host (These two areas must be ensured to be included.)
3.1.2 View network devices
Open the terminal in Raspberry Pi OS and enter the command ifconfig -a, (Our internal IP is 192.168.8.x, used to determine the expansion board's 100 Mbps network card device.) as shown in the image below:
CAT4 4G:
Qualcomm 4G/GPS,NL668-EU/EAU/AM:
ZTE CAT4:
EG25-G:
3.2 Test network devices
This section uses a Qualcomm 4G module as the test module. The same as NL668-EU/EAU/AM.
3.2.1 Ping tests
When testing, there is a priority order. If there are specific requirements for internal and external networks, please adjust the metric values of each network and the DNS server settings.
For related settings regarding network card priority, please refer to the following link:
1. Set network adapter priority
2. Using udhcpc to specify DNS servers
3. Examples of how to use udhcpc
Now the system is connected to both a wired Gigabit network card and 4G, you can use the -I parameter to specify which network interface to start pinging from, as shown below:
ping www.mcuzone.com -I eth0
ping www.mcuzone.com -I usb0
Priority can be checked by executing the route command; the network card with the smaller metric value will be preferred for communication.
We can also force communication through another network by disabling a specific network card. For example, to disable usb0, you can execute the following command:
sudo ifconfig usb0 down
And enable usb0 by the following command:
sudo ifconfig usb0 up
3.2.2 Test speed by iperf3
You can download iperf3 (Windows version) in:
http://www.mcuzone.com/down/Software.asp?ID=10000634
Install iperf3 (Linux version) by using the following command:
sudo apt-get install iperf3
100M Ethernet speed test results:
It is about 92.3Mbps in client mode:
It is about 94.8Mbps in server mode:
Note: The USB to 100M Ethernet adapter may not reach full speed due to the performance limitations of the Zero 2W, the USB hub, and the bandwidth usage of the 4G Cat4.
3.2.3 4G network testing
Due to the performance limitations of Zero 2W, running browsers like Chromium for web page speed testing can make the system run very slowly. So we use the lightweight browser surf for speed testing.
Install the lightweight browser surf:
sudo apt install surf
Then turn off WiFi, unplug the Ethernet cable, leaving only the 4G network connection, and go to https://test.ustc.edu.cn/ for speed testing. Execute the following command in the Raspberry Pi terminal:
surf https://test.ustc.edu.cn
The results are as follows:
Note: Network speed test results are affected by the network environment and testing methods. The actual speeds may vary; this test is for reference only.
3.3 AT Command for 4G
3.3.1 Open AT Command serial port
To operate 4G Module using AT commands on a Raspberry Pi, you first need to open the AT command serial port. The method to open it is as follows:(here use Qualcomm 4G for the demonstration)
To open ttyUSB serial port, input the following command: lsusb:
Record the ID value of the 4G module: 05c6 90b6
Use the following command to open the ttyUSB serial port, where the value after echo is the ID recorded above:
sudo modprobe option
sudo sh -c 'echo 05c6 90b6 > /sys/bus/usb-serial/drivers/option1/new_id'
After execution is complete, the system should have three additional devices: ttyUSB0, ttyUSB1, and ttyUSB2. Input ls /dev to view:
Then Open serial port by serial port tool.
Install minicom:
sudo apt-get install minicom
Open AT Command serial port by minicom:
sudo minicom -D /dev/ttyUSB0
(Note: Typically, three ports (ttyUSB0 to ttyUSB2)will appear. In general, the AT port is ttyUSB0 under most OSs. If that doesn't work, you may try other ports such as ttyUSB1. If multiple USB-to-serial devices are present, further attempts will be needed until the correct AT port is identified.)
The first time you enter an AT command, there may be no echo. If you then input the command at and press Enter, and it returns "OK," it indicates that everything is working properly. If you need to check the echo, please type the command: ate1, then press Enter. After that, you can continue to type other commands and press Enter to see the results.
Note: The operation procedures are the same, but for different 4G models, the corresponding USB IDs will vary, so please refer to the actual USB ID using the lsusb command.
3.3.2 Common AT commands
1) Check if the SIM card is detected:
at+cpin?
Return ready to indicate the card has been recognized, if return error, you need to check the hardware.
2) Check antenna signal quality:
at+csq
Return values between 26 and 31 indicate a good signal, with 31 representing a full signal strength; return values between 20 and 25 indicate a barely acceptable signal; return values below 20 indicate a poor signal or that the antenna might not be connected.
3) Check network registration status:
at+cops?
Normally, it should return the network supporter's code: 7, where 7 represents 4G.
Note: The above command at+csq should not include a question mark, while the other two commands require a question mark.
4) View the SIM card's IMEI code:
at+cgsn
5) Reset 4G module (Sometimes, if you reinsert the SIM card, hot swapping may not work; in such cases, you can use this reset command to reset the module.):
at+reset
6) Disable radio frequency:
at+cfun=0
Enable radio frequency:
at+cfun=1
The two commands mentioned above can be used in pairs to allow the module to re-register with the network without restarting the 4G module.
3.4 Modify the IP address of the 4G
1) Qualcomm 4G/GPS,NL668-EU/EAU/AM, ZTE CAT4:
Set the 4G module's IP to directly obtain a public IP. Please execute the AT command:
Set the IP to public: AT+GTIPPASS=1
Set the IP to private: AT+GTIPPASS=0
Check whether the current IP is a public or private IP:AT+GTIPPASS?
2) CAT4 4G:
Execute the AT command:
AT+ROUTEIP=<newip>
Note: only addresses in the format of 192.168.x.1 are supported. If you set AT+ROUTEIP=192.168.3.1, the final IP address obtained will be 192.168.3.100. After making the changes, you need to power off and restart the system.
Query current IP: AT+ROUTEIP?, it returns two values, the first one is the old IP, and the second one is the new IP.
Test command: AT+ROUTEIP=?
3.5 GPS Testing
3.5.1 Qualcomm 4G-GPS and NL668-EU/EAU/AM
Execute the command lsusb, as shown in the figure below:
Note down the ID of the 4G module: 05c6 90b6.
Use the following command to open the ttyUSB serial port, where the value following echo is the ID value recorded above:
sudo modprobe option
sudo sh -c 'echo 05c6 90b6 > /sys/bus/usb-serial/drivers/option1/new_id'
After executing the two commands above, the system should have three additional devices: ttyUSB0/1/2. You can check them by executing ls /dev:
Execute minicom and open the ttyUSB0 serial port:
sudo minicom -D /dev/ttyUSB0
Then execute:
at+gtgpsepo=1 //Enable AGPS
at+gtgpspower=1 //Enable GPS
Wait a moment for the positioning to succeed, then execute:
at+gtgps? //View NMEA information
You can then see that the serial port outputs GPS information:
3.5.2 EG25-GPS
Execute the command lsusb, as shown in the figure below:
Note down the ID of the 4G module: 2c7c 0125.
Use the following command to open the ttyUSB serial port, where the value following echo is the ID value recorded above:
sudo modprobe option
sudo sh -c 'echo 2c7c 0125 > /sys/bus/usb-serial/drivers/option1/new_id'
After executing the two commands above, the system should have three additional devices: ttyUSB0/1/2/3. You can check them by executing ls /dev/ttyUSB*:
Execute minicom and open the ttyUSB3 serial port:
sudo minicom -D /dev/ttyUSB3
Then execute:
AT+QGPS=1 //Open GPS
After executing successfully, open ttyUSB1:
sudo minicom -D /dev/ttyUSB1
You can then see that the serial port outputs GPS information; wait a moment for it to get a fix:
IV. FAQ
4.1 The OS got stuck halfway through startup, what should I do?
Q1: If the OS is stuck at the Raspberry Pi logo and fails to boot (as shown in the figure):
A1: Please open config.txt located in the root directory of the TF card system partition on your PC to check the USB initialization script.
Please confirm whether the three red boxed areas in the image below are fully configured. If not, manually add the missing configurations and save the file.
# otg_mode=1(Recommend commenting this out)
dtoverlay=dwc2,dr_mode=host(Two places must be ensured to be added)
4.2 What should I do if the mouse and keyboard are not working?
Q2: After startup, neither the keyboard, mouse, nor the 4G module are working. What should I do?
A2: In terms of hardware:
1. Please carefully check whether the ejector pin is aligned with the gold-plated pogo pins and whether the screws are tightened;
2. Please check if the micro port of the Raspberry Pi Zero development board itself has any other external devices connected, not even a USB cable should be attached.
If there are no hardware issues, then it should be resolved from the software side. Please refer to the steps in Answer 1.
4.3 Can the USB gadget still be used after connecting the expansion board?
Q3: I previously used the Micro USB port on my Raspberry Pi Zero as a USB gadget. Now that I’ve connected an expansion board, can I use the USB ports on the expansion board to achieve USB gadget functionality?
A3: No. The original Raspberry Pi Zero uses its Micro USB port as a USB gadget, where the Micro USB OTG functions in device mode. However, our expansion board uses the Raspberry Pi Zero's Micro USB OTG in host mode, OTG supports only one of the two functions at a time. Therefore, if you wish to use the USB gadget feature, you will have to forgo our expansion board and use the Raspberry Pi Zero directly.
4.4 How is power supply provided?
Q4: After power is supplied through the USB-C port on the expansion board, does the Raspberry Pi Zero's Micro power port still need to be powered?
A4: For power supply, choose one of the two options. You can either power the board solely via the USB-C port on the expansion board, or solely via the Micro power port on the Raspberry Pi Zero itself. Do not plug in both power ports simultaneously.
4.5 The IP address for 4G is visible, but there's no internet connection. What should I do?
Q5: After executing ifconfig -a, the 4G device is recognized and an IP address is visible. It can ping IP addresses, but cannot ping domain names (as shown in the figure below). What should I do?
A5: If the ping to the IP address succeeds, it means the 4G module can access the internet normally. If the ping to the domain name fails, it indicates a DNS resolution issue with the 4G system. The following steps are required: Connect the expansion board's Ethernet port to an upstream router to allow the Raspberry Pi Zero to access the internet, and install udhcpc (using the ZTE CAT4 4G as an example here):
sudo apt install udhcpc
After installation, please execute (the network identifier after -i can be checked by running ifconfig -a):
sudo udhcpc -i enx344b50000000
Then ping:
4.6 What should I do if I need to execute udhcpc every time after startup?
Q6: For 4G devices that require DNS server resolution, network connectivity can be established after installing udhcpc. However, udhcpc needs to be execute every time the OS restarts. How can I set it up so that the OS can automatically connect to the internet via 4G network upon boot?
A6: To add startup commands in the rc.local file, you can refer to the following steps (taking Qualcomm 4G as an example, where usb0 is the device name for the 4G connection. It can be viewed by executing ifconfig -a, and the actual device name should be based on the user's physical hardware):
Start the rc-local service:
sudo systemctl enable --now rc-local
Open the rc.local using the following command:
sudo nano /etc/rc.local
Add the commands you want to execute at startup above "exit 0", that is:
sleep 5 && sudo udhcpc -i usb0 && sleep 5 && sudo udhcpc -i usb0 && sleep 5 && sudo udhcpc -i usb0
The sleep command is used to delay the execution of subsequent commands by a specified number of seconds. Since obtaining an IP address for the 4G module requires some time, to prevent udhcpc from failing, it is necessary to execute the command multiple times and add a certain delay between each execution. As a result, after the system boots up, the 4G network becomes available in about 20 seconds.
Then save the file, and the OS will automatically connect to the internet via the 4G module upon startup.
V. Work with OpenWrt
We are using the Raspberry Pi Zero 2W with CAT4 4G to demonstrate running OpenWrt, can be configured as a one-in-one-out switch mode. The 4G module on the expansion board can serve as the WAN port (for direct 4G internet access), while the Ethernet port is configured as the LAN port for connecting to a PC.
The OpenWrt which be used in this document is: openwrt-bcm27xx-bcm2709-rpi-2-squashfs-sysupgrade-linux-6.1.98-20240723.img.gz
4.1 Configure the system
Connect the Ethernet port of the expansion board to the PC's Ethernet port using an Ethernet cable. The 4G module requires a mobile SIM card to be inserted. Power on and start the system. We find Network and Internet settings in Windows, then open the connected network under Ethernet to view the default gateway IP address. This address is the backend configuration page address for the OpenWrt system. As shown in the figure, the address for this test is 192.168.198.1:
Then open a web browser and enter 192.168.198.1 to access the OpenWrt system. The default username is root, and the default password is password:
After logging into the OpenWrt system, click on "System - TTYD Terminal," then run lsusb to check if the 4G module is recognized. The red box in the image below indicates that the CAT4 4G module has been recognized.
Execute the command ip addr to view all network devices. In the figure below, the No. 6, eth1 represents the network name of the CAT4 4G module. If you use NL668-AM/EU/EAU/Qualcomm 4G, this network name could be usb0. Please refer to the actual situation:
4.2 ADD the 4G module
Click on "Network - Interfaces," and then click on "ADD NEW INTERFACE...".
Set it up according to the following picture:
If 4G is NL668-AM/EU/EAU/Qualcomm 4G, Set it up as follows:
In the "Firewall Settings", select the WAN and then click the "SAVE & APPLY" button:
Go back to "Network - Interfaces", wait a moment, and you will see the newly created WAN interface has obtained an IP address. This way, the PC can access the internet through the 4G LTE module(in the two figures below, they are eth1 and usb0 respectively):
Open https://www.speedtest.cn/ on the PC to test speed. At this point, the PC can access the internet through the 4G LTE module, and the test results are as follows(CAT4 4G):
VI. Expansion board selection guide
Contact Us
Email: mcuzone@vip.qq.com
Tel: +86(0)13957118045
If there are any omissions, errors, or infringements on this page, please contact us through the above methods. Thank you!
Copyright 2004-2025 Wildchip




QQ:8204136