• Skip to main content
  • Skip to primary sidebar

RNTLab.com

The Ultimate Shortcut to Learn Electronics and Programming with Open Source Hardware and Software

  • Courses
  • Forum
    • Forum
    • Ask Question
  • Shop
  • Account
  • Blog
  • Login

Esp8266 webserver

Q&A Forum › Category: ESP8266 › Esp8266 webserver
0 Vote Up Vote Down
umarmohammedru asked 4 years ago

Hello everyone.
Q1 Why that some esp8266 webserver  have slow response?
When button is press on the webpage it took a little while before it respond.
Q2 Whenever I try to compile a websocket server code for esp8266 with this function “ws.cleanupClients()” in the loop it doesn’t compile and I get and error of ” the function does not exist in the library’. But if I remove the function it compile successfully.
Did they update the library?
So that now we don’t need to include the function.
Thanks.

7 Answers
0 Vote Up Vote Down
Sara Santos Staff answered 4 years ago

Hi.
What web server example do you say that has a slow response?
Do you have a good wi-if signal?
Can you tell me the example that gave you the websocket error?
Regards,
Sar

0 Vote Up Vote Down
umarmohammedru answered 4 years ago

2.3 WebSocket Web Servers : Control Output(ON/OFF Buttons), page 261.
I have a good Wi-Fi reception.
It’s the first example of the WebSocket control of the ON/OFF button that I got the slow response. So I don’t know whether  because I removed the function of”ws.cleanupClients()” that causes the slow response. But with the “ws.cleanupClients()” it doesn’t compile at all.

Start your code here
0 Vote Up Vote Down
Sara Santos Staff answered 4 years ago

Hi.
I’ve just tested the project again, and everything is working as expected, and the response is quite fast.
The ws.cleanupClients() compiles just fine.
Can you double-check your platformio.ini file? How does it look?
Can you paste the complete compiling error?
What is the esp8266 board model that you are using?
Regards,
Sara

0 Vote Up Vote Down
umarmohammedru answered 4 years ago

 
I am using Arduino IDE maybe that’s why.
I will try it with platform io. Thank you so much indeed

0 Vote Up Vote Down
umarmohammedru answered 4 years ago

With platform io everything works perfect.

0 Vote Up Vote Down
Sara Santos Staff answered 4 years ago

Great!
I should work with both IDEs. Double-check that you have the latest version of the libraries installed and the ESP8266 boards add-on to make it work using Arduino IDE.
Regards,
Sara
 

0 Vote Up Vote Down
umarmohammedru answered 4 years ago

Okay thank you so much

Primary Sidebar

Login to Ask or Answer Questions

This Forum is private and it’s only available for members enrolled in our Courses.

Login »

Latest Course Updates

  • [eBook Updated] Learn Raspberry Pi Pico/Pico W with MicroPython eBook – Version 1.2 May 26, 2025
  • [New Edition] Build ESP32-CAM Projects eBook – 2nd Edition April 16, 2025

You must be logged in to view this content.

Contact Support - Refunds - Privacy - Terms - MakerAdvisor.com - Member Login

Copyright © 2013-2025 · RandomNerdTutorials.com · All Rights Reserved

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.