Skip to contentSkip to conversation

SIM7600G-H: cid 1 activated before atom registered

DISCUSSION G. Weinholt 2 participants 2 messages Nov 10, 2023 – Nov 12, 2023

lore
Share & tools
lore
#0 lore raw

Hello,

I have been troubleshooting a problem with a SIM7600G-H modem where the LTE network does not come up after reboot. It can be worked around by restarting ofono or connman.

A symptom of the problem is that the context can't be activated manually because GPRS is marked as not attached. I've verified with both the modem and Onomondo's signaling logs that GPRS is attached and oFono is wrong.

# dbus-send --print-reply --system --dest=org.ofono  \
 /sim7x00_0/context1 org.ofono.ConnectionContext.SetProperty  \
 string:"Active" variant:boolean:"true"
Error org.ofono.Error.NotAttached: GPRS is not attached
# mdmcmd /dev/serial/by-id/usb-SimTech_*-if02-port0 uart 'AT+CGATT?'
Starting with device
+/dev/serial/by-id/usb-SimTech__Incorporated_SimTech__Incorporated_0123456789ABCDEF-if02-port0, command
+AT+CGATT?
Received buffer: AT+CGATT?
+CGATT: 1

OK

There is an interesting log message: "cid 1 activated before atom registered". This message was added in the commit "gprs: Ignore activated contexts during init, list them later". That commit was followed by another commit: "atmodem: Implement the list_activated_contexts callback".

I found that reverting the first commit makes the problem go away. But the proper fix is probably to implement list_activated_contexts in the qmimodem driver, as was done for the atmodem driver. Maybe other drivers are also affected.

/weinholt

#1 lore raw

Hi,

Quoted 5 lines · G. Weinholt

Hello,

I have been troubleshooting a problem with a SIM7600G-H modem where the LTE network does not come up after reboot. It can be worked around by restarting ofono or connman.

After reboot of what exactly?
vi

Quoted 4 lines

A symptom of the problem is that the context can't be activated manually because GPRS is marked as not attached. I've verified with both the modem and Onomondo's signaling logs that GPRS is attached and oFono is wrong.

So how does restarting oFono help?

Quoted 12 lines
# dbus-send --print-reply --system --dest=org.ofono  \
  /sim7x00_0/context1 org.ofono.ConnectionContext.SetProperty  \
  string:"Active" variant:boolean:"true"
Error org.ofono.Error.NotAttached: GPRS is not attached
# mdmcmd /dev/serial/by-id/usb-SimTech_*-if02-port0 uart 'AT+CGATT?'
Starting with device
(quoted diff) +2 -0
+/dev/serial/by-id/usb-SimTech__Incorporated_SimTech__Incorporated_0123456789ABCDEF-if02-port0, command
+AT+CGATT?

Received buffer: AT+CGATT?
+CGATT: 1

Quoted 1 line

OK

What do AT commands have to do with qmimodem?

Quoted 5 lines

There is an interesting log message: "cid 1 activated before atom registered". This message was added in the commit "gprs: Ignore activated contexts during init, list them later". That commit was followed by another commit: "atmodem: Implement the list_activated_contexts callback".

I'd have to see the log to say what exactly is happening, but...

gobi plugin sets up gprs in post_sim. If your contexts are not being provisioned, then ofono_gprs_register() should be called prior to the modem going Online and prior to drivers/qmimodem/gprs.c ever issuing QMI_WDS_GET_LTE_ATTACH_PARAMETERS, which in turn generates the ofono_gprs_cid_activated() call in question.

Regards,
-Denis