0

How to correctly use SSL certs with the Adafruit SIM800H
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

How to correctly use SSL certs with the Adafruit SIM800H

by vaaalbara on Tue Sep 21, 2021 8:44 am

Hey all - I am trying to use a Adafruit Sim800H to connect to Azure using MQTT with an SSL certificate. My first step is trying to put a new SSL certificate onto the board. To do this I am using this example here: https://github.com/vshymanskyy/TinyGSM/ ... etCert.ino . This seems to follow the typical suggested steps on how to set the SSL - by using AT command to create and write to a file, which is then set as the certificate.

The code I am running is the same as what is in the Github repo - except I have added extra print commands, getting a better idea of where it has broken. Here is an excerpt:

Code: Select all | TOGGLE FULL SIZE
  SerialMon.println(F("Select..."));
  modem.sendAT(GF("+SSLSETCERT=\"" CERT_FILE "\""));
  SerialMon.println(F("cert file on.."));
  if (modem.waitResponse() != 1) return;
  if (modem.waitResponse(5000L, GF(GSM_NL "+SSLSETCERT:")) != 1) return;
  SerialMon.println(F("begin retCode"));
  const int retCode = modem.stream.readStringUntil('\n').toInt();


When I monitor my Arduino, I see "Select" and "cert file on.." printed out. However, then it hangs for a long time, and I get an error saying the command is not available.

Can anyone help me follow up on what may be the cause of this?

I have explored trying to update the firmware. I have downloaded a newer firmware (B11), and have the software needed to shift it to the board. However, it doesnt seem to recognise the board is connected over USB. In this situation, the cable is connected to the SIM800H board USB - is this correct?

Thanks.

vaaalbara
 
Posts: 1
Joined: Tue Sep 21, 2021 8:31 am

Please be positive and constructive with your questions and comments.