How to use the aioblescan.ULongInt function in aioblescan

To help you get started, we’ve selected a few aioblescan examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github frawau / aioblescan / aioblescan / plugins / eddystone.py View on Github external
def tlm_encoder(self):
        encodedurl = []
        encodedurl.append(aios.NBytes("VBATT",2))
        if "battery" in self.type_payload:
            encodedurl[-1].val = self.type_payload["battery"]
        else:
            encodedurl[-1].val = -128
        encodedurl.append(aios.Float88("Temperature"))
        if "temperature" in self.type_payload:
            encodedurl[-1].val = self.type_payload["temperature"]
        else:
            encodedurl[-1].val = -128

        encodedurl.append(aios.ULongInt("Count"))
        if "count" in self.type_payload:
            encodedurl[-1].val = self.type_payload["count"]
        else:
            encodedurl[-1].val = 0

        encodedurl.append(aios.ULongInt("Uptime"))
        if "uptime" in self.type_payload:
            encodedurl[-1].val = self.type_payload["uptime"]
        else:
            encodedurl[-1].val = 0
        return encodedurl
github frawau / aioblescan / aioblescan / plugins / eddystone.py View on Github external
encodedurl[-1].val = self.type_payload["battery"]
        else:
            encodedurl[-1].val = -128
        encodedurl.append(aios.Float88("Temperature"))
        if "temperature" in self.type_payload:
            encodedurl[-1].val = self.type_payload["temperature"]
        else:
            encodedurl[-1].val = -128

        encodedurl.append(aios.ULongInt("Count"))
        if "count" in self.type_payload:
            encodedurl[-1].val = self.type_payload["count"]
        else:
            encodedurl[-1].val = 0

        encodedurl.append(aios.ULongInt("Uptime"))
        if "uptime" in self.type_payload:
            encodedurl[-1].val = self.type_payload["uptime"]
        else:
            encodedurl[-1].val = 0
        return encodedurl