ngardiner / TWCManager

Control power delivered by a Tesla Wall Charger using two wires screwed into its RS-485 terminals.
The Unlicense
131 stars 55 forks source link

Not tripping circuit-brakers use-case #206

Open tjikkun opened 3 years ago

tjikkun commented 3 years ago

My use case for TWCManger is as follows: The house has 3x25A grid connection. The TWC is wired with 3x16A. What I would like, is that when one of the 3 phases exceeds 25A, the TWC is throttled. Right now I hacked this together, where I have a value in HomeAssistant:

value_template: "{{ (states('sensor.power_consumption_phase_l1') |float, states('sensor.power_consumption_phase_l2') | float, states('sensor.power_consumption_phase_l3') | float ) | max * 1000 * 3 - states('sensor.twcmanager_7609_charger_load_w') | float }}"

So this gets the max kW value of the 3 phases, converts it to W and multiplies by 3, so I fake powerconsumption to be equal on all phases, so I never overload one of the phases. then I subtract the charger load from that. Then as power_generation I have set it to 3*25*230W

This works for me, if only one phase has non-charger-load of 11A, TWC get's throttled to 14A. If all phases have non-charger-load of, say, 8A, for a total of 24A TWC continues at 16A, because I take the max of the 3 phases.

But still, this feels very hacky to me. Is there currently a better way to do it with TWCManager? If not, would a contribution like that be accepted? Any suggestions?

mikey4321 commented 3 years ago

A dummy consumption option as you described could also be useful for some users, depending on how their excess solar energy is metered.

I am fortunate that my electricity provider calculates my net import/export across all three phases, (eg house air conditinoer on phase 1 can draw more power than the solar is putting on phase 1 and i'll still get a credit if the other two phases are exporting more.)

If your utility is nasty and does net metering per phase, then your "hack" would cater for this as well which could save money or allow proper green-energy-only charging.