|
LSH-Core
A robust C++ framework for Arduino-based home automation nodes
|
Provides the user-facing macros (LSH_ACTUATOR, LSH_BUTTON, LSH_INDICATOR) for device configuration. More...
#include "config/configurator.hpp"#include "internal/user_config_bridge.hpp"#include "peripherals/input/clickable.hpp"#include "peripherals/output/actuator.hpp"#include "peripherals/output/indicator.hpp"#include "util/debug/debug.hpp"

Go to the source code of this file.
Macros | |
| #define | LSH_ACTUATOR(var_name, pin, id) |
| Defines an Actuator with a compile-time check to ensure its ID is not 0. | |
| #define | LSH_BUTTON(var_name, pin, id) |
| Defines a Clickable (Button) with a compile-time check to ensure its ID is not 0. | |
| #define | LSH_INDICATOR(var_name, pin) Indicator var_name((pin)) |
| Defines an IndicatorLight. Does not require an ID. | |
Provides the user-facing macros (LSH_ACTUATOR, LSH_BUTTON, LSH_INDICATOR) for device configuration.
Copyright 2025 Jacopo Labardi
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
| #define LSH_ACTUATOR | ( | var_name, | |
| pin, | |||
| id | |||
| ) |
Defines an Actuator with a compile-time check to ensure its ID is not 0.
| var_name | The name of the variable to declare (e.g., rel0). |
| pin | The hardware pin for the actuator. |
| id | The unique numeric ID for the actuator. MUST be > 0. |
| #define LSH_BUTTON | ( | var_name, | |
| pin, | |||
| id | |||
| ) |
Defines a Clickable (Button) with a compile-time check to ensure its ID is not 0.
| var_name | The name of the variable to declare (e.g., btn0). |
| pin | The hardware pin for the clickable. |
| id | The unique numeric ID for the clickable. MUST be > 0. |
| #define LSH_INDICATOR | ( | var_name, | |
| pin | |||
| ) | Indicator var_name((pin)) |
Defines an IndicatorLight. Does not require an ID.
| var_name | The name of the variable to declare (e.g., light0). |
| pin | The hardware pin for the indicator. |