Skip to content
Joe Moran edited this page May 12, 2019 · 158 revisions

Message Types

Messages sent to the Pod are typically referred to as Commands while messages returned from the Pod are typically returned to as Responses. All messages start with a single byte indicating the Command/Response type followed by a length byte except for the 0x1D Pod Status Response which is the only message with no length byte.

Pod Commands

All Pod communication originates from the the controlling software (e.g., the PDM or the Loop app). The Pod receives a command and then sends back a synchronous response. The 0x1A Insulin Schedule Command is the only message with an additional sub-message/sub-command immediately following it which is often referred to as the Extra Command.

Pod Responses

Each command received from the Pod will generate a response. Once a Pod is successfully paired, the 0x1D Pod Status is the normal non-error Response for every Command except for a 0x0E Get Status Command with a non-zero type. An 0x06 Error Response can be returned at any time for a non-fatal Command error (with an important special case of a bad nonce error type 0x14). An 0x02 Pod Information Response, Type 2, can also be returned at any time for a fatal Pod fault occurring either prior to or during the execution of the command.

OmniKit Implementation

Links are provided to the omnipod-testing branch source files for various commands, responses and support routines in the OmniKit implementation of Loop as a reference and to aid developers for other platforms. Development of earlier code like commands.py or rtlomni were never completed and links for selected portions are no longer being provided here until someone steps up to finish these efforts.

Commands (to Pod)

Command # Type Normal Response OmniKit Implementation
0x03 Setup Pod 0x01 Version Response, long format ConfigurePodCommand.swift
0x07 Assign ID 0x01 Version Response, short format AssignAddressCommand.swift
0x08 Configure Delivery Flags 0x1D Pod Status Response FaultConfigCommand.swift
0x0E Get Status 0 0x1D Pod Status Response GetStatusCommand.swift
0x0E Get Status 1 0x02 Pod Information, Type 1 GetStatusCommand.swift
0x0E Get Status 2 0x02 Pod Information, Type 2 GetStatusCommand.swift
0x0E Get Status 3 0x02 Pod Information, Type 3 GetStatusCommand.swift
0x0E Get Status 5 0x02 Pod Information, Type 5 GetStatusCommand.swift
0x0E Get Status 6 0x02 Pod Information, Type 6 GetStatusCommand.swift
0x0E Get Status 0x46 0x02 Pod Information, Type 46 GetStatusCommand.swift
0x0E Get Status 0x50 0x02 Pod Information, Type 50 GetStatusCommand.swift
0x0E Get Status 0x51 0x02 Pod Information, Type 51 GetStatusCommand.swift
0x11 Acknowledge Alerts 0x1D Pod Status Response AcknowledgeAlertCommand.swift, AlertSlot.swift, BeepType.swift
0x19 Configure Alerts 0x1D Pod Status Response ConfigureAlertsCommand.swift, AlertSlot.swift, BeepType.swift
0x1A Insulin Schedule Common The Extra Command Response SetInsulinScheduleCommand.swift
0x1A Basal Schedule 0 Response from 0x13 Basal Extra Command BasalSchedule.swift BasalDeliveryTable.swift
0x13 Basal Extra 0x1D Pod Status Response BasalScheduleExtraCommand.swift
0x1A Temp Basal 1 Response from 0x16 Temp Basal Extra Command BasalDeliveryTable.swift
0x16 Temp Basal Extra 0x1D Pod Status Response TempBasalExtraCommand.swift
0x1A Bolus 2 Response from 0x17 Bolus Extra Command SetInsulinScheduleCommand.swift
0x17 Bolus Extra 0x1D Pod Status Response BolusExtraCommand.swift
0x1C Deactivate Pod 0x1D Pod Status Response DeactivatePodCommand.swift
0x1E Beep Configure 0x1D Pod Status Response BeepConfigCommand.swift, BeepType.swift
0x1F Cancel Delivery 0x1D Pod Status Response CancelDeliveryCommand.swift, BeepType.swift

Responses (from Pod)

Response # Type Notes OmniKit Implementation
0x01 Version len==0x1B len==0x15 Long Response for 0x03 Setup Pod Command, Short Response for 0x07 Assign ID Command VersionResponse.swift
0x02 Pod Information Common Response for 0x0E Get Status Command, Type !0 PodInfo.swift
0x02 Pod Information, Type 1 1 Response for 0x0E Get Status Command, Type 1 PodInfoConfiguredAlerts.swift
0x02 Pod Information, Type 2 2 Response when a Pod is faulted (screaming) or Response for 0x0E Get Status Command, Type 2 PodInfoFaultEvent.swift FaultEventCode.swift, LogEventErrorCode.swift
0x02 Pod Information, Type 3 3 Response for 0x0E Get Status Command, Type 3 PodInfoDataLog.swift
0x02 Pod Information, Type 5 5 Response for 0x0E Get Status Command, Type 5 PodInfoFault.swift
0x02 Pod Information, Type 6 6 Response for 0x0E Get Status Command, Type 6 PodInfoTester.swift
0x02 Pod Information, Type 46 0x46 Response for 0x0E Get Status Command, Type 46 PodInfoResetStatus.swift
0x02 Pod Information, Type 50 0x50 Response for 0x0E Get Status Command, Type 50 PodInfoFlashLogRecent.swift
0x02 Pod Information, Type 51 0x51 Response for 0x0E Get Status Command, Type 51 PodInfoFlashLogRecent.swift
0x06 Error 0x14 Response for any command with a bad nonce ErrorResponse.swift
0x06 Error !0x14 Response for any other command request error ErrorResponse.swift
0x1D Pod Status No type or length Default non-error Response for all Commands except 0x03, 0x07 & 0x0E with a non-zero type StatusResponse.swift
Clone this wiki locally