Simple websocket client based on the original with a few added features such as: - setBaud() - set the baud rate for the communication - Initialize() - mimics the constructor - chaged read() to readmsg() to avoid confusion with other functions
Dependents: IoT_Ex BatteryModelTester BatteryModelTester
Fork of WebSocketClient by
Diff: Websocket.h
- Revision:
- 23:0d7b33cd11f9
- Parent:
- 15:9df4ffc6ce48
diff -r 420b83755885 -r 0d7b33cd11f9 Websocket.h --- a/Websocket.h Fri Aug 05 13:31:48 2016 +0000 +++ b/Websocket.h Tue Oct 04 13:57:18 2016 +0000 @@ -104,9 +104,11 @@ * * @param message pointer to the string to be read (null if drop frame) * - * @return true if a websocket frame has been read + * @return 1 if a websocket frame has been read + * @return 0 if a websocket frame could not be read + * @return -1 if the server connection is closed */ - bool readmsg(char * message); + int readmsg(char * message); /** * To see if there is a websocket connection active