mqtt_message_receive error trying to connect to broker
Posted: Tue Apr 28, 2020 10:51 am
Hi,
I'm trying to connect to my broker with the esp32 mqtt ssl template but I get this errors:
I (7091) MQTT_CLIENT: Sending MQTT CONNECT message, type: 1, id: 0000
E (7131) MQTT_CLIENT: mqtt_message_receive: transport_read() error: errno=128
E (7131) MQTT_CLIENT: esp_mqtt_connect: mqtt_message_receive() returned -1
I (7131) MQTT_CLIENT: Error MQTT Connected
I (7141) MQTTS_EXAMPLE: MQTT_EVENT_DISCONNECTED
The configuration is classic:
with
CONFIG_BROKER_URI = mqtt://myBrokerUri:port
and
in mqtt_eclipse_org_pem_start I setted the route of my certificate via Broker certificate override: certs/myCert.pem
I tried to connect to hivemq.com and I had no difficulties so i think the problem is that eclipse doesn't see the certificate.
Someone can help me?
Regards
I'm trying to connect to my broker with the esp32 mqtt ssl template but I get this errors:
I (7091) MQTT_CLIENT: Sending MQTT CONNECT message, type: 1, id: 0000
E (7131) MQTT_CLIENT: mqtt_message_receive: transport_read() error: errno=128
E (7131) MQTT_CLIENT: esp_mqtt_connect: mqtt_message_receive() returned -1
I (7131) MQTT_CLIENT: Error MQTT Connected
I (7141) MQTTS_EXAMPLE: MQTT_EVENT_DISCONNECTED
The configuration is classic:
Code: Select all
const esp_mqtt_client_config_t mqtt_cfg = {
.uri = CONFIG_BROKER_URI,
.cert_pem = (const char *)mqtt_eclipse_org_pem_start,
};
CONFIG_BROKER_URI = mqtt://myBrokerUri:port
and
in mqtt_eclipse_org_pem_start I setted the route of my certificate via Broker certificate override: certs/myCert.pem
I tried to connect to hivemq.com and I had no difficulties so i think the problem is that eclipse doesn't see the certificate.
Someone can help me?
Regards