mobileinsight-core icon indicating copy to clipboard operation
mobileinsight-core copied to clipboard

LTE bandwidth predictor fix

Open Codeman-from-unknown-city opened this issue 1 year ago • 0 comments

This fix make LTE bandwidth predictor works.

What changed:

  • LteBandwidthPredictor waits for event from TrackCellInfoAnalyzer, but the event is dropped by Analyzer base class because it contains None in data field:

TrackCellInfoAnalyzer notifier method:

    def __callback_mib_cell(self, msg):
        self.__mib_antenna = msg.data['Number of Antenna']
        self.__mib_dl_bandwidth = msg.data['DL BW']
        self.__mib_cell_id = msg.data['Physical Cell ID']
        self.__mib_freq = msg.data['Freq']
        event = Event(None, 'MIB_CELL', None)   # sends event with
        self.send(event)                        # 'None' in data field

Event is filtered in Analyzer base method:

    def recv(self, module, event):
        ...
        if not event.data:  # the event is dropped here
            return
        ...

In result the LteBandwidthPredictor never starts.

  • Fixed arrays indices calculations in LteBandwidthPredictor itself. The previous version may create float indices what leads to crash.