Code Monkey home page Code Monkey logo

arduinowebsocketserver's People

Contributors

albaltas avatar aphex avatar bentech avatar danieloneill avatar ejeklint avatar lpmi-13 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

arduinowebsocketserver's Issues

Local network, port forwarding

Sorry to bother you, but I have a small question about your arduino library on github.

Question: How do you serve a websocket from within a local network? In my arduino code, I used the following setup parameters:

byte mac[] = { 0x90, 0xA2, 0xDA, 0x0E, 0xF5, 0xE7 };
byte ip[] = { [local IP address] };
// Create a Websocket server
WebSocket wsServer;

Then, in my client side javascript code, I used the following parameters to open the websocket connection:

$('#connect').click(function() {
if ('WebSocket' in window) {
connection = new WebSocket('ws://[external ip address]/');
console.log('Connecting to server: ' + server);
}
});

Is this correct? It doesn't seem to work.
Also, if I want to use a different port, How do I set that up within the server code? I noticed that your websocket.html file seems to use the 8383 port somehow.

Sorry if this is a dumb question. If there is an easy answer, please email me at [email protected]
Thanks!

BUG

using the library, Iget this error:

"invalid conversion from 'byte*' to 'int'

at this point of code

byte mac[] = {0xDE, 0xAD, 0xBE, 0xEF, 0xFE, 0xED };
byte ip[] = { 192, 168, 1 , 200 }; // IP Address of the Arduino.
WebSerial mySerial(mac, ip); // Initialises WebSerial with mac and ip.

On sha1.cpp: fatal error: avr/io.h: No such file or directory

I can't compile even the lib example and I don't know what to do. I already tried download the avr library and substitute it on the original directory and tried paste the avr directory witch contains all the .h on my project lib dir but none of my tries worked.

Does anyone here with the same problem? does anyone know how to solve it?

Here the message shown on terminal:

lib\ArduinoWebsocketServer\sha1.cpp:2:20: fatal error: avr/io.h: No such file or directory
#include <avr/io.h>
^
compilation terminated.
*** [.pioenvs\d1_mini\lib\ArduinoWebsocketServer\sha1.o] Error 1

What will it take to make it run on a MKR1000?

I'm trying to run a web socket server library for Arduino MKR1000, I landed on this library that seems to be a pretty great one, but where would you start if you'd want to have it running for MKR1000?

64 byte frame limit

Hi

I just tried your Arduino WebSocket server library, and it works great in Chrome and Safari, iOS6.

But i tried IE 10 (Windows 7), and then i get the following message from the serial output from WebSocket.cpp:

Too big frame to handle. Length: 69

I guess that for some reson IE 10 send a larger frame than the other Websocket enables browsers?

Any chance og enabelig frames larger than 64 bytes?

Problems with header sizes on recent browsers

First of all I'd like to thank you on sharing this library, really useful stuff.
I've used it for over a year and never had any issues with it or needed to do any debugging. But recently it started crashing my arduino sketches every time I tried to create a new websocket.
After some debugging, i traced the problem to the temp[60] buffer used for the handshake. The headers are read to this buffer with no length checking, and that's what was causing the crashes, since the headers are much bigger that 60 chars. In Chrome the biggest header i get is 121 bytes:
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/27.0.1453.94 Safari/537.36
Currently the library only works for me in Firefox (even if the header in firefox is also bigger than 60 bytes).
Then I changed the 60 to 128 and now it works again in Chrome, Firefox and IE.
I never really has to look at these headers before today, but I guess they used to be smaller but now they added some more data which made it overflow and crash. It's a simple for anyone having the same issue.

ESP8266

hey there. Nice project. I would like to run a web server on the esp8266, programmed using arduino. How can I implement your code to maybe turn a LED on/off from a web app? is this possible?

ESP32 Secure WebSocket Server over SSL (wss)

I am looking for a secure WebSocket Server implementation over SSL for ESP32 using Arduino IDE, so far I haven't been able to find any implementation regarding the same. Please help to get me started with the same.

If there is any Library for the same or how can I use this library to implement the same, i'd be happy to hear any suggestions regarding the same.

websocket on w5500

Good afternoon.
Write a simple example of how to use websocket on esp32 + w5500. Ethernet.h standard library
I try to add #include <WebSocketServer.h> but I get an error: Arduino-Websocket-master \ sha1.cpp: 2: 20: fatal error: avr / io.h: No such file or directory

Loop still works

Right now, once a socket has been connected, the arduino just becomes a slave to events on the socket.

For example, I can't have the arduino respond to a button being pressed and tell the socket client.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.