How to enable T99W175 5G modem

Hello,
I've been tinkering with T99W175 from AliExpress. It's probably the cheapest option right now for 5G connectivity and I'm happy to report that I got it working.
I will just give some bullet points if someone wants to follow my config:
AT+CUSTOMER should be set to 0 or 8 (tested both, working)
AT+USBSWITCH should be 90D5
Modem has to have jumper soldered on the back side and also pin 2 isolated from the M.2 to USB converter.

Then we can go over some software. Starting from clean install you need following packages (go to LuCi, system, software) : mbim-utils, kmod-usb-net-cdc-mbim, libmbim, umbim, modemmanager
After installing those packages you can go to Network-Interfaces-Add new. As a protocol you should chose ModemManager, as a device your cdc-wdm0 (not ttyUSB, you should not get ttyUSB at this point), APN, authenticaton and IP type according to your cellular provider. Also don't forget to set firewall zones for this interface, i set mine to WAN.
After this save, save&apply and you should be good to go.
To diagnose what's happening you can use GL.iNET GUI (system - log). Unfortunately there's no OEM GUI support for this kind of connection, I will try to get support involved into adding support for original GUI as it's easier to manage this connection than using mmcli in shell.

If you need ttyUSB exposed you need to go into ssh, then type

cat /sys/kernel/debug/usb/devices

You should see some of your devices with "Driver=none". To assign a driver you just need to go and type

echo "05c6 90d5" > /sys/bus/usb-serial/drivers/option1/new_id

Default baudrate is 9600, for AT commands I use YAT terminal on Windows, port settings are 9600 8N1N
After all of this my mmcli looks like this:
Zrzut ekranu 2024-12-22 170825

And speedtest with a 4G connection (didn't yet set proper allowed and preferred mode in mmcli)

Now all that is missing is proper GL GUI support. At this moment the cellular connection seems to get higher priority than WLAN Repeater (should be other way around for me) and there's not a clear way to change it. Also there's no clear way to manage your modem (for example i need to use Windows to change AT commands).
All in all, for sub 40$ 5G modem this thing rocks.

2 Likes

Update after some fiddling with antennas

2 Likes

Hi,

Welcome them to our community!

Thank you for sharing!

1 Like

@jabbik thanks for sharing!
"I am also happily using a t99w175 modem on a gl-a1300 router. Have you managed to get the AT commands working on OpenWrt/gl.inet interface in any way? Thanks

Just to summarize what the authors steps for using T99W175 on any m.2 to USB conversion board including GL-M2:

  1. Modify the T99W175 according to this Russian website - https://4pda.to/forum/index.php?showtopic=1086317#Spoil-129097688-9
    basically, soldering the two connectors; then use a tap to tap off the 2nd most right pin.

This will make T99W175 in USB mode. This however, does not mean that T99W175 has 'AT' command interface enabled (enable ttyUSB) (This requires USB mode enable).

The reason 'AT' command interface requires to be enable, because it is how ModemManager talks to T99W175, including command for initiating connection with mobile data provider.

This is the genius of this post comes in.
2. enable ttyUSB.
Following the instruction of this post. The only part need to be pay attention is the generic driver location.
So: echo "05c6 90d5" > /sys/bus/usb-serial/drivers/option1/new_id Tis line of code might not be suitable for everyone, on arch the command should be: echo "05c6 90d5" > /sys/bus/usb-serial/drivers/generic/new_id

After this, ttyUSB will be enabled, this in turn will enable 'ModemManager' to execute its command that requires 'AT' level interface.

Hope this helps.

1 Like

Thank you for the guide this was really useful. If you have the time I have a few questions.

I got the modem working but if I try to expose the ttyUSB interface, modemmanager would stop working/detecting the modem.

I then tries to send the AT commands detailed by the OP but could not open any AT port. How did you or the AP managed to send the AT commands to the modem?

I have tried to enable ttyUSB with the "echo" command and then use minicom on OpenWRT (tried ttyUSB0, 1 and 3) but this would not work and I could not send commands.

Did you use a Windows PC for this or something else?

'ttyUSB' refers to a device file that represents a serial port exposed over a USB connection.

Need to install "kmod-usb-serial" to have "usb-serial" folder in /sys/bus

in the OP
The command echo "05c6 90d5" > /sys/bus/usb-serial/drivers/option1generic/new_id enables ttyUSB devices for your T99W175 modem by performing the following actions: This command basically forced a driver to be one a device.
changes made directly to sysfs files like new_id do not persist across reboots.
Then: Picocom
1. Dynamically adding a new USB Device ID to the option driver:
○ /sys/bus/usb-serial/drivers/option1/new_id is a special file in the Linux sysfs filesystem. Sysfs provides an interface to kernel objects, allowing userspace programs to interact with and configure devices.
○ The option driver is a generic USB serial driver in the Linux kernel specifically designed to support a wide range of GSM/CDMA modems. Many modems, especially those based on Qualcomm chipsets, are supported by this driver.
○ When you write "05c6 90d5" to this file, you are telling the option driver to recognize a new USB device with:
§ 05c6: This is the Vendor ID (VID). In this case, 05c6 is associated with Qualcomm, Inc., which is the manufacturer of the chipset used in the T99W175 modem.
§ 90d5: This is the Product ID (PID). This specific PID, in conjunction with the VID, uniquely identifies the T99W175 modem when it's operating in its desired USB mode (after the hardware modification).
2. Triggering device probing and binding:
○ Once the new Vendor ID and Product ID pair (05c6:90d5) is added to the option driver's supported device list, the kernel will attempt to "probe" for this new device.
○ If the T99W175 is connected and in USB mode, the option driver will recognize it as a device it can handle.
○ The driver will then "bind" to the device, which involves creating the necessary character devices in the /dev directory. These are typically named ttyUSBx (e.g., ttyUSB0, ttyUSB1, etc.). Each ttyUSB device represents a serial port provided by the modem.
In essence, this command manually informs the Linux kernel's option USB serial driver that the device with VID 05c6 and PID 90d5 should be treated as a serial modem. Without this explicit instruction, the kernel might not automatically associate the T99W175 with a suitable driver, or it might assign a generic driver that doesn't expose the necessary AT command interfaces.
This dynamic addition is particularly useful for devices that might not be in the driver's default compiled-in list of supported devices, or for modems that present different PIDs depending on their operational mode (like the T99W175 needing to be in "USB mode" first).
Once ttyUSB devices are enabled, as you noted, ModemManager (or other communication software) can then interact with the T99W175 using standard AT commands through these serial interfaces to manage mobile data connections.

Application Interaction: Software like ModemManager, minicom, screen, or custom applications can open this /dev/ttyUSBx file and send/receive data, including AT commands for modems, just as they would with a physical RS-232 serial port.

As some user have pointed out, some system (be it linux, windows they can recognise T99W175 without any modification, it's plug and play. for me it is recognised a generic modern.)

Hope this helps.

1 Like

Thank you very much for the detailed reply and for all the information provided. It is nice to know and get a better understanding of what’s happening.

If I may, I would like some advice on what I should do to get it to work as expected.

Here is what I did in order:

  1. Performed the modification on the card (soldered the jumper, isolated the 2nd pin to prevent a short circuit).
  2. Installed the required packages on OpenWRT. (Context note: I am using a 4G/5G Waveshare board for the Raspberry Pi CM4. This has worked perfectly with my previous SIM7600G-H card. I also tested with and m.2 to usb module)
  3. After all of this, I created the ModemManager interface, and the modem connected.

At this point, there were no ttyUSB devices available, but the connection was working, and the modem was connected to my carrier as shown by mmcli (see bellow pic). So ModemManager probably uses MBIM to start the modem primary port: cdc-wdm0. This matches the OP’s pictures.

However, I wanted to change the current mode so that 5G would be the preferred mode. By default (same as the OP’s pictures), the modes were set to: allowed: 3g, 4g, 5g; preferred: 4g.

Unfortunately, ModemManager was not able to perform this action.

To test other things I wanted to access the AT port to talk to the modem directly so I followed the below steps:

  1. echo "05c6 90d5" > /sys/bus/usb-serial/drivers/option1/new_id (This made ModemManager interface unavailable / non-working with message device not present)
  2. I then I ran dmesg | grep ttyUSB and got output:
    [ 1662.893763] usb 1-1.2: GSM modem (1-port) converter now attached to ttyUSB0 [ 1662.907749] usb 1-1.2: GSM modem (1-port) converter now attached to ttyUSB1 [ 1662.928505] usb 1-1.2: GSM modem (1-port) converter now attached to ttyUSB3
  3. Next I tried minicom -D /dev/ttyUSBx (with x set to 0,1 or 2 as shown above) with no success. I tried multiple config, baudrate etc but ether minicom would crash or I would not get any reply from the modem when I tested with simple AT.

This is where I am at the moment. I wanted to run the commands AT+CUSTOMER and AT+USBSWITCH as provided by the OP but with no AT port working this is not possible. And if AT port are "enabled" via the provided command, ModemManager would simply not see the modem anymore and would not detect it.

What did I do wrong here? Is this expected and how to send AT commands to the modem?

Note: I also tried sending AT commands via mmcli but got: error: command failed: 'GDBus.Error:org.freedesktop.ModemManager1.Error.Core.Failed: Failed: No AT port available to run command'

Thank you in avance :grinning_face: