Connecting from ESP8266

8 views
Skip to first unread message

kenv...@gmail.com

unread,
Feb 11, 2018, 12:33:49 AM2/11/18
to ImSmart.tech
Has anyone successfully set/reset a variable using code running on an ESP8266?

I'm using the example code that comes with the ESP8266WiFi library, see snippet below.

It connects successfully to other HTTPS sites, so I know the basics are correct. 

But on some HTTPS sites, including ImSmart.tech, it fails immediately, without even connecting.  I assume this means it's failing somewhere in the initial handshake process, but don't know how to troubleshoot this.  The Arduino IDE debug modes don't provide any useful info.

Anyone have any ideas why it would connect to some HTTPS sites but not ImSmart.tech?

Code snippet (various unrelated lines deleted):

  #include <ESP8266WiFi.h>
  #include <WiFiClientSecure.h>
 
void setup() {
  WiFiClientSecure client;
  Serial.print("connecting to www.imsmart.tech");
  if (!client.connect(www.imsmart.tech, 443)) {
    Serial.println("connection failed");
    return;
  }    
}
Reply all
Reply to author
Forward
0 new messages