ckarrie / homeassistant-oekofen

Oekofen HomeAssistant integration
7 stars 2 forks source link

Add solar collector parameters #5

Closed creadicted closed 1 year ago

creadicted commented 1 year ago

I have a solar collector with the following fields:

"sk1":{
  "L_koll_temp": 171,
  "L_spu": 419,
  "L_pump": 0,
  "L_state": 32,
  "L_statetext": "Differenz Kollektor-Speicher zu niedrig",
  "mode": 1,
  "cooling": 0,
  "spu_max": 800,
  "name": ""
},

I added the majority of the values in to the existing lists. I also added a NON_PUMP_BINARY_SENSORS_BY_DOMAIN section.

ckarrie commented 1 year ago

Nice, thank you, have to tested it? As far as I see, we need to add the sk_indexes to https://github.com/ckarrie/oekofen-api/blob/main/oekofen_api/__init__.py#L51 as well, otherwise it won't be recognised. Feel free to make a pull request, I'm quite busy until friday.

ckarrie commented 1 year ago

Could you provide a complete json from http://ipofyouroekofen:4321/PASSWORD/all? (important tailing ?) to see the possible values and a description?

creadicted commented 1 year ago

Nice, thank you, have to tested it? As far as I see, we need to add the sk_indexes to https://github.com/ckarrie/oekofen-api/blob/main/oekofen_api/__init__.py#L51 as well, otherwise it won't be recognised. Feel free to make a pull request, I'm quite busy until friday.

Yes, I tested it in my local version. The new values are picked up after I restart the device. Here is the sample json

 "sk1":{
  "sk_info":"solar circuit data",
  "L_koll_temp":{"val":473, "unit":"°C", "factor":0.1, "min":-32768, "max":32767},
  "L_spu":{"val":406, "unit":"°C", "factor":0.1, "min":-32768, "max":32767},
  "L_pump":{"val":40, "unit":"%", "factor":1, "min":0, "max":100},
  "L_state":{"val":0, "factor":1},
  "mode":{"val":1, "format":"0:Aus|1:Ein"},
  "cooling":{"val":0, "format":"0:Aus|1:Ökologisch|2:Ein"},
  "spu_max":{"val":800, "unit":"°C", "factor":0.1, "min":200, "max":900},
  "name":{"val":"", "length":20}
 },
ckarrie commented 1 year ago

nice, thank you for your contributions, I merged it

ckarrie commented 1 year ago

Changes crashes my Oekofen without sk domain as mentioned here, we need to add the domais to

wrote a quick fix

ckarrie commented 1 year ago

Hi @creadicted fyi I changed the sk{}.L_pump to a percentage (%) sensor instead of bool (on/off) in https://github.com/ckarrie/homeassistant-oekofen/commit/f1c4954519400ce4c24e2955577cdee0abf7d212 could you check if that is fine?