E: Cloud MQTT input error: -128 // Socket is not connected

Hello there,

I'm trying to connect to the AWS cloud. However, when I attempt to connect, it gives out error 128. Which, accoring to this table, means there's no connected socket.

The complete error message:

AWS_IOT_EVT_CONNECTING
+CSCON: 1
RRC mode: Connected
AWS_IOT_EVT_DISCONNECTED
E: Cloud MQTT input error: -128
+CSCON: 0
RRC mode: Idle
Next connection retry in 30 seconds

I've also taken a look in this thread. Here, the issue was that OP didn't use CA1 when connecting. I do.

There's also some success. According to the AWS monitor, there's a "Get thing shadow" success rate of about 25%(15-6). Could this indicate a signal issue? I know my reception isn't great. Or should I look somewhere in my code or AWS settings?

Parents Reply Children
  • *** Booting Zephyr OS build v2.7.99-ncs1  ***
    The AT host sample started
    AT+CFUN=1
    OK
    AT+CFUN?
    +CFUN: 1
    OK
    AT+CGSN=1
    +CGSN: "351358817002543"
    OK
    AT+CGMI
    Nordic Semiconductor ASA
    OK
    AT+CGMM
    nRF9160-SICA
    OK
    AT+CGMR
    mfw_nrf9160_1.3.1
    OK
    AT+CEMODE?
    +CEMODE: 2
    OK
    AT%XCBAND=?
    %XCBAND: (1,2,3,4,5,8,12,13,18,19,20,25,26,28,66)
    OK
    AT+CMEE?
    +CMEE: 0
    OK
    AT+CMEE=1
    OK
    AT+CNEC?
    +CNEC: 0
    OK
    AT+CNEC=24
    OK
    AT+CGEREP?
    +CGEREP: 0,0
    OK
    AT+CGDCONT?
    OK
    AT+CGACT?
    OK
    AT+CGEREP=1
    OK
    AT+CIND=1,1,1
    OK
    AT+CEREG=5
    OK
    AT+CEREG?
    +CEREG: 5,4
    OK
    AT%CESQ=1
    OK
    AT+CESQ
    +CESQ: 99,99,255,255,255,255
    OK
    AT%XSIM=1
    OK
    AT%XSIM?
    %XSIM: 1
    OK
    AT+CPIN?
    +CPIN: READY
    OK
    AT+CPINR="SIM PIN"
    +CPINR: "SIM PIN",3
    OK
    AT+CIMI
    234507098655705
    OK
    %CESQ: 22,1,15,2
    +CEREG: 2,"86C6","00945D0D",7
    +CGEV: ME PDN ACT 0,0
    +CNEC_ESM: 50,0
    +CEREG: 5,"86C6","00945D0D",7,,,"11100000","11100000"
    +CIND: "service",1
    +CIND: "roam",1AT+CGDCONT?
    +CGDCONT: 0,"IP","hologram","10.171.23.168",0,0
    OK
    AT+COPS=3,2
    OK
    AT+CGACT?
    +CGACT: 0,1
    OK
    AT+COPS?
    +COPS: 0,2,"20408",7
    OK
    AT%XCBAND
    %XCBAND: 20
    OK
    AT+CGDCONT?
    +CGDCONT: 0,"IP","hologram","10.171.23.168",0,0
    OK
    AT+CGACT?
    +CGACT: 0,1
    OK
    %CESQ: 21,1,10,1
    %CESQ: 22,1,15,2
    %CESQ: 22,1,10,1
    %CESQ: 21,1,15,2
    

    Again, apologies for the incomplete information.

Related