Error running Fleet Provisioning to connect MQTT to AWS

Huy_Tran_DF
Posts: 18
Joined: Fri Sep 26, 2025 9:44 am

Error running Fleet Provisioning to connect MQTT to AWS

Postby Huy_Tran_DF » Mon Dec 01, 2025 4:04 am

LOG:

Code: Select all

I (6704) MAP_CORE: PROVISIONING: Certificate found. Thing Name: LED_Panel_Matrix_002
I (6704) MAP_CORE: PHASE 4: START MAIN OPERATION
I (6714) AWS_SERVICE: CONN: Preparing to connect with device certificate
I (6724) AWS_SERVICE: CONN: Device cert length: 1220 bytes
I (6724) AWS_SERVICE: CONN: Device key length: 1675 bytes
I (6734) AWS_SERVICE: CONN: Thing name: LED_Panel_Matrix_002
I (6734) AWS_SERVICE: CONN: ROOT_CA length: 1189 bytes
I (6744) AWS_SERVICE: CONN: Broker URI: mqtts://abcdef-ats.iot.ap-southeast-1.amazonaws.com:8883
I (6754) AWS_SERVICE: CONN: Certificate validation passed, initializing MQTT client...
I (6754) AWS_SERVICE: CONN: Initializing MQTT client with device certificate...
I (6764) AWS_SERVICE: CONN: Registering event handler...
I (6774) AWS_SERVICE: CONN: Starting MQTT client (waiting for TLS handshake)...
I (6784) AWS_SERVICE: CONN: AWS MQTT client started for Thing: LED_Panel_Matrix_002
[b][i]E (8634) esp-tls-mbedtls: mbedtls_ssl_handshake returned -0x7280
I (8634) esp-tls-mbedtls: Certificate verified.
E (8634) esp-tls: Failed to open new connection
E (8634) transport_base: Failed to open a new connection
E (8644) mqtt_client: Error transport connect
E (8644) AWS_SERVICE: MQTT_EVENT_ERROR
W (8644) AWS_SERVICE: MQTT_EVENT_DISCONNECTED[/i][/b]
Successfully provisioned a new Thing LED_Panel_Matrix_002 on AWS (as seen in the provisioning log). But when trying to connect MQTT to AWS IoT with the newly provisioned device certificate, it still gets TLS handshake error -0x7280.
✅ Provisioning successful:
Thing name received: LED_Panel_Matrix_002
Certificate and key saved to NVS
"PROVISIONING: COMPLETE"
❌ MQTT connection failed:
mbedtls_ssl_handshake returned -0x7280
Certificate verified (correct format)
Failed to open new connection

lichurbagan
Posts: 59
Joined: Thu Nov 13, 2025 3:20 pm

Re: Error running Fleet Provisioning to connect MQTT to AWS

Postby lichurbagan » Thu Dec 18, 2025 7:40 am

Open the AWS IoT Core console and go to Security > Certificates. Select the certificate created during provisioning. Verify the Status is set to ACTIVE. Check the attached things and confirm your Thing is listed. Check **Policies** and ensure at least one IoT policy is attached and allows `iot: Connect`.

Who is online

Users browsing this forum: Baidu [Spider], ChatGPT-User, Semrush [Bot] and 12 guests