This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Thingy91 https_client - getaddrinfo failed err 116 50% of the time

Hi All,

I got my hands on a Thingy91 and trying to do devlopment with it starting with a  basic https client sample app. I have registered my Sim and everything works ~50% of the time.

When it works, I found that the network connects and does the ip address query quickly. Though when it doesn't, its like it just timesout. I tried putting a retry counter on the getaddress function, though if 1 fails with a timeout, they will all do the same. Roughly 40s per fail, so 5 retries is around ~3.2min period.

Non-Working example:

*** Booting Zephyr OS build v2.6.99-ncs1  ***
Flash regions		Domain		Permissions
00 02 0x00000 0x18000 	Secure		rwxl
03 31 0x18000 0x100000 	Non-Secure	rwxl

Non-secure callable region 0 placed in flash region 2 with size 32.

SRAM region		Domain		Permissions
00 07 0x00000 0x10000 	Secure		rwxl
08 31 0x10000 0x40000 	Non-Secure	rwxl

Peripheral		Domain		Status
00 NRF_P0               Non-Secure	OK
01 NRF_CLOCK            Non-Secure	OK
02 NRF_RTC0             Non-Secure	OK
03 NRF_RTC1             Non-Secure	OK
04 NRF_NVMC             Non-Secure	OK
05 NRF_UARTE1           Non-Secure	OK
06 NRF_UARTE2           Secure		SKIP
07 NRF_TWIM2            Non-Secure	OK
08 NRF_SPIM3            Non-Secure	OK
09 NRF_TIMER0           Non-Secure	OK
10 NRF_TIMER1           Non-Secure	OK
11 NRF_TIMER2           Non-Secure	OK
12 NRF_SAADC            Non-Secure	OK
13 NRF_PWM0             Non-Secure	OK
14 NRF_PWM1             Non-Secure	OK
15 NRF_PWM2             Non-Secure	OK
16 NRF_PWM3             Non-Secure	OK
17 NRF_WDT              Non-Secure	OK
18 NRF_IPC              Non-Secure	OK
19 NRF_VMC              Non-Secure	OK
20 NRF_FPU              Non-Secure	OK
21 NRF_EGU1             Non-Secure	OK
22 NRF_EGU2             Non-Secure	OK
23 NRF_DPPIC            Non-Secure	OK
24 NRF_REGULATORS       Non-Secure	OK
25 NRF_PDM              Non-Secure	OK
26 NRF_I2S              Non-Secure	OK
27 NRF_GPIOTE1          Non-Secure	OK

SPM: NS image at 0x18200
SPM: NS MSP at 0x200192f8
SPM: NS reset vector at 0x1ad05
SPM: prepare to jump to Non-Secure image.
*** Booting Zephyr OS build v2.6.99-ncs1  ***
HTTPS client sample started
Waiting for network.. OK
Waiting for ip addr.. getaddrinfo() failed, err 116
Waiting for ip addr.. getaddrinfo() failed, err 116
Waiting for ip addr.. getaddrinfo() failed, err 116
Waiting for ip addr.. getaddrinfo() failed, err 116
Waiting for ip addr.. getaddrinfo() failed, err 116
coulnd't get ip over 5 retries

Working Example:

*** Booting Zephyr OS build v2.6.99-ncs1  ***
Flash regions		Domain		Permissions
00 02 0x00000 0x18000 	Secure		rwxl
03 31 0x18000 0x100000 	Non-Secure	rwxl

Non-secure callable region 0 placed in flash region 2 with size 32.

SRAM region		Domain		Permissions
00 07 0x00000 0x10000 	Secure		rwxl
08 31 0x10000 0x40000 	Non-Secure	rwxl

Peripheral		Domain		Status
00 NRF_P0               Non-Secure	OK
01 NRF_CLOCK            Non-Secure	OK
02 NRF_RTC0             Non-Secure	OK
03 NRF_RTC1             Non-Secure	OK
04 NRF_NVMC             Non-Secure	OK
05 NRF_UARTE1           Non-Secure	OK
06 NRF_UARTE2           Secure		SKIP
07 NRF_TWIM2            Non-Secure	OK
08 NRF_SPIM3            Non-Secure	OK
09 NRF_TIMER0           Non-Secure	OK
10 NRF_TIMER1           Non-Secure	OK
11 NRF_TIMER2           Non-Secure	OK
12 NRF_SAADC            Non-Secure	OK
13 NRF_PWM0             Non-Secure	OK
14 NRF_PWM1             Non-Secure	OK
15 NRF_PWM2             Non-Secure	OK
16 NRF_PWM3             Non-Secure	OK
17 NRF_WDT              Non-Secure	OK
18 NRF_IPC              Non-Secure	OK
19 NRF_VMC              Non-Secure	OK
20 NRF_FPU              Non-Secure	OK
21 NRF_EGU1             Non-Secure	OK
22 NRF_EGU2             Non-Secure	OK
23 NRF_DPPIC            Non-Secure	OK
24 NRF_REGULATORS       Non-Secure	OK
25 NRF_PDM              Non-Secure	OK
26 NRF_I2S              Non-Secure	OK
27 NRF_GPIOTE1          Non-Secure	OK

SPM: NS image at 0x18200
SPM: NS MSP at 0x2001a2f8
SPM: NS reset vector at 0x1ae29
SPM: prepare to jump to Non-Secure image.
*** Booting Zephyr OS build v2.6.99-ncs1  ***
HTTPS client sample started
Provisioning certificate
Waiting for network.. OK
Waiting for ip addr.. OK
Connecting to example.com
Sent 61 bytes
Received 370 bytes

>	 HTTP/1.1 200 OK

Finished, closing socket.

I am not sure about the best way to approach this. The only visibility I have of my sim is from nrfcloud, so I cannot see what happens on the backend for failed connections to the network etc.

I also tried using my own DNS from this example. Though results in same as above, sometimes works, sometimes doesn't.

I played around with the at_cmd.c file and overrode the logging. So I got these 2 sets of logs instead, with more verbose information.

Working:

*** Booting Zephyr OS build v2.6.99-ncs1  ***
Flash regions		Domain		Permissions
00 02 0x00000 0x18000 	Secure		rwxl
03 31 0x18000 0x100000 	Non-Secure	rwxl

Non-secure callable region 0 placed in flash region 2 with size 32.

SRAM region		Domain		Permissions
00 07 0x00000 0x10000 	Secure		rwxl
08 31 0x10000 0x40000 	Non-Secure	rwxl

Peripheral		Domain		Status
00 NRF_P0               Non-Secure	OK
01 NRF_CLOCK            Non-Secure	OK
02 NRF_RTC0             Non-Secure	OK
03 NRF_RTC1             Non-Secure	OK
04 NRF_NVMC             Non-Secure	OK
05 NRF_UARTE1           Non-Secure	OK
06 NRF_UARTE2           Secure		SKIP
07 NRF_TWIM2            Non-Secure	OK
08 NRF_SPIM3            Non-Secure	OK
09 NRF_TIMER0           Non-Secure	OK
10 NRF_TIMER1           Non-Secure	OK
11 NRF_TIMER2           Non-Secure	OK
12 NRF_SAADC            Non-Secure	OK
13 NRF_PWM0             Non-Secure	OK
14 NRF_PWM1             Non-Secure	OK
15 NRF_PWM2             Non-Secure	OK
16 NRF_PWM3             Non-Secure	OK
17 NRF_WDT              Non-Secure	OK
18 NRF_IPC              Non-Secure	OK
19 NRF_VMC              Non-Secure	OK
20 NRF_FPU              Non-Secure	OK
21 NRF_EGU1             Non-Secure	OK
22 NRF_EGU2             Non-Secure	OK
23 NRF_DPPIC            Non-Secure	OK
24 NRF_REGULATORS       Non-Secure	OK
25 NRF_PDM              Non-Secure	OK
26 NRF_I2S              Non-Secure	OK
27 NRF_GPIOTE1          Non-Secure	OK

SPM: NS image at 0x18200
SPM: NS MSP at 0x2001a300
SPM: NS reset vector at 0x1ae41
SPM: prepare to jump to Non-Secure image.
*** Booting Zephyr OS build v2.6.99-ncs1  ***
HTTPS client sample started
Common AT socket created
Common AT socket processing thread created
Setting notification handler to 0x1d675
Sending command AT+CMEE?
AT socket thread started
Writing any pending command
Awaiting response for AT+CMEE?
Listening on socket
at_cmd_rx 15 bytes, +CMEE: 0
OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=1
Writing any pending command
Sending command AT+CMEE=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT%CMNG=1,42,0
Writing any pending command
Sending command AT%CMNG=1,42,0
Listening on socket
at_cmd_rx 85 bytes, %CMNG: 42,0,"0000000000000000000000000000000000000000000000000000000000000000"
OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=0
Writing any pending command
Sending command AT+CMEE=0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CMEE?
Writing any pending command
Sending command AT+CMEE?
Listening on socket
at_cmd_rx 15 bytes, +CMEE: 0
OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=1
Writing any pending command
Sending command AT+CMEE=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT%CMNG=3,42,0
Writing any pending command
Sending command AT%CMNG=3,42,0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=0
Writing any pending command
Sending command AT+CMEE=0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Provisioning certificate
Awaiting response for AT+CMEE?
Writing any pending command
Sending command AT+CMEE?
Listening on socket
at_cmd_rx 15 bytes, +CMEE: 0
OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=1
Writing any pending command
Sending command AT+CMEE=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
-----END CERTIFICATE-----
"
Writing any pending command
Sending command AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
-----END CERTIFICATE-----
"
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=0
Writing any pending command
Sending command AT+CMEE=0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Writing any DNS set result 0
Waiting for network.. Sending command AT%XSYSTEMMODE?
pending command
Awaiting response for AT%XSYSTEMMODE?
Listening on socket
at_cmd_rx 28 bytes, %XSYSTEMMODE: 1,0,1,0
OK

Enqueueing response for sync call
Awaiting response for AT%XSYSTEMMODE=1,0,0,0
Writing any pending command
Sending command AT%XSYSTEMMODE=1,0,0,0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
Writing any pending command
Sending command AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CEREG=5
Writing any pending command
Sending command AT+CEREG=5
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CSCON=1
Writing any pending command
Sending command AT+CSCON=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT%XSYSTEMMODE=1,0,0,0
Writing any pending command
Sending command AT%XSYSTEMMODE=1,0,0,0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CEREG=5
Writing any pending command
Sending command AT+CEREG=5
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CSCON=1
Writing any pending command
Sending command AT+CSCON=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CFUN=1
Writing any pending command
Sending command AT+CFUN=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Writing any pending command
Listening on socket
at_cmd_rx 58 bytes, +CEREG: 2,"3060","0833070C",7,0,0,"11100000","11100000"

Writing any pending command
Listening on socket
at_cmd_rx 12 bytes, +CSCON: 1

Writing any pending command
Listening on socket
at_cmd_rx 56 bytes, +CEREG: 5,"3060","0833070C",7,,,"00001000","11100000"

OK
Waiting for ip addr.. Writing any pending command
Listening on socket
OK
Connecting to example.com
Sent 61 bytes
Received 369 bytes

>	 HTTP/1.1 200 OK

Finished, closing socket.
at_cmd_rx 12 bytes, +CSCON: 0

Writing any pending command
Listening on socket

And finally, not working:

*** Booting Zephyr OS build v2.6.99-ncs1  ***
Flash regions		Domain		Permissions
00 02 0x00000 0x18000 	Secure		rwxl
03 31 0x18000 0x100000 	Non-Secure	rwxl

Non-secure callable region 0 placed in flash region 2 with size 32.

SRAM region		Domain		Permissions
00 07 0x00000 0x10000 	Secure		rwxl
08 31 0x10000 0x40000 	Non-Secure	rwxl

Peripheral		Domain		Status
00 NRF_P0               Non-Secure	OK
01 NRF_CLOCK            Non-Secure	OK
02 NRF_RTC0             Non-Secure	OK
03 NRF_RTC1             Non-Secure	OK
04 NRF_NVMC             Non-Secure	OK
05 NRF_UARTE1           Non-Secure	OK
06 NRF_UARTE2           Secure		SKIP
07 NRF_TWIM2            Non-Secure	OK
08 NRF_SPIM3            Non-Secure	OK
09 NRF_TIMER0           Non-Secure	OK
10 NRF_TIMER1           Non-Secure	OK
11 NRF_TIMER2           Non-Secure	OK
12 NRF_SAADC            Non-Secure	OK
13 NRF_PWM0             Non-Secure	OK
14 NRF_PWM1             Non-Secure	OK
15 NRF_PWM2             Non-Secure	OK
16 NRF_PWM3             Non-Secure	OK
17 NRF_WDT              Non-Secure	OK
18 NRF_IPC              Non-Secure	OK
19 NRF_VMC              Non-Secure	OK
20 NRF_FPU              Non-Secure	OK
21 NRF_EGU1             Non-Secure	OK
22 NRF_EGU2             Non-Secure	OK
23 NRF_DPPIC            Non-Secure	OK
24 NRF_REGULATORS       Non-Secure	OK
25 NRF_PDM              Non-Secure	OK
26 NRF_I2S              Non-Secure	OK
27 NRF_GPIOTE1          Non-Secure	OK

SPM: NS image at 0x18200
SPM: NS MSP at 0x2001a300
SPM: NS reset vector at 0x1ae41
SPM: prepare to jump to Non-Secure image.
*** Booting Zephyr OS build v2.6.99-ncs1  ***
HTTPS client sample started
Common AT socket created
Common AT socket processing thread created
Setting notification handler to 0x1d675
Sending command AT+CMEE?
AT socket thread started
Writing any pending command
Awaiting response for AT+CMEE?
Listening on socket
at_cmd_rx 15 bytes, +CMEE: 0
OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=1
Writing any pending command
Sending command AT+CMEE=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT%CMNG=1,42,0
Writing any pending command
Sending command AT%CMNG=1,42,0
Listening on socket
at_cmd_rx 85 bytes, %CMNG: 42,0,"0000000000000000000000000000000000000000000000000000000000000000"
OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=0
Writing any pending command
Sending command AT+CMEE=0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CMEE?
Writing any pending command
Sending command AT+CMEE?
Listening on socket
at_cmd_rx 15 bytes, +CMEE: 0
OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=1
Writing any pending command
Sending command AT+CMEE=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT%CMNG=3,42,0
Writing any pending command
Sending command AT%CMNG=3,42,0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=0
Writing any pending command
Sending command AT+CMEE=0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Provisioning certificate
Awaiting response for AT+CMEE?
Writing any pending command
Sending command AT+CMEE?
Listening on socket
at_cmd_rx 15 bytes, +CMEE: 0
OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=1
Writing any pending command
Sending command AT+CMEE=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
-----END CERTIFICATE-----
"
Writing any pending command
Sending command AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
-----END CERTIFICATE-----
"
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CMEE=0
Writing any pending command
Sending command AT+CMEE=0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Writing any DNS set result 0
Waiting for network.. Sending command AT%XSYSTEMMODE?
pending command
Awaiting response for AT%XSYSTEMMODE?
Listening on socket
at_cmd_rx 28 bytes, %XSYSTEMMODE: 1,0,1,0
OK

Enqueueing response for sync call
Awaiting response for AT%XSYSTEMMODE=1,0,0,0
Writing any pending command
Sending command AT%XSYSTEMMODE=1,0,0,0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
Writing any pending command
Sending command AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CEREG=5
Writing any pending command
Sending command AT+CEREG=5
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CSCON=1
Writing any pending command
Sending command AT+CSCON=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT%XSYSTEMMODE=1,0,0,0
Writing any pending command
Sending command AT%XSYSTEMMODE=1,0,0,0
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CEREG=5
Writing any pending command
Sending command AT+CEREG=5
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CSCON=1
Writing any pending command
Sending command AT+CSCON=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Awaiting response for AT+CFUN=1
Writing any pending command
Sending command AT+CFUN=1
Listening on socket
at_cmd_rx 5 bytes, OK

Enqueueing response for sync call
Writing any pending command
Listening on socket
at_cmd_rx 58 bytes, +CEREG: 2,"3060","0833070C",7,0,0,"11100000","11100000"

Writing any pending command
Listening on socket
at_cmd_rx 12 bytes, +CSCON: 1

Writing any pending command
Listening on socket
at_cmd_rx 12 bytes, +CSCON: 0

Writing any pending command
Listening on socket
at_cmd_rx 12 bytes, +CSCON: 1

Writing any pending command
Listening on socket
at_cmd_rx 56 bytes, +CEREG: 5,"3060","0833070C",7,,,"00001000","11100000"

OK
Waiting for ip addr.. Writing any pending command
Listening on socket
getaddrinfo() failed, err 116
Waiting for ip addr.. getaddrinfo() failed, err 116
Waiting for ip addr.. getaddrinfo() failed, err 116
Waiting for ip addr.. getaddrinfo() failed, err 116
Waiting for ip addr.. at_cmd_rx 58 bytes, +CEREG: 2,"3060","0833070C",7,0,0,"11100000","11100000"

Writing any pending command
Listening on socket
at_cmd_rx 12 bytes, +CSCON: 0

Writing any pending command
Listening on socket
getaddrinfo() failed, err 114
coulnd't get ip over 5 retries
at_cmd_rx 12 bytes, +CSCON: 1

Writing any pending command
Listening on socket
at_cmd_rx 56 bytes, +CEREG: 5,"3060","0833070C",7,,,"00001000","11100000"

Writing any pending command
Listening on socket

Parents
  • Sorry I don't know what order these posts are going in, I hope they are chronological, thread on website is still broken, so I am just replying to the main thread.

    I did some more testing at home today, I think I have a decent signal here. Same results using a new https basic app from nrf toolchain v1.7.1. ~50% failure chance. Once its working it works, but when it doesn't it really doesn't and doesn't seem recover either.

    This time I left my app trying to get an address constantly over the course of an hour or 2, cereg shows that I am connected and I got some cseq commands polling signal strength on each failure. The below happens every 2nd restart on average.

    On failure:

    *** Booting Zephyr OS build v2.6.99-ncs1-1  ***
    Flash regions		Domain		Permissions
    00 02 0x00000 0x18000 	Secure		rwxl
    03 31 0x18000 0x100000 	Non-Secure	rwxl
    
    Non-secure callable region 0 placed in flash region 2 with size 32.
    
    SRAM region		Domain		Permissions
    00 07 0x00000 0x10000 	Secure		rwxl
    08 31 0x10000 0x40000 	Non-Secure	rwxl
    
    Peripheral		Domain		Status
    00 NRF_P0               Non-Secure	OK
    01 NRF_CLOCK            Non-Secure	OK
    02 NRF_RTC0             Non-Secure	OK
    03 NRF_RTC1             Non-Secure	OK
    04 NRF_NVMC             Non-Secure	OK
    05 NRF_UARTE1           Non-Secure	OK
    06 NRF_UARTE2           Secure		SKIP
    07 NRF_TWIM2            Non-Secure	OK
    08 NRF_SPIM3            Non-Secure	OK
    09 NRF_TIMER0           Non-Secure	OK
    10 NRF_TIMER1           Non-Secure	OK
    11 NRF_TIMER2           Non-Secure	OK
    12 NRF_SAADC            Non-Secure	OK
    13 NRF_PWM0             Non-Secure	OK
    14 NRF_PWM1             Non-Secure	OK
    15 NRF_PWM2             Non-Secure	OK
    16 NRF_PWM3             Non-Secure	OK
    17 NRF_WDT              Non-Secure	OK
    18 NRF_IPC              Non-Secure	OK
    19 NRF_VMC              Non-Secure	OK
    20 NRF_FPU              Non-Secure	OK
    21 NRF_EGU1             Non-Secure	OK
    22 NRF_EGU2             Non-Secure	OK
    23 NRF_DPPIC            Non-Secure	OK
    24 NRF_REGULATORS       Non-Secure	OK
    25 NRF_PDM              Non-Secure	OK
    26 NRF_I2S              Non-Secure	OK
    27 NRF_GPIOTE1          Non-Secure	OK
    
    SPM: NS image at 0x18200
    SPM: NS MSP at 0x2001a300
    SPM: NS reset vector at 0x1aead
    SPM: prepare to jump to Non-Secure image.
    *** Booting Zephyr OS build v2.6.99-ncs1-1  ***
    HTTPS client sample started
    Common AT socket createdCommon AT socket processing thread created
    Setting notification handler to 0x1d6e1
    Sending command AT+CMEE?
    AT socket thread started
    Writing any pending command
    Awaiting response for AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=1,42,0
    Writing any pending command
    Sending command AT%CMNG=1,42,0
    Listening on socket
    at_cmd_rx 85 bytes, %CMNG: 42,0,"0000000000000000000000000000000000000000000000000000000000000000"
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=3,42,0
    Writing any pending command
    Sending command AT%CMNG=3,42,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Provisioning certificate
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
    MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
    MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
    d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
    QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
    MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
    b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
    9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
    CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
    nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
    43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
    T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
    gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
    BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
    TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
    DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
    hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
    06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
    PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
    YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
    CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
    -----END CERTIFICATE-----
    "
    Writing any pending command
    Sending command AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
    MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
    MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
    d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
    QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
    MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
    b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
    9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
    CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
    nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
    43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
    T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
    gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
    BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
    TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
    DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
    hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
    06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
    PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
    YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
    CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
    -----END CERTIFICATE-----
    "
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    ---------> Waiting for network.. 
    Awaiting response for AT%XSYSTEMMODE?
    Writing any pending command
    Sending command AT%XSYSTEMMODE?
    Listening on socket
    at_cmd_rx 28 bytes, %XSYSTEMMODE: 1,0,0,0
    OK
    
    Enqueueing response for sync call
    System mode (1) and preference (0) are already configured
    Awaiting response for AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
    Writing any pending command
    Sending command AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Sending AT command to set system mode: AT%XSYSTEMMODE=1,0,0,0
    Awaiting response for AT%XSYSTEMMODE=1,0,0,0
    Writing any pending command
    Sending command AT%XSYSTEMMODE=1,0,0,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CFUN=1
    Writing any pending command
    Sending command AT+CFUN=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Writing any pending command
    Listening on socket
    at_cmd_rx 58 bytes, +CEREG: 2,"3059","0818A60C",7,0,0,"11100000","11100000"
    
    +CEREG notification: +CEREG: 2,"3059","0818A60C",7,0,0,"11100000","11100000"
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    +CSCON notification
    Writing any pending command
    Listening on socket
    at_cmd_rx 56 bytes, +CEREG: 5,"3059","0818A60C",7,,,"11100000","11100000"
    
    +CEREG notification: +CEREG: 5,"3059","0818A60C",7,,,"11100000","11100000"
    
    ---------> OK
    ---------> getting address...
    Writing any pending command
    Listening on socket
    ---------> getaddrinfo() failed, err 116
    Sending command AT+CEREG=5
    Awaiting response for AT+CEREG=5
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG?
    Writing any pending command
    Sending command AT+CEREG?
    Listening on socket
    at_cmd_rx 62 bytes, +CEREG: 5,5,"3059","0818A60C",7,,,"11100000","11100000"
    OK
    
    Enqueueing response for sync call
    ---------> reg status 5
    Awaiting response for AT+CESQ
    Writing any pending command
    Sending command AT+CESQ
    Listening on socket
    at_cmd_rx 33 bytes, +CESQ: 99,99,255,255,14,33
    OK
    
    Enqueueing response for sync call
    ---------> cesq status 5, val '+CESQ: 99,99,255,255,14,33
    '
    ---------> getting address...
    Writing any pending command
    Listening on socket
    ---------> getaddrinfo() failed, err 116
    Sending command AT+CEREG=5
    Awaiting response for AT+CEREG=5
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG?
    Writing any pending command
    Sending command AT+CEREG?
    Listening on socket
    at_cmd_rx 62 bytes, +CEREG: 5,5,"3059","0818A60C",7,,,"11100000","11100000"
    OK
    
    Enqueueing response for sync call
    ---------> reg status 5
    Awaiting response for AT+CESQ
    Writing any pending command
    Sending command AT+CESQ
    Listening on socket
    at_cmd_rx 33 bytes, +CESQ: 99,99,255,255,14,33
    OK
    
    Enqueueing response for sync call
    ---------> cesq status 5, val '+CESQ: 99,99,255,255,14,33
    '
    ---------> getting address...
    Writing any pending command
    Listening on socket
    ---------> getaddrinfo() failed, err 116
    Sending command AT+CEREG=5
    Awaiting response for AT+CEREG=5
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG?
    Writing any pending command
    Sending command AT+CEREG?
    Listening on socket
    at_cmd_rx 62 bytes, +CEREG: 5,5,"3059","0818A60C",7,,,"11100000","11100000"
    OK
    
    Enqueueing response for sync call
    ---------> reg status 5
    Awaiting response for AT+CESQ
    Writing any pending command
    Sending command AT+CESQ
    Listening on socket
    at_cmd_rx 32 bytes, +CESQ: 99,99,255,255,9,33
    OK
    
    Enqueueing response for sync call
    ---------> cesq status 5, val '+CESQ: 99,99,255,255,9,33
    '
    ---------> getting address...
    Writing any pending command
    Listening on socket
    ---------> getaddrinfo() failed, err 116
    Sending command AT+CEREG=5
    Awaiting response for AT+CEREG=5
    at_cmd_rx 5 bytes, OK

  • Hi,

     

    I think you should update the modem to a newer version and try again. See my former response, linking to step 4 here:

    https://infocenter.nordicsemi.com/topic/ug_thingy91_gsg/UG/thingy91_gsg/updating_fw_usb.html?cp=14_0_3_0

     

    Kind regards,

    Håkon

  • Thread appears to be working once more!

    I updated my device to mfw v1.3.1 and its running the basic https example with ncs v1.7.0. Unfortunately its still doing roughly the same thing, only working roughly 50% of the time.

    I drove out to the farmland again close to the tower and got a really strong signal. The main difference is this time when it fails, it doesn't connect to the network instead of connecting and failing on the DNS query. When it finally does connect, everything works well including the issue in this post. Though fundamentally, the 50% connection rate is still true when close to the tower.

    New logs. When its working:

    *** Booting Zephyr OS build v2.6.99-ncs1  ***
    Flash regions		Domain		Permissions
    00 02 0x00000 0x18000 	Secure		rwxl
    03 31 0x18000 0x100000 	Non-Secure	rwxl
    
    Non-secure callable region 0 placed in flash region 2 with size 32.
    
    SRAM region		Domain		Permissions
    00 07 0x00000 0x10000 	Secure		rwxl
    08 31 0x10000 0x40000 	Non-Secure	rwxl
    
    Peripheral		Domain		Status
    00 NRF_P0               Non-Secure	OK
    01 NRF_CLOCK            Non-Secure	OK
    02 NRF_RTC0             Non-Secure	OK
    03 NRF_RTC1             Non-Secure	OK
    04 NRF_NVMC             Non-Secure	OK
    05 NRF_UARTE1           Non-Secure	OK
    06 NRF_UARTE2           Secure		SKIP
    07 NRF_TWIM2            Non-Secure	OK
    08 NRF_SPIM3            Non-Secure	OK
    09 NRF_TIMER0           Non-Secure	OK
    10 NRF_TIMER1           Non-Secure	OK
    11 NRF_TIMER2           Non-Secure	OK
    12 NRF_SAADC            Non-Secure	OK
    13 NRF_PWM0             Non-Secure	OK
    14 NRF_PWM1             Non-Secure	OK
    15 NRF_PWM2             Non-Secure	OK
    16 NRF_PWM3             Non-Secure	OK
    17 NRF_WDT              Non-Secure	OK
    18 NRF_IPC              Non-Secure	OK
    19 NRF_VMC              Non-Secure	OK
    20 NRF_FPU              Non-Secure	OK
    21 NRF_EGU1             Non-Secure	OK
    22 NRF_EGU2             Non-Secure	OK
    23 NRF_DPPIC            Non-Secure	OK
    24 NRF_REGULATORS       Non-Secure	OK
    25 NRF_PDM              Non-Secure	OK
    26 NRF_I2S              Non-Secure	OK
    27 NRF_GPIOTE1          Non-Secure	OK
    
    SPM: NS image at 0x18200
    SPM: NS MSP at 0x2001c230
    SPM: NS reset vector at 0x1b0b5
    SPM: prepare to jump to Non-Secure image.
    *** Booting Zephyr OS build v2.6.99-ncs1  ***
    rst reason 0x10000
    Rst source: AIRCR.SYSRESETREQ
    HTTPS client sample started
    Sending command AT+CPSMS=
    Failed to send AT command (err:9)
    Awaiting response for AT+CPSMS=
    Sending command AT+CEDRXS=3
    Failed to send AT command (err:9)
    Awaiting response for AT+CEDRXS=3
    Common AT socket created
    Common AT socket processing thread created
    Setting notification handler to 0x1d8e9
    Sending command AT%CESQ=1
    AT socket thread started
    Writing any pending command
    Awaiting response for AT%CESQ=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=1,42,0
    Writing any pending command
    Sending command AT%CMNG=1,42,0
    Listening on socket
    at_cmd_rx 85 bytes, %CMNG: 42,0,"0000000000000000000000000000000000000000000000000000000000000000"
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=3,42,0
    Writing any pending command
    Sending command AT%CMNG=3,42,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Provisioning certificate
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
    MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
    MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
    d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
    QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
    MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
    b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
    9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
    CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
    nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
    43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
    T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
    gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
    BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
    TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
    DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
    hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
    06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
    PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
    YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
    CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
    -----END CERTIFICATE-----
    "
    Writing any pending command
    Sending command AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
    MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
    MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
    d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
    QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
    MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
    b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
    9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
    CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
    nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
    43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
    T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
    gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
    BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
    TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
    DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
    hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
    06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
    PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
    YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
    CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
    -----END CERTIFICATE-----
    "
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Writing any-----> DNS set result 0
    -----> Waiting for network.. 
    Sending command AT%XSYSTEMMODE?
     pending command
    Awaiting response for AT%XSYSTEMMODE?
    Listening on socket
    at_cmd_rx 28 bytes, %XSYSTEMMODE: 1,0,0,0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
    Writing any pending command
    Sending command AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%XSYSTEMMODE=1,0,0,0
    Writing any pending command
    Sending command AT%XSYSTEMMODE=1,0,0,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CFUN=1
    Writing any pending command
    Sending command AT+CFUN=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Writing any pending command
    Listening on socket
    at_cmd_rx 18 bytes, %CESQ: 52,2,6,0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 32 bytes, +CEREG: 2,"3060","082F630B",7
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 54,2,15,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 56 bytes, +CEREG: 5,"3060","082F630B",7,,,"11100000","11100000"
    
    -----> CONNECTED
    
    
    ----------------------------
    -----> APP COMPLETE <-------
    ----------------------------
    -----> Waiting for ip addr.. 
    Writing any pending command
    Listening on socket
    -----> GOT IP
    -----> Connecting to example.com
    -----> Sent 61 bytes
    -----> Received 346 bytes
    
    >	 HTTP/1.1 200 OK
    
    -----> Finished, closing socket.

    When its not:

    *** Booting Zephyr OS build v2.6.99-ncs1  ***
    Flash regions		Domain		Permissions
    00 02 0x00000 0x18000 	Secure		rwxl
    03 31 0x18000 0x100000 	Non-Secure	rwxl
    
    Non-secure callable region 0 placed in flash region 2 with size 32.
    
    SRAM region		Domain		Permissions
    00 07 0x00000 0x10000 	Secure		rwxl
    08 31 0x10000 0x40000 	Non-Secure	rwxl
    
    Peripheral		Domain		Status
    00 NRF_P0               Non-Secure	OK
    01 NRF_CLOCK            Non-Secure	OK
    02 NRF_RTC0             Non-Secure	OK
    03 NRF_RTC1             Non-Secure	OK
    04 NRF_NVMC             Non-Secure	OK
    05 NRF_UARTE1           Non-Secure	OK
    06 NRF_UARTE2           Secure		SKIP
    07 NRF_TWIM2            Non-Secure	OK
    08 NRF_SPIM3            Non-Secure	OK
    09 NRF_TIMER0           Non-Secure	OK
    10 NRF_TIMER1           Non-Secure	OK
    11 NRF_TIMER2           Non-Secure	OK
    12 NRF_SAADC            Non-Secure	OK
    13 NRF_PWM0             Non-Secure	OK
    14 NRF_PWM1             Non-Secure	OK
    15 NRF_PWM2             Non-Secure	OK
    16 NRF_PWM3             Non-Secure	OK
    17 NRF_WDT              Non-Secure	OK
    18 NRF_IPC              Non-Secure	OK
    19 NRF_VMC              Non-Secure	OK
    20 NRF_FPU              Non-Secure	OK
    21 NRF_EGU1             Non-Secure	OK
    22 NRF_EGU2             Non-Secure	OK
    23 NRF_DPPIC            Non-Secure	OK
    24 NRF_REGULATORS       Non-Secure	OK
    25 NRF_PDM              Non-Secure	OK
    26 NRF_I2S              Non-Secure	OK
    27 NRF_GPIOTE1          Non-Secure	OK
    
    SPM: NS image at 0x18200
    SPM: NS MSP at 0x2001c230
    SPM: NS reset vector at 0x1b0b5
    SPM: prepare to jump to Non-Secure image.
    *** Booting Zephyr OS build v2.6.99-ncs1  ***
    rst reason 0x10000
    Rst source: AIRCR.SYSRESETREQ
    HTTPS client sample started
    Sending command AT+CPSMS=
    Failed to send AT command (err:9)
    Awaiting response for AT+CPSMS=
    Sending command AT+CEDRXS=3
    Failed to send AT command (err:9)
    Awaiting response for AT+CEDRXS=3
    Common AT socket created
    Common AT socket processing thread created
    Setting notification handler to 0x1d8e9
    Sending command AT%CESQ=1
    AT socket thread started
    Writing any pending command
    Awaiting response for AT%CESQ=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=1,42,0
    Writing any pending command
    Sending command AT%CMNG=1,42,0
    Listening on socket
    at_cmd_rx 85 bytes, %CMNG: 42,0,"0000000000000000000000000000000000000000000000000000000000000000"
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=3,42,0
    Writing any pending command
    Sending command AT%CMNG=3,42,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Provisioning certificate
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
    MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
    MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
    d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
    QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
    MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
    b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
    9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
    CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
    nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
    43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
    T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
    gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
    BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
    TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
    DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
    hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
    06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
    PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
    YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
    CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
    -----END CERTIFICATE-----
    "
    Writing any pending command
    Sending command AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
    MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
    MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
    d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
    QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
    MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
    b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
    9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
    CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
    nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
    43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
    T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
    gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
    BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
    TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
    DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
    hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
    06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
    PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
    YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
    CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
    -----END CERTIFICATE-----
    "
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Writing any-----> DNS set result 0
    -----> Waiting for network.. 
    Sending command AT%XSYSTEMMODE?
     pending command
    Awaiting response for AT%XSYSTEMMODE?
    Listening on socket
    at_cmd_rx 28 bytes, %XSYSTEMMODE: 1,0,0,0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
    Writing any pending command
    Sending command AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%XSYSTEMMODE=1,0,0,0
    Writing any pending command
    Sending command AT%XSYSTEMMODE=1,0,0,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CFUN=1
    Writing any pending command
    Sending command AT+CFUN=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Writing any pending command
    Listening on socket
    at_cmd_rx 18 bytes, %CESQ: 54,2,9,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 32 bytes, +CEREG: 2,"3060","082F630B",7
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 59,2,15,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 37 bytes, +CEREG: 2,"3060","082F630B",7,0,15
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 21 bytes, %CESQ: 255,0,255,0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CEREG: 2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,17,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 18 bytes, %CESQ: 58,2,9,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,15,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,10,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,16,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,11,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,16,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,11,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,17,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,12,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,18,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,12,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,18,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,13,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,18,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,12,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 18 bytes, %CESQ: 57,2,7,1
    
    ...gets cesq a 100x more times
    
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,19,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 59,2,13,1
    
    Writing any pending command
    Listening on socket
    Sending command AT+CFUN=4
    Awaiting response for AT+CFUN=4
    at_cmd_rx 21 bytes, %CESQ: 255,0,255,0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CEREG: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%XSYSTEMMODE=0,1,0,0
    Writing any pending command
    Sending command AT%XSYSTEMMODE=0,1,0,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CFUN=1
    Writing any pending command
    Sending command AT+CFUN=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 64,3,23,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 32 bytes, +CEREG: 2,"341C","014DD273",9
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 65,3,16,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 64,3,25,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 65,3,19,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 64,3,25,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,17,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,28,4
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,16,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,16,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,18,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 66,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 66,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 32 bytes, +CEREG: 2,"3860","082F635B",9
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 37 bytes, +CEREG: 2,"3860","082F635B",9,0,14
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 70,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 70,3,28,4
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 71,3,22,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 69,3,27,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 69,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 66,3,27,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 69,3,20,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 69,3,27,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 69,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 72,3,26,3

Reply
  • Thread appears to be working once more!

    I updated my device to mfw v1.3.1 and its running the basic https example with ncs v1.7.0. Unfortunately its still doing roughly the same thing, only working roughly 50% of the time.

    I drove out to the farmland again close to the tower and got a really strong signal. The main difference is this time when it fails, it doesn't connect to the network instead of connecting and failing on the DNS query. When it finally does connect, everything works well including the issue in this post. Though fundamentally, the 50% connection rate is still true when close to the tower.

    New logs. When its working:

    *** Booting Zephyr OS build v2.6.99-ncs1  ***
    Flash regions		Domain		Permissions
    00 02 0x00000 0x18000 	Secure		rwxl
    03 31 0x18000 0x100000 	Non-Secure	rwxl
    
    Non-secure callable region 0 placed in flash region 2 with size 32.
    
    SRAM region		Domain		Permissions
    00 07 0x00000 0x10000 	Secure		rwxl
    08 31 0x10000 0x40000 	Non-Secure	rwxl
    
    Peripheral		Domain		Status
    00 NRF_P0               Non-Secure	OK
    01 NRF_CLOCK            Non-Secure	OK
    02 NRF_RTC0             Non-Secure	OK
    03 NRF_RTC1             Non-Secure	OK
    04 NRF_NVMC             Non-Secure	OK
    05 NRF_UARTE1           Non-Secure	OK
    06 NRF_UARTE2           Secure		SKIP
    07 NRF_TWIM2            Non-Secure	OK
    08 NRF_SPIM3            Non-Secure	OK
    09 NRF_TIMER0           Non-Secure	OK
    10 NRF_TIMER1           Non-Secure	OK
    11 NRF_TIMER2           Non-Secure	OK
    12 NRF_SAADC            Non-Secure	OK
    13 NRF_PWM0             Non-Secure	OK
    14 NRF_PWM1             Non-Secure	OK
    15 NRF_PWM2             Non-Secure	OK
    16 NRF_PWM3             Non-Secure	OK
    17 NRF_WDT              Non-Secure	OK
    18 NRF_IPC              Non-Secure	OK
    19 NRF_VMC              Non-Secure	OK
    20 NRF_FPU              Non-Secure	OK
    21 NRF_EGU1             Non-Secure	OK
    22 NRF_EGU2             Non-Secure	OK
    23 NRF_DPPIC            Non-Secure	OK
    24 NRF_REGULATORS       Non-Secure	OK
    25 NRF_PDM              Non-Secure	OK
    26 NRF_I2S              Non-Secure	OK
    27 NRF_GPIOTE1          Non-Secure	OK
    
    SPM: NS image at 0x18200
    SPM: NS MSP at 0x2001c230
    SPM: NS reset vector at 0x1b0b5
    SPM: prepare to jump to Non-Secure image.
    *** Booting Zephyr OS build v2.6.99-ncs1  ***
    rst reason 0x10000
    Rst source: AIRCR.SYSRESETREQ
    HTTPS client sample started
    Sending command AT+CPSMS=
    Failed to send AT command (err:9)
    Awaiting response for AT+CPSMS=
    Sending command AT+CEDRXS=3
    Failed to send AT command (err:9)
    Awaiting response for AT+CEDRXS=3
    Common AT socket created
    Common AT socket processing thread created
    Setting notification handler to 0x1d8e9
    Sending command AT%CESQ=1
    AT socket thread started
    Writing any pending command
    Awaiting response for AT%CESQ=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=1,42,0
    Writing any pending command
    Sending command AT%CMNG=1,42,0
    Listening on socket
    at_cmd_rx 85 bytes, %CMNG: 42,0,"0000000000000000000000000000000000000000000000000000000000000000"
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=3,42,0
    Writing any pending command
    Sending command AT%CMNG=3,42,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Provisioning certificate
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
    MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
    MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
    d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
    QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
    MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
    b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
    9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
    CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
    nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
    43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
    T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
    gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
    BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
    TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
    DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
    hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
    06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
    PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
    YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
    CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
    -----END CERTIFICATE-----
    "
    Writing any pending command
    Sending command AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
    MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
    MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
    d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
    QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
    MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
    b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
    9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
    CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
    nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
    43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
    T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
    gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
    BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
    TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
    DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
    hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
    06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
    PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
    YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
    CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
    -----END CERTIFICATE-----
    "
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Writing any-----> DNS set result 0
    -----> Waiting for network.. 
    Sending command AT%XSYSTEMMODE?
     pending command
    Awaiting response for AT%XSYSTEMMODE?
    Listening on socket
    at_cmd_rx 28 bytes, %XSYSTEMMODE: 1,0,0,0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
    Writing any pending command
    Sending command AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%XSYSTEMMODE=1,0,0,0
    Writing any pending command
    Sending command AT%XSYSTEMMODE=1,0,0,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CFUN=1
    Writing any pending command
    Sending command AT+CFUN=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Writing any pending command
    Listening on socket
    at_cmd_rx 18 bytes, %CESQ: 52,2,6,0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 32 bytes, +CEREG: 2,"3060","082F630B",7
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 54,2,15,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 56 bytes, +CEREG: 5,"3060","082F630B",7,,,"11100000","11100000"
    
    -----> CONNECTED
    
    
    ----------------------------
    -----> APP COMPLETE <-------
    ----------------------------
    -----> Waiting for ip addr.. 
    Writing any pending command
    Listening on socket
    -----> GOT IP
    -----> Connecting to example.com
    -----> Sent 61 bytes
    -----> Received 346 bytes
    
    >	 HTTP/1.1 200 OK
    
    -----> Finished, closing socket.

    When its not:

    *** Booting Zephyr OS build v2.6.99-ncs1  ***
    Flash regions		Domain		Permissions
    00 02 0x00000 0x18000 	Secure		rwxl
    03 31 0x18000 0x100000 	Non-Secure	rwxl
    
    Non-secure callable region 0 placed in flash region 2 with size 32.
    
    SRAM region		Domain		Permissions
    00 07 0x00000 0x10000 	Secure		rwxl
    08 31 0x10000 0x40000 	Non-Secure	rwxl
    
    Peripheral		Domain		Status
    00 NRF_P0               Non-Secure	OK
    01 NRF_CLOCK            Non-Secure	OK
    02 NRF_RTC0             Non-Secure	OK
    03 NRF_RTC1             Non-Secure	OK
    04 NRF_NVMC             Non-Secure	OK
    05 NRF_UARTE1           Non-Secure	OK
    06 NRF_UARTE2           Secure		SKIP
    07 NRF_TWIM2            Non-Secure	OK
    08 NRF_SPIM3            Non-Secure	OK
    09 NRF_TIMER0           Non-Secure	OK
    10 NRF_TIMER1           Non-Secure	OK
    11 NRF_TIMER2           Non-Secure	OK
    12 NRF_SAADC            Non-Secure	OK
    13 NRF_PWM0             Non-Secure	OK
    14 NRF_PWM1             Non-Secure	OK
    15 NRF_PWM2             Non-Secure	OK
    16 NRF_PWM3             Non-Secure	OK
    17 NRF_WDT              Non-Secure	OK
    18 NRF_IPC              Non-Secure	OK
    19 NRF_VMC              Non-Secure	OK
    20 NRF_FPU              Non-Secure	OK
    21 NRF_EGU1             Non-Secure	OK
    22 NRF_EGU2             Non-Secure	OK
    23 NRF_DPPIC            Non-Secure	OK
    24 NRF_REGULATORS       Non-Secure	OK
    25 NRF_PDM              Non-Secure	OK
    26 NRF_I2S              Non-Secure	OK
    27 NRF_GPIOTE1          Non-Secure	OK
    
    SPM: NS image at 0x18200
    SPM: NS MSP at 0x2001c230
    SPM: NS reset vector at 0x1b0b5
    SPM: prepare to jump to Non-Secure image.
    *** Booting Zephyr OS build v2.6.99-ncs1  ***
    rst reason 0x10000
    Rst source: AIRCR.SYSRESETREQ
    HTTPS client sample started
    Sending command AT+CPSMS=
    Failed to send AT command (err:9)
    Awaiting response for AT+CPSMS=
    Sending command AT+CEDRXS=3
    Failed to send AT command (err:9)
    Awaiting response for AT+CEDRXS=3
    Common AT socket created
    Common AT socket processing thread created
    Setting notification handler to 0x1d8e9
    Sending command AT%CESQ=1
    AT socket thread started
    Writing any pending command
    Awaiting response for AT%CESQ=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=1,42,0
    Writing any pending command
    Sending command AT%CMNG=1,42,0
    Listening on socket
    at_cmd_rx 85 bytes, %CMNG: 42,0,"0000000000000000000000000000000000000000000000000000000000000000"
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=3,42,0
    Writing any pending command
    Sending command AT%CMNG=3,42,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Provisioning certificate
    Awaiting response for AT+CMEE?
    Writing any pending command
    Sending command AT+CMEE?
    Listening on socket
    at_cmd_rx 15 bytes, +CMEE: 0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=1
    Writing any pending command
    Sending command AT+CMEE=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
    MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
    MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
    d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
    QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
    MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
    b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
    9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
    CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
    nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
    43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
    T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
    gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
    BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
    TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
    DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
    hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
    06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
    PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
    YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
    CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
    -----END CERTIFICATE-----
    "
    Writing any pending command
    Sending command AT%CMNG=0,42,0,"-----BEGIN CERTIFICATE-----
    MIIDrzCCApegAwIBAgIQCDvgVpBCRrGhdWrJWZHHSjANBgkqhkiG9w0BAQUFADBh
    MQswCQYDVQQGEwJVUzEVMBMGA1UEChMMRGlnaUNlcnQgSW5jMRkwFwYDVQQLExB3
    d3cuZGlnaWNlcnQuY29tMSAwHgYDVQQDExdEaWdpQ2VydCBHbG9iYWwgUm9vdCBD
    QTAeFw0wNjExMTAwMDAwMDBaFw0zMTExMTAwMDAwMDBaMGExCzAJBgNVBAYTAlVT
    MRUwEwYDVQQKEwxEaWdpQ2VydCBJbmMxGTAXBgNVBAsTEHd3dy5kaWdpY2VydC5j
    b20xIDAeBgNVBAMTF0RpZ2lDZXJ0IEdsb2JhbCBSb290IENBMIIBIjANBgkqhkiG
    9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4jvhEXLeqKTTo1eqUKKPC3eQyaKl7hLOllsB
    CSDMAZOnTjC3U/dDxGkAV53ijSLdhwZAAIEJzs4bg7/fzTtxRuLWZscFs3YnFo97
    nh6Vfe63SKMI2tavegw5BmV/Sl0fvBf4q77uKNd0f3p4mVmFaG5cIzJLv07A6Fpt
    43C/dxC//AH2hdmoRBBYMql1GNXRor5H4idq9Joz+EkIYIvUX7Q6hL+hqkpMfT7P
    T19sdl6gSzeRntwi5m3OFBqOasv+zbMUZBfHWymeMr/y7vrTC0LUq7dBMtoM1O/4
    gdW7jVg/tRvoSSiicNoxBN33shbyTApOB6jtSj1etX+jkMOvJwIDAQABo2MwYTAO
    BgNVHQ8BAf8EBAMCAYYwDwYDVR0TAQH/BAUwAwEB/zAdBgNVHQ4EFgQUA95QNVbR
    TLtm8KPiGxvDl7I90VUwHwYDVR0jBBgwFoAUA95QNVbRTLtm8KPiGxvDl7I90VUw
    DQYJKoZIhvcNAQEFBQADggEBAMucN6pIExIK+t1EnE9SsPTfrgT1eXkIoyQY/Esr
    hMAtudXH/vTBH1jLuG2cenTnmCmrEbXjcKChzUyImZOMkXDiqw8cvpOp/2PV5Adg
    06O/nVsJ8dWO41P0jmP6P6fbtGbfYmbW0W5BjfIttep3Sp+dWOIrWcBAI+0tKIJF
    PnlUkiaY4IBIqDfv8NZ5YBberOgOzW6sRBc4L0na4UU+Krk2U886UAb3LujEV0ls
    YSEY1QSteDwsOoBrp+uvFRTp2InBuThs4pFsiv9kuXclVzDAGySj4dzp30d8tbQk
    CAUw7C29C79Fv1C5qfPrmAESrciIxpg0X40KPMbp1ZWVbd4=
    -----END CERTIFICATE-----
    "
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CMEE=0
    Writing any pending command
    Sending command AT+CMEE=0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Writing any-----> DNS set result 0
    -----> Waiting for network.. 
    Sending command AT%XSYSTEMMODE?
     pending command
    Awaiting response for AT%XSYSTEMMODE?
    Listening on socket
    at_cmd_rx 28 bytes, %XSYSTEMMODE: 1,0,0,0
    OK
    
    Enqueueing response for sync call
    Awaiting response for AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
    Writing any pending command
    Sending command AT%XMAGPIO=1,1,1,7,1,746,803,2,698,748,2,1710,2200,3,824,894,4,880,960,5,791,849,7,1565,1586
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%XSYSTEMMODE=1,0,0,0
    Writing any pending command
    Sending command AT%XSYSTEMMODE=1,0,0,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CFUN=1
    Writing any pending command
    Sending command AT+CFUN=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Writing any pending command
    Listening on socket
    at_cmd_rx 18 bytes, %CESQ: 54,2,9,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 32 bytes, +CEREG: 2,"3060","082F630B",7
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 59,2,15,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 37 bytes, +CEREG: 2,"3060","082F630B",7,0,15
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 21 bytes, %CESQ: 255,0,255,0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CEREG: 2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,17,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 18 bytes, %CESQ: 58,2,9,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,15,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,10,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,16,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,11,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,16,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,11,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,17,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,12,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,18,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,12,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,18,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,13,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,18,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,12,1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 18 bytes, %CESQ: 57,2,7,1
    
    ...gets cesq a 100x more times
    
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 58,2,19,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 59,2,13,1
    
    Writing any pending command
    Listening on socket
    Sending command AT+CFUN=4
    Awaiting response for AT+CFUN=4
    at_cmd_rx 21 bytes, %CESQ: 255,0,255,0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CEREG: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT%XSYSTEMMODE=0,1,0,0
    Writing any pending command
    Sending command AT%XSYSTEMMODE=0,1,0,0
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG=5
    Writing any pending command
    Sending command AT+CEREG=5
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CSCON=1
    Writing any pending command
    Sending command AT+CSCON=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CFUN=1
    Writing any pending command
    Sending command AT+CFUN=1
    Listening on socket
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 64,3,23,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 32 bytes, +CEREG: 2,"341C","014DD273",9
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 65,3,16,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 64,3,25,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 65,3,19,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 64,3,25,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,17,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,28,4
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,16,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,16,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,18,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 66,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 67,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 66,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 68,3,26,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 32 bytes, +CEREG: 2,"3860","082F635B",9
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 1
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 37 bytes, +CEREG: 2,"3860","082F635B",9,0,14
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 12 bytes, +CSCON: 0
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 70,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 70,3,28,4
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 71,3,22,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 69,3,27,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 69,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 66,3,27,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 69,3,20,2
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 69,3,27,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 69,3,21,3
    
    Writing any pending command
    Listening on socket
    at_cmd_rx 19 bytes, %CESQ: 72,3,26,3

Children
  • Hi,

     

    In the failing log:

    at_cmd_rx 37 bytes, +CEREG: 2,"3060","082F630B",7,0,15
    ...
    at_cmd_rx 37 bytes, +CEREG: 2,"3860","082F635B",9,0,14

    It sets the last byte here for both LTE M and NB1, which is the rejected cause code from the network, as per the documented readout from CEREG.

    These resolve to:

    Cause #14 – EPS services not allowed in this PLMN

    Cause #15 – No suitable cells in tracking area

     

    You are not permitted to the network. This can be congestion, or other reasons, but you'll have to ask the network provider. Have you used up the data quote on the SIM card?

     

    Kind regards,

    Håkon

  • Currently at 5/10MB.

    So from what you know, my device was likely trying to connect to the network only through LTE-M, likely just the network rejecting?

  • Hi,

     

    rfleming said:

    Currently at 5/10MB.

    So from what you know, my device was likely trying to connect to the network only through LTE-M, likely just the network rejecting?

    For some reason, the network is rejecting you. The device cannot get a detailed answer on why this happens, that is something that the network provider must answer. You can try to contact iBasis support to hear if there's a problem roaming in your area.

     

    Kind regards,

    Håkon

  • Hi Hakon,

    I have reached out to iBasis and also to our provider in Australia that iBasis is roaming on to see if we can sort that issue out.

    In parallel I do still see the below sometimes. Since the CEREG is +5 and it has a decent signal, I am surprised I got the error 116. If you think its likely the network, I'll concentrate on heading down that path instead and wait to see what they get back to me with. Could a packet trace help with this at all?

    Enqueueing response for sync call
    ---------> cesq status 5, val '+CESQ: 99,99,255,255,17,37
    '
    ---------> getting address...
    Writing any pending command
    Listening on socket
    ---------> getaddrinfo() failed, err 116
    Sending command AT+CEREG=5
    Awaiting response for AT+CEREG=5
    at_cmd_rx 5 bytes, OK
    
    Enqueueing response for sync call
    Awaiting response for AT+CEREG?
    Writing any pending command
    Sending command AT+CEREG?
    Listening on socket
    at_cmd_rx 62 bytes, +CEREG: 5,5,"3059","0818A60D",7,,,"11100000","11100000"
    OK
    

    Thanks again,

    Ryan.

  • Hi Ryan,

     

    rfleming said:
    If you think its likely the network, I'll concentrate on heading down that path instead and wait to see what they get back to me with. Could a packet trace help with this at all?

    Yes, all signs point towards network connectivity issues. I can look at a modem trace if you provide me one.

     

    Kind regards,

    Håkon

Related