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

rf230_last_rssi is rssi value in dBm, fixed RF230_MIN_RX_POWER also i… #14

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

mexx42
Copy link

@mexx42 mexx42 commented Feb 29, 2020

  • rework to always have rssi in dBm (negative value) in all places - hopefully
  • added /s/min_rssi ressource to arduino-merkurboard to query the smallest rssi since last request to this resource
  • RF230_MIN_RX_POWER is fixed and supports value in dBm (e.g. -72 ignores all packets that have lower rssi than -72)

fixes are also in other places where rssi gets print out which are not in our scope (e.g. ravenusb) - how to test ? - or should we simply ignore them ?

please review, tests, verify and merge into master ;)

regards,
m.

* else the rssi register is used having range 0 (91dBm) to 28 (-10dBm)
* For simplicity RF230_MIN_RX_POWER is based on the energy-detect value and divided by 3 when autoack is not set.
* else the rssi register is used having range 0 (-91dBm) to 28 (-10dBm)
* For simplicity RF230_MIN_RX_POWER i specified in dBm also and gets converted to the correct register values
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i -> is

@@ -667,7 +667,7 @@ ISR(TRX24_RX_START_vect)
// DEBUGFLOW('3');
/* Save RSSI for this packet if not in extended mode, scaling to 1dB resolution */
#if !RF230_CONF_AUTOACK
rf230_last_rssi = 3 * hal_subregister_read(SR_RSSI);
rf230_last_rssi = 90 - 3 * hal_subregister_read(SR_RSSI);
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead of using "90" we could use a define #RSSI_BASE_VAL - like in the chip specification
but where to put it ? in rf230bb.h ? is it common for all rf230 ?

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

Successfully merging this pull request may close these issues.

None yet

1 participant