File tree Expand file tree Collapse file tree 2 files changed +6
-0
lines changed
examples/ZED-F9P/Example18_PointPerfectClient Expand file tree Collapse file tree 2 files changed +6
-0
lines changed Original file line number Diff line number Diff line change @@ -138,6 +138,9 @@ void beginClient()
138
138
wifiClient.setCACert (AWS_CERT_CA);
139
139
wifiClient.setCertificate (AWS_CERT_CRT);
140
140
wifiClient.setPrivateKey (AWS_CERT_PRIVATE);
141
+ mqttClient.setId (MQTT_CLIENT_ID);
142
+ mqttClient.setKeepAliveInterval (60 *1000 );
143
+ mqttClient.setConnectionTimeout ( 5 *1000 );
141
144
if (!mqttClient.connect (AWS_IOT_ENDPOINT, AWS_IOT_PORT)) {
142
145
Serial.print (F (" MQTT connection failed! Error code = " ));
143
146
Serial.println (mqttClient.connectError ());
Original file line number Diff line number Diff line change @@ -15,6 +15,9 @@ const char MQTT_TOPIC_KEY[] = "/pp/key/ip";
15
15
// <Your PointPerfect Thing> -> Credentials -> IP correction topic for EU/US region
16
16
const char MQTT_TOPIC_SPARTN [] = "/pp/ip/us" ; // choice of {eu, us}
17
17
18
+ // <Your PointPerfect Thing> -> Credentials -> Client Id
19
+ static const char MQTT_CLIENT_ID [] = "<ADD YOUR CLIENT ID HERE>" ;
20
+
18
21
// <Your PointPerfect Thing> -> Credentials -> Amazon Root Certificate
19
22
static const char AWS_CERT_CA [] PROGMEM = R "EOF(
20
23
-- -- - BEGIN CERTIFICATE -- -- -
You can’t perform that action at this time.
0 commit comments