Hi -
I'm not very experienced with Arduino and I am trying to follow an example project with ESP32 Wifi module. I have successfully made a blinking LED so that is a good start.
I wanted to make a simple Wifi web server and so I downloaded a .iso file from github. The file has this line #include <WebSocketsServer.h> which causes a compile error, I suppose this is because I do not have the library "WebSocketsServer" installed. I have tried to search for that library using the library manager but it can't find it. I have searched github for it but also can't find it.
Any suggestions on where I can find this file as this example is useless without it.
Welcome to the forum
Why did you start a topic in the Uncategorised category of the forum when its description is
DO NOT CREATE TOPICS IN THIS CATEGORY
Your topic has been moved to the Programming category
Which Arduino board are you using ?
Pleas post a link to where you downloaded this file from
I typed #include <WebSocketsServer.h>
as a Google search and the first hit I got was
it seems also to be listed in the Arduino's known libraries
Hello Bob - thank you. I'm sorry for posting in the wrong section. I guess I wasn't sure which section to post my question in.
I'm using the ESP32 DEVKITV1.
The project file came from here GitHub - mo-thunderz/Esp32WifiPart2: How to create a Webserver on an ESP32 with Websockets and JSON
Thanks J-M-L but perhaps I am not getting it but surely the result you got are not the same as WebSocketsServer.h the library that I need.
Don't I need to find the exact library?
Please look at this example code.
https://github.com/mo-thunderz/Esp32WifiPart2/blob/main/Arduino/ESP32WebserverWebsocket/ESP32WebserverWebsocket.ino
It has some documentation in a commented section at the start
// For installation, the following libraries need to be installed:
// * Websockets by Markus Sattler (can be tricky to find -> search for "Arduino Websockets"
Yes and as @cattledog wrote
so the one I shared seems to be the right one
okay, so I should download the zip file from github (I see there is a WebSocketsServer.h file in there among many others) and 'add zip library' from the Arduino sketch menu?
It is more simple to use the Library Manager of the IDE.
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.