* new packet score function

This commit is contained in:
Scott Powell 2025-02-04 15:00:28 +11:00
parent 7da0a5f7ec
commit a93412216a
6 changed files with 28 additions and 21 deletions

View file

@ -21,11 +21,6 @@ public:
float packetScore(float snr, int packet_len) override {
int sf = ((CustomLLCC68 *)_radio)->spreadingFactor;
const float A = 0.7;
const float B = 0.4;
float ber = exp(-pow(10, (snr / 10)) / (A * pow(10, (snr / 10)) + B * (1 << sf)));
return pow(1 - ber, packet_len * 8);
return packetScoreInt(snr, sf, packet_len);
}
};