ESPHome  2024.11.1
ota_backend_arduino_esp8266.h
Go to the documentation of this file.
1 #pragma once
2 #ifdef USE_ARDUINO
3 #ifdef USE_ESP8266
4 #include "ota_backend.h"
5 
6 #include "esphome/core/defines.h"
7 #include "esphome/core/macros.h"
8 
9 namespace esphome {
10 namespace ota {
11 
13  public:
14  OTAResponseTypes begin(size_t image_size) override;
15  void set_update_md5(const char *md5) override;
16  OTAResponseTypes write(uint8_t *data, size_t len) override;
17  OTAResponseTypes end() override;
18  void abort() override;
19 #if USE_ARDUINO_VERSION_CODE >= VERSION_CODE(2, 7, 0)
20  bool supports_compression() override { return true; }
21 #else
22  bool supports_compression() override { return false; }
23 #endif
24 };
25 
26 } // namespace ota
27 } // namespace esphome
28 
29 #endif
30 #endif
OTAResponseTypes begin(size_t image_size) override
std::string size_t len
Definition: helpers.h:293
OTAResponseTypes write(uint8_t *data, size_t len) override
Implementation of SPI Controller mode.
Definition: a01nyub.cpp:7