Arduino Tiny Web Server - BlinkLED project
Uploader Comments (webweavert)
All Comments (15)
-
Great Work! Thanks for showing this!
Lee Studley
-
@stheodro The program does close the connections as soon as the response is sent back. The reason for the slow performance is the W5100 which allows a maximum of 4 sockets being opened. Because we cannot afford to keep an open socket to send light status notifications to a client, each client polls the Arduino server every 400ms or so to get status updates. Creating a new connection is time consuming and the more client browsers connect, the more problems you'll see.
-
@stheodro The best solution would have been to close all connections UNLESS any update/change was made to the light status. Then even if you had 3,000 browser they would get only the quick led/light status update like LOW or HIGH then close all connection quick. Programs should not be bandwidth hogs in order to be fast and efficient. Can't we use the technology like E-mail or Twitter enjoys? where is the sociability here?
Please TinyWebServer Engineer i know you can make it happen :)
-
@davidbl1981 You're absolutely right. I tested this program using four web browers connected at the same time...well it was sloooooooooow to a crawl. What is the point of the program if its going to lag and get stuck? i checked using WireShark and the Arduino never closes the connection, constantly taking to the browser connected to it. Even if no one turns the light off or on, the Arduno keeps the network flooded with data talking to any browser connected to it. NOT GOOD at all.
-
Hi Arduino community.
If using windows, to get the BlinkLED up and running follow my steps:
1. Format you SD card to FAT or FAT16 with windows
2. Using SD adapter download the 2 files: ( index.htm , jquery.js , main.js , lights.png )
3. Then plug the tiny SD card to Arduino
4. Plug you Ethernet to Arduino
5. Open the ( BlinkLed.pde ) program using arduino software to upload it.
3. to test go to your web browser and type your arduinos IP address
THE END
-
Just remember that the Ethernet shield can only serve up 4 simultaneous connections at a time. So when you keep connecting back via Ajax to get led status your actually taking up important connection limits. At least if you need to share it with multiple users.
-
@youssefvideotube That's something I want to know to
-
@webweavert Realy Nice Job... but i have another little question... does the Tiny Web Server support php scripts ?
Thanks! Do you think it should be easy adding PHP support?
LosNir 3 months ago
@LosNir PHP has a large interpreter which will not fit in the limited amount of ROM and RAM available on the Arduino. A better approach is to use a small Linux computer that talks to an Arduino over USB. You can run PHP on the small computer and let the Arduino handle the interactions with the hardware.
webweavert 3 months ago
Great! im new to this i have a question. if you use this should the arduino needs to be connected to a computer or not?
bhyltng 11 months ago
@bhyltng No, you do not. The Arduino with the Ethernet shield are only connected to a power supply and your wired Ethernet network. Any computer, not just the phone, can access the web server running on the Arduino.
webweavert 11 months ago