Fix compile for upcoming Arduino Core 2.0.15 (#20908)

* Fix compile for Arduino Core > 2.0.14
* missing include `esp_arduino_version.h`
This commit is contained in:
Jason2866 2024-03-10 14:08:29 +01:00 committed by GitHub
parent 14f976b8a4
commit 224a9fb717
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -6,7 +6,7 @@
* 2 wire communication - I2C
*******************************************************************/
#include "be_constobj.h"
#include "esp_idf_version.h"
#include "esp_arduino_version.h"
extern int b_serial_init(bvm *vm);
extern int b_serial_deinit(bvm *vm);
@ -16,7 +16,7 @@ extern int b_serial_read(bvm *vm);
extern int b_serial_available(bvm *vm);
extern int b_serial_flush(bvm *vm);
#if ESP_IDF_VERSION_MAJOR < 5
#if (ESP_ARDUINO_VERSION < ESP_ARDUINO_VERSION_VAL(2, 0, 15))
#include "esp32-hal.h"
#else
// it should be #include "HardwareSerial.h"