Closed talondnb closed 5 years ago
Image of a map is scaled to match a width of a card. It shouldn't affect map calibration, as coordinates of points in configuration should come from an original image. Could you provide more details about your issue with accuracy?
I've attached my floorplan, which is drawn straight off a scaled PDF drawing of my home that was provided by the builder when we first built, so it is accurate. I've marked the docking station (green), base (red) and reference (black) points.
Here is my card configuration:
base_position:
x: 79
'y': 843
debug: false
default_mode: predefined_zones
entity: vacuum.roborock
map_image: /local/floorplan.png
reference_point:
x: 112
'y': 809
type: 'custom:xiaomi-vacuum-map-card'
zones:
- - - 23316
- 21161
- 28476
- 31415
- - 28511
- 28682
- 31117
- 30108
- - - 24785
- 31483
- 31012
- 36118
- - 28581
- 30244
- 31047
- 31874
- - - 27480
- 36186
- 28319
- 45676
- - 28441
- 36271
- 30995
- 40226
- - 28476
- 42077
- 31012
- 45574
- - 27479
- 45693
- 31467
- 49581
Now, with the above, if I command the roborock to stop directly in front of a doorway of the bedroom I want to clean, it stops short and rather than be in front of the doorway (blue) it is in front of a wall (red) and so is unable to clean the intended zone.
Can you advise what I can do from here? I'm running valetudo so no cloud connectivity.
My first idea would be to use an image with higher resolution, because for big maps with small distance between calibration points even 1px can make a big difference for places that are far from them (error is multiplied by the distance).
I was originally using much higher res but reduced it as this was before the card allowed for scroll ability on mobile devices. I'll try this again and reply with my findings.
You can try to use the latest version of a card and calibrate it using points that will be e.g. in different corners of a map. In case of problems you can continue this thread.
Still having issues with this, please see here:
https://community.home-assistant.io/t/xiaomi-vacuum-interactive-map-card/123901/257
I've been trying to get my floorplan into the card and have just realised after some testing today that it does not seem to be 1:1 scale.
I created my floorplan at 284px x 1000px and set the base and reference points as per testing. But the card shows up as follows:
This looks to be scaled up. If I right click the floorplan in the card and save a copy, the opened image comes to 1732 x 492?
Is this an issue with the card or am I missing something? I've removed all older floorplan versions from my www folder and I've also cleared cache in my browser, but the issue exists.
The main issue here is that I'm not able to accurately clean defined zone areas.