nRF Connect SDK API 3.3.99
Loading...
Searching...
No Matches

◆ SNR_IDX_TO_DB

#define SNR_IDX_TO_DB ( snr)

#include <include/modem/modem_info.h>

Value:
((snr) - SNR_OFFSET_VAL)
#define SNR_OFFSET_VAL
Definition modem_info.h:49

Converts SNR index value returned by the modem to dB.

The index value of SNR can be converted to dB with the following formula:

  • index – 24

Example values:

  • 0: SNR < -24 dB
  • 1: -24 ≤ SNR < -23 dB
  • 2: -23 ≤ SNR < -22 dB
  • ...
  • 47: 22 ≤ SNR < 23 dB
  • 48: 23 ≤ SNR < 24 dB
  • 49: 24 ≤ SNR dB

See modem AT command reference guide for more information.

Parameters
[in]snrSNR index value as 'int'.
Returns
SNR upper bound in dB as 'int'.