This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

AGPS with nrf cloud, Cannot parse schema version: 123

Hello,

I come to you because I wanted to recover the GPS data in my project for that I based on the sample agps, however when I launch my project at the time of the reception of data of the cloud I have this error:

ASSERTION FAIL [version == (1)] @ WEST_TOPDIR/nrf/subsys/net/lib/nrf_cloud/src/nrf_cloud_agps.c549
Cannot parse schema version: 123
This problem does not appear when I run the sample, do you have any idea what the problem is or what I missed?

Parents
  • Hello again Tatiana,

    Thanks a lot for your feedback! So, the ASSERT in nrf_cloud_agps.c, which actually is located on line 850, is the following:

    version = buf[NRF_CLOUD_AGPS_BIN_SCHEMA_VERSION_INDEX];
    
    parsed_len += NRF_CLOUD_AGPS_BIN_SCHEMA_VERSION_SIZE;
    
    
    
    __ASSERT(version == NRF_CLOUD_AGPS_BIN_SCHEMA_VERSION,
    
    "Cannot parse schema version: %d", version);
    
    

    The binary schema version is supposed to be 1, as defined in nrf_cloud_agps_schema_v1.h:16:

    #define NRF_CLOUD_AGPS_BIN_SCHEMA_VERSION (1)

    However, the value which comes in from your application via the argument evt->data.msg.buf is obviously 123, which causes the ASSERT.

    int err = gps_process_agps_data(evt->data.msg.buf, evt->data.msg.len);

    A good starting point might be to check why your application applies this value to the cloud message.

    I hope this will help you!

    Regards,

    Markus

Reply
  • Hello again Tatiana,

    Thanks a lot for your feedback! So, the ASSERT in nrf_cloud_agps.c, which actually is located on line 850, is the following:

    version = buf[NRF_CLOUD_AGPS_BIN_SCHEMA_VERSION_INDEX];
    
    parsed_len += NRF_CLOUD_AGPS_BIN_SCHEMA_VERSION_SIZE;
    
    
    
    __ASSERT(version == NRF_CLOUD_AGPS_BIN_SCHEMA_VERSION,
    
    "Cannot parse schema version: %d", version);
    
    

    The binary schema version is supposed to be 1, as defined in nrf_cloud_agps_schema_v1.h:16:

    #define NRF_CLOUD_AGPS_BIN_SCHEMA_VERSION (1)

    However, the value which comes in from your application via the argument evt->data.msg.buf is obviously 123, which causes the ASSERT.

    int err = gps_process_agps_data(evt->data.msg.buf, evt->data.msg.len);

    A good starting point might be to check why your application applies this value to the cloud message.

    I hope this will help you!

    Regards,

    Markus

Children
No Data
Related