Ive recently had a MKR 1400 replaced as we though it was faulty (turns out battery charging was faulty but connectivity wasn't). The board is setup with a couple of sensors and transfers data to Arduino IoT cloud. Problem is after about 2 and a half days it drops the connection and will only re connect when its rebooted either by power cycling or pressing the reset button...
Is there either any way i can code a reset, say every 24 hours, or catch when its not connected and reconnect...?
static unsigned long delayStarttime;
unsigned long currentTime = millis();
if (currentTime - delayStarttime >= 60000UL) //dev 1min = 60000 5 min =300000 15 min 90000 and so on
{
NVIC_SystemReset();
}