File: PyViCareGateway.py

package info (click to toggle)
pyvicare 2.58.1-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 4,944 kB
  • sloc: python: 6,182; sh: 5; makefile: 2
file content (13 lines) | stat: -rw-r--r-- 393 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
from PyViCare.PyViCareDevice import Device
from PyViCare.PyViCareUtils import handleNotSupported


class Gateway(Device):

    @handleNotSupported
    def getSerial(self):
        return self.getProperty("gateway.devices")["gatewayId"]

    @handleNotSupported
    def getWifiSignalStrength(self) -> int:
        return int(self.getProperty("gateway.wifi")["properties"]["strength"]["value"])