From 03da3d743960824dabcc51e43f157fd58220b250 Mon Sep 17 00:00:00 2001 From: Rene 'Renne' Bartsch Date: Tue, 17 Jul 2018 17:31:04 +0200 Subject: [PATCH] Reference to XdrvMailbox.index and example call of parser function added to section FUNC_COMMAND ID. --- Sensor-API.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Sensor-API.md b/Sensor-API.md index 809ac5d4..f6ede560 100644 --- a/Sensor-API.md +++ b/Sensor-API.md @@ -135,6 +135,14 @@ This callback ID is called to allow a sensor to prepare for saving configuration ### FUNC_COMMAND This callback ID is called when a sensor specific command ``Sensor`` is executed where xx is the sensor index. +``` + case FUNC_COMMAND: + if (XSNS_ == XdrvMailbox.index) { + result = Command() { ... }; // Return true on success + } + break; + +``` ``` // Data struct of FUNC_COMMAND ID struct XDRVMAILBOX {