Now I am playing with these GPRS modems, I’m also looking into how to communicate with them. Apart from the manufacturer’s manuals, I’ve also been looking at the standards for the AT commands, ETSI TS 127 007. It’s a huge document, and there are commands in there that make me think about the phones we had in the late ’90s and early 2000’s. It makes me wonder how much of the functionality of such a phone was inside the modem rather then inside the microcontroller.

But that isn’t what I was wanting to write about today. Today’s topic is network registration.

The AT+CREG? command queries our registration status. But it ain’t that simple, a look at this stack overflow comment. The AT+CREG? command required out circuit mode registration status. This was the original operation of GSM, circuit switched. It was a phone after all, and the POTS phone network was circuit switched. Back in the days, we used to WAP on out phones (if we were rich).  It’s like dial-up internet on the cell phone. It literally dialled in, you had to configure a phone number to use WAP. Your couldn’t be called while accessing the internet, the line was busy. Circuit Switched operation. Later came GPRS. This was a packet mode. Meaning, no longer dialling up, no busy lines, all of that was gone. However, earlier models might disable internet while a call was going on. Anyhow, that’s where the AT+CGREG? command comes in. What is our packet mode registration?

After GSM with it’s data extension GPRS, which came with an enhancement called EDGE, we got a new network called UMTS. Soon to be called 3G, but at the of introduction, it was called by its name, UMTS. We got upgraded cell towers and new phones, but else, nothing changed a lot. We still got circuit mode for phone calls, and packet mode for data communication. So, the commands AT+CREG? and AT+CGREG? still suffice for this new network type.

After UMTS came LTE, which by now was immediately marketed as 4G. This is the trend now, number G. I guess it makes sense, some higher number makes people want it, right? But at the time LTE was introduced, it wasn’t even “real 4G”, it was “3.95G”, or something like that. Whatever, let’s continue. The main difference between LTE and its predecessors was it being a fully packet switched service. Phone calls would go over the packet interface as well. Voice over IP. This means, we no longer have a separate circuit and a separate packet registration. I suppose this is why they came up with a new command AT+CEREG? to query this registration status.

And after 4G came 5G. Now this “G” naming convention is really mixing into the name of the underlying technology, behond, it’s called 5G-NR. Where NR stands for “New Radio”. Really? So, when we got 7G, we’re still going to call the thing we had at 5G “New”. This is kinda like USB, where “Full Speed” is slower then “High Speed”.   Oh well… 5G got its own query AT+C5REG?. However I am not sure what the difference is justifying its own query.

When querying the registration status (with high enough verbosity level) of one of the parameters in the response is <AcT>, Access Technology, which can be

1 GSM Compact
8 EC-GSM-IoT (A/Gb mode)
9 E-UTRAN (NB-S1 mode)
10 E-UTRA connected to a 5GCN
11 NR connected to a 5GCN
13 E-UTRA-NR dual connectivity

At this point, some terminology might need to be explained

G(E)RAN GSM (EDGE) Radio Access Network GSM, GPRS, EDGE 2G
UTRAN UMTS Terrestrial Radio Access Network UMTS 3G
E-UTRAN Evolved Universal Terrestrial Radio Access Network LTE 4G
NG-RAN Next Generation (?) Radio Access Network 5G-NR 5G

I’m not sure about the full name for NG-RAN. “RAN” Obviously stands for “Radio Access Network”. While for 5G, the RAT (Radio Access Technology) is called “5G NR (New Radio)“, this does not explain what “NG” stands for. I could guess it means “Next Generation”, but that is a guess. I haven’t found much about GSM vs GSM Compact. HSDPA and HSUPA  are extensions to UMTS, where the D and U stand for upsteam and downstream. Anyhow, this explains a bit about the RANs in the document. And when I mention a rat, I’m not talking about an animal.