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

hi, i am using nrf52840, i need to get a rssi value from the near by mobile phones. is there any example for that. where can i get the example

i am using ble_app_multilink_central example. is this enough to get rssi value.

Parents
  • Hi,

    To be able to get RSSI from nearby devices, the devices will have to transmitt something that your central can receive. If you setup the phone to do BLE advertising like a peripheral device, you can get the RSSI from the advertising report that you receive with the BLE_GAP_EVT_ADV_REPORT event in the ble_evt_handler in the central examples. You can print the RSSI value using the following line:

    NRF_LOG_INFO("RSSI: %d", p_ble_evt->evt.gap_evt.params.adv_report.rssi);
    

    Best regards,

    Jørgen

Reply
  • Hi,

    To be able to get RSSI from nearby devices, the devices will have to transmitt something that your central can receive. If you setup the phone to do BLE advertising like a peripheral device, you can get the RSSI from the advertising report that you receive with the BLE_GAP_EVT_ADV_REPORT event in the ble_evt_handler in the central examples. You can print the RSSI value using the following line:

    NRF_LOG_INFO("RSSI: %d", p_ble_evt->evt.gap_evt.params.adv_report.rssi);
    

    Best regards,

    Jørgen

Children
Related