Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[miio] Add-support: Miio Binding Dreame L10s pro Ultra Heat #17034

Open
TsAbsinthe opened this issue Jul 10, 2024 · 11 comments
Open

[miio] Add-support: Miio Binding Dreame L10s pro Ultra Heat #17034

TsAbsinthe opened this issue Jul 10, 2024 · 11 comments
Labels
enhancement An enhancement or new feature for an existing add-on

Comments

@TsAbsinthe
Copy link

Please add support for the new DREAME L10s pro Ultra heat.

Model: dreame.vacuum.r2338a

Thank you!

@TsAbsinthe TsAbsinthe added the enhancement An enhancement or new feature for an existing add-on label Jul 10, 2024
@lsiepel lsiepel changed the title Add-support: Miio Binding Dreame L10s pro Ultra Heat [miio] Add-support: Miio Binding Dreame L10s pro Ultra Heat Jul 10, 2024
@TsAbsinthe
Copy link
Author

Can I assist with some informations about the robot?

@marcelrv
Copy link
Contributor

marcelrv commented Sep 4, 2024

Yes, please switch on once the
Create channels for new/unsupported devices (MIOT protocol) wait for a minute or 2 and inform me which channels are working.

It also creates a logfile, which would be great to attach to this issue.

If the channels remain empty, and e.g. as this is the first time you use the feature, you may need to restart the binding to have the configuration picked up. (or restart openhab)

@TsAbsinthe
Copy link
Author

TsAbsinthe commented Sep 16, 2024

Hi @marcelrv - I switch on the "Create channels for new/unsupported devices (MIOT protocol)".

The outcome is not really much... only one file...
info_2F113844.json
That's all. Nothing else is happening - no new folder conf/misc/miio

i am not sure, if I done everything right. I also restarted the OH. I'm using OH 4.2.1.

@marcelrv
Copy link
Contributor

That is really odd.
Best to try to switch on debug logging to see if any errors are coming up.

log:set debug org.openhab.binding.miio if you are in the console
then you can do a
log:tail org.openhab.binding.miio

then try once more to switch on/off.

@TsAbsinthe
Copy link
Author

Hi, i am quite sure - something is wrong...

I started the log as requested @marcelrv

openhab> log:set debug org.openhab.binding.miio openhab> log:tail org.openhab.binding.miio 13:35:30.934 [DEBUG] [io.internal.handler.MiIoVacuumHandler] - Periodic update for 'miio:vacuum:4b37b4a323' (miio:vacuum) 13:35:30.935 [DEBUG] [rnal.transport.MiIoAsyncCommunication] - Command added to Queue {"id":5987,"method":"get_dnd_timer","params":[]} -> 10.0.1 .38 (Device: 789657668 token: 47374A37XXXXXXXXXXXXXXXX39425A5A Queue: 1). Send via cloudserver: de 13:35:30.935 [DEBUG] [rnal.transport.MiIoAsyncCommunication] - Command added to Queue {"id":5988,"method":"get_clean_summary","params":[]} -> 10 .0.1.38 (Device: 789657668 token: 47374A37XXXXXXXXXXXXXXXX39425A5A Queue: 2). Send via cloudserver: de 13:35:30.936 [DEBUG] [rnal.transport.MiIoAsyncCommunication] - Command added to Queue {"id":5989,"method":"get_status","params":[]} -> 10.0.1.38 (Device: 789657668 token: 47374A37XXXXXXXXXXXXXXXX39425A5A Queue: 3). Send via cloudserver: de 13:35:30.937 [DEBUG] [rnal.transport.MiIoAsyncCommunication] - Command added to Queue {"id":5990,"method":"miIO.info","params":[]} -> 10.0.1.38 (Device: 789657668 token: 47374A37XXXXXXXXXXXXXXXX39425A5A Queue: 4). Send via cloudserver: de 13:35:30.937 [DEBUG] [rnal.transport.MiIoAsyncCommunication] - Command added to Queue {"id":5991,"method":"get_consumable","params":[]} -> 10.0. 1.38 (Device: 789657668 token: 47374A37XXXXXXXXXXXXXXXX39425A5A Queue: 5). Send via cloudserver: de 13:35:31.002 [DEBUG] [.miio.internal.cloud.MiCloudConnector] - Send request to https://de.api.io.mi.com/app/home/rpc/789657668 with data '{"id": 5987,"method":"get_dnd_timer","params":[]}' 13:35:31.038 [DEBUG] [.miio.internal.cloud.MiCloudConnector] - Request to 'de' server '/home/rpc/789657668'. Response: '{"code":-7,"message":"un known err","result":null}' 13:35:31.039 [DEBUG] [rnal.transport.MiIoAsyncCommunication] - Command {"id":5987,"method":"get_dnd_timer","params":[]} send via cloudserver de 13:35:31.040 [DEBUG] [rnal.transport.MiIoAsyncCommunication] - Received message is without id: {"code":-7,"message":"unknown err","result":null} 13:35:31.041 [DEBUG] [.internal.handler.MiIoAbstractHandler] - Received response for device 4b37b4a323 type: DND_GET, result: {}, fullresponse: {"error":"Received message is without id"} 13:35:31.041 [DEBUG] [.internal.handler.MiIoAbstractHandler] - Error received for command '{"id":5987,"method":"get_dnd_timer","params":[]}': "R eceived message is without id". 13:35:31.042 [DEBUG] [.miio.internal.cloud.MiCloudConnector] - Send request to https://de.api.io.mi.com/app/home/rpc/789657668 with data '{"id": 5988,"method":"get_clean_summary","params":[]}' 13:35:31.071 [DEBUG] [.miio.internal.cloud.MiCloudConnector] - Request to 'de' server '/home/rpc/789657668'. Response: '{"code":-7,"message":"un known err","result":null}' 13:35:31.071 [DEBUG] [rnal.transport.MiIoAsyncCommunication] - Command {"id":5988,"method":"get_clean_summary","params":[]} send via cloudserver de 13:35:31.072 [DEBUG] [rnal.transport.MiIoAsyncCommunication] -

@marcelrv
Copy link
Contributor

yes, you defined your things as a miio:vacuum. This is only for roborock vacuums.
Please use miio:basic as the thingtype.

I also see you have communication via cloud. Unless you have a very specific setup requiring this (e.g. different VLANS for your robot), you better use direct communication.

Best is to first try tohave your device discovered and added via gui. Than if all working you can change it to text config.

@TsAbsinthe
Copy link
Author

Hi @marcelrv,

My setup is a little bit specific. I use a docker running on a synology. So I have to use cloud connection. When I set to "direct" I lose the connection and the thing went offline.

strange things are happening ;) I configure a new thing as miio:basic. But then the channel "Create channels for new/unsupported devices (MIOT protocol)" is missing...

`UID: miio:basic:XXX
label: "Roboter"
thingTypeUID: miio:basic
configuration:
cloudServer: DE
refreshInterval: 30
host: XXX
communication: cloud
deviceId: "XXX"
timeout: 15000
token: XXX
location: "Roboter: Ying 2.2"
channels:

  • id: network#ssid
    channelTypeUID: miio:ssid
    label: SSID
    configuration: {}
  • id: network#bssid
    channelTypeUID: miio:bssid
    label: BSSID
    configuration: {}
  • id: network#rssi
    channelTypeUID: miio:rssi
    label: RSSI
    configuration: {}
  • id: network#life
    channelTypeUID: miio:life
    label: Life
    configuration: {}
  • id: actions#commands
    channelTypeUID: miio:commands
    label: Execute Command
    configuration: {}
  • id: actions#rpc
    channelTypeUID: miio:rpc
    label: Execute RPC (cloud) Command
    configuration: {}
    `

I don't know how to solve this problem. Do you have any idea?

@marcelrv
Copy link
Contributor

Best is to first try tohave your device discovered and added via gui. Than if all working you can change it to text config.

That button only shows when the thingtype is miio:unsupported. If you do the discovery via gui, then it is defined as a miio:generic, than after interogation with the device, it gets convetred to the proper thing type (vaccum, basic, gateway,lumi or if unknow unsupported)

if you really insist in text config you can indeed define it as a miio:unsupported
For the cloud way you can still discover via GUI than go in the thing properties and change communication to cloud.

Don't know what makes your synology docker special, but here it works fine when making sure you select as your network ' host' and select the right primary network
image
image

(for testing I just made a new openhab docker with miio on synology, can connect fine with local devices)
image

@TsAbsinthe
Copy link
Author

HI @marcelrv

I tried a lot, but the robot is not listed by auto discover. I only get a thing working (status online) by adding the device manually in the gui. And only via cloud.

I think my docker is the same as yours... I am a little bit confuse what is wrong...

But, if I get the robot online via cloud, no file is created with experimental channels...

@TsAbsinthe
Copy link
Author

Hi @marcelrv,

I did a factory reset with the robot. After this the robot showed up in auto discover. I added the vacuum again to openhanded. Unfortunately the vacuum is offline with direct connection.

In the log are the same entries...

2024-10-11 21:46:05.783 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Communication error for Mi device at 10.0.1.38: Receive timed out 2024-10-11 21:46:05.784 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Sending Ping to device '789657668' (10.0.1.38) 2024-10-11 21:46:14.005 [DEBUG] [ernal.handler.MiIoUnsupportedHandler] - Periodic update for 'miio:unsupported:629343cae5' (miio:unsupported) 2024-10-11 21:46:14.005 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {"id":11634,"method":"miIO.info","params":[]} -> 10.0.1.38 (Device: 789657668 token: 47374A37XXXXXXXXXXXXXXXX39425A5A Queue: 1). Send via cloudserver: DE 2024-10-11 21:46:14.032 [DEBUG] [miio.internal.cloud.MiCloudConnector] - Send request to https://de.api.io.mi.com/app/home/rpc/789657668 with data '{"id":11634,"method":"miIO.info","params":[]}' 2024-10-11 21:46:14.061 [DEBUG] [miio.internal.cloud.MiCloudConnector] - Request to 'de' server '/home/rpc/789657668'. Response: '{"code":-7,"message":"unknown err","result":null}' 2024-10-11 21:46:14.061 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command {"id":11634,"method":"miIO.info","params":[]} send via cloudserver DE 2024-10-11 21:46:14.061 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Received message is without id: {"code":-7,"message":"unknown err","result":null} 2024-10-11 21:46:14.062 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for device 629343cae5 type: MIIO_INFO, result: {}, fullresponse: {"error":"Received message is without id"} 2024-10-11 21:46:14.062 [DEBUG] [internal.handler.MiIoAbstractHandler] - Error received for command '{"id":11634,"method":"miIO.info","params":[]}': "Received message is without id". 2024-10-11 21:46:20.794 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Communication error for Mi device at 10.0.1.38: Receive timed out 2024-10-11 21:46:20.795 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Sending Ping to device '789657668' (10.0.1.38) 2024-10-11 21:46:29.851 [DEBUG] [.internal.handler.MiIoGenericHandler] - Periodic update for 'miio:generic:856589a8b6' (miio:generic) 2024-10-11 21:46:29.851 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command added to Queue {"id":8073,"method":"miIO.info","params":[]} -> 10.0.1.38 (Device: 789657668 token: 47374A37XXXXXXXXXXXXXXXX39425A5A Queue: 1). Send via cloudserver: DE 2024-10-11 21:46:29.854 [DEBUG] [miio.internal.cloud.MiCloudConnector] - Send request to https://de.api.io.mi.com/app/home/rpc/789657668 with data '{"id":8073,"method":"miIO.info","params":[]}' 2024-10-11 21:46:30.106 [DEBUG] [miio.internal.cloud.MiCloudConnector] - Request to 'de' server '/home/rpc/789657668'. Response: '{"code":-7,"message":"unknown err","result":null}' 2024-10-11 21:46:30.106 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Command {"id":8073,"method":"miIO.info","params":[]} send via cloudserver DE 2024-10-11 21:46:30.106 [WARN ] [.core.thing.binding.BaseThingHandler] - Handler MiIoGenericHandler tried updating the thing status although the handler was already disposed. 2024-10-11 21:46:30.107 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Received message is without id: {"code":-7,"message":"unknown err","result":null} 2024-10-11 21:46:30.107 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for device 856589a8b6 type: MIIO_INFO, result: {}, fullresponse: {"error":"Received message is without id"} 2024-10-11 21:46:30.107 [DEBUG] [internal.handler.MiIoAbstractHandler] - Error received for command '{"id":8073,"method":"miIO.info","params":[]}': "Received message is without id". 2024-10-11 21:46:35.809 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Communication error for Mi device at 10.0.1.38: Receive timed out 2024-10-11 21:46:35.809 [DEBUG] [nal.transport.MiIoAsyncCommunication] - No response from device 789657668 at 10.0.1.38 for command {"id":5843,"method":"miIO.info","params":[]}. 2024-10-11 21:46:35.809 [DEBUG] [nal.transport.MiIoAsyncCommunication] - Received message is without id: {"error":"No Response"} 2024-10-11 21:46:35.810 [DEBUG] [internal.handler.MiIoAbstractHandler] - Received response for device 2F113844 type: MIIO_INFO, result: {}, fullresponse: {"error":"Received message is without id"} 2024-10-11 21:46:35.810 [DEBUG] [internal.handler.MiIoAbstractHandler] - Error received for command '{"id":5843,"method":"miIO.info","params":[]}': "Received message is without id".

Do you have any idea, what is wrong with my set up?

@marcelrv
Copy link
Contributor

no, I don't know.
There are several 'odd' things happening, the device can't be reached local (it should reply to the ping), the cloud gives 'unknown err' responses. The log apprears show multiple devices with the same issue.

My only suggestion is to try to download a virgin openhab, spin it up and only install miio binding. [you prob want to disable the miio things in your regular openhab install]
Than via the UI add your userID/password for the cloud and do a discovery while making sure you are on the same network/subnet/VLAN as your devices.
Your devices should be able to be found and pinged. Add them via the UI and give it a few minutes of time to let it fully configure itself.
If it works then, we may be able to find out where it breaks in your regular openhab install.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement An enhancement or new feature for an existing add-on
Projects
None yet
Development

No branches or pull requests

2 participants