Meross MSG100 unreliable state updating

Sometime after updating Meross Integration to v5.4.1 and Home Assistant Core to 2024.12.x the garage cover state has been behaving erratically: sometimes it changes state once (i.e. closed to opening), but not a second time (opening to open). This goes in both directions (i.e. when opening and closing), but is not reliably reproducible - sometimes it works fine.

Any ideas on where to start with this? Below are the diagnostics of an open/close cycle.

{
  "home_assistant": {
    "installation_type": "Home Assistant OS",
    "version": "2024.12.3",
    "dev": false,
    "hassio": true,
    "virtualenv": false,
    "python_version": "3.13.0",
    "docker": true,
    "arch": "x86_64",
    "timezone": "Europe/Rome",
    "os_name": "Linux",
    "os_version": "6.6.63-haos",
    "supervisor": "2024.11.4",
    "host_os": "Home Assistant OS 14.0",
    "docker_version": "27.2.0",
    "chassis": "vm",
    "run_as_root": true
  },
  "custom_components": {
    "hacs": {
      "documentation": "https://hacs.xyz/docs/configuration/start",
      "version": "2.0.1",
      "requirements": [
        "aiogithubapi>=22.10.1"
      ]
    },
    "gtfs2": {
      "documentation": "https://github.com/vingerha/gtfs2/wiki",
      "version": "0.4",
      "requirements": [
        "pygtfs==0.1.9",
        "gtfs-realtime-bindings==1.0.0",
        "protobuf"
      ]
    },
    "sonoff": {
      "documentation": "https://github.com/AlexxIT/SonoffLAN",
      "version": "3.8.1",
      "requirements": [
        "pycryptodome>=3.6.6"
      ]
    },
    "sinapsi_alfa": {
      "documentation": "https://github.com/alexdelprete/ha-sinapsi-alfa",
      "version": "0.2.4",
      "requirements": [
        "pymodbus>=3.5.4",
        "getmac>=0.9.4"
      ]
    },
    "tapo_control": {
      "documentation": "https://github.com/JurajNyiri/HomeAssistant-Tapo-Control",
      "version": "6.0.1",
      "requirements": [
        "pytapo==3.3.37"
      ]
    },
    "ecowitt": {
      "documentation": "https://www.home-assistant.io/integrations/ecowitt",
      "version": "0.7",
      "requirements": [
        "pyecowitt==0.14"
      ]
    },
    "hon": {
      "documentation": "https://github.com/Andre0512/hon/",
      "version": "0.14.0",
      "requirements": [
        "pyhOn==0.17.5"
      ]
    },
    "flightradar24": {
      "documentation": "https://github.com/AlexandrErohin/home-assistant-flightradar24",
      "version": "v1.23.0",
      "requirements": [
        "FlightRadarAPI==1.3.34",
        "pycountry==23.12.11"
      ]
    },
    "dynamic_energy_cost": {
      "documentation": "https://github.com/martinarva/dynamic_energy_cost/",
      "version": "0.5.0",
      "requirements": []
    },
    "icloud3": {
      "documentation": "https://gcobb321.github.io/icloud3_v3_docs/#/",
      "version": "3.1.3",
      "requirements": [
        "srp"
      ]
    },
    "auto_backup": {
      "documentation": "https://github.com/jcwillox/hass-auto-backup",
      "version": "1.5.3",
      "requirements": []
    },
    "meross_lan": {
      "documentation": "https://github.com/krahabb/meross_lan",
      "version": "5.4.1",
      "requirements": []
    },
    "satellitetracker": {
      "documentation": "https://github.com/djtimca/hasatellitetracker",
      "version": "0.0.8",
      "requirements": [
        "n2yoasync==0.0.6"
      ]
    },
    "dpc": {
      "documentation": "https://github.com/caiosweet/Home-Assistant-custom-components-DPC-Alert",
      "version": "2023.10.0",
      "requirements": []
    },
    "powercalc": {
      "documentation": "https://docs.powercalc.nl",
      "version": "v1.16.5",
      "requirements": [
        "numpy>=1.21.1"
      ]
    }
  },
  "integration_manifest": {
    "domain": "meross_lan",
    "name": "Meross LAN",
    "after_dependencies": [
      "mqtt",
      "dhcp",
      "recorder",
      "persistent_notification"
    ],
    "codeowners": [
      "krahabb"
    ],
    "config_flow": true,
    "dhcp": [
      {
        "hostname": "*",
        "macaddress": "48E1E9*"
      },
      {
        "hostname": "*",
        "macaddress": "C4E7AE*"
      },
      {
        "hostname": "*",
        "macaddress": "34298F1*"
      },
      {
        "registered_devices": true
      }
    ],
    "documentation": "https://github.com/krahabb/meross_lan",
    "integration_type": "hub",
    "iot_class": "local_polling",
    "issue_tracker": "https://github.com/krahabb/meross_lan/issues",
    "loggers": [
      "custom_components.meross_lan"
    ],
    "mqtt": [
      "/appliance/+/publish"
    ],
    "requirements": [],
    "version": "5.4.1",
    "is_built_in": false,
    "overwrites_built_in": false
  },
  "setup_times": {
    "null": {
      "setup": 3.507599467411637e-05
    },
    "01J277F0TT5XAYKQ41ED4QT84F": {
      "wait_import_platforms": -6.875203689560294e-05,
      "config_entry_setup": 0.03045384999131784
    },
    "01J277F4KHAG06DS90AHK5XJZY": {
      "wait_import_platforms": -0.00011721596820279956,
      "config_entry_setup": 0.13730899704387411
    }
  },
  "data": {
    "device_id": "###############################0",
    "host": "##############0",
    "key": "###############################0",
    "payload": {
      "ability": {
        "Appliance.Config.Key": {},
        "Appliance.Config.Trace": {},
        "Appliance.Config.Wifi": {},
        "Appliance.Config.WifiList": {},
        "Appliance.Config.WifiX": {},
        "Appliance.Control.Bind": {},
        "Appliance.Control.Multiple": {
          "maxCmdNum": 5
        },
        "Appliance.Control.TimerX": {
          "notify": [
            "Appliance.GarageDoor.State"
          ],
          "sunOffsetSupport": 1
        },
        "Appliance.Control.ToggleX": {},
        "Appliance.Control.TriggerX": {
          "notify": [
            "Appliance.GarageDoor.State"
          ]
        },
        "Appliance.Control.Unbind": {},
        "Appliance.Control.Upgrade": {},
        "Appliance.Digest.TimerX": {},
        "Appliance.Digest.TriggerX": {},
        "Appliance.GarageDoor.Config": {},
        "Appliance.GarageDoor.State": {},
        "Appliance.System.Ability": {},
        "Appliance.System.All": {},
        "Appliance.System.Clock": {},
        "Appliance.System.DNDMode": {},
        "Appliance.System.Debug": {},
        "Appliance.System.Firmware": {},
        "Appliance.System.Hardware": {},
        "Appliance.System.Online": {},
        "Appliance.System.Position": {},
        "Appliance.System.Report": {},
        "Appliance.System.Runtime": {},
        "Appliance.System.Time": {}
      },
      "all": {
        "system": {
          "hardware": {
            "type": "msg100",
            "subType": "us",
            "version": "3.5.0",
            "chipType": "mt7682",
            "uuid": "###############################0",
            "macAddress": "################0"
          },
          "firmware": {
            "version": "3.2.7",
            "compileTime": "2022/08/30 12:14:18 GMT +08:00",
            "encrypt": 1,
            "wifiMac": "################0",
            "innerIp": "##############0",
            "server": "###################0",
            "port": "@0",
            "userId": "@0"
          },
          "time": {
            "timestamp": 1734360722,
            "timezone": "Europe/Rome",
            "timeRule": [
              [
                1585443600,
                7200,
                1
              ],
              [
                1603587600,
                3600,
                0
              ],
              [
                1616893200,
                7200,
                1
              ],
              [
                1635642000,
                3600,
                0
              ],
              [
                1648342800,
                7200,
                1
              ],
              [
                1667091600,
                3600,
                0
              ],
              [
                1679792400,
                7200,
                1
              ],
              [
                1698541200,
                3600,
                0
              ],
              [
                1711846800,
                7200,
                1
              ],
              [
                1729990800,
                3600,
                0
              ],
              [
                1743296400,
                7200,
                1
              ],
              [
                1761440400,
                3600,
                0
              ],
              [
                1774746000,
                7200,
                1
              ],
              [
                1792890000,
                3600,
                0
              ],
              [
                1806195600,
                7200,
                1
              ],
              [
                1824944400,
                3600,
                0
              ],
              [
                1837645200,
                7200,
                1
              ],
              [
                1856394000,
                3600,
                0
              ],
              [
                1869094800,
                7200,
                1
              ],
              [
                1887843600,
                3600,
                0
              ]
            ]
          },
          "online": {
            "status": 1
          }
        },
        "digest": {
          "togglex": [
            {
              "channel": 0,
              "onoff": 1,
              "lmTime": 0
            }
          ],
          "triggerx": [
            {
              "channel": 0,
              "id": "1111111111111111",
              "count": 1
            }
          ],
          "timerx": [
            {
              "channel": 0,
              "id": "1111111111111111",
              "count": 1
            }
          ],
          "garageDoor": [
            {
              "channel": 0,
              "open": 1,
              "lmTime": 1734256237
            }
          ]
        }
      }
    },
    "timestamp": 1732723971.1854968,
    "device": {
      "class": "MerossDevice",
      "conf_protocol": "auto",
      "pref_protocol": "http",
      "curr_protocol": "http",
      "polling_period": 30,
      "device_response_size_min": 2680,
      "device_response_size_max": 5000,
      "MQTT": {
        "cloud_profile": true,
        "locally_active": false,
        "mqtt_connection": true,
        "mqtt_connected": true,
        "mqtt_publish": false,
        "mqtt_active": false
      },
      "HTTP": {
        "http": true,
        "http_active": true
      },
      "namespace_handlers": {
        "Appliance.System.All": {
          "lastrequest": 1734360722.8728766,
          "lastresponse": 1734360722.9446642,
          "polling_epoch_next": 1734361017.9446642,
          "polling_strategy": "async_poll_all"
        },
        "Appliance.System.DNDMode": {
          "lastrequest": 1734360752.9645412,
          "lastresponse": 1734360753.0331788,
          "polling_epoch_next": 1734361053.0331788,
          "polling_strategy": "async_poll_lazy"
        },
        "Appliance.System.Runtime": {
          "lastrequest": 1734360752.9645445,
          "lastresponse": 1734360753.0331788,
          "polling_epoch_next": 1734361053.0331788,
          "polling_strategy": "async_poll_lazy"
        },
        "Appliance.GarageDoor.State": {
          "lastrequest": 1734360752.9644797,
          "lastresponse": 1734360753.0331788,
          "polling_epoch_next": 1734361053.0331788,
          "polling_strategy": null
        },
        "Appliance.Control.ToggleX": {
          "lastrequest": 1734360752.9644797,
          "lastresponse": 1734360753.0331788,
          "polling_epoch_next": 1734361053.0331788,
          "polling_strategy": null
        },
        "Appliance.GarageDoor.Config": {
          "lastrequest": 1734360752.9645462,
          "lastresponse": 1734360753.0331788,
          "polling_epoch_next": 1734361053.0331788,
          "polling_strategy": "async_poll_lazy"
        },
        "Appliance.System.Debug": {
          "lastrequest": 0.0,
          "lastresponse": 1734333216.7388337,
          "polling_epoch_next": 1734333216.7388337,
          "polling_strategy": null
        }
      },
      "namespace_pushes": {},
      "device_info": {
        "uuid": "###############################0",
        "onlineStatus": 1,
        "devName": "Garage",
        "devIconId": "device039_un",
        "bindTime": 1593871028,
        "deviceType": "msg100",
        "subType": "us",
        "channels": [
          {}
        ],
        "region": "eu",
        "fmwareVersion": "3.2.7",
        "hdwareVersion": "3.0.0",
        "userDevIcon": "",
        "iconType": 1,
        "domain": "###################0",
        "reservedDomain": "###################0",
        "hardwareCapabilities": []
      }
    },
    "trace": [
      [
        "time",
        "rxtx",
        "protocol",
        "method",
        "namespace",
        "data"
      ],
      [
        "2024/12/16 - 15:52:50",
        "",
        "auto",
        "GETACK",
        "Appliance.System.All",
        {
          "system": {
            "hardware": {
              "type": "msg100",
              "subType": "us",
              "version": "3.5.0",
              "chipType": "mt7682",
              "uuid": "###############################0",
              "macAddress": "################0"
            },
            "firmware": {
              "version": "3.2.7",
              "compileTime": "2022/08/30 12:14:18 GMT +08:00",
              "encrypt": 1,
              "wifiMac": "################0",
              "innerIp": "##############0",
              "server": "###################0",
              "port": "@0",
              "userId": "@0"
            },
            "time": {
              "timestamp": 1734360722,
              "timezone": "Europe/Rome",
              "timeRule": [
                [
                  1585443600,
                  7200,
                  1
                ],
                [
                  1603587600,
                  3600,
                  0
                ],
                [
                  1616893200,
                  7200,
                  1
                ],
                [
                  1635642000,
                  3600,
                  0
                ],
                [
                  1648342800,
                  7200,
                  1
                ],
                [
                  1667091600,
                  3600,
                  0
                ],
                [
                  1679792400,
                  7200,
                  1
                ],
                [
                  1698541200,
                  3600,
                  0
                ],
                [
                  1711846800,
                  7200,
                  1
                ],
                [
                  1729990800,
                  3600,
                  0
                ],
                [
                  1743296400,
                  7200,
                  1
                ],
                [
                  1761440400,
                  3600,
                  0
                ],
                [
                  1774746000,
                  7200,
                  1
                ],
                [
                  1792890000,
                  3600,
                  0
                ],
                [
                  1806195600,
                  7200,
                  1
                ],
                [
                  1824944400,
                  3600,
                  0
                ],
                [
                  1837645200,
                  7200,
                  1
                ],
                [
                  1856394000,
                  3600,
                  0
                ],
                [
                  1869094800,
                  7200,
                  1
                ],
                [
                  1887843600,
                  3600,
                  0
                ]
              ]
            },
            "online": {
              "status": 1
            }
          },
          "digest": {
            "togglex": [
              {
                "channel": 0,
                "onoff": 1,
                "lmTime": 0
              }
            ],
            "triggerx": [
              {
                "channel": 0,
                "id": "1111111111111111",
                "count": 1
              }
            ],
            "timerx": [
              {
                "channel": 0,
                "id": "1111111111111111",
                "count": 1
              }
            ],
            "garageDoor": [
              {
                "channel": 0,
                "open": 1,
                "lmTime": 1734256237
              }
            ]
          }
        }
      ],
      [
        "2024/12/16 - 15:52:50",
        "",
        "auto",
        "GETACK",
        "Appliance.System.Ability",
        {
          "Appliance.Config.Key": {},
          "Appliance.Config.Trace": {},
          "Appliance.Config.Wifi": {},
          "Appliance.Config.WifiList": {},
          "Appliance.Config.WifiX": {},
          "Appliance.Control.Bind": {},
          "Appliance.Control.Multiple": {
            "maxCmdNum": 5
          },
          "Appliance.Control.TimerX": {
            "notify": [
              "Appliance.GarageDoor.State"
            ],
            "sunOffsetSupport": 1
          },
          "Appliance.Control.ToggleX": {},
          "Appliance.Control.TriggerX": {
            "notify": [
              "Appliance.GarageDoor.State"
            ]
          },
          "Appliance.Control.Unbind": {},
          "Appliance.Control.Upgrade": {},
          "Appliance.Digest.TimerX": {},
          "Appliance.Digest.TriggerX": {},
          "Appliance.GarageDoor.Config": {},
          "Appliance.GarageDoor.State": {},
          "Appliance.System.Ability": {},
          "Appliance.System.All": {},
          "Appliance.System.Clock": {},
          "Appliance.System.DNDMode": {},
          "Appliance.System.Debug": {},
          "Appliance.System.Firmware": {},
          "Appliance.System.Hardware": {},
          "Appliance.System.Online": {},
          "Appliance.System.Position": {},
          "Appliance.System.Report": {},
          "Appliance.System.Runtime": {},
          "Appliance.System.Time": {}
        }
      ],
      [
        "2024/12/16 - 15:52:50",
        "TX",
        "http",
        "GET",
        "Appliance.Control.ToggleX",
        {
          "togglex": []
        }
      ],
      [
        "2024/12/16 - 15:52:50",
        "RX",
        "http",
        "GETACK",
        "Appliance.Control.ToggleX",
        {
          "channel": 0,
          "togglex": {
            "channel": 0,
            "onoff": 1,
            "lmTime": 0
          }
        }
      ],
      [
        "2024/12/16 - 15:52:50",
        "TX",
        "http",
        "GET",
        "Appliance.GarageDoor.Config",
        {
          "config": {}
        }
      ],
      [
        "2024/12/16 - 15:52:50",
        "RX",
        "http",
        "GETACK",
        "Appliance.GarageDoor.Config",
        {
          "config": {
            "signalDuration": 500,
            "buzzerEnable": 1
          }
        }
      ],
      [
        "2024/12/16 - 15:52:50",
        "TX",
        "http",
        "GET",
        "Appliance.GarageDoor.State",
        {
          "state": {}
        }
      ],
      [
        "2024/12/16 - 15:52:50",
        "RX",
        "http",
        "GETACK",
        "Appliance.GarageDoor.State",
        {
          "state": {
            "channel": 0,
            "open": 1,
            "lmTime": 1734256237
          }
        }
      ],
      [
        "2024/12/16 - 15:52:50",
        "TX",
        "http",
        "GET",
        "Appliance.System.Debug",
        {
          "debug": {}
        }
      ],
      [
        "2024/12/16 - 15:52:50",
        "RX",
        "http",
        "GETACK",
        "Appliance.System.Debug",
        {
          "debug": {
            "system": {
              "version": "3.2.7",
              "sysUpTime": "377h27m17s",
              "localTimeOffset": 3600,
              "localTime": "Mon Dec 16 15:52:49 2024",
              "suncalc": "7:31;16:40"
            },
            "network": {
              "linkStatus": "connected",
              "signal": 100,
              "ssid": "#########0",
              "gatewayMac": "################0",
              "innerIp": "##############0",
              "wifiDisconnectCount": 1
            },
            "cloud": {
              "activeServer": "###################0",
              "mainServer": "###################0",
              "mainPort": "@0",
              "secondServer": "###################0",
              "secondPort": "@0",
              "userId": "@0",
              "sysConnectTime": "Sun Dec 15 19:18:06 2024",
              "sysOnlineTime": "19h34m43s",
              "sysDisconnectCount": 5
            }
          }
        }
      ],
      [
        "2024/12/16 - 15:52:50",
        "TX",
        "http",
        "GET",
        "Appliance.System.Runtime",
        {
          "runtime": {}
        }
      ],
      [
        "2024/12/16 - 15:52:50",
        "RX",
        "http",
        "GETACK",
        "Appliance.System.Runtime",
        {
          "runtime": {
            "signal": 100
          }
        }
      ]
    ]
  }
}```

I am seeing the same issue but I think it is not an integration issue because mine is integrated through homekit devices. I will assume that the state as reported by the device is not being received for some reason. Like you, it is not easily reproducible and occurs on open or closed state intermittently.

If I reload the device from the HK device integration panel it will refresh the state to be read correctly. Just FYI, I have it blocked from the internet at the router…I think I’ll go check those logs.

Thanks rouxdoo, you are right, it is not an integration issue. I see the same behaviour in the native app as well.

Having come across this troubleshooting guide I realized that the spacing between the magnets was slightly off (something must have bumped into them). With that corrected, status now updates correctly and consistently.