Hello,
We are developing a application that sends some data to AWS in some intervals(3 - 15 minutes). This application were currently being tested on custom nrf9160 boards, Thingy:91's and nRF9160 DK's
We included Cell ID and RSRP value to our payload for testing purposes. But when our devices is registered a new Cell, in the first payload the RSRP value returns as zero. Second and later data payloads contains reasonable RSRP values unless the device is registered to a new cell.
What can we do to correct this problem? What are your suggestions?
We are developing this application based on aws_fota sample of ncs v1.1.0.
We get RSRP value using the functions below.
int modem_info_rsrp_register(rsrp_cb_t cb)
{
modem_info_rsrp_cb = cb;
int rc = at_notif_register_handler(NULL,
modem_info_rsrp_subscribe_handler);
if (rc != 0) {
LOG_ERR("Can't register handler rc=%d", rc);
return rc;
}
if (at_cmd_write(AT_CMD_CESQ_ON, NULL, 0, NULL) != 0) {
return -EIO;
}
return 0;
static void modem_data_init(void)
{
int err;
err = modem_info_init();
if (err)
{
printk("Modem info could not be established: %d\n", err);
return;
}
modem_info_params_init(&modem_param);
modem_info_rsrp_register(modem_rsrp_handler);
}
void main(void)
{
int err = 0;
printk("MQTT AWS Jobs FOTA Sample, 9160_fw_v: %s\n", CONFIG_APP_VERSION);
bsd_modem_initialization();
modem_configure();
client_init(&client, CONFIG_MQTT_BROKER_HOSTNAME);
err = aws_fota_init(&client, CONFIG_APP_VERSION, aws_fota_cb_handler);
if (err != 0)
{
printk("[%s:%d] ERROR: aws_fota_init %d\n", __func__, __LINE__, err);
return;
}
modem_data_init();
modem_info_params_get(&modem_param);
modem_data_parsing_for_aws();
psm_request();
err = mqtt_connection_start();
...
}
Best Regards,
Ali Rıza