31: GSM Control
Controls the GSM modem, including flight mode and network search.
Documented Method (5) values SET, GET
Shared optional header · Message ID (1) can identify a request, response or publication. A response's own ID is separate from Response To (3). Message ID and reply rules apply unless an interaction states an exception.
Message fields
Fields specific to GSM Control. Operation sections below explain when each field is used.
| Field | Type | Description |
|---|---|---|
| Flight modeField 1 | bool | |
| DurationField 2 | uint32 | |
| GSM ActiveField 3 | bool | |
| Request ControlField 4 | bool | Note this will always be true when GETting state in flight mode (as control has been taken). |
| Start SearchField 5 | uint8 | Trigger a network search. When present, takes priority over flight mode / duration fields.
|
Request
Omit Start Search (field 5), which takes priority over flight-mode controls when present. GSM Active and Request Control (fields 3 and 4) are ignored by SET.
Shared optional Message ID and reply rules
Request headers
- MethodHeader 5
uint8requiredValue
1· SETRequest a service to be perform an action
- DurationHeader 7
uint32optionalTo be used with the SUBSCRIBE method, or actions that can be timed. When used with a timed action: This defines how long the action should go on for. When used with the SUBSCRIBE method: This defines a duration to keep the subscription active for. A value of 0 means the subscription is indefinite until explicitly unsubscribed. A message with an EXPIRED status code will be sent if the subscription duration elapses without being renewed with a new subscription request.
Request data fields
- Flight modeField 1
booloptionalEnable or disable flight mode. Omission disables it.
- DurationField 2
uint32optionalWhen enabling flight mode, provide 1 to 259200 minutes. If omitted, use header Duration in milliseconds divided by 60000 and rounded down. Disabling flight mode ignores the duration.
Expected response (MT5 - ACK)
Correlation, status and acknowledgment rules · MT5 packet format
Request
Shared optional Message ID and reply rules
Request headers
- MethodHeader 5
uint8requiredValue
2· GETRequest a service to be perform an action
Expected response (MT31)
Successful GET returns GSM state directly.
Correlation, status and acknowledgment rules
Response data fields
- Flight modeField 1
boolrequired- GSM ActiveField 3
boolrequired- DurationField 2
uint32optionalRemaining external modem reservation time in minutes, returned with field 4.
- Request ControlField 4
booloptionalPresent with value true when the modem is reserved for external use.
Start a network search
Leave flight mode and trigger the selected network search.
Request
Start Search takes priority even when its value is 0. Fields 1 to 4 and header Duration (7) are ignored when Start Search is present.
Shared optional Message ID and reply rules
Request headers
- MethodHeader 5
uint8requiredValue
1· SETRequest a service to be perform an action
Request data fields
- Start SearchField 5
uint8requiredTrigger a network search. When present, takes priority over flight mode / duration fields.
0· Full: Full network scan.1· Auto: Automatic search using the last known band.
Expected response (MT5 - ACK)
Correlation, status and acknowledgment rules · MT5 packet format
Message and field constants
Identifiers for this message type and its fields. See the operation sections above for rules and limits.