From 019fe20e1c4431af31e6ab5f6fe339c2df95ae6c Mon Sep 17 00:00:00 2001 From: fvanroie <15969459+fvanroie@users.noreply.github.com> Date: Mon, 12 Jul 2021 04:13:50 +0200 Subject: [PATCH] Add HASP_USE_CUSTOM --- include/hasp_conf.h | 4 ++++ src/custom/my_custom_template.cpp | 5 +++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/include/hasp_conf.h b/include/hasp_conf.h index eca7a92b..28d2c96f 100644 --- a/include/hasp_conf.h +++ b/include/hasp_conf.h @@ -117,6 +117,10 @@ #define HASP_NUM_GPIO_CONFIG 8 #endif +#ifndef HASP_USE_CUSTOM +#define HASP_USE_CUSTOM 0 +#endif + // #ifndef HASP_NUM_OUTPUTS // #define HASP_NUM_OUTPUTS 3 // #endif diff --git a/src/custom/my_custom_template.cpp b/src/custom/my_custom_template.cpp index b2d65935..a19200b5 100644 --- a/src/custom/my_custom_template.cpp +++ b/src/custom/my_custom_template.cpp @@ -2,9 +2,10 @@ For full license information read the LICENSE file in the project folder */ #include "hasplib.h" -#include "custom/my_custom.h" -#if HASP_USE_CUSTOM > 0 +#if HASP_USE_CUSTOM > 0 && false // <-- set this to true in your code + +#include "custom/my_custom.h" void custom_setup() {