How to calculate bluetooth distance in arduino ide and display on blynk app

Is there a way to display the rssi bluetooth value on the arduino IDE? I would like to display the rssi value and then use that to determine the distance and then display that value on the Blynk app. I am using an ESP32.

A quick google search :

Get this to work and later add Blynk to the code. Remember to keep your void loop clean.

Personally, I don’t recommend this method to calculate distance between devices, it’s not accurate and not stable. If you use this method in open space you will get a result that might be good but if you use this method where there’s a lots of obstacles like walls then you will get a different, not accurate result.


what do you recommend ?

I recommend ir distance sensor for short distances or ultrasonic sensor for medium distances or laser distance sensor for long distances.