Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How are the RSSI Values created? #153

Open
swatza opened this issue Jul 10, 2018 · 3 comments
Open

How are the RSSI Values created? #153

swatza opened this issue Jul 10, 2018 · 3 comments

Comments

@swatza
Copy link

swatza commented Jul 10, 2018

I was trying to dig through the code as I am using this as a low cost sensor for some RF research to figure out what the outputted value represents. The best guess I have is that its an RCPI 8bit between 0-220 (as comments I found indicated min values were 90 and max were 220) but I am not sure if that mapping is correct.

Any information about the exact details would be helpful.

@JyeSmith
Copy link
Contributor

In receiver.cpp you can see the analogRead function which reads the RSSI value.

The below link explains the returned value 😃

https://www.arduino.cc/en/Tutorial/AnalogInput

@swatza
Copy link
Author

swatza commented Jul 10, 2018

Okay, so if I am understanding this correctly: mapping 0-1023 from 90 to 220 or 0 to 100. Therefore 90 would equal 0 Volts and 220 should equal 5V or 100%.

@JyeSmith
Copy link
Contributor

The RSSI min/max output range isn't from 0 to 5v, but more like 0.5 to 1.2. Hence the min and max calibration values are only ~90 to ~220.

The 0 to 100 conversion you see in the code is to normalise Rx modules on the same scale. It then makes it easy to see a 2% difference, which is the threshold for switching between the Rx modules.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants