Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Compilation errors with arduino_esp32 version 3.0.0 #156

Closed
mazgch opened this issue May 29, 2024 · 6 comments
Closed

Compilation errors with arduino_esp32 version 3.0.0 #156

mazgch opened this issue May 29, 2024 · 6 comments
Assignees

Comments

@mazgch
Copy link
Contributor

mazgch commented May 29, 2024

Describe the bug

In file included from /../ArduinoWebsockets/src/tiny_websockets/internals/ws_common.hpp:35,
                 from /../ArduinoWebsockets/src/tiny_websockets/message.hpp:3,
                 from /../ArduinoWebsockets/src/ArduinoWebsockets.h:4,
                 from /private/var/folders/gp/8jsyb2256k32d6sg4qyg25rr0000gn/T/.arduinoIDE-unsaved2024429-2129-qcvm11.y88m/Esp32-Server/Esp32-Server.ino:20:
/../ArduinoWebsockets/src/tiny_websockets/network/esp32/esp32_tcp.hpp:16:60: error: 'WiFiClientSecure' was not declared in this scope; did you mean 'WiFiClient'?
   16 |   class SecuredEsp32TcpClient : public GenericEspTcpClient<WiFiClientSecure> {
      |                                                            ^~~~~~~~~~~~~~~~
      |                                                            WiFiClient
/../ArduinoWebsockets/src/tiny_websockets/network/esp32/esp32_tcp.hpp:16:76: error: template argument 1 is invalid
   16 |   class SecuredEsp32TcpClient : public GenericEspTcpClient<WiFiClientSecure> {
      |                                                                            ^
/../ArduinoWebsockets/src/tiny_websockets/network/esp32/esp32_tcp.hpp: In member function 'void websockets::network::SecuredEsp32TcpClient::setCACert(const char*)':
/../ArduinoWebsockets/src/tiny_websockets/network/esp32/esp32_tcp.hpp:19:13: error: 'class websockets::network::SecuredEsp32TcpClient' has no member named 'client'
   19 |       this->client.setCACert(ca_cert);
      |             ^~~~~~
/..ArduinoWebsockets/src/tiny_websockets/network/esp32/esp32_tcp.hpp: In member function 'void websockets::network::SecuredEsp32TcpClient::setCertificate(const char*)':
/..ArduinoWebsockets/src/tiny_websockets/network/esp32/esp32_tcp.hpp:23:13: error: 'class websockets::network::SecuredEsp32TcpClient' has no member named 'client'
   23 |       this->client.setCertificate(client_ca);
      |             ^~~~~~
/../ArduinoWebsockets/src/tiny_websockets/network/esp32/esp32_tcp.hpp: In member function 'void websockets::network::SecuredEsp32TcpClient::setPrivateKey(const char*)':
/../ArduinoWebsockets/src/tiny_websockets/network/esp32/esp32_tcp.hpp:27:13: error: 'class websockets::network::SecuredEsp32TcpClient' has no member named 'client'
   27 |       this->client.setPrivateKey(private_key);
      |             ^~~~~~

To Reproduce
Install latest arduino_esp32 version 3.0.0 https://github.com/espressif/arduino-esp32/releases/tag/3.0.0
Compile an ArduinoWebSocket example, e.g Esp32-Server.ion

Expected behavior
Compiles well

Code
no changes

Additional context
Install latest arduino_esp32 version 3.0.0

@mazgch
Copy link
Contributor Author

mazgch commented May 29, 2024

seems a #include <WiFiClientSecure.h> may be needed in at least esp32_tcp.hpp

mazgch added a commit to mazgch/hpg that referenced this issue May 29, 2024
- BOOT pin pull up must be set
- Ringbuffer can't be size 0
- you may need to patch ArduinoWebsockets gilmaimon/ArduinoWebsockets#156
- avoid some -wFormat= warnings (better disable completely as wifimanager, SARA-R5 and other libs are affected)
@Mukund2900
Copy link

Mukund2900 commented May 30, 2024

I am getting the same issue. (switched to 2.0.17 and not getting this issue anymore)

@erickcrus
Copy link

seems a #include <WiFiClientSecure.h> may be needed in at least esp32_tcp.hpp

This works for me.

@mazgch
Copy link
Contributor Author

mazgch commented Jun 3, 2024

See #158

@gilmaimon
Copy link
Owner

Thanks @mazgch and everyone - I've released 0.5.4

Can you confirm it solves your issue?

@mazgch
Copy link
Contributor Author

mazgch commented Jun 7, 2024

Solved by release 0.5.4, can be further improved by #160

@mazgch mazgch closed this as completed Jun 7, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants