From 41eb1e6b866b32a239115060ec55ea40a52f8565 Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Sat, 14 May 2016 00:17:01 +0200 Subject: [PATCH] Add section about logging --- source/_components/mqtt.markdown | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/source/_components/mqtt.markdown b/source/_components/mqtt.markdown index df2adc25741..fe6c392d357 100644 --- a/source/_components/mqtt.markdown +++ b/source/_components/mqtt.markdown @@ -171,6 +171,18 @@ The MQTT component will register the service `publish` which allows publishing m } ``` +### {% linkable_title Logging %} + +The [logger](/components/logger/) component allow the logging of received MQTT messages. + +```yaml +# Example configuration.yaml entry +logger: + default: warning + logs: + homeassistant.components.device_tracker.mqtt: debug +``` + ## {% linkable_title Testing your setup %} The `mosquitto` broker package is shipping commandline tools to send and recieve MQTT messages. As an alternative have a look at [hbmqtt_pub](http://hbmqtt.readthedocs.org/en/latest/references/hbmqtt_pub.html) and [hbmqtt_sub](http://hbmqtt.readthedocs.org/en/latest/references/hbmqtt_sub.html) which are provied by HBMQTT. For sending test messages to a broker running on localhost check the example below: