nRF9160 DK - A-GPS

Hi,

I'm using nRF9160DK with SDKs v3.0.0

I am trying to use A-GPS with nRFCloud REST. I used the location example and it works correctly. The documentation states that A-GPS is used via the location.h library

docs.nordicsemi.com/.../location.html

The thing I don't understand about this example is whether the application actually uses A-GPS, or should I work in the LOCATION_EVT_GNSS_ASSISTANCE_REQUEST event.

In the example, I cannot understand where the assistance request is activated.

  • Hello,

    I will look more into it and get back to you with more information.

    Best regards,

    Michal

  • Hello,

    thank u for your reply. Unfortunately, I'm still stuck. I tried reading the documentation to better understand A-GPS.

  • From digging into the location library, I think the following happens:

    As long as you have the following in your prj.conf

    # nRF Cloud (for A-GNSS and cell location)
    CONFIG_NRF_CLOUD=y
    CONFIG_NRF_CLOUD_REST=y
    CONFIG_NRF_CLOUD_AGNSS=y
    CONFIG_MODEM_INFO=y # required by CONFIG_NRF_CLOUD_AGNSS
    CONFIG_MODEM_INFO_ADD_NETWORK=y # required by CONFIG_NRF_CLOUD_AGNSS
    
    # Library that maintains the current date time UTC for A-GNSS and P-GPS purposes
    CONFIG_DATE_TIME=y

    And you initialize location_init() function with the event handler like in the sample, then the location library should take care of it in the background.

    Those two links may be useful as well:

    nRF Cloud A-GNSS

    Using GNSS and GNSS assistance

    If you want to dig more into it, you can for example look into

    ncs/v3.0.0/nrf/lib/location/method_gnss.c

    or

    ncs/v3.0.0/nrf/lib/location/method_cloud_location.c

    as well as location_core.c and other files in that directory, as well the header files like

    ncs/v3.0.0/nrf/include/modem/location.h

    I have asked internally as well, just to make sure my assumptions are correct.

    Best regards,

    Michal

Related