OpenSprinkler Forums OpenSprinkler Unified Firmware ESP32 port of 2.1.9 firmware Reply To: ESP32 port of 2.1.9 firmware

#75800

polskifacet
Participant

I added the extra lines to .cpp

int Esp32LocalClient::peek() {
return client.peek();
}

void Esp32LocalClient::setTimeout(int timeout) {
client.setTimeout(timeout);
}
void Esp32LocalClient::flush() {
client.flush();
}

void Esp32LocalClient::stop() {
client.stop();
}
#endif

I’m not sure what to do in the .h

.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp: In member function ‘virtual OTF::LocalClient* OTF::Esp32LocalServer::acceptClient()’:
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp:15:51: error: invalid new-expression of abstract class type ‘OTF::Esp32LocalClient’
activeClient = new Esp32LocalClient(wiFiClient);
^
In file included from .pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp:2:
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.h:11:9: note: because the following virtual functions are pure within ‘OTF::Esp32LocalClient’:
class Esp32LocalClient : public LocalClient {
^~~~~~~~~~~~~~~~
In file included from .pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.h:5,
from .pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp:2:
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/LocalServer.h:36:18: note: ‘virtual void OTF::LocalClient::flush()’
virtual void flush() = 0;
^~~~~
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/LocalServer.h:37:18: note: ‘virtual void OTF::LocalClient::stop()’
virtual void stop() = 0;
^~~~
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp: At global scope:
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp:58:6: error: no declaration matches ‘void OTF::Esp32LocalClient::flush()’
void Esp32LocalClient::flush() {
^~~~~~~~~~~~~~~~
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp:58:6: note: no functions named ‘void OTF::Esp32LocalClient::flush()’
In file included from .pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp:2:
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.h:11:9: note: ‘class OTF::Esp32LocalClient’ defined here
class Esp32LocalClient : public LocalClient {
^~~~~~~~~~~~~~~~
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp:62:6: error: no declaration matches ‘void OTF::Esp32LocalClient::stop()’
void Esp32LocalClient::stop() {
^~~~~~~~~~~~~~~~
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp:62:6: note: no functions named ‘void OTF::Esp32LocalClient::stop()’
In file included from .pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp:2:
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.h:11:9: note: ‘class OTF::Esp32LocalClient’ defined here
class Esp32LocalClient : public LocalClient {
^~~~~~~~~~~~~~~~
Compiling .pio/build/esp32_sprinkler/libefe/ESP32-ENC28J60/extmod/esp_eth_phy_enc28j60.c.o
*** [.pio/build/esp32_sprinkler/lib941/OpenThings-Framework-Firmware-Library/Esp32LocalServer.cpp.o] Error 1
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/OpenThingsFramework.cpp: In constructor ‘OTF::OpenThingsFramework::OpenThingsFramework(uint16_t, char*, int)’:
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/OpenThingsFramework.cpp:23:21: error: ‘virtual void OTF::Esp32LocalServer::begin()’ is private within this context
localServer.begin();
^
In file included from .pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/OpenThingsFramework.h:14,
from .pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/OpenThingsFramework.cpp:1:
.pio/libdeps/esp32_sprinkler/OpenThings-Framework-Firmware-Library/Esp32LocalServer.h:30:12: note: declared private here
void begin();
^~~~~
*** [.pio/build/esp32_sprinkler/lib941/OpenThings-Framework-Firmware-Library/OpenThingsFramework.cpp.o] Error 1