Supported SNI (fix by kyriazis)

This commit is contained in:
Francesco Stefanni
2021-04-07 11:24:39 +02:00
parent 7f19c69554
commit c1d6abaff7

View File

@@ -593,6 +593,9 @@ class TinyGsmSim7000 : public TinyGsmModem<TinyGsmSim7000>,
sendAT(GF("+CASSLCFG="), mux, ',', GF("protocol,0")); sendAT(GF("+CASSLCFG="), mux, ',', GF("protocol,0"));
waitResponse(); waitResponse();
sendAT(GF("+CSSLCFG=\"sni\","), mux, ',', GF("\""), host, GF("\""));
waitResponse();
sendAT(GF("+CAOPEN="), mux, ',', GF("\""), host, GF("\","), port); sendAT(GF("+CAOPEN="), mux, ',', GF("\""), host, GF("\","), port);
if (waitResponse(timeout_ms, GF(GSM_NL "+CAOPEN:")) != 1) { return 0; } if (waitResponse(timeout_ms, GF(GSM_NL "+CAOPEN:")) != 1) { return 0; }