Sorry for not replying in a while!
I recently built a docker that runs a python webserver middle-man that runs between Xeoma and MQTT (You can view it here: https://github.com/skylord123/xeoma-mqtt ). It takes requests from the HTTP Request Sender module (you point this module to the docker open port) and it will turn the http request into an MQTT message and post it so HA can act on it. I've been using it with a second motion detection module on my front yard cameras to trigger my garage door lights if motion is detected in my driveway and my front door light if motion is detected on the path going up to my front door. It works pretty well. Only issue I have right now is bugs flying in front of the camera but I have been able to bring these false reports down by using the "Disregard motion shorter than" in the motion module.
Now I have also setup HA to trigger recordings on my inside cameras when my PIR motion sensor goes off. It works like this: The PIR motion sensor is an ESP8266 with a cheap PIR motion sensor. When motion is detected it sends a message over MQTT to a channel. HA then gets this and then triggers the "HTTP Switcher" module on my inside camera to start recording. I use this with the motion module and tagging so I know which event triggered the recording. Here is how it looks:
Camera module setup: https://u34423400.dl.dropboxusercontent.com/u/34423400/DualCameraTriggerWithCondition.png
Camera condition module setup: https://u34423400.dl.dropboxusercontent.com/u/34423400/ConditionDualTrigger.png
And here is the code I use to trigger the recording from HA (had to use CURL commands) as well as get status of the switch (so HA isn't in the dark when a reset happens or something and the switch is still on):
- Code: Select All Code
switch:
- platform: command_line
switches:
inside_camera_record:
command_on: 'curl -k "http://xxx.xxx.xxx.xxx:10090/record_trigger_on?module=HttpSwitcher.8"'
command_off: 'curl -k "http://xxx.xxx.xxx.xxx:10090/record_trigger_off?module=HttpSwitcher.8"'
command_state: 'curl -k "http://xxx.xxx.xxx.xxx:10090/record_trigger_off?module=HttpSwitcher.8&show_status=true"'
value_template: '{{ "On" in value }}'
I really want to make it so the xeoma-mqtt code I have written can trigger switches in xeoma from MQTT (that way I don't have to use Curl). Will probably add this in the future. But this works great for now.
EDIT: SMTP to trigger your lights.. Oh man. You can definitely easily improve that response time by switching to another method.