- Platform information:
- Hardware: CPUArchitecture/RAM/storage
- OS: what OS is used and which version
- Java Runtime Environment: which java platform is used and what version
- openHAB version:2.5.10
- Issue of the topic: please be detailed explaining your issue
I have configured AgentDVR (https://www.ispyconnect.com/userguide-agent-mqtt.aspx) to talk to my mosquitto mqtt instance. I currently use mqtt to control a number of Tuya switches and plugs. I have figured out what mosquitto_pub command I need to send on my Linux server to start/stop recording but I want to do that from within OpenHab. I can’t seem to figure out how to configure the Thing and Item that will allow me to do that within rules. For example I would like to record for 30 seconds whenever the front door is opened.
Here is the mosquitto_pub command that will accomplish what I want. I would appreciate it if someone could help or guide me towards the solution to implement it in Openhab.
mosquitto_pub -t “Agent/commands” -m “cmd=recordswitch&ot=2&oid=6” -h localhost