|
From: Tom T. <tom...@et...> - 2016-03-14 23:05:56
|
On Wed, Mar 9, 2016 at 2:43 AM, Mona Lisampson <mon...@gm...> wrote:
> OpenBTS> noise
> noise RSSI is -2147483647 dB wrt full scale
> MS RSSI target is -50 dB wrt full scale
> INFO: the current noise level is acceptable
The 2147483647 value is caused by a divide-by-zero in the transceiver
noise calculation. Prior to start, the noise averaging vector is
initialized with zero, so early calls to NOISELEV before the vector is
populated will report in error.
One quick fix is to cap the noise value. I'm not exactly sure how the
noise estimate affects the upper layer power control loop, but the
patch below should at least prevent bogus values from being sent.
--- a/Transceiver52M/Transceiver.cpp
+++ b/Transceiver52M/Transceiver.cpp
@@ -759,6 +759,8 @@ void Transceiver::driveControl(size_t chan)
else if (strcmp(command,"NOISELEV")==0) {
if (mOn) {
float lev = mStates[chan].mNoiseLev;
+ if (lev < 1e-6)
+ lev = 1e-6;
sprintf(response,"RSP NOISELEV 0 %d",
(int) round(20.0 * log10(rxFullScale / lev)));
}
--
-TT
|