michaelarnauts / cec-mqtt-bridge

A HDMI-CEC to MQTT bridge for connecting HDMI-CEC-devices to your Home Automation system.
145 stars 48 forks source link

Add config for ir sleep time #23

Open heikomat opened 5 years ago

heikomat commented 5 years ago

This moves the sleep-time of ir-command-checks to a config variable. With this change you can reduce the ir sleep-time (or increase it, though i wouldn't know why anyone would wand that).

reducing the sleep time in turn reduces the delay between receiving an ir command and the associated mqtt-message, which can make actions (like pressing a button on a remote and the resulting action based on the mqtt message) feel snappier.

In my example i have one Raspberry PI running this bridge and another one that is connected to the remote control of my sound system and running an mqtt client. With this change, using the volume-buttons on my ir-remote feels snappier (i set it to 0.01 instead of the default 0.2)