NRF9160 AWS IOT no connection possible.

Dear

We are bussy with oure first NRF IOT application, in the past we used AWS as cloud environment.

Now we want to write some data in the cloud based on the NRF9160-DK board.

After a clean and up to date, setup from the Nordic SDK and downloading the stock AWS example with the needed adaption, described in the tutorial online, like the URL to the cloud and adding downloading the 3 certificates into the device with AT CMD project.

We run in some problem, after programming the AWS project we got this error:

I can’t find what -119 problem means?

*** Booting Zephyr OS build v3.3.99-ncs1 ***

*** Booting Zephyr OS build v3.3.99-ncs1 ***

I: The AWS IoT sample started, version: v1.0.0

E: AWS IoT library could be initialized, error: 0

E: Adding application specific topics succes, error: 0

E: Modem could be configured, error: 0

E: initializing modem info module, error: 0

+CEREG: 2,"0C3F","02C93C01",7

I: LTE cell changed: Cell ID: 46742529, Tracking area: 3135

+CSCON: 1

I: RRC mode: Connected

+CEREG: 1,"0C3F","02C93C01",7,,,"11100000","00000110"

I: Network registration status: Connected - home network

I: PSM parameter update: TAU: 3600, Active time: -1

%XTIME: "80","32604161952580","01"

I: Date time obtained

I: Next connection retry in 5 seconds

I: AWS_IOT_EVT_CONNECTING

W: connection_poll_start failed, error: -119

E: aws_iot_connect, error: -119

I: Next connection retry in 5 seconds

How can we solve this problem or what configuration is missing?

Parents Reply Children
  • Hello

    I added the lines by myself and got this error: "warning: attempt to assign the value 'y' to the undefined symbol AWS_IOT_LOG_LEVE_DBG" i added this to prj.conf

    Which sec_tag did you write the credentials to, and have you changed CONFIG_AWS_IOT_CLIENT_ID_STATIC, CONFIG_AWS_IOT_BROKER_HOST_NAME and CONFIG_AWS_IOT_SEC_TAG to the correct values?

    Maybe, HOST name is changed the other are stock values.

    CONFIG_AWS_IOT_CLIENT_ID_STATIC="my-thing"
    CONFIG_AWS_IOT_BROKER_HOST_NAME="xxxxx.iot.xxxx.amazonaws.com"
    CONFIG_AWS_IOT_SEC_TAG=201
  • emsys said:
    I added the lines by myself and got this error: "warning: attempt to assign the value 'y' to the undefined symbol AWS_IOT_LOG_LEVE_DBG" i added this to prj.conf

    I'm sorry, that was a typo on my end. It should be CONFIG_AWS_IOT_LOG_LEVEL_DBG=y.

    emsys said:
    Maybe, HOST name is changed the other are stock values.

    Which sec_tag did you write the credentials to? 201?

    And what did you name the device in AWS and the device certificate?

  • Hello

    Sorry for the delay, other project gets a bigger priority.

    The problem is still exist.

    I update my certificate without any success.

    This the output from the debug trace

    Connection poll in progress

    W: connection_poll_start failed, error: -119

    E: aws_iot_connect, error: -119

    I: Next connection retry in 5 seconds

    E: getaddrinfo, error -11

    E: client_broker_init, error: -10

     

    I changed this 3 lines

    CONFIG_AWS_IOT_CLIENT_ID_STATIC="AWS_Thing"

    CONFIG_AWS_IOT_BROKER_HOST_NAME="avbdfegwrkr9hu-ats.iot.eu-west-1.amazonaws.com"

    CONFIG_AWS_IOT_SEC_TAG=16842750

    The tag was changed to this number by uploading the certificates.

  • Could you enable debug logging in the aws_iot library to see if that gives us some more information?

    CONFIG_AWS_IOT_LOG_LEVEL_DBG=y

    Also, if you disable minimal logging, it will be easier to see where various log lines come from.

    CONFIG_LOG_MODE_MINIMAL=n

    Also, if you can take a modem trace, that would be helpful.

  • Modem Trace:

    *** Booting Zephyr OS build v3.3.99-ncs1-1 ***
    *** Booting Zephyr OS build v3.3.99-ncs1-1 ***
    I: The AWS IoT sample started, version: v1.0.0
    I: Trace thread ready
    I: Trace level override: 2
    +CEREG: 2,"0C3F","02C93C01",7
    I: LTE cell changed: Cell ID: 46742529, Tracking area: 3135
    +CSCON: 1
    I: RRC mode: Connected
    +CEREG: 1,"0C3F","02C93C01",7,,,"11100000","00000110"
    I: Network registration status: Connected - home network
    I: PSM parameter update: TAU: 3600, Active time: -1
    %XTIME: "40","32116191900540","00"
    I: Date time obtained
    I: Next connection retry in 30 seconds
    I: AWS_IOT_EVT_CONNECTING
    W: connection_poll_start failed, error: -119
    E: aws_iot_connect, error: -119
    I: Next connection retry in 30 seconds
    W: getaddrinfo, error: -11
    

Related