Skip to content

Many connection issues with Venus A v144/v147 #8

Description

@Jojo-A

Hi @MarstekEnergy,
as already mentioned in the HA core PR (home-assistant/core#156012 (comment)) I have many connection issues, that lead to flooding the error logs with these messages:

Logger: pymarstek.udp
Quelle: custom_components/marstek/coordinator.py:77
Integration: Marstek
Erstmals aufgetreten: 10:54:39 (83 Vorkommnisse)
Zuletzt protokolliert: 11:03:54

Request timeout: 192.168.0.117:30000
Send request to 192.168.0.117:30000: {"id": 7758, "method": "ES.GetMode", "params": {"id": 0}}
Send request to 192.168.0.117:30000: {"id": 7759, "method": "PV.GetStatus", "params": {"id": 0}}
Send request to 192.168.0.117:30000: {"id": 7760, "method": "ES.GetMode", "params": {"id": 0}}
Send request to 192.168.0.117:30000: {"id": 7761, "method": "PV.GetStatus", "params": {"id": 0}}

as well as

Logger: custom_components.marstek.coordinator
Quelle: custom_components/marstek/coordinator.py:102
Integration: Marstek
Erstmals aufgetreten: 10:55:29 (11 Vorkommnisse)
Zuletzt protokolliert: 11:03:39

No valid data received from device at 192.168.0.117 (device_mode=Unknown, soc=0, power=0) - connection failed
No valid data received from device at 192.168.0.117 (device_mode=Unknown, soc=14, power=0) - connection failed

and

Logger: custom_components.marstek.coordinator
Quelle: custom_components/marstek/coordinator.py:123
Integration: Marstek
Erstmals aufgetreten: 10:55:29 (11 Vorkommnisse)
Zuletzt protokolliert: 11:03:39

Device 192.168.0.117 status request failed: No valid data received from device at 192.168.0.117. Scanner will detect IP changes automatically

This leads to complete connection losses and for some reason the Venus A then "forgets" its configuration (output power settings, API setting,...) and gets permanently unresponsive.

This "feels" like the many API requests make the Venus' firmware crash and restart and it forgets the configs. But I might be wrong...

After changing the request delay and the timeouts, it works much more stable, although I still get thousands of errors per day.

Here is what I changed in the coordinator.py:

        try:
            # Use library method to get complete device status
            # Note: get_device_status catches exceptions internally and returns default values
            # So we need to check the returned data to detect failures
            device_status = await self.udp_client.get_device_status(
                current_ip,
                port=DEFAULT_UDP_PORT,
                #timeout=5.0,  # Increased timeout for device status requests
                timeout=10.0,  # Increased timeout for device status requests
                include_pv=True,
                #delay_between_requests=5.0,
                delay_between_requests=60.0,
            )

As said, this does NOT FIX the communication issue. It just reduces the errors to a level where the Venus does not become permanently unresponsive (reduction from thousands of errors per hour to only a few thousands per day).

Please let me know if I can provide additional data what might help you to trace down that issue!

Greetings and thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions