Working YAML for my Growatt MOD 4000TL3-XH used with the https://github.com/wills106/homeassistant-solax-modbus
You can flash your module either by USb, or using a TTL converter. Just make sure GPIO0 is grounded during boot:
Thanks to rosenrot00 for the ESPHome2ModBus convertor https://github.com/rosenrot00/esphome_modbus_bridge