Initial setup steps for various M.2 modem module models - BELABOX/tutorial GitHub Wiki

Software and hardware required

Software

Windows

  • Putty

Click the Serial radio button and put the AT command COM port in the Serial Line field. Speed is usually 9600.

Putty connection setup

After connecting, try typing AT and pressing enter. If you're properly connected the modem should respond with OK.

Putty AT test

Be aware that Ctrl+V will not work for pasting into a Putty terminal, so either use Shift+Insert or mouse right click if you need to paste something.

Linux

  • Minicom, or
  • GNU screen

Connecting to modem directly through Belabox

If your modem is not recognized by your computer via the above methods it may be necessary to connect to the modem directly through Belabox. This can be done via SSH:

  1. Connect Belabox to the same wifi network your PC is using.
  2. Navigate to the “advanced/developer” section of the Belabox UI.
  3. Select “Start SSH”.
  4. Open Powershell (windows) or Bash (Linux) and connect to Belabox via the following command: ssh user@[belabox IP] where the belabox IP is it’s IP address on your wifi network.
  5. You may be prompted to continue without establishing the authenticity of the host. Respond with yes.
  6. A password will be requested. Copy/paste the password generated in the Belabox UI.

Congratulations! You have successfully connected to the Belabox via SSH. Belabox does not have a way to communicate directly to your modem so we will need to install it:

  • Run sudo apt install screen
  • Run sudo apt install usbutils (optional but useful for identifying and interacting with USB ports)

Now you have all the tools necessary for dealing with your modem via Belabox. Useful commands:

  • sudo mmcli -L - requires the same password as before but provides a list of all modems connected and identified by Modem Manager.
  • lsusb - shows a list of all USB devices connected to Belabox and can be useful for ensuring the Belabox recognizes your modem.
  • ls /dev/ttyUSB* - lists all the USB serial devices connected to Belabox and can be used to identify the appropriate serial port to communicate with your modem.

SSH Connection Example

Now its time to talk to your Modem. Typically, windows device manager could identify which COM port is used to by the USB device to listen for AT commands but you’ll need to brute force it here by connecting to each USB serial port and running AT. If the port responds with OK it is likely the correct port.

Run screen /dev/ttyUSB0 115200 which will open a new window for communicating with the port. Send the AT command and check for a response of OK. If this port doesn't work, try USB1, USB2, etc. until you find the correct serial port.

Hardware

USB carrier board

An adapter with an M.2 B-key slot for the modem, often a SIM card slot (unless intended only for eSIM modems), and a USB connector of some sort.

Antennas

Make sure your antennas are for LTE and/or 5G, and have SMA connectors (not RP-SMA as those are generally used for Wi-Fi, although some will work with modems as well). Always connect the minimum recommended number of antennas (usually Main and one Aux) to your modem before connecting it to anything that will power it on (like a PC or BELABOX), or you'll risk damaging the antenna amplifier in the modem.

Antenna connector leads

The connectors on these modems are commonly I-PEX MHF4 (a.k.a. IPEX4, IPEX-4, or IPX-4) which can be a little bit tricky both to connect and disconnect, and a couple of people on the Discord server have reported either damaging the onboard connector or even ripping it from the modem PCB. Make sure to use connector leads with SMA connectors on the other (antenna) end, connect them carefully to the modem, and don't disconnect them from the modem unless absolutely necessary, to avoid risk of aforementioned damage. The connector leads are generally cheaper than ordering more modem modules, so don't move the same leads around between modems unless you're willing to take your chances.

Modems

These instructions are for initial setup procedures (usually on delivery), and should not be required more than once for each modem.

Dell DW5821e (a.k.a. Foxconn T77W968)

Added by vhasi, edited by ...

Description

The Dell DW5821e is a very capable Cat16 LTE modem module originally used in Dell laptops. Some initial setup steps may be required (see below) but in some cases they will work without issues as delivered.

There is also an eSIM model called DW5821e-eSIM, which will work exactly like the non-eSIM model if you want to use a physical SIM card in the SIM card slot on the carrier board.

Firmware

It's possible that there are problems with some newer firmware versions (F1.0.0.5.*), but this has not been confirmed. If your modem works and you aren't in need of any specific feature or fix in a newer firmware, do not upgrade the firmware in the modem.

Finding the COM port on Windows

Start Device Manager and open the Ports category, then use the Application Interface port for AT commands.

Device Manager -> Ports

Useful commands

  • AT - check that the modem is awake.
  • AT&F - factory reset.
  • AT^RESET - reboot the modem. This will require reconnecting Putty since the COM port disappears and reappears.
  • AT^NV=2497,1,"01" - disable FTM (Field Test Mode). A lot of second-hand modules (from AliExpress et al) have FTM enabled on delivery.
  • ATI - modem information, including model, firmware version, IMEI, etc.
  • AT^DEBUG? - a lot more modem information.
  • AT$QCCLAC - list all available AT commands.

Initial setup procedure (lucky version)

When taking delivery of a DW5821e, mount it to your carrier board of choice and make sure to connect the required antennas properly. Only the Main antenna is used for TX (upload), and only Aux1 is required for RX (download). Feel free to attach antennas to Aux2 and Aux3 for better RX performance, but it will not improve TX speeds.

Also make sure you have a working SIM card in the carrier board SIM card slot, and then connect the USB port of the carrier board to the USB port of your choice on your BELABOX. If the stars are aligned in your favour the modem will pop up as a WWAN device (wwan*) in belaUI after up to a minute or two, but if it doesn't you'll need to send some AT commands.

Initial setup procedure (unlucky version)

Connect the carrier board to a Windows PC, wait a minute for the device to settle, and then use Putty to connect to the modem (see above). Type (or cut and paste) the following commands into the Putty terminal window, and make sure the modem responds with OK after each command before sending the next command.

  1. AT^NV=2497,1,"01"
  2. AT^RESET

Successful AT commands

If any of these commands results in ERROR instead of OK, you may need to do a factory reset first so send AT&F. Should that fail as well, leave the modem connected to the PC and Putty connected to the modem while you go make yourself a cup of tea, and then try again. You can also try sending the same command over and over a few times - this has proven successful for some people on the Discord server. Once you get OK back from the commands and the modem reboots as expected, close Putty, disconnect the carrier board from the PC, and retry the lucky setup procedure above. If it still fails, get on Discord and explain thoroughly what you've done, what doesn't work, how it doesn't work, and what you were expecting to happen.

Fibocom L850-GL

Added by vhasi, edited by ...

Description

The Fibocom L850-GL is a Cat9 LTE modem originally used in Lenovo ThinkPad laptops. Some initial setup steps may be required (see below) but in some cases they will work without issues as delivered.

Finding the COM port on Windows

Start Device Manager and open the Ports category, then use the modem's highest numbered COM port for AT commands.

Useful commands

  • AT&F - factory reset.
  • AT+GTUSBMODE=7 - set the preferred USB communication mode.

Initial setup procedure (lucky version)

When taking delivery of an L850-GL, mount it to your carrier board of choice and make sure to connect the required antennas properly. This modem only has two antenna connectors (Main5 and Aux6), and both are required to be connected to antenna for reasonable functionality.

Also make sure you have a working SIM card in the carrier board SIM card slot, and then connect the USB port of the carrier board to the USB port of your choice on your BELABOX. The modem should pop up as a WWAN device (wwan*) in belaUI after up to a minute or two, but if it doesn't you'll need to send some AT commands.

Initial setup procedure (unlucky version)

Connect the carrier board to a Windows PC, wait a minute for the device to settle, and then use Putty to connect to the modem (see above). Type (or cut and paste) the following commands into the Putty terminal window, and make sure the modem responds with OK after each command before sending the next command.

  1. AT&F
  2. AT+GTUSBMODE=7

If any of these commands results in ERROR instead of OK, leave the modem connected to the PC and Putty connected to the modem while you go make yourself a cup of tea, and then try again. Once you get OK back from the commands, close Putty, disconnect the carrier board from the PC, and retry the lucky setup procedure above. If it still fails, get on Discord and explain thoroughly what you've done, what doesn't work, how it doesn't work, and what you were expecting to happen.

Fibocom L860-GL-16

Added by vhasi, edited by ...

Description

The Fibocom L860-GL-16 is a Cat16 LTE modem originally used in Lenovo ThinkPad laptops.

I have not personally tested this, just adding it for the link below. /vhasi

Links

https://wiki.gentoo.org/wiki/Fibocom_L860-GL-16#Is_my_modem_FCC_locked.3F

Fibocom FM350-GL

Added by FarlesBarkley edited by ...

Description

The Fibocom FM350-GL is an m.2 5G modem used by multiple laptops. It is an inexpensive 5G option but can be tricky to get working. Below are a couple AT commands that MAY help get it working:

  1. AT+CFUN? checks the functionality of the card. a response of "1" means it is fully operational. Your modem may arrive in factory test mode "5". If so, run AT+CFUN=1 to change modes.
  2. AT+GTESIMCFG=1,0,0 this command disables ESIM mode. The user manual states the ESIM mode may need to be disabled for certain carriers to work.
  3. AT+GTFCCLOCKMODE? this command checks if there is an FCC lock on. A response of "0" means no lock. Any other response means a lock exists. Try AT+GTFCCLOCKMODE=0 to remove the lock.
  4. AT+E5GOPT? Certain carriers appear to have weird IPV4V6 protocols that don't work well with the modem. If the modem responds with a "7" try AT+E5GOPT=5 or vice versa.

The above have worked individually or collectively or not at all. Use at your own risk.