INSTAR Deutschland GmbHINSTAR Deutschland GmbH

ioBroker as MQTT Broker for your Camera



Q: I installed my MQTT camera according to your guide in ioBroker. But now I do use the MQTT Adapter as my primary MQTT Broker - not as a MQTT Client. And I am unable to update Command Topics through the ioBroker object tree.

A: Our ioBroker Guide uses the MQTT service of your INSTAR Full HD camera as your MQTT broker. Accordingly, you have to set the MQTT Adapter to Client/subscriber mode and connect it to your camera:

INSTAR MQTT for ioBroker

Client Mode

Operated as an MQTT Client it is very important not to activate any of those option seen the center of the following screenshot. Especially, activating the publishing of states when a clients connects to ioBroker can have surprising consequences

INSTAR MQTT for ioBroker

After saving the settings and restarting the MQTT adapter, your camera should push out all retained MQTT Status Topics (login credentials are excluded and only accessible by Command Topics) and ioBroker will add them to the Object Tree. You can now use a tool like MQTT.fx to update a Command Topic and see your cameras response in the Status Topic in ioBroker:

INSTAR MQTT for ioBroker

Alternatively, you can edit the RAW Command Topic - that you added following our ioBroker Guide - directly inside the ioBroker Object Tree and trigger an updated, signaled by the status update immediately after:

INSTAR MQTT for ioBroker

You are now able to use any event inside ioBroker to update your camera settings. As well as, using updates in camera settings to toggle states in ioBroker.

Broker Mode

If you operate the MQTT Adapter in Server/broker mode:

INSTAR MQTT for ioBroker

Make sure that the prefix field is left empty, you check the option to publish topics if their value changed and set the Quality-of-Service to 1 - At least once:

INSTAR MQTT for ioBroker

This time we have to configure our camera to connect to the external broker (ioBroker):

INSTAR MQTT for ioBroker

And everything should now work like it did with the client mode.

Note: In mode the Status Topics will also be resolved to their RAW Value. So instead of seeing a value of {"val":"1"} you will have to work with the raw value 1:

INSTAR MQTT for ioBroker