Support Select entities and create seperate devices for each "LP" and more...
Bascht74 opened this issue · comments
Hi,
I tried the current version of your HA integration and is very nice and easy to install. Very nice!
I have some suggestions for the next versions... (sorted by importance, e.g. 4-7 are more like "nice to have")
- If you have two or more "LP" it makes more sense to separate the entities for the two LP in different devices. So one device for each LP (
OpenWB {name} (LP1)
,OpenWB {name} (LP2)
a.s.o{name}
fromopenWB/lp/{n}/strChargePointName
). The unique entities (that exists only once on the openWB controller) could be bound to a "general" device named e.g.OpenWB Controller
(e.g. sensor.openwb_leistungsabgabe_haus_pv). Theentities sensor.openwb_cp{n}_ladepunktsbezeichnung
could be deleted as they are not needed anymore... - Use the "Select" entity instead of the sensor entity for
openwb_lademodus
, so you could get rid of the servicechange_global_charge_mode
. If you use number entities and select entities you could substitute every service that is needed right now and the entities are way more usable for users. - The entities with "Wh" sould be in "kWh" (e.g.
openwb_energie_erzeugt_haus
, this is more readable and uses the same unit as energy meters and the LP itself (e.g.sensor.openwb_cp1_geladene_energie
andsensor.openwb_cp1_ladezahler
uses kWh). - Instead of "
true
" and "false
" you should use "on
" and "off
" for the binary sensors, e.G.sensor.openwb_cp1_energiemengenbegrenzung_aktiv_modus_sofortladen
should be "on
" or "off
". If you use "on
" and "off
", HA translates the state to the language set in HA. It would be better as well to usebinary sensors
instead ofsensors
for those entities withtrue
/false
. - The IP-Address entity could be disabled or removed because you used the "visit" function.
- You could read the ip address from
openWB/system/IpAddress
so it is not needed for setup and could be read at start of the integration. - The active LP could be read through a loop into
openWB/lp/{n}/
and checkboolChargePointConfigured
. If you combine 6+7 only one parameter is needed for setup. The check for LP could be at integration start so that you can add new devices if a user installs e.g. a second LP. - show openWB/system/Version as firmware version like:
Thx again for the integration. I hope that constructive feedback is welcome...
Sebastian
Thank you very much for your feedback, Sebastian!
I'll take this into consideration when I start the next round of development. Due to the fact that I'm still waiting for my openWB to be shipped, my motivation to improve the code is not so high at the moment. So, this will take some time.
If you want to contribute in the meantime, feel free to make a PR which I'm happy to include.
Andreas
Just as a side note: my openWB is finally here and HA integration is working together but i am waiting for my BEV and so i may can contribute by testing or so.