The modem.restart() function does not return. It appears to hang on: sendAT(GF("+REBOOT"));