From f32f00f8aeae3f4e9959701f09cc79f826fff93b Mon Sep 17 00:00:00 2001 From: Rene 'Renne' Bartsch Date: Thu, 12 Jul 2018 17:49:48 +0200 Subject: [PATCH] Minor improvements of code example. --- Sensor-API.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Sensor-API.md b/Sensor-API.md index 587f5559..7a5753e7 100644 --- a/Sensor-API.md +++ b/Sensor-API.md @@ -11,6 +11,9 @@ Conditional compiling of a sensor driver is achieved by commenting/uncommenting Any sensor driver needs a callback function following the scheme ``` +// Conditional compilation of driver +#ifdef USE_ + // Define driver ID #define XSNS_ @@ -27,7 +30,7 @@ Any sensor driver needs a callback function following the scheme */ boolean Xsns(byte callback_id) { - // ??? + // Set return value to `false` boolean result = false; // Check if I2C interface mode @@ -72,11 +75,12 @@ boolean Xsns(byte callback_id) { case FUNC_FREE_MEM break; } -// } // i2c_flg +// } // if(i2c_flg) // Return boolean result return result; } +#endif // USE_ ```