How to connect device using AT-Commands(Simcom7020g) into HiveMQ Cloud use raspberry pi

NBIOT module in raspberry pi

Serial port open: /dev/ttyAMA0
Response: AT+CGATT=1
OK
AT+CGACT?
+CGACT: 1,1

OK
AT+CGACT?
Response: AT+COPS?
+COPS: 0,2,“23415”,9

OK
Response: AT+CGCONTRDP
+CGCONTRDP: 1,5,“lpwa.vodafone.iot”,“100.93.241.83.255.255.255.0”,“10.105.16.254”,“10.105.144.254”,1430

OK
IP Address: 100.93.241.83.255.255.255.0
AT+CGCONTRDP
Response: AT+CFUN=1
OK
Response: AT+CTLSCFG=1,1,“100.93.241.83.255.255.255.0”,2,50090,3,0,4,0,5,2
OK
Response: AT+CTLSCONN=1,1
OK
Response: AT+CMQNEW=“49xxxxxxxxxxx.s2.eu.hivemq.cloud”,“8883”,60000,1132
ERROR
Failed to create MQTT connection

always fail connect HIVEMQ what I missing?

Hello @snailt-tony

There is a thread where another forum member was able to connect a SIM7600 device, you can use it as a reference.

Kind regards,
Diego from HiveMQ Team

I wasnt successful in connecting due to the firmware on my device.

I was successful connecting to AWS IOT has there cert has the ability to downgrade TLS 1.2 / 128

The 7600 AT command is different from 7020G at command, the example not work for me.

Hello @snailt-tony ,

To confirm, are you encountering further errors when attempting to connect the 7020G device, or are you encountering the same connection failure as notated above? Are you using a HiveMQ Cloud broker, a Community, Professional, or Enterprise edition Broker, or another broker implementation entirely?

Could you also confirm the TLS version supported by the device in-use, and if TLS is enabled? If utilizing HiveMQ Cloud, please do note that TLS is required for connection.

Best,
Aaron from the HiveMQ Team

Serial port open: /dev/ttyAMA0
Response: AT+CGATT=1
OK
AT+CGACT?
+CGACT: 1,1

OK
AT+CGACT?
Response: AT+COPS?
+COPS: 0,2,“23415”,9

OK
Response: AT+CGCONTRDP
+CGCONTRDP: 1,5,“lpwa.vodafone.iot”,“100.93.50.43.255.255.255.0”,“10.105.16.254”,“10.105.144.254”,1430

OK
IP Address: 100.93.50.43.255.255.255.0
AT+CGCONTRDP
Response: AT+CFUN=1
OK
Response: AT+CTLSCFG=1,1,“100.93.50.43.255.255.255.0”,2,8883,3,0,4,0,5,2
OK
Response: AT+CTLSCONN=1,1
OK

+CTLSCONN: 1,-82
Response: AT+CTLSCONN=1,1
OK
Response: AT+CMQTTSNEW=“495d5fe4405a49ccba357d0aff2ed80b.s2.eu.hivemq.cloud”,“8883”,60000,1132
ERROR

+CTLSCONN: 1,-82
Failed to create MQTT connection

I use HiveMQ cloud free version for test right now, if i can success connect. will consider upgrade later.

the simcom7600 at command error as below
[10:39:18:143] AT+CSSLCFG=“sslversion”,0,4

[10:39:18:155] ERROR

[10:39:29:369] AT+CSSLCFG=“authmode”,0,3

[10:39:29:377] ERROR

[10:39:43:944] AT+CSSLCFG=“ignorelocaltime”,0,1

[10:39:43:952] ERROR

[10:39:53:755] AT+CSSLCFG=“cacert”,0,“isrgrootx1.pem”

[10:39:53:763] ERROR

[10:40:04:083] AT+CSSLCFG=“ciphersuites”,0,0xFFFF

[10:40:04:090] ERROR

[10:40:20:092] AT+CSSLCFG=“enableSNI”,0,1

[10:40:20:099] ERROR

[10:40:28:480] AT+CSSLCFG?

[10:40:28:487] ERROR

Hello @snailt-tony

First, you must ensure that your module SIMCOM 7020G supports SNI in a TLS handshake. HiveMQ Cloud requires the TLS-SNI extension (Server Name Indication) to be available. As far as I know, SIMCOM 7020G doesn’t support SNI but maybe the manufacturer has made this feature available in the latest firmware update.

Please refer to the following FAQ post in order to check more information regarding TLS-SNI extension Frequently Asked Questions

Kind regards,
Diego from HiveMQ Team