Growcube report
GrowcubeReport inherited classes are used to receive commands from the Growcube.
- class growcube_client.growcubereport.AutoWaterGrowcubeReport(data)
Bases:
GrowcubeReport
Response 23 - AutoWater Reports a historic watering event
- property channel: int
Channel number 0-3 Returns:
Channel number 0-3
- property day: int
Day of month Returns:
Day of month
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- property hour: int
Hour Returns:
Hour
- property minute: int
Minute Returns:
Minute
- property month: int
Month Returns:
Month
- property timestamp: datetime
Timestamp Returns:
Timestamp
- property year: int
Year Returns:
Year
- class growcube_client.growcubereport.CheckDuZhuanGrowcubeReport(data)
Bases:
GrowcubeReport
Response 29 - RepCheckDuZhuan I have no idea what this is, the chinese phrase “du zhuan” translates to something like “read transmission”
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- property state: bool
State Returns:
True if state is 1, otherwise False
- class growcube_client.growcubereport.CheckSensorGrowcubeReport(data)
Bases:
GrowcubeReport
Response 28 - RepCheckSenSorNotConnected Reports that a sensor is malfunctioning
- property fault_state: bool
Fault state Returns:
True if fault, otherwise False
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- class growcube_client.growcubereport.CheckSensorLockGrowcubeReport(data)
Bases:
GrowcubeReport
Response 34 - ReqCheckSenSorLock I have no idea what this is.
- property channel: int
Channel number 0-3 Returns:
Channel number 0-3
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- property lock_state: bool
Lock state Returns:
True if locked, otherwise False
- class growcube_client.growcubereport.CheckSensorNotConnectedGrowcubeReport(data)
Bases:
GrowcubeReport
Response 30 - RepCheckSenSorNotConnect Reports that a sensor is not connected
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- class growcube_client.growcubereport.CheckWifiStateGrowcubeReport(data)
Bases:
GrowcubeReport
Response 31 - RepWifistate Reports wifi state, probably ony valid when in AP mode, to check if the new WiFi SSID is available
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- property state: bool
State Returns:
True if state is 1, otherwise False
- class growcube_client.growcubereport.DeviceVersionGrowcubeReport(data)
Bases:
GrowcubeReport
Response 24 - RepDeviceVersion Reports firmware version and device ID
- property device_id: str
Device ID Returns:
Device ID
- get_description() str
Get a human readable description of the report Returns:
A human readable description of the report
- property version: str
Firmware version Returns:
Firmware version
- class growcube_client.growcubereport.EraseDataGrowcubeReport(data)
Bases:
GrowcubeReport
Response 25 - RepErasureData
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- property success: bool
Success Returns:
True if success, otherwise False
- class growcube_client.growcubereport.GrowCubeIPGrowcubeReport(data)
Bases:
GrowcubeReport
Response 32 - RepGrowCubeIP Reports the IP address of the Growcube, I have no idea how to trigger this
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- property ip: str
IP address Returns:
IP address
- class growcube_client.growcubereport.GrowcubeReport(command)
Bases:
object
Growcube report base class
- CMD_INNER = '@'
- Response = {20: 'RepWaterStateCmd', 21: 'RepSTHSateCmd', 22: 'RepCurveCmd', 23: 'RepAutoWaterCmd', 24: 'RepDeviceVersionCmd', 25: 'RepErasureDataCmd', 26: 'RepPumpOpenCmd', 27: 'RepPumpCloseCmd', 28: 'RepCheckSenSorNotConnectedCmd', 29: 'RepCheckDuZhuanCmd', 30: 'RepCheckSenSorNotConnectCmd', 31: 'RepWifistateCmd', 32: 'RepGrowCubeIPCmd', 33: 'RepLockstateCmd', 34: 'ReqCheckSenSorLockCmd', 35: 'RepCurveEndFlagCmd'}
- property command: str
Command value Returns:
Command value
- get_description() str
Get a human readable description of the report Returns:
A human readable description of the report
- static get_report(message) Self
Create a report from a message Args:
message: The message to create a report from
- Returns:
A GrowcubeReport child class instance
- class growcube_client.growcubereport.LockStateGrowcubeReport(data)
Bases:
GrowcubeReport
Response 33 - RepLockstate Reports if the device is in locked state, as indicated by the red LED on the device
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- property lock_state: bool
Lock state Returns:
True if locked, otherwise False
- class growcube_client.growcubereport.MoistureHumidityStateGrowcubeReport(data)
Bases:
GrowcubeReport
Response 21 - RepSTHSate Report moisture, humidity and temperature for a channel
- property channel
Channel number 0-3 Returns:
Channel number 0-3
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- property humidity
Humidity value Returns:
Humidity value, %
- property moisture
Moisture value Returns:
Moisture value, %
- property temperature
Temperature value Returns:
Temperature value, °C
- class growcube_client.growcubereport.PumpCloseGrowcubeReport(data)
Bases:
GrowcubeReport
Response 27 - RepPumpClose Reports that a pump has been stopped
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- class growcube_client.growcubereport.PumpOpenGrowcubeReport(data)
Bases:
GrowcubeReport
Response 26 - RepPumpOpen Reports that a pump has been started
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- class growcube_client.growcubereport.RepCurveEndFlagGrowcubeReport(data)
Bases:
GrowcubeReport
Response 35 - RepCurveEndFlag Reports the end of the water event reports stream
- property channel: int
Channel number 0-3 Returns:
Channel number 0-3
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- class growcube_client.growcubereport.UnknownGrowcubeReport(command, data)
Bases:
GrowcubeReport
Reports an unknown response
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- class growcube_client.growcubereport.WaterStateGrowcubeReport(data)
Bases:
GrowcubeReport
Response 20 - RepWaterState Reports water low state
- get_description()
Get a human readable description of the report Returns:
A human readable description of the report
- property water_warning: bool
Water warning Returns:
True if water warning, otherwise False