Closed bbijoch closed 2 years ago
Thanks! I don't have the ORP sensor so I didn't know what properties in the json to look for.
However I'd expect the relays to be working already, as you can toggle them on and off and read their state. Are you by any chance referring to the binary inputs instead?
For relays you have only On/Off states. There is no Auto “A”. My pump is set to auto and it is working according to time schedule. It would be great to if you could change this toggle button to something 3-states, maybe “input select”.
I understand.
That one is tricky. For most of the things someone might want to do with relays from home assistant I think it makes more sense for them to be switches. You want to turn them on or off. And even if you have a time schedule, the state of the relay lets you know if it's working or not (because your time schedule turnet it on).
If it's set to AUTO you don't know if right now is on or off. I suspect this is better modelled as a separate switch. Something like pool.relay_pump_auto: ON/OFF
. That way you can know both it's current state and it's auto state. I'll investigate it.
Also, and this might just be my personal preference, once I have control of the relay from Homeassistant I prefer not to use the built in scheduler anymore. I can set a schedule in a nicer way from home assitant. And in fact I've set up one automation that turns it on only when I have excess solar production from my panels.
For now I'll start with the ORP sensor, that's less controversial.
I just added support for ORP and Free Chlorine in PPM in PyPoolstation. I now just have to update the integration to display that info.
I updated this integration with support for ORP and Chlorine sensors. I made some adjustements so if the chlorinator doesn't seem to have one of both of those sensors the integration doesn't even attempt to create sensors or target values for them.
Give it a try in HACS and let me know how it works.
ORP is working great. Thank you so much! I am waiting for 3-state relays :)
Could you please include ORP and relays states? I used your library pypoolstation to retrieve values from my poolstation.
mo - current ORP so - target ORP
mc - relay 1 operating mode: on(1)/off(0)/auto(A) mj - relay 2 operating mode: on(1)/off(0)/auto(A) mb - relay 3 operating mode: on(1)/off(0)/auto(A) mf - relay 4 operating mode: on(1)/off(0)/auto(A)
ac - relay 1 status on(1)/off(0) aj - relay 2 status on(1)/off(0) ab - relay 3 status on(1)/off(0) af - relay 4 status on(1)/off(0)
It would be great if you create "Input Select" control for those relays On/Off/Auto.
Thanks and great work btw.