arachnetech / homebridge-mqttthing

A plugin for Homebridge allowing the integration of many different accessory types using MQTT.
Apache License 2.0
462 stars 104 forks source link

Exception while creating services: TypeError: Cannot read properties of undefined (reading 'getSwitch') #626

Closed Asherlc closed 1 year ago

Asherlc commented 1 year ago

Recently started getting this error when starting homebridge-mqttthing:

 Exception while creating services: TypeError: Cannot read properties of undefined (reading 'getSwitch')`

my config is pretty simple:

       {
            "type": "doorbell",
            "name": "Doorbell",
            "url": "mqtt://192.168.0.106:1883",
            "logMqtt": true,
            "switchValues": [
                "bell1"
            ],
            "_bridge": {
                "username": "0E:F9:65:6C:2A:BC",
                "port": 59575
            },
            "accessory": "mqttthing"
        }

anyone have any ideas? not even sure how to get a good stack trace with homebridge

Asherlc commented 1 year ago

Nvm, i needed to specify a topic in the config