Read the statement by Michael Teeuw here.
MMM-HomeAssistant-Sensors (Development) - Show your HA Sensors on your Mirror
-
This works so nice :) Thank you @Snille
-
@aseadc86 Thank you! :) It is not possible to get two values on the same row (I think) in it’s current form… And also the “pictures” from the sensors does not work. I’m just out of time to fix it… :)
-
I have the same issue as some of the other users here “Error fetching stats” with no errors in MM or HA. I generated a new token and changed it in the config, still no luck.
What version of HA are you running?
It was working for me until HA 2021.10: https://forum.magicmirror.builders/topic/15751/mmm-homeassistant-sensors-stopped-working-after-ha-2021-10-update?_=1645122750604
-
@ivanov_d Hm… Am I missing something? It’s working fine here (except for the pictures), I’m on: Core Version core-2022.2.8 and Supervisor Version supervisor-2022.01.1
Where do you get the error? -
@snille I don’t see any errors in either MM or HA, however I am still getting Error fetching stats in the module front end. Any suggestions for additional places where I could look? I checked the config and all seems fine to me.
-
@ivanov_d Strange… I’m running HA on it’s own machine and MM on it’s own machine as well, don’t know if that matters… The HA module works on both my “Development” build and the “Real” mirror…
Oh, I’m NOT using a password for the API, that has in deed been deprecated…
This is my “top” part of the Module:{ disabled: false, module: 'MMM-homeassistant-sensors', hiddenOnStartup: true, position: 'top_center', classes: "Me Work Weather", config: { host: "X.X.X.X", port: "8123", https: false, title: "Information", updateInterval: 60000, fade: 0, token: "Very-Long-MM-Token...", values: [...]
When did it stop working?
-
@snille it stopped working after HA version 2021.10 when the API discovery feature was deprecated. I am running HA Supervised on one raspberry pi and MM on another raspberry pi in the same network.
Here is the config of the MM module:
{ module: 'MMM-homeassistant-sensors', position: 'top_right', config: { title: 'Сензори', rowClass: 'normal', host: "192.168.1.19", port: "8123", https: true, //I have SSL enables since my instance is exposed to the Internet token: "here_goes_my_token", values: [ { sensor: "sensor.bathroom_temp_temperature", name: 'Температура', icons: [{ "default": "thermometer" }] }, { sensor: "sensor.bathroom_temp_humidity", name: 'Влажност', icons: [{ "default": "water-percent" }] }, { sensor: "switch.bathroom_fan_1", name: 'Вентилатор 1', icons: [{ "on": "fan", "off": "fan-off" }], replace: [{ "on": "вкл.", "off": "изкл." }] }, { sensor: "switch.bathroom_fan_2", name: 'Вентилатор 2', icons: [{ "on": "fan", "off": "fan-off" }], replace: [{ "on": "вкл.", "off": "изкл." }] }, ] } },
Here is the changelog of HA 2021.10:
The API endpoint /api/discovery_info now only return blank values. This endpoint is scheduled to be removed in Home Assistant Core 2022.1. As a regular user of Home Assistant, this change should not affect you. (@ludeeus - #56097) (api docs)
In the past I was having issues with https and the local IP address and then I changed it to the DNS hostname blabla.duckdsn.org and the external port for https (443) and it was working fine until the /api/discovery_info endpoint was deprecated.
-
@snille Well that’s really not a deal breaker. It works and gaps the bridge. It’s a great module!
-
@ivanov_d It’s still working for me, when using https. It got to be something else…
I changed my conf to this and it works…{ disabled: false, module: 'MMM-homeassistant-sensors', hiddenOnStartup: false, position: 'top_right', config: { host: "my.ha.url.com", port: "443", https: true, updateInterval: 60000, fade: 0, title: "Information", noaddress: "Away", token: "token...", values: [ { sensor: "sensor.living_room_temperature", name: "Temp i Vardagsrummet %t%", icons: [{ "default": "thermometer" } ] } ] } }
I’m on Hass.IO (from start), maybe the api is still active there? I don’t get it…
It does not work for me on port 8123, but that’s to be expected when using ssl. -
@snille what is the most up-to-date code repo? The one that I pulled from is https://github.com/theskyisthelimit/MMM-homeassistant-sensors.git
Could it be that I have an old code base? I tried with different ports, URL/IP, still the same and still no errors in both logs HA or MM …
EDIT: I tried with another HA instance that I have which doesn’t have SSL enabled and it worked, so now I need to figure out what the difference between the two are :)
Will keep you posted.