Good morning to you all,
I have connected my Arduino MKR WiFi 1010 to the Arduino Cloud via WiFi.
On the platform's connection monitor, a reconnection is detected exactly every 30 seconds. I have tried with several boards of the same type.
Does anyone know how to solve this issue?
Thanks in advance.
What code are you using?
How is the board powered and what's connected to it?
I have only uploaded to my Arduino the necessary code to connect to WiFi through Arduino Cloud."
// Code generated by Arduino IoT Cloud, DO NOT EDIT.
#include <ArduinoIoTCloud.h>
#include <Arduino_ConnectionHandler.h>
const char SSID[] = SECRET_SSID; // Network SSID (name)
const char PASS[] = SECRET_OPTIONAL_PASS; // Network password (use for WPA, or use as key for WEP)
void onPulsanteChange();
bool led;
bool pulsante;
void initProperties(){
ArduinoCloud.addProperty(led, READ, ON_CHANGE, NULL);
ArduinoCloud.addProperty(pulsante, READWRITE, ON_CHANGE, onPulsanteChange);
}
WiFiConnectionHandler ArduinoIoTPreferredConnection(SSID, PASS);
The following variables are automatically generated and updated when changes are made to the Thing
bool led;
bool pulsante;
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);
/*
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() {
ArduinoCloud.update();
// Your code here
}
/*
Since Pulsante is READ_WRITE variable, onPulsanteChange() is
executed every time a new value is received from IoT Cloud.
*/
void onPulsanteChange() {
// Add your code here to act upon Pulsante change
}
Please correct your post and add code tags around your code.
There is a small pencil
below your existing posts.
- click on this pencil ➜ that will let you edit your post.
- Select the part of the text that corresponds to the code
- Click on the
<code/>icon in the toolbar to indicate that it is code - click
Save Edit
(Also make sure to properly indent the code in the IDE before copying and pasting it here. This can be done by pressing ctrlT on a PC or cmdT on a Mac)
Anything connected to your arduino ? How is it powered?
Anything connecter.
Powered by usb port of my pc
does the board actually reboot ?
Add a Serial.print() in the setup and check on the serial monitor if this is really what's happening
The serial monitor confirms the disconnection every 30 seconds. I tested it on different PCs and various MRK WiFi1010 boards.
you said in the title "the Arduino board resets"
which is it ? does the board actually resets (= reboot) or just looses the internet access every 30s and automatically reconnects ?
I tried with different Arduino MKR 1010 Wifi.
All this board looses internet access every 30 sec and automatically reconnects. In loop.
Did you update the WiFiNINA firmware (see Check the WiFiNINA firmware version) to the latest version ?
Have you checked your router settings like DHCP lease time?
This morning I ran several tests. In the end, I came to the conclusion that the problem is my account (?!!). With an account different from mine, using the same board, the same sketch, on the same PC, and the same internet connection, everything worked fine.
How is that possible?
seems this might be an Arduino Cloud oddity then
I'm moving your post in that category
You should edit the title of your post as the board does not reset every 30 seconds. this is misleading.
Have you updated the firmware ?
yes but I repeat, this problem happens with several cards. the same card, the same sketch loaded from a different account does not cause problems
Have you tried from a different network?
Yes.
Is there a possibility of contacting those who manage the Arduino Cloud platform?
I'm experiencing other anomalies:
-
I try to set the SECRET OPTION PASS field in a random sketch by setting the new password of my WiFi but when I exit and return to the tab it gives me the old password again.
-
my Arduino board is correctly connected via USB cable but it is not detected in the firmware update screen. If I try to upload the sketch it does it correctly.
-
If I try to set up an ARDUINO UNO R4 board it gives me errors when compiling the code.
All things that don't happen using my friend's account, on the same PC, with the same sketch, the same cable, the same cards.
This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.
