moatze
moatze

Reputation: 148

ATcommand at+cops? gives undefined return

I'm working with the EGS5 Cinterion wireless module. I located the module in an area where I recieve just a few operators with low signal strength (-100dBm - -105dBm). When I use AT+COPS=? I see that 4 operators are available.

AT+COPS=? +COPS: (1,"E-Plus",,"26203"),(1,"Telekom.de",,"26201"), (1,"Vodafone.de",,"26202"),(1,"o2 - de",,"26207"),,(0-4),(0,2)

AT+CREG? +CREG: 0,0 and AT+COPS? +COPS: 1

Changing to one of the operators above with AT+COPS=1,2,......returns OK, but when i check AT+COPS?I get +COPS: 1again.

Changing to AT+COPS=0returns ERROR

I don't understand why I can't connect to a network, even it is available. My SIM isn't locked or anything, and all is working perfectly when I put the wireless module in an area with better reception

EDIT: at^smondreturns ^SMOND:262,07,C762,C389,76,687,109,,,0,,,2,,,,,,,0,,,,,,,0,,,,,,,0,,,,,,,0,,,,,,,0,,,,,,,0,2,2,99 so im connected to PLMN 26207, thats correct? But AT+COPS?returns still +COPS: 1

Upvotes: 2

Views: 10418

Answers (1)

hlovdal
hlovdal

Reputation: 28180

I think you are confused about what AT+COPS? returns. The first number does not correspond to which network the phone is attached to, it is the <mode> value.

The command is defined in 27.007, and its syntax is

Table 36: +COPS parameter command syntax
Command                   Possible response(s)

+COPS=[<mode>[,<format>   +CME ERROR: <err>
[,<oper>[,<AcT>]]]]

+COPS?                    +COPS: <mode>[,<format>,<oper>[,<AcT>]]
                          +CME ERROR: <err>

+COPS=?                   +COPS: [list of supported (<stat>,long alphanumeric
                          <oper>,short alphanumeric <oper>,numeric <oper>
                          [,<AcT>])s][,,(list of supported <mode>s),(list of
                          supported <format>s)]
                          +CME ERROR: <err>

and <mode> is defined as

<mode>:
0 automatic (<oper> field is ignored)
1 manual (<oper> field shall be present, and <AcT> optionally)
2 deregister from network
3 set only <format> (for read command +COPS?), do not attempt registration/deregistration (<oper> and
<AcT> fields are ignored); this value is not applicable in read command response
4 manual/automatic (<oper> field shall be present); if manual selection fails, automatic mode (<mode>=0) is
entered

So the response +COPS: 1 only tells you that the phone is attached to a specific network operator. The AT+COPS? command could have given the details of which operator, but those parameters are optional so the phone is not required to.

Why mode value 0 fails I cannot say, but it might be that the module only supports automatic under some conditions and not always (say for some AcT values). And regarding switching operator, notice that this is dependent on roaming agreements with your home network operator and each of the guest networks. So just because AT+COPS=? returns a list of N operators, that does not imply that you are allowed to switch to any of them.

Upvotes: 5

Related Questions