cancel
Showing results for 
Search instead for 
Did you mean: 

In Bluetooth p2pSever,How to get RSSI Value from connected p2pClient in STM32WB5MMG?

Kavinraj
Associate III

 I want to get RSSI value of connected p2p Clients to p2p Server and can i able to get multiple connection of p2p clients RSSI value.

The  main objective is get Client's exact distance from p2p server using RSSI.

1 ACCEPTED SOLUTION

Accepted Solutions
STTwo-32
ST Employee

Hello @Kavinraj 

The RSSI is part of the advertising packet received from the BLE stack. The RSSI is the Tx Power level. You can check the AD type and the RSSI value is the data next to it. You can also read this information using the command HCI_READ_RSSI.

STTwo32_0-1712238116490.pngSTTwo32_1-1712238146455.jpeg

Best Regards.

STTwo-32

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

View solution in original post

5 REPLIES 5
STTwo-32
ST Employee

Hello @Kavinraj 

The RSSI is part of the advertising packet received from the BLE stack. The RSSI is the Tx Power level. You can check the AD type and the RSSI value is the data next to it. You can also read this information using the command HCI_READ_RSSI.

STTwo32_0-1712238116490.pngSTTwo32_1-1712238146455.jpeg

Best Regards.

STTwo-32

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Kavinraj
Associate III

Hello @STTwo-32 ,

     I want to get distance of BLE Slave devices(CLIENT) using RSSI value. In this case i have doubt about to use STM32 Master as a BLE Server or BLE Beacon.

Here attaching sample model of our project objective.

Kavinraj_0-1713166688341.png

 

   

Hello @Kavinraj 

The RSSI is a parameter that may help you to estimate the distance. But, On BLE Technologie you need to have a direct Line of site to have a good estimation of the distance. I suggest you measure different distance and collect the RSSI of each distance then you can create a mathematical equation that receive the RSSI as input and calculate the distance. Then, using the triangulation Methode (3 node fixe), you can estimate the exact location of each node. The Serial Trace need to be implemented to visualize the data.

Best Regards.

STTwo-32

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Kavinraj
Associate III

Hello @STTwo-32 

            I have too much oscillation in RSSI value even the target ble is placed fixed distance. How to reduce oscillation in RSSI value?

           I m Currently using The formula for RSSI value to Distance,    

           Distance(m) =  pow( 10 , (Rssi of 1meter distance -  obtained RSSI) /20  ) ; 

          I read rssi value  in  every 50ms once, after taking average of 20 times then its converted  into distance.

Can you suggest me to right way get it and if  I'm doing wrong kindly guide me.

 

 

 

The BLE Technologie is not the best for distance estimation or measurement since the RSSI value is based on a signal that get impacted by any type of interference. So, we don't have a specific way to do that since this implementation is done by searchers and not and industrial application. We didn't test this application before.

Best Regards.

STTwo-32

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.