Xiaomi Robot Vacuum Binding

I would say so.

the: miiocli viomivacuum start/pause/stop/home commands work.
so how is that translated to the (vacuum/spot/pause/dock) arguments?

Best Regards

Dominic

By the way: where is the current build / 2.5.9 Snapshot available for download?

You can download the latest incl the v7/v8 with control channel here https://verpaalen.com/openhab2/org.openhab.binding.miio-2.5.9-SNAPSHOT.jar

Note for folks with dreame.vacuum.mc1808… it also has control channel for this one

Note: This is merged now in the official 2.5.9-SNAPSHOT

1 Like

Oke, not sure how. But the vacuum is online and i’m getting the info. Thanks for putting my on the richt track.

Next. the Xiaomi Gateway V3, It gets found, i having it online but as a “Unsupported Xiaomi Mi Device”.

In my app, it’s also there and connected to it, 4 smoke detectors, 1 water detector. How can ik make the visible in Openhab ?. If there’s another topic about this, please redirect it to there, i could not find it.

Look for the mihome binding to control these connected devices.
The miio binding (that shows your ‘Unsupported Xiaomi Mi Device’) can communicate with the V3 and send commands to it (e.g to enable telnet) but has no logic to control these devices.

Great :slight_smile:
Might be a small spelling mistake:
battary_life (instead battery)

Regarding the room cleaning using room numbers i got success, using a couple of numbers with the set_mode_withroom command

Start cleaning everywhere
set_mode_withroom[0, 1, 0]
Start cleaning everywhere including edges
set_mode_withroom[1, 1, 0]
pause cleaning
set_mode_withroom[0, 0, 0]
//ROOMS
corridor
set_mode_withroom[0,1,1,13]
kitchen
set_mode_withroom[0,1,1,10]
..and so on (i got no values using "get_room_mapping" :/ so try&error)

Any hints, how to get room numbers for my vi/xiaomi v8 ? :slight_smile:

it might be hidden in the mapinfo.
If you can share a mapfile and the location of the rooms you already found the roomnr off than I can try if I can link the few unknown parts of the mapfiles to roomnumbers. (see offline viewer topic for how/where to find these rrmap files)

Is it possible to get a ‘input’ from the smoke detector to trigger a rule ?

(i want to use one to guard mt 3d printer and to kill power when there is a fire or smoke)

Hi Marcel,

thanks for your awesome work! Short question: Is there a way to switch the map store mode of the Roborock S50 to On/Off or delete the map on the vacuum?
I have two floors, but they are very similar so my vacuum thinks it is in the ground floor when I put him into the first floor, making all the algorithms go crazy! I’d love to implement a “differen-floor” mode, where the map is deleted…

Thanks!

Better ask in the mihome topic. (separate binding) I have very little knowledge of the gateway specific logic.

If I recall well, this is a feature that valetuo adds (saving and restoring multiple maps). This does mean going through the challenges of rooting it. Check before if this is correct as it may depend on the model of vacuum you have.

1 Like

Hi Marcel.
Yesterday they bring me for gift a Xiaomi Mi Mop Pro STYJ02YM . i am using your last version of binding. The binding found the model as you see in the photos.


With the following channels
The problem is that i dont get values from all the channels , if you see in the battery i have only 1 and not the percent 12

Also i have a lot of errors in the log file.
2020-09-20 19:12:07.321 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [0,0,0,0,12], fullresponse: {“result”:[0,0,0,0,12],“id”:445}

2020-09-20 19:12:07.336 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [1,1,0,0], fullresponse: {“result”:[1,1,0,0],“id”:446}

2020-09-20 19:12:35.452 [DEBUG] [miio.internal.cloud.MiCloudConnector] - Send request: {“getVirtualModel”:false,“getHuamiDevices”:0} to https://de.api.io.mi.com/app/home/device_list

2020-09-20 19:12:35.594 [DEBUG] [miio.internal.cloud.MiCloudConnector] - Devices token info saved to C:\openHAB2\userdata\miio\miioTokens-de.json

2020-09-20 19:12:35.594 [DEBUG] [miio.internal.cloud.MiCloudConnector] - Xiaomi cloud info: Device name: ‘Mi Robot Vacuum-Mop P’, did: ‘374883132’, token: ‘xxxxxxxxxx’, ip: 192.168.178.54, server: de

2020-09-20 19:12:35.594 [DEBUG] [iio.internal.discovery.MiIoDiscovery] - Cloud Info: Device name: ‘Mi Robot Vacuum-Mop P’, did: ‘374883132’, token: ‘xxxxxxxxxx’, ip: 192.168.178.54, server: de

2020-09-20 19:12:35.610 [DEBUG] [iio.internal.discovery.MiIoDiscovery] - Discovered Mi Device xxxxxxxxxx (374883132) at 192.168.178.54 as miio:generic:xxxxxxxxxx

2020-09-20 19:12:35.610 [DEBUG] [iio.internal.discovery.MiIoDiscovery] - Discovered token for device xxxxxxxxxx: xxxxxxxxxx

2020-09-20 19:12:37.202 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Periodic update for ‘miio:generic:xxxxxxxxxx’ (miio:basic)

2020-09-20 19:12:37.202 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:447,“method”:“get_prop”,“params”:[“run_state”,“mode”,“err_state”,“battery_life”,“box_type”]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXX Queue: 1)

2020-09-20 19:12:37.202 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:448,“method”:“get_prop”,“params”:[“mop_type”,“s_time”,“s_area”,“suction_grade”,“water_grade”]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXXXQueue: 2)

2020-09-20 19:12:37.202 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:449,“method”:“get_prop”,“params”:[“remember_map”,“has_map”,“is_mop”,“has_newmap”]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXX Queue: 3)

2020-09-20 19:12:37.202 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:450,“method”:“miIO.info”,“params”:[]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXXX Queue: 4)

2020-09-20 19:12:37.296 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [5,0,2105,1], fullresponse: {“result”:[5,0,2105,1],“id”:447}

2020-09-20 19:12:37.296 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Unexpected size different. Request size 5, response size 4. (Req: [“run_state”,“mode”,“err_state”,“battery_life”,“box_type”], Resp:[5,0,2105,1])

2020-09-20 19:12:37.296 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Error while handing message {“result”:[5,0,2105,1],“id”:447}

java.lang.IndexOutOfBoundsException: Index: 4, Size: 4

at java.util.ArrayList.rangeCheck(ArrayList.java:657) ~[?:1.8.0_232]

at java.util.ArrayList.get(ArrayList.java:433) ~[?:1.8.0_232]

at com.google.gson.JsonArray.get(JsonArray.java:194) ~[bundleFile:?]

at org.openhab.binding.miio.internal.handler.MiIoBasicHandler.updatePropsFromJsonArray(MiIoBasicHandler.java:438) ~[bundleFile:?]

at org.openhab.binding.miio.internal.handler.MiIoBasicHandler.onMessageReceived(MiIoBasicHandler.java:521) [bundleFile:?]

at org.openhab.binding.miio.internal.transport.MiIoAsyncCommunication$MessageSenderThread.run(MiIoAsyncCommunication.java:233) [bundleFile:?]

2020-09-20 19:12:37.312 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [0,0,0,0,12], fullresponse: {“result”:[0,0,0,0,12],“id”:448}

2020-09-20 19:12:37.329 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [1,1,0,0], fullresponse: {“result”:[1,1,0,0],“id”:449}

2020-09-20 19:12:37.344 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: MIIO_INFO, result: {“hw_ver”:“Linux”,“fw_ver”:“3.5.3_0017”,“ap”:{“ssid”:“FRITZ!Box 6490 Cable”,“bssid”:“dc:39:6f:a8:a9:2d”},“netif”:{“localIp”:“192.168.178.54”,“mask”:“255.255.255.0”,“gw”:“192.168.178.1”},“model”:“viomi.vacuum.v8”,“mac”:“5C:6B:D7:02:19:59”,“token”:“xxxxxxxxxx”,“life”:13454}, fullresponse: {“partner_id”:"",“id”:450,“code”:0,“message”:“ok”,“result”:{“hw_ver”:“Linux”,“fw_ver”:“3.5.3_0017”,“ap”:{“ssid”:“FRITZ!Box 6490 Cable”,“bssid”:“dc:39:6f:a8:a9:2d”},“netif”:{“localIp”:“192.168.178.54”,“mask”:“255.255.255.0”,“gw”:“192.168.178.1”},“model”:“viomi.vacuum.v8”,“mac”:“5C:6B:D7:02:19:59”,“token”:“xxxxxxxxxx”,“life”:13454}}

2020-09-20 19:12:37.344 [DEBUG] [internal.handler.MiIoAbstractHandler] - No RSSI info in response

2020-09-20 19:13:07.220 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Periodic update for ‘miio:generic:xxxxxxxxxx’ (miio:basic)

2020-09-20 19:13:07.220 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:451,“method”:“get_prop”,“params”:[“run_state”,“mode”,“err_state”,“battery_life”,“box_type”]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXXX Queue: 1)

2020-09-20 19:13:07.220 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:452,“method”:“get_prop”,“params”:[“mop_type”,“s_time”,“s_area”,“suction_grade”,“water_grade”]} -> 192.168.178.54 (Device: xxxxxxxxxx XXXXXXXXXXXXXXX Queue: 2)

2020-09-20 19:13:07.220 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:453,“method”:“get_prop”,“params”:[“remember_map”,“has_map”,“is_mop”,“has_newmap”]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXX Queue: 3)

2020-09-20 19:13:07.309 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [5,0,2105,1], fullresponse: {“result”:[5,0,2105,1],“id”:451}

2020-09-20 19:13:07.309 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Unexpected size different. Request size 5, response size 4. (Req: [“run_state”,“mode”,“err_state”,“battery_life”,“box_type”], Resp:[5,0,2105,1])

2020-09-20 19:13:07.310 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Error while handing message {“result”:[5,0,2105,1],“id”:451}

java.lang.IndexOutOfBoundsException: Index: 4, Size: 4

at java.util.ArrayList.rangeCheck(ArrayList.java:657) ~[?:1.8.0_232]

at java.util.ArrayList.get(ArrayList.java:433) ~[?:1.8.0_232]

at com.google.gson.JsonArray.get(JsonArray.java:194) ~[bundleFile:?]

at org.openhab.binding.miio.internal.handler.MiIoBasicHandler.updatePropsFromJsonArray(MiIoBasicHandler.java:438) ~[bundleFile:?]

at org.openhab.binding.miio.internal.handler.MiIoBasicHandler.onMessageReceived(MiIoBasicHandler.java:521) [bundleFile:?]

at org.openhab.binding.miio.internal.transport.MiIoAsyncCommunication$MessageSenderThread.run(MiIoAsyncCommunication.java:233) [bundleFile:?]

2020-09-20 19:13:07.322 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [0,0,0,0,12], fullresponse: {“result”:[0,0,0,0,12],“id”:452}

2020-09-20 19:13:07.331 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [1,1,0,0], fullresponse: {“result”:[1,1,0,0],“id”:453}

2020-09-20 19:13:13.718 [ERROR] [.moquette.broker.NewNettyMQTTHandler] - Unexpected exception while processing MQTT message. Closing Netty channel. CId=root.1600621836795

java.io.IOException: An existing connection was forcibly closed by the remote host

at sun.nio.ch.SocketDispatcher.read0(Native Method) ~[?:1.8.0_232]

at sun.nio.ch.SocketDispatcher.read(SocketDispatcher.java:43) ~[?:1.8.0_232]

at sun.nio.ch.IOUtil.readIntoNativeBuffer(IOUtil.java:223) ~[?:1.8.0_232]

at sun.nio.ch.IOUtil.read(IOUtil.java:192) ~[?:1.8.0_232]

at sun.nio.ch.SocketChannelImpl.read(SocketChannelImpl.java:377) ~[?:1.8.0_232]

at io.netty.buffer.PooledByteBuf.setBytes(PooledByteBuf.java:247) ~[bundleFile:4.1.42.Final]

at io.netty.buffer.AbstractByteBuf.writeBytes(AbstractByteBuf.java:1147) ~[bundleFile:4.1.42.Final]

at io.netty.channel.socket.nio.NioSocketChannel.doReadBytes(NioSocketChannel.java:347) ~[bundleFile:4.1.42.Final]

at io.netty.channel.nio.AbstractNioByteChannel$NioByteUnsafe.read(AbstractNioByteChannel.java:148) [bundleFile:4.1.42.Final]

at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:700) [bundleFile:4.1.42.Final]

at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:635) [bundleFile:4.1.42.Final]

at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:552) [bundleFile:4.1.42.Final]

at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:514) [bundleFile:4.1.42.Final]

at io.netty.util.concurrent.SingleThreadEventExecutor$6.run(SingleThreadEventExecutor.java:1044) [bundleFile:4.1.42.Final]

at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) [bundleFile:4.1.42.Final]

at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) [bundleFile:4.1.42.Final]

at java.lang.Thread.run(Thread.java:748) [?:1.8.0_232]

2020-09-20 19:13:37.230 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Periodic update for ‘miio:generic:xxxxxxxxxx’ (miio:basic)

2020-09-20 19:13:37.230 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:454,“method”:“get_prop”,“params”:[“run_state”,“mode”,“err_state”,“battery_life”,“box_type”]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXXX Queue: 1)

2020-09-20 19:13:37.230 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:455,“method”:“get_prop”,“params”:[“mop_type”,“s_time”,“s_area”,“suction_grade”,“water_grade”]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXXX Queue: 2)

2020-09-20 19:13:37.230 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:456,“method”:“get_prop”,“params”:[“remember_map”,“has_map”,“is_mop”,“has_newmap”]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXX Queue: 3)

2020-09-20 19:13:37.230 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:457,“method”:“miIO.info”,“params”:[]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXX Queue: 4)

2020-09-20 19:13:37.308 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [5,0,2105,1], fullresponse: {“result”:[5,0,2105,1],“id”:454}

2020-09-20 19:13:37.308 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Unexpected size different. Request size 5, response size 4. (Req: [“run_state”,“mode”,“err_state”,“battery_life”,“box_type”], Resp:[5,0,2105,1])

2020-09-20 19:13:37.308 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Error while handing message {“result”:[5,0,2105,1],“id”:454}

java.lang.IndexOutOfBoundsException: Index: 4, Size: 4

at java.util.ArrayList.rangeCheck(ArrayList.java:657) ~[?:1.8.0_232]

at java.util.ArrayList.get(ArrayList.java:433) ~[?:1.8.0_232]

at com.google.gson.JsonArray.get(JsonArray.java:194) ~[bundleFile:?]

at org.openhab.binding.miio.internal.handler.MiIoBasicHandler.updatePropsFromJsonArray(MiIoBasicHandler.java:438) ~[bundleFile:?]

at org.openhab.binding.miio.internal.handler.MiIoBasicHandler.onMessageReceived(MiIoBasicHandler.java:521) [bundleFile:?]

at org.openhab.binding.miio.internal.transport.MiIoAsyncCommunication$MessageSenderThread.run(MiIoAsyncCommunication.java:233) [bundleFile:?]

2020-09-20 19:13:37.328 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [0,0,0,0,12], fullresponse: {“result”:[0,0,0,0,12],“id”:455}

2020-09-20 19:13:37.341 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [1,1,0,0], fullresponse: {“result”:[1,1,0,0],“id”:456}

2020-09-20 19:13:37.348 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: MIIO_INFO, result: {“hw_ver”:“Linux”,“fw_ver”:“3.5.3_0017”,“ap”:{“ssid”:“FRITZ!Box 6490 Cable”,“bssid”:“dc:39:6f:a8:a9:2d”},“netif”:{“localIp”:“192.168.178.54”,“mask”:“255.255.255.0”,“gw”:“192.168.178.1”},“model”:“viomi.vacuum.v8”,“mac”:“5C:6B:D7:02:19:59”,“token”:“xxxxxxxxxx”,“life”:13514}, fullresponse: {“partner_id”:"",“id”:457,“code”:0,“message”:“ok”,“result”:{“hw_ver”:“Linux”,“fw_ver”:“3.5.3_0017”,“ap”:{“ssid”:“FRITZ!Box 6490 Cable”,“bssid”:“dc:39:6f:a8:a9:2d”},“netif”:{“localIp”:“192.168.178.54”,“mask”:“255.255.255.0”,“gw”:“192.168.178.1”},“model”:“viomi.vacuum.v8”,“mac”:“5C:6B:D7:02:19:59”,“token”:“xxxxxxxxxx”,“life”:13514}}

2020-09-20 19:13:37.349 [DEBUG] [internal.handler.MiIoAbstractHandler] - No RSSI info in response

2020-09-20 19:14:07.246 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Periodic update for ‘miio:generic:xxxxxxxxxx’ (miio:basic)

2020-09-20 19:14:07.246 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:458,“method”:“get_prop”,“params”:[“run_state”,“mode”,“err_state”,“battery_life”,“box_type”]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXXX Queue: 1)

2020-09-20 19:14:07.246 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:459,“method”:“get_prop”,“params”:[“mop_type”,“s_time”,“s_area”,“suction_grade”,“water_grade”]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXXX Queue: 2)

2020-09-20 19:14:07.246 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {“id”:460,“method”:“get_prop”,“params”:[“remember_map”,“has_map”,“is_mop”,“has_newmap”]} -> 192.168.178.54 (Device: xxxxxxxxxx token: XXXXXXXXXXXXXXXX Queue: 3)

2020-09-20 19:14:07.420 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [5,0,2105,1], fullresponse: {“result”:[5,0,2105,1],“id”:458}

2020-09-20 19:14:07.420 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Unexpected size different. Request size 5, response size 4. (Req: [“run_state”,“mode”,“err_state”,“battery_life”,“box_type”], Resp:[5,0,2105,1])

2020-09-20 19:14:07.435 [DEBUG] [io.internal.handler.MiIoBasicHandler] - Error while handing message {“result”:[5,0,2105,1],“id”:458}

java.lang.IndexOutOfBoundsException: Index: 4, Size: 4

at java.util.ArrayList.rangeCheck(ArrayList.java:657) ~[?:1.8.0_232]

at java.util.ArrayList.get(ArrayList.java:433) ~[?:1.8.0_232]

at com.google.gson.JsonArray.get(JsonArray.java:194) ~[bundleFile:?]

at org.openhab.binding.miio.internal.handler.MiIoBasicHandler.updatePropsFromJsonArray(MiIoBasicHandler.java:438) ~[bundleFile:?]

at org.openhab.binding.miio.internal.handler.MiIoBasicHandler.onMessageReceived(MiIoBasicHandler.java:521) [bundleFile:?]

at org.openhab.binding.miio.internal.transport.MiIoAsyncCommunication$MessageSenderThread.run(MiIoAsyncCommunication.java:233) [bundleFile:?]

2020-09-20 19:14:07.451 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [0,0,0,0,12], fullresponse: {“result”:[0,0,0,0,12],“id”:459}

2020-09-20 19:14:07.466 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for xxxxxxxxxx type: GET_PROPERTY, result: [1,1,0,0], fullresponse: {“result”:[1,1,0,0],“id”:460}

sorry for the big post.
Nikos

Maybe your vacuum allows only 4 parameters to be retrieved at one time, or one of the parameters is not supported (normally this would respond with null)

Can you try in the command channel (advanced channel, click ‘show more’ to see it in paperUI) to execute
get_prop ["run_state","mode","err_state","battery_life"]
as well as get_prop ["box_type"]

if the first responds with 4 parameters and the 2nd gives a normal response we know the issue and can simply resolve it ( we need to add a line with "maxProperties": 4, to the database file https://github.com/openhab/openhab-addons/blob/main/bundles/org.openhab.binding.miio/src/main/resources/database/viomi.vacuum.v8.json)

If the first does not respond with parameters, please try each property individually to see which one does not provide a response.

For the batter to show % prob we need to add a line "Channel Type" : "system.battery-level",
You could already download the db json file (above link) and make the modifications. see binding readme on where to save it.

Thanks for your fast respond.
when i give the first command i get back this : {“result”:[5,0,2105],“id”:10264}
the first command give this : {“result”:[1],“id”:10268}

what does that mean for me now :slight_smile:

How to proceed below???

Sorry but i need your guidance.

Thanks a lot
Nikos

as you only got 3 items in your result, one of the 4 properties is not working well.
To find out which one, can you try each of them separately

get_prop ["run_state""]
get_prop ["mode""]
get_prop ["err_state"]
get_prop ["battery_life"]
I expect one of these to fail… that property is not supported by your device than and we need to remove the channel for it

ok these are the results i think that the battery_life its not working??

i think i found the error why i dont get the battery_life back. If i type
get_prop [“battery_life”] return nothing but if i type get_prop [“battary_life”] then i get the value from the battery. so its a typo on the word battery to battary. How can we correct this?? only with the json file??

Can you once more to try to run the get_prop ["run_state","mode","err_state","battary_life", "box_type" ] to confirm indeed 5 properties in one go works fine?

To fix it now, that would require you to download the json file from the link in my earlier post and make make the change the property.

now it give me back 5 properties. {“result”:[5,0,2105,100,1],“id”:47}
i have edit the json file like this
“property”: “battary_life”,
“friendlyName”: “Battery level”,
“channel”: “battary_life”,
“type”: “Number”,
“refresh”: true,
“actions”: [
]
but then the binding couldn’t recognise the Device Model String i ahve edit manual viomi.vacuum.v8 and now its looking all correct. i will test it more and i will inform you if something its not working. one last thing how to get the maps?? i dont see any map file in my openhab files?


Thanks
Nikos

Okay, great…
wrt to the device model string, and the firware & manufacturer… Ive seen with other devices as well that those don’t work. I have already removed them in the official 2.5.9

To test if the map commands work, can you try to delete the thing, and than manually add it as a miio:vacuum thing. Non of the channels will work but the big question will be… does the map channel work? If yes, than it needs bit of work but than we know.

You can also try first if the get_map_v1[] command works… if no response or error response installing the adding it as vacuum thing is not needed