albertogeniola / meross-homeassistant

Custom component that leverages the Meross IoT library to integrate with Homeassistant
MIT License
697 stars 78 forks source link

MSS310 smart plug doesn't transmit power consumption data to home assistant #404

Open adicrescenzo opened 1 year ago

adicrescenzo commented 1 year ago

Describe the bug The smart plug MSS310 doesn't transmit any data related to the power consumption (current, voltage and power)

Your environment HomeAssistant version: Supervisor 2022.11.2 Hassio Version (if applicable): 9.3 Hardware environment: Virtual Machine running on Proxmox

I'm using the Meross Local Broker, the device is correctly paired and I can switch it on and off from homeassistant but there aren't any data related to the power consumption:

Logs taken from the Local Broker

MQTT Tab

2022-11-23 12:59:03.744997601 Config loaded from /etc/mosquitto/mosquitto.conf.
2022-11-23 12:59:03.744996080 mosquitto version 2.0.10 starting
2022-11-23 07:06:08.100763812 time="2022-11-23T08:06:08+01:00" level=info msg="error code: 401"
2022-11-23 07:06:07.318829881 time="2022-11-23T08:06:07+01:00" level=info msg="No cache set."
2022-11-23 07:06:07.318829221 time="2022-11-23T08:06:07+01:00" level=info msg="registered superuser checker: files"
2022-11-23 07:06:07.318811531 time="2022-11-23T08:06:07+01:00" level=info msg="registered user checker: files"
2022-11-23 07:06:07.318808981 time="2022-11-23T08:06:07+01:00" level=info msg="registered acl checker: files"
2022-11-23 07:06:07.318806491 time="2022-11-23T08:06:07+01:00" level=info msg="registered superuser checker: http"
2022-11-23 07:06:07.318803481 time="2022-11-23T08:06:07+01:00" level=info msg="registered user checker: http"
2022-11-23 07:06:07.318791521 time="2022-11-23T08:06:07+01:00" level=info msg="registered acl checker: http"
2022-11-23 07:06:07.318788131 time="2022-11-23T08:06:07+01:00" level=info msg="Backend registered: Files"
2022-11-23 07:06:07.318738341 time="2022-11-23T08:06:07+01:00" level=warning msg="unknown or empty hasher, defaulting to PBKDF2"
2022-11-23 07:06:07.318737411 time="2022-11-23T08:06:07+01:00" level=info msg="Backend registered: HTTP"
2022-11-23 07:06:07.318720901 time="2022-11-23T08:06:07+01:00" level=warning msg="unknown or empty hasher, defaulting to PBKDF2"
2022-11-23 07:06:07.309805032 [08:06:07] INFO:
Starting mosquitto...
2022-11-23 07:06:07.309135398 [08:06:07] INFO:
Waiting for acl file...
2022-11-23 07:06:07.308414184 [08:06:07] INFO:
Waiting for auth file...
2022-11-23 07:06:06.801637037 [08:06:06] INFO:
Waiting for local dev server...
2022-11-23 07:06:06.740919974 Registered to /org/freedesktop/resolve1/dnssd/meross_5flocal_5fmqtt
2022-11-23 07:06:06.740919414 Service registered in /org/freedesktop/resolve1/dnssd/meross_5flocal_5fmqtt
2022-11-23 07:06:06.740918454 Attempting a new registration...
2022-11-23 07:06:06.740917894 Service meross_local_mqtt unregistered.
2022-11-23 07:06:06.740917194 Unregistering '/org/freedesktop/resolve1/dnssd/meross_local_mqtt'
2022-11-23 07:06:06.740916024 Unregistering it...
2022-11-23 07:06:06.740914604 Service 'meross_local_mqtt' already exists.
2022-11-23 07:06:06.740858842 Requested service registration for 'meross_local_mqtt'

Local Agent Tab

2022-11-24 10:15:50.982419259 DEBUG:Local MQTT: received message on topic /appliance/2208024516145751080148e1e99d063a/subscribe: b'{"header":{"from":"/app/1-810c498aaa14036ea816e414156d289f/subscribe","messageId":"c183df7a01da09493515d742b8d878c3","method":"GET","namespace":"Appliance.Control.Electricity","payloadVersion":1,"sign":"a572d166d731a39cedc2c4164828bcc2","timestamp":1669284951,"triggerSrc":"Android","uuid":"2208024516145751080148e1e99d063a"},"payload":{"channel":0}}'
2022-11-24 10:15:21.022904537 DEBUG:Local MQTT: received message on topic /appliance/2208024516145751080148e1e99d063a/subscribe: b'{"header":{"from":"/app/1-810c498aaa14036ea816e414156d289f/subscribe","messageId":"b64750a86f82412f597054bdb50c3a21","method":"GET","namespace":"Appliance.Control.Electricity","payloadVersion":1,"sign":"5ec4d3ac128fe00e0d4ffd1a564f4518","timestamp":1669284921,"triggerSrc":"Android","uuid":"2208024516145751080148e1e99d063a"},"payload":{"channel":0}}'
2022-11-24 10:15:20.981978213 DEBUG:Local MQTT: received message on topic /appliance/2208024516145751080148e1e99d063a/subscribe: b'{"header":{"from":"/app/1-810c498aaa14036ea816e414156d289f/subscribe","messageId":"96a95489e3d887ceab2f82b3ad0f6316","method":"GET","namespace":"Appliance.Control.Electricity","payloadVersion":1,"sign":"3631aaf360ed0260fe32d2fe23a09652","timestamp":1669284921,"triggerSrc":"Android","uuid":"2208024516145751080148e1e99d063a"},"payload":{"channel":0}}'
2022-11-24 10:14:51.021690704 DEBUG:Local MQTT: received message on topic /appliance/2208024516145751080148e1e99d063a/subscribe: b'{"header":{"from":"/app/1-810c498aaa14036ea816e414156d289f/subscribe","messageId":"24260f3324e76ff46eb24c09ea877452","method":"GET","namespace":"Appliance.Control.Electricity","payloadVersion":1,"sign":"5ca6d32853f5c9b6c3f5b48246ad11b3","timestamp":1669284891,"triggerSrc":"Android","uuid":"2208024516145751080148e1e99d063a"},"payload":{"channel":0}}'
2022-11-24 10:14:50.982346471 DEBUG:Local MQTT: received message on topic /appliance/2208024516145751080148e1e99d063a/subscribe: b'{"header":{"from":"/app/1-810c498aaa14036ea816e414156d289f/subscribe","messageId":"a64551c0c401d12290a822916b240c6c","method":"GET","namespace":"Appliance.Control.Electricity","payloadVersion":1,"sign":"53ebb86b6c61912c74c0235abd7ee840","timestamp":1669284891,"triggerSrc":"Android","uuid":"2208024516145751080148e1e99d063a"},"payload":{"channel":0}}'
smeagol-github commented 1 year ago

Good evening - I'm also having this issue.

Running VMware VM on ESXi.

Home Assistant 2022.11.4 Supervisor 2022.11.2 Operating System 9.3 Frontend 20221108.0 - latest

Local Broker 0.0.1-rc0 MerossHA/1.2.6 MQTT broker only mode.

I'm happy to do any testing or provide log dumps.

Perhaps of note - I did experience the issue with pairing these devices repeatedly during setup - I ended up setting up a special DHCP lease for them pointing to a DNS view that resolves all the meross.com addresses to the Home Assistant server and that solved that problem for me.

FoxScout commented 1 year ago

I am also having this error. The actual measurement of power, voltage, current, ... is the last one received. I think I have this problem one or two weeks ago. Recently I saw that MEROSS updated the firmware from my lightbulbs and maybe the MS310 also???

ab-c-def commented 1 year ago

Having the same issue here. I can turn Dnd on and off but no power data is coming through.

Altecco commented 1 year ago

Hello, I have the same issue, I moved from Online integration to the local broker due to issue after MSS310 firmware update issue. As other people commented, I can turn on and off but no data on any sensor.

FoxScout commented 1 year ago

Hello, I have the same issue, I moved from Online integration to the local broker due to issue after MSS310 firmware update issue. As other people commented, I can turn on and off but no data on any sensor.

Did it solve the problem the LAN broker? Did it made lose the conection to meross cloud? Once the problem appears, I just need only to restart the server and it works again.

adicrescenzo commented 1 year ago

Hello, I have the same issue, I moved from Online integration to the local broker due to issue after MSS310 firmware update issue. As other people commented, I can turn on and off but no data on any sensor.

Did it solve the problem the LAN broker? Did it made lose the conection to meross cloud? Once the problem appears, I just need only to restart the server and it works again.

The problem occures with the LAN broker, I never tried with the meross cloud because I want to keep everything in my LAN. Restarting the broker doesn't solve the problem, hope that someone can find the solution soon.

FoxScout commented 1 year ago

Hello, I have the same issue, I moved from Online integration to the local broker due to issue after MSS310 firmware update issue. As other people commented, I can turn on and off but no data on any sensor.

Did it solve the problem the LAN broker? Did it made lose the conection to meross cloud? Once the problem appears, I just need only to restart the server and it works again.

The problem occures with the LAN broker, I never tried with the meross cloud because I want to keep everything in my LAN. Restarting the broker doesn't solve the problem, hope that someone can find the solution soon.

Did you try to reboot the sistem, not only the broker?

adicrescenzo commented 1 year ago

Hello, I have the same issue, I moved from Online integration to the local broker due to issue after MSS310 firmware update issue. As other people commented, I can turn on and off but no data on any sensor.

Did it solve the problem the LAN broker? Did it made lose the conection to meross cloud? Once the problem appears, I just need only to restart the server and it works again.

The problem occures with the LAN broker, I never tried with the meross cloud because I want to keep everything in my LAN. Restarting the broker doesn't solve the problem, hope that someone can find the solution soon.

Did you try to reboot the sistem, not only the broker?

Sure, I rebooted Home Assistant a plenty of time but unfortunately nothing changed.

Darkpepsi666 commented 1 year ago

Same problem here. Home Assitant tell me this:

Expected data source not listed You’re configuring a statistic but you couldn’t find your source in the dropdown? That’s caused by a bug in the integration providing the entity. Integrations need to configure their entities correctly so Home Assistant knows that we need to track statistics for it and how.

Open an issue with the author of the integration and link them to https://developers.home-assistant.io/docs/core/entity/sensor#long-term-statistics.

phnguy commented 1 year ago

Same here, no update for this issue?

Growiel commented 1 year ago

I would like to add my voice to the masses here.

In the meantime I will use the LAN addon, but it's not 100% local since I have to keep the devices paired with the Meross for them to work...

Ostepanov commented 1 year ago

Same issue

jamesdeeen commented 1 year ago

Hi, for me also no power data is transmitted.

Home Assistant 2023.7.1

MerossHA/1.2.8

Meross Local Broker Addon Current version: 0.0.1-alpha45 (Changelog)

2 devices mss310

power switch is working, but no power (w) data is shown mqtt:

"payload":{"electricity":{"channel":0," current":0, "voltage":0, "power":0, "config":{"voltageRatio":188,"electricityRatio":102}}}

the smart plugs are in a separate wifi network without access to the internet, all is completely local.

thank you for your incredible work, when this last bit is working, and i'm cloud free from meross, then i will support your work also with some money :)

greetings from germany

adub08 commented 11 months ago

I Also have the issue. Any word on any fixes to this?

benoitm974 commented 11 months ago

Homeassistant deprecated the power and energy in the switch entity. I've pushed a pull request where I've added an energy sensor for plug with energy counter here: https://github.com/albertogeniola/meross-homeassistant/pull/460 to be tested. By the way, I don't know how/if the deprecated code need to be removed from the code and when.

benoitm974 commented 11 months ago

Works in the energy dashboard and shown as new sensor in each plug: cafetiere sources_energy

vmpr commented 10 months ago

Works in the energy dashboard and shown as new sensor in each plug: cafetiere sources_energy

What did you do?

benoitm974 commented 10 months ago

Sorry my message was split in two, yet there are both linked, I pushed code changes to the plugin in order to add energy sensor for plug with energy counter here: https://github.com/albertogeniola/meross-homeassistant/pull/460 Maybe you can thumb up the pull request to get it review and merge, or you can patch the plugin from the code in the pull request.

benoitm974 commented 9 months ago

1.2.10 integrates power transmission can we close this issue ?

albertogeniola commented 9 months ago

Yup! Closing!

adicrescenzo commented 9 months ago

@benoitm974 thank you very much for this implementation. @albertogeniola unfortunately I can't update because I'm using the Local Add-On plugin and this version is not compatibile with it. Do you have any idea when you will release the new version also compatible with the Local Add On? Thanks

albertogeniola commented 9 months ago

@benoitm974 thank you very much for this implementation. @albertogeniola unfortunately I can't update because I'm using the Local Add-On plugin and this version is not compatibile with it. Do you have any idea when you will release the new version also compatible with the Local Add On? Thanks

Last version is now compatible with the updated addon. Just update the addon first and then update the meross component. Please let me know if that works as expected!

adicrescenzo commented 9 months ago

@albertogeniola I've updated the local addon to version 0.0.1-alpha49 then I've updated the meross component to the last available version (1.2.10) but I got an authentication error at the startup and all devices doesn't work anymore. Am I missing something? Thanks

albertogeniola commented 9 months ago

All your devices should be working. You only need to reconfigure the addon via the wizard. Just put back your original login

adicrescenzo commented 9 months ago

All your devices should be working. You only need to reconfigure the addon via the wizard. Just put back your original login

I've done it but I still get "Invalid credentials". The local broker seems to works properly because all my devices are online

albertogeniola commented 9 months ago

Hi @adicrescenzo , can you put a screenshot of the error when you configure the Meross Component?

erpayo commented 9 months ago

Hi, same problem here. Installed local only, switch works (on/off) but all sensors values are 0. 3 plugs mss310 and all 3 with same behaviour. local addon version 0.0.1-alpha49 and meross component version 1.2.10

Searching the web I've seen that mss310 reports 0 in sensors when it does not get NTP time: https://github.com/krahabb/meross_lan/issues/55

If any log may be of any help I'd be glad to post.

RaoulSargent commented 9 months ago

Hi, same problem here. Installed local only, switch works (on/off) but all sensors values are 0. Searching the web I've seen that mss310 reports 0 in sensors when it does not get NTP time

Same.

I did not want any of my 11 meross plugs talking to the internet at all, so I added a firewall rule to totally block them and ran into this issue that they would not work without getting the 'time'.

After a bit of wireshark-ing I found the NTP servers they were trying to contact, which when allowed through the firewall resolved the problem.

Still, I do not want them talking to the Internet, so I blocked them again and added a local DNS entry for my own NTP servers under the name of the ones the plugs wanted to connect with, hoping to spoof/redirect the NTP requests to my own NTP server. - This failed.

Call me paranoid... but... On the suspicion that the meross plugs NTP requests only working with potentially 'dodgy' NTP servers, has the potential these might not be 'true' NTP requests. Perhaps they are using secured/encrypted NTP, obviously a good thing, but I still want to totally isolate these devices. Even if it is legit, secured NTP, it can still be used as some kind of telemetry, leaking location, IP, etc.

Without being able to accept being provided an alternative NTP server (in my limited testing) that means I cannot isolate them from the internet.

I did not do any further decoding of the transmitted packets as I gave up with the meross plugs as being suspicious and untrustable.

I now only use Z-Wave and Zigbee plugs.

erpayo commented 9 months ago

Hi, same problem here. Installed local only, switch works (on/off) but all sensors values are 0. Searching the web I've seen that mss310 reports 0 in sensors when it does not get NTP time

Same.

I did not want any of my 11 meross plugs talking to the internet at all, so I added a firewall rule to totally block them and ran into this issue that they would not work without getting the 'time'.

After a bit of wireshark-ing I found the NTP servers they were trying to contact, which when allowed through the firewall resolved the problem.

Still, I do not want them talking to the Internet, so I blocked them again and added a local DNS entry for my own NTP servers under the name of the ones the plugs wanted to connect with, hoping to spoof/redirect the NTP requests to my own NTP server. - This failed.

Call me paranoid... but... On the suspicion that the meross plugs NTP requests only working with potentially 'dodgy' NTP servers, has the potential these might not be 'true' NTP requests. Perhaps they are using secured/encrypted NTP, obviously a good thing, but I still want to totally isolate these devices. Even if it is legit, secured NTP, it can still be used as some kind of telemetry, leaking location, IP, etc.

Without being able to accept being provided an alternative NTP server (in my limited testing) that means I cannot isolate them from the internet.

I did not do any further decoding of the transmitted packets as I gave up with the meross plugs as being suspicious and untrustable.

I now only use Z-Wave and Zigbee plugs.

The thing is they were working fine (reporting power and energy consumption) under the same network/firewall under merosss app and cloud. Once paired with local MQTT sensors report 0.

I have a pihole dns in my network, so could you provide the NTP server names to try if whitelisting them makes it work?

Thanks

RaoulSargent commented 9 months ago
image

I think I recall this was the main ones (multiple hence the regex): (.|^)aliyun.com$

But I also blocked: ch.pool.ntp.org

erpayo commented 9 months ago
image

I think I recall this was the main ones (multiple hence the regex): (.|^)aliyun.com$

But I also blocked: ch.pool.ntp.org

not lucky.

The only dns request to pihole from mss310 is for A 0.north-america.pool.ntp.org and is not blocked

RaoulSargent commented 9 months ago

Check: https://github.com/bytespider/Meross/issues/53 This has some of the details of what went on (in 2022) but has recently been closed with comments suggesting fixes are now in place. Hopefully that will be what you need to know.

erpayo commented 9 months ago

maybe I'm doing something wrong... looking into MQTT logs there are almost zero GETACK messages... bunch of GET but no GETACK.

I've seen one GETACK message, Appliance.System.All when turning on/off the plug. There is a SET message, then a PUSH, then a GET and then the GETACK. But no more ACKs: {"header":{"messageId":"c9fde7ade5dfc39e0c46918a41ef74eb","namespace":"Appliance.System.All","triggerSrc":"Agent","method":"GETACK","payloadVersion":1,"from":"/appliance/2112237136286551808848e1e983b246/publish","uuid":"2112237136286551808848e1e983b246","timestamp":1699285563,"timestampMs":416,"sign":"e54af7fa3155a1b682293a047b08b5e5"},"payload":{"all":{"system":{"hardware":{"type":"mss310","subType":"un","version":"6.0.0","chipType":"rtl8710cf","uuid":"2112237136286551808848e1e983b246","macAddress":"48:e1:e9:83:b2:46"},"firmware":{"version":"6.3.21","compileTime":"2022/10/31-16:22:11","encrypt":1,"wifiMac":"00:0b:82:a8:3a:ad","innerIp":"192.168.1.59","server":"192.168.1.5","port":2001,"userId":1},"time":{"timestamp":1699285563,"timezone":"","timeRule":[]},"online":{"status":1,"bindId":"4tACx9GDsPLgnivQ","who":1}},"digest":{"togglex":[{"channel":0,"onoff":0,"lmTime":1699285561}]}}}}

erpayo commented 9 months ago

One detail: I've used Custom Pairer app to pair devices to Meross Local Broker Addon

albertogeniola commented 9 months ago

@erpayo I believe your probblem is not related to the original issue, nor to the Invalid Credentials one. Please open a separate issue for that on the local-addon repository.

@RaoulSargent : I confirm NTP is necessary. Please have a look at here.

@adicrescenzo , can you provide a screenshot of the "Invali Credentials" problem? Also, can you please provide the logs from HA when the issue occurs? You should see the merossIot low-level library printing the authentication error.

adicrescenzo commented 9 months ago

@albertogeniola sure, these are the screenshots:

Screenshot 2023-11-06 alle 21 34 10 Screenshot 2023-11-06 alle 21 34 33
albertogeniola commented 9 months ago

Ok looks like the credentials upgrade was not successful. So, you need to reset them. To do so, do as follows:

  1. Navigate to settings -> addons -> Meross Local Broker Addon
  2. Click on "open web UI"
  3. From the menu select "Setup"
  4. Click Edit Configuration
  5. Put your username and password as you would pit them in the HA component login form
  6. Click on SAVE

Then, click "I have installed the App".

At this point, open another tab and try again the login via the Meross component.

That should make it. If does not, please collect the logs from the "status" panel of the addon and post or here.

Let us know!

adicrescenzo commented 9 months ago

Ok looks like the credentials upgrade was not successful. So, you need to reset them. To do so, do as follows:

  1. Navigate to settings -> addons -> Meross Local Broker Addon
  2. Click on "open web UI"
  3. From the menu select "Setup"
  4. Click Edit Configuration
  5. Put your username and password as you would pit them in the HA component login form
  6. Click on SAVE

Then, click "I have installed the App".

At this point, open another tab and try again the login via the Meross component.

That should make it. If does not, please collect the logs from the "status" panel of the addon and post or here.

Let us know!

Unfortunately it didn't work, attached you can find the logs. I also tried to delete the Meross Cloud IoT integration and add it again. In that case the service API address isn't recognized automatically:

Screenshot 2023-11-07 alle 06 57 57

home-assistant_meross_cloud_2023-11-07T05-56-53.222Z.log

albertogeniola commented 9 months ago

Hi @adicrescenzo ,

Thanks. Please first upgrade the meross component via hacs, it looks like you are not using the latest version.

Secondly, please retry the credentials upgrade process and attach the logs you find into the "local api" section under the "status menu" of the local addon. Then do the same when trying to login.

Thanks!

adicrescenzo commented 9 months ago

Hi @adicrescenzo ,

Thanks. Please first upgrade the meross component via hacs, it looks like you are not using the latest version.

Secondly, please retry the credentials upgrade process and attach the logs you find into the "local api" section under the "status menu" of the local addon. Then do the same when trying to login.

Thanks!

Attached you can find the logs. Meross component is updated to the last available version, please check the attached screenshot.

Screenshot 2023-11-07 alle 07 59 25 Screenshot 2023-11-07 alle 07 59 03

home-assistant_meross_cloud_2023-11-07T06-51-22.412Z.log local_api.log

albertogeniola commented 9 months ago

Hi @adicrescenzo ,

looking at the logs here's what I find. In particular, the credentials update action fails because of the following.

Update credentials call

PUT /_admin_/configuration HTTP/1.0" 200 -
2023-11-07 06:47:19.373262067 ERROR:HttpApiError: CODE_WRONG_EMAIL
2023-11-07 06:47:19.372346676 ERROR:Received non-ok API status code: CODE_WRONG_EMAIL. Failed request to API. Response was: {'apiStatus': 1008, 'sysStatus': 0, 'info': 'Email unregistered', 'timestamp': 1699339639, 'data': {}}

It looks like you are attempting to federate with Meross cloud using the default meross@local account. That won't work: the meross@local account is not valid for Meross cloud. If you want to federate with Meross, you need to use your Meross credentials (the same you would use on the official Meross mobile App).

Instead, if you don't want to federate with Meross, you can still use the same meross@local account, but you should uncheck the "Enable Meross Link" and then upgrade your credentials again.

adicrescenzo commented 9 months ago

Hi @adicrescenzo ,

looking at the logs here's what I find. In particular, the credentials update action fails because of the following.

Update credentials call

PUT /_admin_/configuration HTTP/1.0" 200 -
2023-11-07 06:47:19.373262067 ERROR:HttpApiError: CODE_WRONG_EMAIL
2023-11-07 06:47:19.372346676 ERROR:Received non-ok API status code: CODE_WRONG_EMAIL. Failed request to API. Response was: {'apiStatus': 1008, 'sysStatus': 0, 'info': 'Email unregistered', 'timestamp': 1699339639, 'data': {}}

It looks like you are attempting to federate with Meross cloud using the default meross@local account. That won't work: the meross@local account is not valid for Meross cloud. If you want to federate with Meross, you need to use your Meross credentials (the same you would use on the official Meross mobile App).

Instead, if you don't want to federate with Meross, you can still use the same meross@local account, but you should uncheck the "Enable Meross Link" and then upgrade your credentials again.

Ok clear, I don't want to use the Meross Cloud but just the Local Broker. I tought that the meross link should be enabled to do so. I'll retry this evening and I'll let you know. Can I change the password without pair again all my devices to the Local Broker? Because now everyone can see my password :)

Thanks

albertogeniola commented 9 months ago

The password is hashed, but I suggest you to change it anyways.

In any case, you can update your user's password without impacting the devices.

Al

On Tue, Nov 7, 2023, 11:43 adicrescenzo @.***> wrote:

Hi @adicrescenzo https://github.com/adicrescenzo ,

looking at the logs here's what I find. In particular, the credentials update action fails because of the following.

Update credentials call

PUT /admin/configuration HTTP/1.0" 200 - 2023-11-07 06:47:19.373262067 ERROR:HttpApiError: CODE_WRONG_EMAIL 2023-11-07 06:47:19.372346676 ERROR:Received non-ok API status code: CODE_WRONG_EMAIL. Failed request to API. Response was: {'apiStatus': 1008, 'sysStatus': 0, 'info': 'Email unregistered', 'timestamp': 1699339639, 'data': {}}

It looks like you are attempting to federate with Meross cloud using the default @. account. That won't work: the @. account is not valid for Meross cloud. If you want to federate with Meross, you need to use your Meross credentials (the same you would use on the official Meross mobile App).

Instead, if you don't want to federate with Meross, you can still use the same @.** account, but you should uncheck the "Enable Meross Link"* and then upgrade your credentials again.

Ok clear, I don't want to use the Meross Cloud but just the Local Broker. I tought that the meross link should be enabled to do so. I'll retry this evening and I'll let you know. Can I change the password without pair again all my devices to the Local Broker? Because now everyone can see my password :)

Thanks

— Reply to this email directly, view it on GitHub https://github.com/albertogeniola/meross-homeassistant/issues/404#issuecomment-1798253697, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABDO7C6XOP6PCIITXD46W6TYDIGGBAVCNFSM6AAAAAASKGN67WVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTOOJYGI2TGNRZG4 . You are receiving this because you were mentioned.Message ID: @.***>

adicrescenzo commented 9 months ago

@albertogeniola thanks to your suggestions I've just paired successfully the Meross IOT Integration with the Local Broker Addon but I can't see any devices even if their status is "online" in the Local Broker. Is anything else that should I do?

Screenshot 2023-11-07 alle 17 56 05

Thanks

adicrescenzo commented 9 months ago

I solved the issue repairing all the devices from scratch but I still can't see any data related to power usage:

Screenshot 2023-11-07 alle 18 50 56
adicrescenzo commented 9 months ago

If it can help I can see that data has been received by the Local Broker, in fact in the Local Agent logs I have plenty of this row:

`2023-11-09 19:49:39.229261876 DEBUG:Local MQTT: received message on topic /appliance/2208024098407751080148e1e99cfc0e/subscribe: b'{"header":{"from":"/app/1-618025f7db6cd99e7f87a42f2d823be0/subscribe","messageId":"2a1e573f6f451c59bcf061834e09709a","method":"GET","namespace":"Appliance.Control.Electricity","payloadVersion":1,"sign":"b0a1f62dd0c29d12b348c965a7c03c72","timestamp":1699559379,"triggerSrc":"Android","uuid":"2208024098407751080148e1e99cfc0e"},"payload":{"channel":0}}'

2023-11-09 19:49:38.988844409 DEBUG:Local MQTT: received message on topic /appliance/2208023396064351080148e1e99cf1cb/subscribe: b'{"header":{"from":"/app/1-618025f7db6cd99e7f87a42f2d823be0/subscribe","messageId":"bdf5cea7d08ec5cf73f653bcff42ef77","method":"GET","namespace":"Appliance.Control.ConsumptionX","payloadVersion":1,"sign":"be326ca8378d3aae51a95dedb79f16a5","timestamp":1699559379,"triggerSrc":"Android","uuid":"2208023396064351080148e1e99cf1cb"},"payload":{"channel":0}}'

2023-11-09 19:49:38.792052714 DEBUG:Local MQTT: received message on topic /appliance/2208024516145751080148e1e99d063a/subscribe: b'{"header":{"from":"/app/1-618025f7db6cd99e7f87a42f2d823be0/subscribe","messageId":"9dc0f42c65441b191325a100cc115d87","method":"GET","namespace":"Appliance.Control.ConsumptionX","payloadVersion":1,"sign":"86046f3aa22ff084b5d7aeee40015357","timestamp":1699559379,"triggerSrc":"Android","uuid":"2208024516145751080148e1e99d063a"},"payload":{"channel":0}}'`

Patrick010 commented 8 months ago

I have the same issue. My Local Agent log also shows the same messages as adicrescenzo already posted

2023-12-06 23:49:48.245184172 DEBUG:Local MQTT: received message on topic /appliance/2212093723290851080548e1e9b26454/subscribe: b'{"header":{"from":"/app/1-ad8b68928df961ae03590a9dd5552bc5/subscribe","messageId":"4cc24ccd8f9f0582e234a631e3a048d2","method":"GET","namespace":"Appliance.Control.ConsumptionX","payloadVersion":1,"sign":"ab25878332feffdbd1ecb779d86a3791","timestamp":1701906588,"triggerSrc":"Android","uuid":"2212093723290851080548e1e9b26454"},"payload":{"channel":0}}'

I tried connecting to MQTT with MQTT Explorer to see if any messages are getting through, but if I use the same credentials as in the Local Broker setup, I get Connection Refused, Not Authorized

2023-12-06 23:53:59.215402590 DEBUG:DEVICE_ACL=> username: _agent, topic: $SYS/client-disconnections, acc: 1, clientid: broker
2023-12-06 23:53:59.213540361 INFO:127.0.0.1 - - [07/Dec/2023 00:53:59] "
POST /_devs_/auth HTTP/1.1
" 403 -
2023-12-06 23:53:59.197333088 WARNING:LOGIN_CHECK(custom)=> User login attempt failed (UserId me@the.net)
2023-12-06 23:53:59.197304761 DEBUG:LOGIN_CHECK(custom)=> Login attempt from user "me@the.net", provided hash "45731dfecbd0c80857bcc1c52e587a988466e68ae853e0498e089cac10babc89", expected "176661b06915f0ed779d3f59fae6ea0b9a1140127b888a2469689cb888f37436".
2023-12-06 23:53:59.193622042 DEBUG:LOGIN_CHECK=> clientid (mqtt-explorer-26bb2900) does not belong to app/device: performing custom login.
2023-12-06 23:53:59.193403892 DEBUG:LOGIN_CHECK=> username: me@the.net, password: ******, clientid: mqtt-explorer-26bb2900, topic: None, acc: None