Skip to content

Commit 29cc073

Browse files
committed
Cellular: faster modem recovery from crashing powered on
(see #952 (comment))
1 parent 0f5ad97 commit 29cc073

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

vehicle/OVMS.V3/components/ovms_cellular/src/ovms_cellular.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,9 @@ void modem::SetPowerMode(PowerMode powermode)
340340
case Sleep:
341341
case DeepSleep:
342342
if ((original!=On)&&(original!=Sleep)&&(original!=DeepSleep))
343-
SendSetState1(PoweringOn); // We are not in the task, so queue the state change
343+
SendSetState1(PowerOffOn); // We are not in the task, so queue the state change
344+
// We don't know the actual power state of the modem, it can be still powered on
345+
// after a crash. PowerOffOn initiates a power cycle, which works in any case.
344346
break;
345347

346348
case Off:

0 commit comments

Comments
 (0)