Search found 4 matches
- Fri Dec 21, 2018 4:31 pm
- Forum: ESP32 boards
- Topic: Send data via websocket from ESP32 to server?
- Replies: 5
- Views: 12830
Re: Send data via websocket from ESP32 to server?
Ok, encapsulating the send statement with a try/except environment combined with a reconnect on connection loss works.
- Fri Dec 21, 2018 1:27 pm
- Forum: ESP32 boards
- Topic: Send data via websocket from ESP32 to server?
- Replies: 5
- Views: 12830
Re: Send data via websocket from ESP32 to server?
Well, not quite ;) After a while my script crashes: Traceback (most recent call last): File "main.py", line 167, in <module> File "uwebsockets/protocol.py", line 212, in send File "uwebsockets/protocol.py", line 137, in write_frame OSError: [Errno 104] ECONNRESET After googling for a while it seems ...
- Fri Dec 21, 2018 11:47 am
- Forum: ESP32 boards
- Topic: Send data via websocket from ESP32 to server?
- Replies: 5
- Views: 12830
Re: Send data via websocket from ESP32 to server?
Thank you!
I had to remove the "import logging" and all corresponding call in protocol.py and client.py since the module is not available. But then it works just fine!
I had to remove the "import logging" and all corresponding call in protocol.py and client.py since the module is not available. But then it works just fine!
- Wed Dec 19, 2018 6:25 pm
- Forum: ESP32 boards
- Topic: Send data via websocket from ESP32 to server?
- Replies: 5
- Views: 12830
Send data via websocket from ESP32 to server?
Hi all, I'm trying to send sensor measurement data from an ESP32 to a raspberry based server. A test setup running on another computer with the complete python3 environment works like a charm. The minimal working example under python3 looks like this: import websocket ws = websocket.WebSocket() ws.c...