w1ll1am23 / pyeconet

Python 3 interface to the EcoNet API
MIT License
34 stars 20 forks source link

Support for vacation modes. #11

Closed vangorra closed 11 months ago

vangorra commented 4 years ago

My gladiator support vacation mode. Here is the response data. Hopefully @appleguru can also add their data as well so we can get proper support.

{
  "results": {
    "locations": [
      {
        "@AWAY": false,
        "@AWAYCONFIG": true,
        "@LOCATION_INFO": "Somewhere, WY",
        "@LOCATION_NAME": "Home",
        "@LOCATION_STATUS": "I'm Home",
        "@VACATION": false,
        "@VACATIONCONFIG": false,
        "@WEATHER": "60°",
        "@WEATHER_F": 60,
        "@WEATHER_I": "clearn.png",
        "equiptments": [
          {
            "@ACTIVE": true,
            "@ALERTCOUNT": 0,
            "@AWAY": false,
            "@AWAYCONFIG": true,
            "@AWAY_MSG": "",
            "@BCONFIG": [
              {
                "align": "center",
                "name": "@SCHEDULESTATUS",
                "type": "TEXT_LABEL_VIEW",
                "value": ""
              },
              {
                "name": "@SCHEDULERESUME",
                "title": "Resume",
                "type": "BUTTON_VIEW",
                "value": ""
              },
              {
                "align": "center",
                "type": "TEXT_LABEL_VIEW",
                "value": "Hot Water Availability"
              },
              {
                "align": "center",
                "name": "@HOTWATER",
                "title": "Hot Water Availability",
                "type": "SINGLE_IMAGE_VIEW",
                "value": "ic_tank_hundread_percent_v2.png"
              }
            ],
            "@CONNECTED": true,
            "@DRACTIVE": {
              "constraints": {
                "dialog": [
                  {
                    "message": "This should not impact the water temperature in your home. Do you want to opt out for this event ?",
                    "title": "Tank temperature has been changed in response to a Utility Load Control event",
                    "value": 1
                  }
                ]
              },
              "value": ""
            },
            "@ENABLED": {
              "constraints": {
                "enumText": [
                  "Disabled",
                  "Enabled"
                ],
                "enumTextIcon": [
                  "ic_device_off.png",
                  "ic_enabled.png"
                ],
                "lowerLimit": 0,
                "upperLimit": 1
              },
              "status": "Enabled",
              "value": 1
            },
            "@HOTWATER": "ic_tank_hundread_percent_v2.png",
            "@LEAKINSTALLED": {
              "constraints": {
                "align": "center",
                "bgcolor": "#11ab00",
                "enumText": [
                  "No",
                  "Yes"
                ],
                "enumTextIcon": [],
                "fontcolor": "#000000",
                "lowerLimit": 0,
                "upperLimit": 1
              },
              "status": "",
              "title": "Leak sensor connected",
              "value": 1
            },
            "@NAME": {
              "constraints": {
                "stringLength": 64
              },
              "value": "Gladiator Water Heater"
            },
            "@OVERRIDE": {
              "constraints": {
                "bgcolor": "#FFFF00",
                "fontcolor": "#000000",
                "icon": "ic_high_level_alert.png"
              },
              "status": "",
              "value": ""
            },
            "@OVERRIDESTATUS": "",
            "@RESUME": false,
            "@RUNNING": "",
            "@SCHEDULE": false,
            "@SCHEDULERESUME": "",
            "@SCHEDULESTATUS": "",
            "@SETPOINT": {
              "constraints": {
                "error": [],
                "isConversion": true,
                "lowerLimit": 110,
                "unit": 1,
                "upperLimit": 140,
                "warning": [
                  {
                    "message": "CAUTION HOT WATER. Contact may cause serious burns to skin",
                    "value": 121
                  }
                ]
              },
              "value": 120
            },
            "@STATUS": "Enabled",
            "@TANK": {
              "constraints": {
                "green": 55,
                "orange": 25,
                "red": 20
              },
              "status": "Element operating normally",
              "value": 100
            },
            "@TCONFIG": [
              {
                "align": "center",
                "name": "@OVERRIDESTATUS",
                "type": "TEXT_LABEL_VIEW",
                "value": ""
              },
              {
                "align": "center",
                "name": "@RUNNING",
                "type": "TEXT_LABEL_VIEW",
                "value": ""
              }
            ],
            "@TYPE": "hotspringWaterHeater",
            "@VACATION": false,
            "@VALVE": {
              "constraints": {
                "dialog": [
                  {
                    "message": "Closing the shut off valve will disable the water heater",
                    "title": "Closing Valve",
                    "value": 0
                  }
                ],
                "enumText": [
                  "Open",
                  "Close"
                ],
                "enumTextIcon": [],
                "error": [],
                "lowerLimit": 0,
                "upperLimit": 1
              },
              "status": "Open",
              "value": 0
            },
            "@VALVESTATUS": {
              "constraints": {
                "align": "center",
                "bgcolor": "#11ab00",
                "fontcolor": "#000000"
              },
              "status": "",
              "title": "Shut-OFF Valve - Open",
              "value": 1
            },
            "actions": [
              "waterheaterScheduleView",
              "networkSettings",
              "waterheaterUsageReportView",
              "waterheaterHealthView"
            ],
            "device_name": "123456789",
            "device_type": "WH",
            "serial_number": "MY_SERIAL"
          }
        ],
        "location_id": "976ett7c-1686-4559-b9f0-5715gg1d2a26"
      }
    ]
  },
  "success": true,
  "logs": ""
}
appleguru commented 4 years ago

Here's mine:

{
   "results":{
      "locations":[
         {
            "@AWAY":false,
            "@AWAYCONFIG":false,
            "@LOCATION_INFO":"Somewhere, USA",
            "@LOCATION_NAME":"Home",
            "@LOCATION_STATUS":"I'm Home",
            "@VACATION":false,
            "@VACATIONCONFIG":false,
            "@WEATHER":"41°",
            "@WEATHER_F":41,
            "@WEATHER_I":"clearn.png",
            "equiptments":[
               {
                  "@ACTIVE":true,
                  "@ALERTCOUNT":0,
                  "@AWAY":false,
                  "@AWAYCONFIG":false,
                  "@AWAY_MSG":"",
                  "@BCONFIG":[
                     {
                        "align":"center",
                        "name":"@SCHEDULESTATUS",
                        "type":"TEXT_LABEL_VIEW",
                        "value":""
                     },
                     {
                        "name":"@SCHEDULERESUME",
                        "title":"Resume",
                        "type":"BUTTON_VIEW",
                        "value":""
                     },
                     {
                        "align":"center",
                        "type":"TEXT_LABEL_VIEW",
                        "value":"Hot Water Availability"
                     },
                     {
                        "align":"center",
                        "name":"@HOTWATER",
                        "title":"Hot Water Availability",
                        "type":"SINGLE_IMAGE_VIEW",
                        "value":"ic_tank_hundread_percent_v2.png"
                     }
                  ],
                  "@COMBUSTION":{
                     "constraints":{
                        "formatDecimal":1,
                        "green":55,
                        "lowerLimit":0,
                        "orange":25,
                        "red":20,
                        "units":"HRS",
                        "upperLimit":10000000
                     },
                     "status":"Compressor life is normal",
                     "value":100
                  },
                  "@CONNECTED":true,
                  "@DRACTIVE":{
                     "constraints":{
                        "dialog":[
                           {
                              "message":"This should not impact the water temperature in your home. Do you want to opt out for this event ?",
                              "title":"Tank temperature has been changed in response to a Utility Load Control event",
                              "value":1
                           }
                        ]
                     },
                     "value":""
                  },
                  "@DRESOVER":{
                     "constraints":{
                        "enumText":[
                           "false",
                           "true "
                        ],
                        "enumTextIcon":[

                        ],
                        "lowerLimit":0,
                        "upperLimit":1
                     },
                     "status":"false",
                     "value":0
                  },
                  "@ENABLED":{
                     "constraints":{
                        "enumText":[
                           "Disabled",
                           "Enabled "
                        ],
                        "enumTextIcon":[
                           "ic_device_off.png",
                           "ic_enabled.png"
                        ],
                        "lowerLimit":0,
                        "upperLimit":1
                     },
                     "status":"Enabled ",
                     "value":1
                  },
                  "@HOTWATER":"ic_tank_hundread_percent_v2.png",
                  "@JA13STATUS":"",
                  "@LEAKINSTALLED":{
                     "constraints":{
                        "align":"center",
                        "bgcolor":"#bec2bf",
                        "enumText":[
                           "No ",
                           "Yes"
                        ],
                        "enumTextIcon":[

                        ],
                        "fontcolor":"#000000",
                        "lowerLimit":0,
                        "upperLimit":1
                     },
                     "status":"",
                     "title":"Leak sensor not installed",
                     "value":0
                  },
                  "@MODE":{
                     "constraints":{
                        "enumText":[
                           "Off           ",
                           "Energy Saver  ",
                           "Heat Pump     ",
                           "High Demand   ",
                           "Electric      ",
                           "Vacation      "
                        ],
                        "enumTextIcon":[
                           "ic_device_off.png",
                           "ic_energy_saver.png",
                           "ic_heat_pump.png",
                           "ic_high_demand.png",
                           "ic_electric.png",
                           "ic_vacation.png"
                        ],
                        "lowerLimit":0,
                        "upperLimit":5
                     },
                     "status":"Energy Saver  ",
                     "value":1
                  },
                  "@MODECONFIG":{
                     "constraints":{
                        "bgcolor":"#008000",
                        "enumText":[
                           "Off           ",
                           "Energy Saver  ",
                           "Heat Pump     ",
                           "High Demand   ",
                           "Electric      ",
                           "Vacation      "
                        ],
                        "enumTextIcon":[

                        ],
                        "fontcolor":"#FFFFFF",
                        "icon":"ic_energy_saver",
                        "lowerLimit":0,
                        "upperLimit":5
                     },
                     "status":"",
                     "value":""
                  },
                  "@MODEIMAGE":"ic_energy_saver.png",
                  "@NAME":{
                     "constraints":{
                        "stringLength":64
                     },
                     "value":"Heat Pump Water Heater"
                  },
                  "@OVERRIDE":{
                     "constraints":{
                        "bgcolor":"#FFFF00",
                        "fontcolor":"#000000",
                        "icon":"ic_high_level_alert.png"
                     },
                     "status":"",
                     "value":""
                  },
                  "@OVERRIDESTATUS":"",
                  "@RESUME":false,
                  "@RUNNING":"",
                  "@SCHEDULE":false,
                  "@SCHEDULERESUME":"",
                  "@SCHEDULESTATUS":"",
                  "@SETPOINT":{
                     "constraints":{
                        "error":[

                        ],
                        "formatDecimal":0,
                        "isConversion":true,
                        "lowerLimit":110,
                        "units":"deg F",
                        "upperLimit":140,
                        "warning":[
                           {
                              "message":"CAUTION HOT WATER. Contact may cause serious burns to skin",
                              "value":121
                           }
                        ]
                     },
                     "value":120
                  },
                  "@STATUS":"Enabled ",
                  "@TANK":{
                     "constraints":{
                        "green":40,
                        "orange":30,
                        "red":30
                     },
                     "status":"Element operating normally",
                     "value":100
                  },
                  "@TCONFIG":[
                     {
                        "align":"center",
                        "name":"@MODEIMAGE",
                        "type":"SINGLE_IMAGE_VIEW",
                        "value":"ic_energy_saver.png"
                     },
                     {
                        "align":"center",
                        "name":"@RUNNING",
                        "type":"TEXT_LABEL_VIEW",
                        "value":""
                     },
                     {
                        "align":"center",
                        "name":"@OVERRIDESTATUS",
                        "type":"TEXT_LABEL_VIEW",
                        "value":""
                     }
                  ],
                  "@TYPE":"heatpumpWaterHeaterGen5",
                  "@VACATION":false,
                  "@VALVE":{
                     "constraints":{
                        "dialog":[
                           {
                              "message":"Closing the shut off valve will disable the water heater",
                              "title":"Closing Valve",
                              "value":0
                           }
                        ],
                        "error":[

                        ]
                     },
                     "value":""
                  },
                  "@VALVESTATUS":{
                     "constraints":{
                        "align":"center",
                        "bgcolor":"#bec2bf",
                        "fontcolor":"#000000"
                     },
                     "status":"",
                     "title":"Shut-OFF Valve not installed",
                     "value":1
                  },
                  "actions":[
                     "waterheaterScheduleView",
                     "networkSettings",
                     "waterheaterUsageReportView",
                     "waterheaterHealthView"
                  ],
                  "device_name":"123456789",
                  "device_type":"WH",
                  "serial_number":"MY_SERIAL"
               }
            ],
            "location_id":"MY_LOCATION_ID"
         }
      ]
   },
   "success":true,
   "logs":""
}
vangorra commented 11 months ago

After struggling with this water heater, it was much easier to buy a cheap device and use Econet esphome.