Thanks for checking in. I closed the post as I was able to make the connection work.
What I found was that I was trying to connect to
http://ec2-xx-yyy-zzz-v.compute-1.amazonaws.com from the Espruino board, and that did not work (although that is the host I used for the node
ws client without an issue).
By removing the
http:// I was able to connect the Espruino to the hosted socket. I really thought I had tried that the other day to no avail, but I suppose something must have been different.
@MaBe sent me a message letting me know that there is a 32 char limit for the internal hostname, so I'm a bit confused as my hostname is 40 characters. Nevertheless, it seems to be connecting and sending data ok, but will intermittently disconnect.
A stranger issue that I am having is when connecting locally. When testing, I host the
ws server on my local machine and connect the Espruino to the same WiFi. After finding the ip of my computer that is running the server, I use that on the Espruino to connect. However, I only seem to be able to connect 1/10 times.
Most of the time it simply fails to connect, and then randomly without changing anything it will work. Any ideas what that might be about?