I've got two MKR WIFI 1010. One of them was connected to the cloud and running, the other one is an ongoing project. When working with the ongoing project, I had a pause, and when I continued again, I've got this error message:
ArduinoIoTCloudTCP::handle_ConnectMqttBroker could not connect to mqtts-sa.iot.arduino.cc:8883
ArduinoIoTCloudTCP::handle_ConnectMqttBroker 3 connection attempt at tick time 111081
Checking data for the other MKR, I noticed that it had not posted any new values for a while. I fetched it, and the same error occurred.
***** Arduino IoT Cloud - configuration info *****
Device ID: c35cf23c-d54c-42c9-9246-71d774b627b3
Thing ID: 68087245-caa3-4166-b6ec-79606437a2fe
MQTT Broker: mqtts-sa.iot.arduino.cc:8883
hei
WiFi.status(): 0
Current WiFi Firmware: 1.4.7
hei
Connected to "MyWifi"
hei
hei
ArduinoIoTCloudTCP::handle_ConnectMqttBroker could not connect to mqtts-sa.iot.arduino.cc:8883
ArduinoIoTCloudTCP::handle_ConnectMqttBroker 1 connection attempt at tick time 36013
I've read all I can find both here in forum and on google, but nothing seems to fit my situation. I've even deleted the device, and created a new thing for scratch, with a auto generated sketch. It doesn't work.
Here's the sketch
/*
Sketch generated by the Arduino IoT Cloud Thing "thg_test"
https://create.arduino.cc/cloud/things/68087245-caa3-4166-b6ec-79606437a2fe
Arduino IoT Cloud Variables description
The following variables are automatically generated and updated when changes are made to the Thing
CloudTemperature test;
Variables which are marked as READ/WRITE in the Cloud Thing will also have functions
which are called when their values are changed from the Dashboard.
These functions are generated with the Thing and added at the end of this sketch.
*/
#include "thingProperties.h"
void setup() {
// Initialize serial and wait for port to open:
Serial.begin(9600);
// This delay gives the chance to wait for a Serial Monitor without blocking if none is found
delay(1500);
// Defined in thingProperties.h
initProperties();
// Connect to Arduino IoT Cloud
ArduinoCloud.begin(ArduinoIoTPreferredConnection,false);
/*
The following function allows you to obtain more information
related to the state of network and IoT Cloud connection and errors
the higher number the more granular information you’ll get.
The default is 0 (only errors).
Maximum is 4
*/
setDebugMessageLevel(2);
ArduinoCloud.printDebugInfo();
}
void loop() {
test = 20;
Serial.println("hei");
ArduinoCloud.update();
delay(2000);
}
I've been banging my head for several days now, and I'm stuck. Unable to find any steps for how to troubleshoot this problem.