SDRAngel  4.11.5
Developer docs for <a href="https://github.com/f4exb/sdrangel">SDRangel<\a>, an Open Source Qt5 / OpenGL 3.0+ SDR and signal analyzer frontend to various hardware.
Static Public Member Functions | List of all members
CalcDb Class Reference

#include <db.h>

Static Public Member Functions

static double dbPower (double magsq, double floor=1e-12)
 
static double powerFromdB (double powerdB)
 

Detailed Description

Definition at line 24 of file db.h.

Member Function Documentation

◆ dbPower()

double CalcDb::dbPower ( double  magsq,
double  floor = 1e-12 
)
static

Definition at line 22 of file db.cpp.

Referenced by TestSourceGui::displayAmplitude(), TestMIGui::displayAmplitude(), FreeDVDemod::getSNRLevels(), BFMDemodGUI::rdsUpdate(), DATVDemodGUI::tick(), WFMDemodGUI::tick(), NFMDemodGUI::tick(), AMDemodGUI::tick(), FreqTrackerGUI::tick(), ATVDemodGUI::tick(), SSBDemodGUI::tick(), FreeDVDemodGUI::tick(), UDPSourceGUI::tick(), BFMDemodGUI::tick(), ChannelAnalyzerGUI::tick(), UDPSinkGUI::tick(), FileSourceGUI::tick(), AMModGUI::tick(), FreeDVModGUI::tick(), NFMModGUI::tick(), WFMModGUI::tick(), SSBModGUI::tick(), ATVModGUI::tick(), DSDDemodGUI::tick(), WFMDemod::webapiFormatChannelReport(), AMDemod::webapiFormatChannelReport(), FreqTracker::webapiFormatChannelReport(), UDPSink::webapiFormatChannelReport(), UDPSource::webapiFormatChannelReport(), NFMDemod::webapiFormatChannelReport(), DSDDemod::webapiFormatChannelReport(), BFMDemod::webapiFormatChannelReport(), WFMMod::webapiFormatChannelReport(), AMMod::webapiFormatChannelReport(), SSBDemod::webapiFormatChannelReport(), NFMMod::webapiFormatChannelReport(), FreeDVMod::webapiFormatChannelReport(), SSBMod::webapiFormatChannelReport(), FreeDVDemod::webapiFormatChannelReport(), FileSource::webapiFormatChannelReport(), ATVMod::webapiFormatChannelReport(), and BFMDemod::webapiFormatRDSReport().

23 {
24  assert(floor > 0.0);
25 
26  if (magsq > floor)
27  {
28  return 10.0 * log10(magsq);
29  }
30  else
31  {
32  return 10.0 * log10(floor);
33  }
34 }
Fixed< IntType, IntBits > floor(Fixed< IntType, IntBits > const &x)
Definition: fixed.h:2301
+ Here is the caller graph for this function:

◆ powerFromdB()

double CalcDb::powerFromdB ( double  powerdB)
static

Definition at line 36 of file db.cpp.

Referenced by FreeDVDemod::FreeDVSNR::accumulate(), AMDemod::applySettings(), FreqTracker::applySettings(), UDPSink::applySettings(), UDPSource::applySettings(), SSBDemod::applySettings(), and FileSource::applySettings().

37 {
38  return pow(10.0, powerdB / 10.0);
39 }
+ Here is the caller graph for this function:

The documentation for this class was generated from the following files: