Force a Modem to Lock onto a Specific Carrier


If the relative signal quality of local cellular providers is known, a modem can be forced to lock onto a carrier deemed to have the best quality. SIM cards that host multiple cell providers may have difficulties latching on in certain areas. This command will bypass the sometimes tedious process of the modem/SIM latching onto a carrier.

1. Check the Available Cellular Providers

The available cellular providers can be checked using the AT+COPS=? command. Note: Command response may take up to 30 seconds.

A response should be in the format below:

<CR><LF>
+COPS: (<stat>,<operator in format 0>,<operator in format 1>,<operator in format 2>,<access technology>),
....(<stat>,<operator in format 0>,<operator in format 1>,<operator in format 2>,<access technology>)
<CR><LF>
OK<CR><LF>

Figure 1: Response to AT+COPS=? command.

 

NameValueDescription
<stat>0 = unknown
1 = available
2 = current
3 = forbidden
Operator availability
<operator in format 0>“Verizon”Operator identity in alphanumeric long form (Max 16 characters)
<operator in format 1>“Teal”Operator identity in alphanumeric short form (Max 8 characters)
<operator in format 2>“311480”Numeric operator identity in 5 or 6 digits [country code (3) + network code (2 or 3)]. The value field displays the network identifier for Verizon.
<access technology>0 = GSM
2 = UTRAN
7 = E-UTRAN
Access technology refers to either 2G (GSM), 3G (UTRAN), or 4G LTE (E-UTRAN).

 

 

2. Select a Provider

Once a provider is selected from the available list, send the following command:

AT+COPS=<mode>,<format type>,<operator>,<access technology>

Figure 2: Manual cellular carrier selection.

 

NameValueDescription
<mode>0 = automatic selection; <operator> is ignored
1 = manual selection based on <operator>
2 = deregister from network
3 = set only <format> parameter, the parameter <operator> is ignored
4 = manual/automatic: if <operator> is not reached, the modem will default to an automatic selection
Defines the operator selection: automatic or manual.
<format type>0 = alphanumeric long form (Max 16 characters)
1 = alphanumeric short form (Max 8 characters)
2 = 5 or 6 digits [country code (3) + network code (2 or 3)]
Specifies the operator name format.
<operator>“311480”Operator identity in selected name format.
<access technology>0 = GSM
2 = UTRAN
7 = E-UTRAN
Access technology refers to either 2G (GSM), 3G (UTRAN), or 4G LTE (E-UTRAN).

 

 

3. Return the Current Selected Provider

Check the currently selected provider using the AT+COPS? command to confirm the provider has been selected correctly.

A response should be in the format below:

<CR><LF> 
+COPS: <mode>,<format>,<operator in format x>,<access technology><CR><LF> 
<CR><LF>
OK<CR><LF>

Figure 3: Confirmation of manual cellular carrier selection via the AT+COPS? command.

 

 

4. Test Network Communication with WQData LIVE

  • Send the Custom 1, followed by the Custom 2 command.
    • The Custom 1 command activates the modem and sets an HTTP connection to wqdatalive.com.
    • The Custom 2 command tests the communication with WQData LIVE by transmitting null data to wqdatalive.com and seeing if a timestamp is returned.

Figure 4: Successful Custom 1 command response.

Figure 5: Successful Custom 2 command response.