feat: support esp-idf

This commit is contained in:
Itay Shoshani
2024-10-26 09:46:26 +03:00
parent 7f68f3fdac
commit 1c6575a264

View File

@@ -4,8 +4,10 @@
/// немного переработанная версия старого компонента /// немного переработанная версия старого компонента
#pragma once #pragma once
#include <Arduino.h>
#include <stdarg.h> #include <stdarg.h>
#ifndef F
#define F(string_literal) (string_literal)
#endif
#include "esphome.h" #include "esphome.h"
#include "esphome/components/binary_sensor/binary_sensor.h" #include "esphome/components/binary_sensor/binary_sensor.h"
@@ -16,6 +18,8 @@
#include "esphome/core/component.h" #include "esphome/core/component.h"
#include "esphome/core/helpers.h" #include "esphome/core/helpers.h"
using String = std::string;
// весь функционал сохранения пресетов прячу под дефайн // весь функционал сохранения пресетов прячу под дефайн
// #define PRESETS_SAVING // #define PRESETS_SAVING
#ifdef PRESETS_SAVING #ifdef PRESETS_SAVING