#1) I assume you are trying to associate existing HS Devices with commands published via MQTT. mcsMQTT calls these non-plugin devices and will be showing in a pink on the Association tab. When the Associate checkbox is clicked a blank subscribe and a pre-populated publish text boxes are presented. The subscribe textbox needs to be filled in with the MQTT topic that will cause the HS device to be updated. This needs to be a unique subscribe topic as provisions do not exist for multiple devices being updated on a single topic other than the provisions made for JSON decoding for the plugin (green backround) Devices. I don't know about the timing relationship, but I would think whatever is showing in the text box when the Submit button is clicked will be what is taken as the topic. A page refresh would confirm.
#2) The CAPI message is produced when there is a HS Device that was associated with a MQTT subscribe topic and the payload that was received on that topic is not one of the control options setup for that HS Device. For example, HS device may have controls for ON and OFF and the MQTT payload used to command this device was OPEN. This is likely why you are not seeing some devices being updated. If you enable the debug then I believe I put in the log the list of commands that a device is expecting. The log is produced in \data\mcsMQTT as a .txt file. It could be that the MQTT payload sometimes match what the Device is expecting and sometimes does not so it may look intermittent. In the cases where no update and not CAPI messages are in the HS log then look at the payload on the Association tab and confirm it is updating. If not then look closely at the subscription topic vs. what your external device is publishing.
#2) The CAPI message is produced when there is a HS Device that was associated with a MQTT subscribe topic and the payload that was received on that topic is not one of the control options setup for that HS Device. For example, HS device may have controls for ON and OFF and the MQTT payload used to command this device was OPEN. This is likely why you are not seeing some devices being updated. If you enable the debug then I believe I put in the log the list of commands that a device is expecting. The log is produced in \data\mcsMQTT as a .txt file. It could be that the MQTT payload sometimes match what the Device is expecting and sometimes does not so it may look intermittent. In the cases where no update and not CAPI messages are in the HS log then look at the payload on the Association tab and confirm it is updating. If not then look closely at the subscription topic vs. what your external device is publishing.
Comment