Growatt Integration - Solar Assistant

@Anders57S after my post I realised that I forgot to mention I have a Pi running solar assistant via the RS485 port this is my method of control.
I also noted that the growatt inverter \ solar assistant had a bug which means that you cannot select battery first, if you select Grid First in the automation it selects battery first on the actual inverter. Took me a while to figure this out and you have to change the output source priority at the same time otherwise it just doesn’t do what you want. I ended up with TOU charging set from 00:01-23:59 and my automation overrides it. So far so good I can boost my charge overnight during octopus cheap rate and I’m also dragging the solar forcast off solcast which changes the amount of overnight charge so if its a nice sunny day then it won’t run the boost charge. Now say as I approach peak rate I also have a boost button I can turn on so that when i actually reach peak rate my battery will be topped up.

alias: Charge Growatt Battery based on the helper times
description: ""
trigger:
  - platform: state
    entity_id:
      - binary_sensor.growatt_battery_charge_schedule
condition: []
action:
  - choose:
      - conditions:
          - condition: state
            entity_id: binary_sensor.growatt_battery_charge_schedule
            state: "on"
            for:
              hours: 0
              minutes: 0
              seconds: 0
        sequence:
          - service: select.select_option
            target:
              entity_id: null
            data:
              option: Enabled
          - service: select.select_option
            target:
              entity_id:
                - select.battery_first_grid_charge
            data:
              option: Enabled
          - service: select.select_option
            data:
              option: Grid first
            target:
              entity_id: select.output_source_priority
          - service: input_text.set_value
            data:
              value: Scheduled Charge
            target:
              entity_id:
                - input_text.battery_status
      - conditions:
          - condition: state
            entity_id: binary_sensor.growatt_battery_charge_schedule
            state: "off"
            for:
              hours: 0
              minutes: 0
              seconds: 0
        sequence:
          - service: select.select_option
            target:
              entity_id:
                - select.battery_first_grid_charge
            data:
              option: Disabled
          - service: select.select_option
            data:
              option: Load first
            target:
              entity_id: select.output_source_priority
          - service: input_text.set_value
            data:
              value: Scheduled Ended
            target:
              entity_id:
                - input_text.battery_status
mode: single
1 Like

I may have solved it a bit primitive but I have not much knowledge in programming, so I use the GUI options and when needed changes a single value or formatting in the yaml-files :slight_smile:

(edit: I also use HA via SA for control and monitoring. In addition I have ShineWifi-X installed and with full functionality using Growatt eco system)

My approach has been to identify basic scenarios and then set a basic schedule in Growatt Server. The scenarios is mostly uniform so it works good enough for now.

  1. Charge with AC night
  2. Self consumption at morning hours
  3. Sell before lunch
  4. Charge with AC at afternoon
  5. Self consumption at evening

Then I have matches automations in HA within those prerequisites.
For instance (I have some more conditions but for exemplifying)
scenario 1, charge only if cheap
Scenario 2: Only if expensive and solar production is low (sun hasn’t risen yet)
Scenario 3: only if expensive and SOC is sufficient and that estimated production for the day is high enough.
Scenario 4: only if cheap and if SOC is low and estimated production is low.

if conditions aren’t met, I will revert to Load First.

My settings are that Growatt controls between full hour and to one minute before. For instance 08:00-11:59 and the automations is conditioned for one minute less in each end (08:01-11:58) so that there is no ambiguity.

This way it seems to work for me. As I mentioned earlier I can go from “valid priority mode” to and from Load First, but I cannot jump between Grid First and Battery First since one of them is “master” according to the set schedule in Growatt Server.

I would have hoped that there were som trick to fool Growatt Server, like have all set to 00:00-00:00 and enabled, but then I get time conflicts in Growatt GUI.

I dont know it has to do with latest beta (2023-03-17 that fixed some bugs in mqtt) or if I found the golden egg :slight_smile:

I tested a lot of combos and found that if I set Battery First to be active from 00:00-23:59, then I can jump between all Priority Modes as i desire. Makes it a lot easier :slight_smile:

UPDATE:
I think I found the issue - I did not have “change settings ALLOWED” enabled in MQTT settings on SA originally. Now I have enabled it and it looks like it works!!!

ORIGINAL MESSAGE BELOW:
guys, I am not sure if I am doing things right…

I have automation to check IO and once IO slot is set to ON, it should trigger and change growatt to battery first. I am using solar asssistant via rs485 connected to my raspberry pi. mqtt works and I can see all entities on Home assistant.

The automation sees the trigger and runs.it shows that option 1 is selected (Change growatt work mode to battery first).
but this change is actually not reflected in growatt settings and I still see that battery is being discharged rather than charged.

can anyone suggest, what am I doing wrong here or what I am missing?

image


(here I set schedule manually, however it does not care even if scheduling is set to 00;00 - 23:59

Hi, ich habe eine Growatt 1500TL-X ohne Batterie mit Solar Assistant im einem HA drin.
Nun würde ich in gerne Steuern für eine Nulleinspeisung, kann Mir da hier jemand helfen,
beim einstellen. Wäre Klasse ! :+1:

Hi, sorry to bump and old thread but it seems to fit my need perfectly, I think.
First of all I am still very much a HA rookie and this is my first attempt at an automation.
I have an SPH 6000 inverter with panels and 6.5kWh battery.
I’m getting a Zappi EV charger installed soon to charge my soon to be delivered EV.
I plan to use Octopus Intelligent Go which give a cheap rate slot between 23:30 and 05:30 and other in half hour increments whenever there is excess power in the grid.
I don’t have IOG as yet so I don’t see the entity Octopus Intelligent Slot. I assume that will appear when a firs register and set up IOG?
@snu-snu-snu do you only have an automation for when intelligent slot switches on? How does it handle when the slot switches off? Is that taken care of by your Work Mode Schedule settings in SA?
My thought were to have one automation for when it switches on and another for when it switches off, or am I missing something?
Obviously I can’t try any of this out until I get my car and charger but any pointers and advice in preparation would be greatly appreciated.