Replies: 11 comments 1 reply
-
Which script is that, @notsomot? I've a thinking that it is the script "MQTT final", going by the line number. That looks for all the world like the event script MQTT final is installed as a resident script. That's not right. If that were installed as a resident then you'd get an error like that, because the in-built table "event" would not exist in a resident. It needs to be an event script, set to not execute during ramping, and tied to the group address / keyword MQTT. |
Beta Was this translation helpful? Give feedback.
-
Thanks for the prompt reply @autoSteve. Have moved the script and getting a similar error Also, was unsure what yaml to edit, so have tried a few different places with limited success. When I use the MQTT expolorer, I can see the homeassistant and the CBUS. I can send the CBUS commands via the HA. But they arent talking to each other naturally. If someone was able to spend an hour or two with me, teaching me, would be happy to pay. |
Beta Was this translation helpful? Give feedback.
-
Hi Steve, Library cbuslogic:0: Unable to find network tag '0/56/3' Got a new error this time, guess that is progress. Do I tag the objects in the CBUS objects list with the tag MQTT? |
Beta Was this translation helpful? Give feedback.
-
I suggest reading the README to get a handle on exactly what to do. For CBus sync, you need to install the following two scripts only:
Then set up keywords for objects in the SHAC that you want to sync with HA, which is documented in the README. MQTT Final is only applicable for firmware 1.15.0+. If using less than this then upgrade, or see the README about using "MQTT" event-based instead. The resident script "Heartbeat", and everything else is optional. The yaml files in acMQTT are examples for using ESPHome IoT devices, which you probably don't need. The other yaml that might want editing is /homeassistant/configuration.yaml in HA to set up things like Google Assistant. There are examples for how to set up keywords in the README. At the most basic, for lighting objects all that is needed is the keyword "MQTT", with the additional keyword "light" being the default type. Other keywords exist for many things, like switch, sensor and more. Also keywords like "pn=My desired name" to use a name other than the SHAC object name, and "sa=Kitchen" for suggested area. So, for example: Or: Tagging with these keywords does two things. Firstly it allows HA discovery topics to be automatically built. Secondly it allows the MQTT Final script to fire when object values change in CBus, which causes MQTT send receive to send the value to the Mosquitto broker, which HA then picks up. For the error, post a screen clip of what your objects look like. |
Beta Was this translation helpful? Give feedback.
-
Here's what some of my objects are set up like: |
Beta Was this translation helpful? Give feedback.
-
Hi @autoSteve Do I just put this in the configeration.yaml ? |
Beta Was this translation helpful? Give feedback.
-
This is the exact content of mine. I use Nabu Casa HA Cloud, hence the Google assistant settings. What sort of HA timeouts?
|
Beta Was this translation helpful? Give feedback.
-
Something is posessed here. Join the Zoom again and I'll take you through some things... |
Beta Was this translation helpful? Give feedback.
-
You are a dead set legend, thankyou again Steve. Made my day. |
Beta Was this translation helpful? Give feedback.
-
New commit just now for MQTT send receive. Ignores the capitalisation of MQTT and MQTT final. 🤣 |
Beta Was this translation helpful? Give feedback.
-
And the MQTT final event script is GONE, and good riddance! No capitalisation work-around. There is now just a single resident script for MQTT send receive as the name suggests. If you've not been looped in to recent commits @notsomot, this is one of the latest, and coolest I think. I did loop you in to 'Announcements', so you've likely seen this. Recently also, by default there is a change to the entity naming so things become like light.kitchen_main_light, instead of light cbus_mqtt_254_56_1. This will break dashboards, so if you've no desire to change then there's a variable near the top of the script to change behaviour to legacy. But It's sooo much better to manage things like automations with the more friendly entity name, so ripping the bandaid off and fixing dashboards might be worth it. I'm trying to discipline myself to create branches in github and then merge them to acMqtt. Doing so will notify you of changes that may be significant as long as you're watching the acMqtt repository, which you currently are not. |
Beta Was this translation helpful? Give feedback.
-
Heya,
Would someone be interested in walking me through this, please? I have got to a point, im not going anywhere - looking for someone to assist with fault finding and remote login to see what I have done wrong.
Can see the CBus, the home assistant, but getting errors
Resident script:43: attempt to index global 'event' (a nil value)
stack traceback:
Beta Was this translation helpful? Give feedback.
All reactions