3G Electron on 2G Networks


#1

Hey all,

Me and @SCM are trying to solve this network connectivity issue and were wondering about a few technical details about 2G and 3G and GSM GPRS UMTS and EDGE technologies.

We are using the U270 Electron (Africa 3G) on Pemba Island in Tanzania. It seems that there are a lot of 2G towers around, with fewer 3G towers peppered throughout the island.

Using 3G Electron vs 2G Electron to connect to 2G

I understand that 2G and 3G technologies operate on the same frequency bands, where the 2G bands are E-GSM-900 (900 MHz) and DCS-1800 (1800 Mhz) .

The G350 2G modems on the Electron 2G connect to the internet using GPRS.

The U270 3G modems on the Electro 3G Africa have many more standards it can utilize for connection, including UMTS, HSDPA, HSUPA technologies. These modems can also “fall back” to legacy 2G connection standards including GPRS and EDGE standards.

So, if the only towers nearby our Electron are 2G, which Electron will work better at connecting to the network. For example, if there is a 3G tower further away with a weak signal, will the 3G Electron attempt to connect to that tower instead of the closer 2G tower?

If there is only 2G towers available, will both Electron types exhibit the same connectivity strength under identical test conditions? In other words, if I have a 2G Electron and a 3G Electron sitting on a table beside each other, and the nearest cell tower is only equipped to handle GPRS connectivity, and both Electrons have the same carrier’s SIM card in them, which one will be better at establishing and maintaining internet connectivity?


#2

I would think of the Electrons in terms of being a mobile phone. This helps us relate with our experience using our 3G capable phones on 2G/3G network.

The Electron is designed with an optimized and tested antenna range backed by certification so we have confidence that the hardware gives good performance.

Argument better whether 2G or 3G connects better, I would say that fundamentally there should not be a difference as I presume that the innards of the 3G ublox modem to be capable of doing the 2G connectivity stuff as well as a 2G only ublox modem.


#3

Okay, that makes sense.

Is there a situation where a 3G Electron would get stuck trying to establish a connection to a distant 3G tower when there is a stronger and closer 2G tower? Or would it just automatically pick the strongest signal?

I guess what it comes down to is how the 3G Electron prioritizes data transfer rates vs signal strength when choosing which tower to connect to.


#4

Definitely a question for the Particle folks so let’s have :coffee: and wait for their inputs :sunglasses:.


#5

I don’t know the algorithm for how the u-blox modem decides to switch between 2G and 3G. However I did want to mention that you can force the modem to use a specific band using the AT+UBANDSEL command. So if you have a U270 and you force 900 MHz, it will use 2G even if 3G is available. I realize that’s not what you asked about, but it is a technique that can sometimes be useful, especially when testing.


#6

@rickkas7

I’m using your CellularHelper repo as a jumping off point for testing cellular connectivity however the part where I read what type of network I’ve connected to with

CellularHelperEnvironmentCellData::postProcess()

is confusing me.

The band that this function is parsing is coming out as either DCS 1800 or GSM 900 , even though I am testing on a U-260 Electron.

Note that I am using AT+UBANDSEL to successfully select the 850 and 1900 MHz bands as per:

[ Modem::getBandAvailable ] = = = = = = = = = =
    10.753 AT send      15 "AT+UBANDSEL=?\r\n"
    10.764 AT read  +   27 "\r\n+UBANDSEL: (0,850,1900)\r\n"
    10.775 AT read OK    6 "\r\nOK\r\n"
0000010775 [app.main] INFO: Available bands: 
0,850,1900

[ Modem::getBandSelect ] = = = = = = = = = =
    10.776 AT send      14 "AT+UBANDSEL?\r\n"
    10.786 AT read  +   23 "\r\n+UBANDSEL: 850,1900\r\n"
    10.796 AT read OK    6 "\r\nOK\r\n"
0000010796 [app.main] INFO: Selected bands: 
850,1900
0000010796 [app.main] INFO: Trying band: BAND_0

[ Modem::setBandSelect ] = = = = = = = = = =

[ Modem::getBandAvailable ] = = = = = = = = = =
    10.797 AT send      15 "AT+UBANDSEL=?\r\n"
    10.808 AT read  +   27 "\r\n+UBANDSEL: (0,850,1900)\r\n"
    10.818 AT read OK    6 "\r\nOK\r\n"

[ Modem::getBandSelect ] = = = = = = = = = =
    10.818 AT send      14 "AT+UBANDSEL?\r\n"
    10.829 AT read  +   23 "\r\n+UBANDSEL: 850,1900\r\n"
    10.839 AT read OK    6 "\r\nOK\r\n"
0000010839 [app.main] WARN:  band(s) set! Value will be saved in NVM when powering off modem.
0000010839 [app.main] INFO: Checking that band really was set correctly....

[ Modem::getBandSelect ] = = = = = = = = = =
    10.840 AT send      14 "AT+UBANDSEL?\r\n"
    10.851 AT read  +   23 "\r\n+UBANDSEL: 850,1900\r\n"
    10.861 AT read OK    6 "\r\nOK\r\n"
0000010861 [app.main] INFO: Selected bands: 
850,1900
0000010861 [app.main] WARN: --------------------DONE GET/SET BANDS---------------------

:hamburger:
and

[ Modem::getBandAvailable ] = = = = = = = = = =
    77.071 AT send      15 "AT+UBANDSEL=?\r\n"
    77.081 AT read  +   27 "\r\n+UBANDSEL: (0,850,1900)\r\n"
    77.091 AT read OK    6 "\r\nOK\r\n"
0000077091 [app.main] INFO: Available bands: 
0,850,1900

[ Modem::getBandSelect ] = = = = = = = = = =
    77.092 AT send      14 "AT+UBANDSEL?\r\n"
    77.102 AT read  +   23 "\r\n+UBANDSEL: 850,1900\r\n"
    77.112 AT read OK    6 "\r\nOK\r\n"
0000077112 [app.main] INFO: Selected bands: 
850,1900
0000077112 [app.main] INFO: Trying band: BAND_850

[ Modem::setBandSelect ] = = = = = = = = = =

[ Modem::getBandAvailable ] = = = = = = = = = =
    77.113 AT send      15 "AT+UBANDSEL=?\r\n"
    77.124 AT read  +   27 "\r\n+UBANDSEL: (0,850,1900)\r\n"
    77.134 AT read OK    6 "\r\nOK\r\n"

[ Modem::getBandSelect ] = = = = = = = = = =
    77.134 AT send      14 "AT+UBANDSEL?\r\n"
    77.145 AT read  +   23 "\r\n+UBANDSEL: 850,1900\r\n"
    77.155 AT read OK    6 "\r\nOK\r\n"
    77.155 AT send      17 "AT+UBANDSEL=850\r\n"
    78.576 AT read OK    6 "\r\nOK\r\n"
0000078576 [app.main] WARN:  band(s) set! Value will be saved in NVM when powering off modem.
0000078576 [app.main] INFO: Checking that band really was set correctly....

[ Modem::getBandSelect ] = = = = = = = = = =
    78.577 AT send      14 "AT+UBANDSEL?\r\n"
    78.588 AT read  +   18 "\r\n+UBANDSEL: 850\r\n"
    78.598 AT read OK    6 "\r\nOK\r\n"
0000078598 [app.main] INFO: Selected bands: 
850
0000078598 [app.main] WARN: --------------------DONE GET/SET BANDS---------------------

:hamburger:
and

[ Modem::getBandAvailable ] = = = = = = = = = =
   143.091 AT send      15 "AT+UBANDSEL=?\r\n"
   143.101 AT read  +   27 "\r\n+UBANDSEL: (0,850,1900)\r\n"
   143.111 AT read OK    6 "\r\nOK\r\n"
0000143111 [app.main] INFO: Available bands: 
0,850,1900

[ Modem::getBandSelect ] = = = = = = = = = =
   143.112 AT send      14 "AT+UBANDSEL?\r\n"
   143.122 AT read  +   18 "\r\n+UBANDSEL: 850\r\n"
   143.132 AT read OK    6 "\r\nOK\r\n"
0000143132 [app.main] INFO: Selected bands: 
850
0000143132 [app.main] INFO: Trying band: BAND_1900

[ Modem::setBandSelect ] = = = = = = = = = =

[ Modem::getBandAvailable ] = = = = = = = = = =
   143.133 AT send      15 "AT+UBANDSEL=?\r\n"
   143.144 AT read  +   27 "\r\n+UBANDSEL: (0,850,1900)\r\n"
   143.154 AT read OK    6 "\r\nOK\r\n"

[ Modem::getBandSelect ] = = = = = = = = = =
   143.154 AT send      14 "AT+UBANDSEL?\r\n"
   143.165 AT read  +   18 "\r\n+UBANDSEL: 850\r\n"
   143.175 AT read OK    6 "\r\nOK\r\n"
   143.175 AT send      18 "AT+UBANDSEL=1900\r\n"
   165.986 AT read OK    6 "\r\nOK\r\n"
0000165986 [app.main] WARN:  band(s) set! Value will be saved in NVM when powering off modem.
0000165987 [app.main] INFO: Checking that band really was set correctly....

[ Modem::getBandSelect ] = = = = = = = = = =
   165.987 AT send      14 "AT+UBANDSEL?\r\n"
   165.998 AT read  +   19 "\r\n+UBANDSEL: 1900\r\n"
   166.008 AT read OK    6 "\r\nOK\r\n"
0000166008 [app.main] INFO: Selected bands: 
1900
0000166008 [app.main] WARN: --------------------DONE GET/SET BANDS---------------------

:grin:
:grin:
:grin:

but those just result in the following:

38.652 AT send      11 "AT+CGED=5\r\n"
38.663 AT read ERR  39 "\r\n+CME ERROR: operation not supported\r\n"
38.664 AT send      11 "AT+CGED=3\r\n"
38.684 AT read  +   22 "\r\n+CGED: RAT:\"UMTS\",\r\n"
38.694 AT read UNK  61 "\r\nMCC:302, MNC:720, LAC:cf35, CI:012020d, DLF:1037, ULF:812\r\n"
38.705 AT read OK    6 "\r\nOK\r\n"
service rat=UMTS mcc=302, mnc=720, lac=cf35 ci=12020d band=DCS 1800 dlf=1037 ulf=812

:pizza:
and

99.735 AT send      11 "AT+CGED=5\r\n"
99.746 AT read ERR  39 "\r\n+CME ERROR: operation not supported\r\n"
99.747 AT send      11 "AT+CGED=3\r\n"
99.757 AT read  +   22 "\r\n+CGED: RAT:\"UMTS\",\r\n"
99.767 AT read UNK  61 "\r\nMCC:302, MNC:720, LAC:cf35, CI:012020d, DLF:1037, ULF:812\r\n"
99.778 AT read OK    6 "\r\nOK\r\n"
service rat=UMTS mcc=302, mnc=720, lac=cf35 ci=12020d band=DCS 1800 dlf=1037 ulf=812`

:pizza:
and

192.938 AT send 11 "AT+CGED=5\r\n"
192.949 AT read ERR 39 "\r\n+CME ERROR: operation not supported\r\n"
192.950 AT send 11 "AT+CGED=3\r\n"
192.960 AT read + 22 "\r\n+CGED: RAT:“UMTS”,\r\n"
192.970 AT read UNK 59 "\r\nMCC:302, MNC:720, LAC:cf35, CI:0122fba, DLF:437, ULF:37\r\n"
192.981 AT read OK 6 "\r\nOK\r\n"
service rat=UMTS mcc=302, mnc=720, lac=cf35 ci=122fba band=GSM 900 dlf=437 ulf=37

:cactus:
:hushed::open_mouth::astonished::scream:

I’m guessing that there must be a bug in the CellularHelper code?

I tried to figure out the bug but the uBlox AT command documentation doesn’t really specify what the ULF and DLF frequencies mean:

I’m guessing since
16383 = (2^14) - 1
that these values represent some kind of bitmask? Or maybe their range is just a function of a allocated chunk of memory (14 bits?) on the modem rather than actually being used as a bitmask?

@rickkas7 should know I guess, you wrote the darn thing!


Force Electron to 2G mode
#7

Oh, I just realized a flaw in my plan. AT+BANDSEL will work in the specific case of Tanzania because it uses 2100 for 3G and 900/1800 for 2G. But it won’t always work in other locations, like the US. Since the US uses 850/1900 for both 2G and 3G you can’t force 2G in the general case by band selection. Sometimes you can, because by chance I have AT&T 3G on 850 and T-Mobile 2G on 1900, for example, but that’s not guaranteed everywhere.


#8

Indeed, I realized that too once I started digging into the deployment of UMTS bands worldwide:

I did a search for the word “frequency” in the uBlox AT command manual and couldn’t find anything that would help me determine what kind of service is being subscribed to other than the AT+COPS command and AT+CGED=3 command, both of which return the downlink frequency and uplink frequency of the connection, but not the actual UMTS or GSM band in use.

The <rat> item in the AT+CGED=3 command will return “GSM” “UMTS” or “LTE” , so that is one way to find out if you are connected to 3G or 2/2.5G

I guess setting the band select should be enough to know that you are connecting to a specific band, but as of now I’m not sure how to verify that the modem has in fact connected to said band, unless there is some way to translate the uplink or downlink frequency to a band as it appears your code was trying to do, @rickkas7


#9

As far as I know there is no easy way to find the band. The RAT=UMTS indicates 3G. If RAT=GSM or RAT is not specified (it’s not on a G350), then it’s 2G.

As for the band, you can get it from the ulf for 3G or arfcn for2G. There’s code in the CellularHelper library to do it. I’m unaware of any other way, but if you can find something more direct, that would be great.