begin of WebSockets Server development

receive and phasing of WebSockets Header working
This commit is contained in:
Markus Sattler
2015-05-22 14:19:01 +02:00
commit 02da0e0aa7
7 changed files with 537 additions and 0 deletions

31
tests/webSocket.html Normal file
View File

@ -0,0 +1,31 @@
<html>
<head>
<script>
var connection = new WebSocket('ws://10.11.2.1:81/test', ['esp8266', 'test']);
// When the connection is open, send some data to the server
connection.onopen = function () {
connection.send('ping'); // Send the message 'Ping' to the server
};
// Log errors
connection.onerror = function (error) {
console.log('WebSocket Error ' + error);
};
// Log messages from the server
connection.onmessage = function (e) {
console.log('Server: ' + e.data);
};
</script>
</head>
<body>
Test Websocket.
</body>
</html>