nrf_cloud not connecting in thingy91X

Hello Nordic team,

I’m working with the following setup:

  • Board: Thingy:91X (nRF9161)

  • nRF Connect SDK version: v2.9.0

  • Modem firmware version: mfw_nrf91x1_2.0.2

  • Lesson being followed: Intermediate SDK Lesson L9_E6

  • Application working successfully: nrf_cloud_multiple_services


Issue:

The nrf_cloud_multiple_services sample connects successfully to nRF Cloud (I see MQTT and location data working).

However, when running the L9_E6 lesson application, I get the following output (see attached image), specifically:

Thank you,

José

Parents
  • Hi! The -128 error you are seeing is typical for invalid credentials. I suspect that for the nRF Cloud Multi Service sample, you are using the UUID as client ID. To connect the sample from the lesson, you would need to do the same. The device certificate is tied to one specific client ID. At the moment, you are using nrf-<IMEI> as device ID. This kind of device ID is not available for Thingy:91 X, as it is reserved for the old JITP certificates used by older development kits. You can try the kconfig option "CONFIG_NRF_CLOUD_CLIENT_ID_SRC_INTERNAL_UUID". If you feel the need to re-register your device, you can follow the guide here: https://github.com/nRFCloud/utils

    Let me know if that solves the issue!

  • YES! Right on point! The device ID was previously set to nrf-<IMEI>, but now it correctly matches the one expected by nRF Cloud, as shown in the screenshots. The fix was simply updating the prj.conf with the following settings:


    # Enable modem-based JSON Web Token (JWT) generation required for nRF Cloud authentication
    CONFIG_MODEM_JWT=y
    
    # Configure the nRF Cloud library to use the device's internal UUID as the client ID
    CONFIG_NRF_CLOUD_CLIENT_ID_SRC_INTERNAL_UUID=y


    Now the ID in the provisioned device using the Multiple-Services example

    Matches my code (L9_E6 of ncs-intermediate):
    Thank you for your assistant if it is not much trouble why do i get the Failed to save session state?
    [00:02:50.471,282] <err> nrf_cloud_transport: Failed to save session state: -2
Reply
  • YES! Right on point! The device ID was previously set to nrf-<IMEI>, but now it correctly matches the one expected by nRF Cloud, as shown in the screenshots. The fix was simply updating the prj.conf with the following settings:


    # Enable modem-based JSON Web Token (JWT) generation required for nRF Cloud authentication
    CONFIG_MODEM_JWT=y
    
    # Configure the nRF Cloud library to use the device's internal UUID as the client ID
    CONFIG_NRF_CLOUD_CLIENT_ID_SRC_INTERNAL_UUID=y


    Now the ID in the provisioned device using the Multiple-Services example

    Matches my code (L9_E6 of ncs-intermediate):
    Thank you for your assistant if it is not much trouble why do i get the Failed to save session state?
    [00:02:50.471,282] <err> nrf_cloud_transport: Failed to save session state: -2
Children
No Data
Related