

def status(self):
    if (not self._wait_for_modem()):
        return None
    csq = self.modem.signal_strength()
    if (not csq):
        level = 0
    elif (csq >= 30):
        level = 4
    elif (csq >= 20):
        level = 3
    elif (csq >= 10):
        level = 2
    else:
        level = 1
    vars = {
        '_signal': level,
        '_title': self.title,
        'Messages Sent': self.sent_messages,
        'Messages Received': self.received_messages,
    }
    if hasattr(self.modem, 'network'):
        self['Network Operator'] = self.modem.network
    return vars

dataset/ETHPy150Open rapidsms/rapidsms-core-dev/lib/rapidsms/backends/gsm.py Backend.status/VarMisuse@144/180 `vars`->`self`