Multiple instances of MMM-MQTT wont subscribe to mqtt messages
rob73 last edited by rob73
I am very new at this but I have setup a simple configuration. I use mqtt messages for my ‘home information system’. I use esp8266’s connected to sensors and send those messages to node-red to keep track of stuff here at the house. I have MMM-MQTT module setup & it is straight down the middle, top_center in the config. I have about 24 subscriptions in that module displayed. I would like another column of data, so I just added another module and adjusted the spacing and it placed it right beside the other module, it was almost perfect for what I want. As long as the second module has the same subscriptions as the first one, they show up. As in if I copy the whole module config and just paste it in the config file. If I set any new mqtt subscriptions, they will not be displayed, they display nothing in the data field. I think the second instance is not actually subscribing to the messages on the mqtt broker. I can send messages and receive them on other devices but they are not picked up on the second instance of MMM-MQTT that I added to the configuration file. After some testing, I determined that it is not subscribing to any messages that are placed in the config file under the second instance of that module.
Any help would be appreciated on this topic. I have it configured to be in the top_center. If I could make two columns right down the middle on that single module, that would probably do for me. I struggle to edit the config files to get the spacing and formatting the text. I am so new to it, I dont even know whats possible and what is not. Its like reading a foreign language to me, lol.
This afternoon I added the module MMM-Gas. I added two instances of that module in my config file. If I give them different zip codes, it will display two instances but they will both have the same zip code.
Is this normal behavior of having two instances of a module in the setup or am I not configuring them right? I dont know enough about this stuff yet to know what I can do and what I cant. I am guessing I am trying to do something that isnt possible or I am not setting it up right…
I found a workaround for the MMM-Gas two zip code issue that I had. I copied the module to a new folder called MMM-MyGas. Edited the files to make that a separate module & it allowed me to have two of those modules on the display with two different zip codes. I work in a different zip code and it will be handy to know the gas prices there too.
I am going to do the same to the MMM-MQTT module and see if that will work the same way. I will post the results when I get some modifying and testing done.
After a few modifications and tests, I can setup two different MMM-MQTT columns if I do the module copy like I did with the MMM-Gas module. Its a workaround, but I am not sure this is the only way that it can be done. It does work, but I have no idea if it is the correct way to do something like this. I may not be explaining myself very well, and if anyone has any questions, just comment or message me.