sca075 / mqtt_vacuum_camera

Camera Integration for Home Assistant to export and render all Vacuums connected via MQTT( including Valetudo Hypfer and RE(rand256)) Maps.
Apache License 2.0
106 stars 7 forks source link

Tracking: Images redraw when no trims are set. #242

Closed sca075 closed 2 months ago

sca075 commented 3 months ago

Checklist

The problem

When resetting the trims with reset_trim at current is implemented that if the vacuum isn't "docked" the trims should be re-calculated at each frame. While testing the new released 2024.08.1 I noticed that (on V1 vacuums but probably also with other) the Camera render the robot and path but not the floor. Reload of the Camera correctly update the image.

What version of an integration has described problem?

2024.08.1

What was the last working version of an integration?

2024.06.4

What vacuum model do you have problems with?

Roborock.V1

Please firmware installed on your Vacuum.

not relevant.

What type of platform you use?

ARM (Raspberry Pi, Odroid, etc.) > 4GB

What version of Home Assistant do you use?

2024.8.1

What type of installation are you running?

Home Assistant OS

Logs or Errors shown in the HA snapshots (please enable the Debug Mode) text will be auto formatted to code.

No errors occurs but from the logs the image base layer looks never draw till the camera reload.

Function, that in your opinion is creating the issue.

Image Aspect Ratio

Additional information

Will be working on this trying to confirm the root cause and eventually fix it. This issue is for tracing reason created.

sca075 commented 2 months ago

Found cause of the issue, the fix should be released with one of the beta of 2024.10.0

sca075 commented 2 months ago

Thanks to @hayvan96 in https://community.home-assistant.io/t/valetudo-vacuums-map-camera-for-home-assistant/600182/141?u=gsca075 it looks that by calling the camera reset_trims service once now the issue with the image update is fixed :) To automatically detect when it is the case to reset the trims I'm going to implement an event "vacuum.start", so that the camera will reset the trims automatically.