OperationalState Cluster

Cluster ID: 0x0060  |  Endpoint: Typically on Endpoint 1 (application endpoint)

OperationalState is a general-purpose state machine Cluster in Matter for describing appliance operational states. It provides a unified control interface for devices requiring Start/Pause/Stop/Resume operations, such as washing machines, dryers, ovens, and robot vacuums. As the base Cluster, device-specific variants (e.g., OvenCavityOperationalState, RVCOperationalState) all inherit from it.

General-Purpose Base Cluster

OperationalState defines generic state and error enumerations. Device-specific Clusters (e.g., oven, robot vacuum) inherit these base definitions and extend them with their own state values and error codes. For example, a robot vacuum (RVC) adds states like SeekingCharger and Charging, as well as errors like StuckAtObstacle and DustBinFull.

Commands

OperationalState Cluster has 4 commands corresponding to basic appliance operations. All commands return an OperationalCommandResponse containing an ErrorStateStruct to indicate success or failure. Click a command ID in the table below to jump to its detailed description.

ID Name Description Response
0x00 Pause Pause the current operation OperationalCommandResponse
0x01 Stop Stop the operation OperationalCommandResponse
0x02 Start Start the operation OperationalCommandResponse
0x03 Resume Resume a paused operation OperationalCommandResponse

Pause (0x00)

Pauses the device's current operation. On success,OperationalState attribute changes to Paused (2). The device preserves current progress and can be resumed via the Resume command. No parameters required.

State Constraints

Pause is only valid when the device is in the Running (1) state. Calling it in the Stopped (0) or Error (3) state returns a CommandInvalidInState (3) error.

Usage Scenarios

While the washing machine is running, the user needs to open the door to add clothes. The app sends a Pause command; the washer pauses, drains, and unlocks the door. After adding clothes, send Resume to continue.

Stop (0x01)

Completely stops the device's current operation. On success,OperationalState attribute changes to Stopped (0). Unlike Pause, Stop discards current progress; a new Start is required to begin a new operation cycle. No parameters required.

Usage Scenarios

An oven is baking and the user realizes the settings are wrong. Sending the Stop command terminates baking; afterwards the user can reconfigure parameters and send Start for a new baking cycle.

Start (0x02)

Starts the device's operation. On success,OperationalState attribute changes to Running (1). Typically called when the device is in the Stopped (0) state. No parameters required.

Usage Scenarios

After the user selects the wash program and temperature, they tap Start in the app; the app sends the Start command to begin the wash cycle.

Resume (0x03)

Resumes an operation previously paused by Pause. On success,OperationalState attribute changes to Running (1) and the device continues from where it was paused. No parameters required.

State Constraints

Resume is only valid when the device is in the Paused (2) state. Calling it in the Stopped (0) state returns a CommandInvalidInState (3) error — use Start instead of Resume in that case.

Usage Scenarios

With the washing machine paused, the user closes the door and taps Continue. The app sends the Resume command and the washer continues from where it paused.

OperationalCommandResponse

All four commands (Pause/Stop/Start/Resume) return this response. It contains an ErrorStateStruct indicating whether the command succeeded.

FieldTypeDescription
CommandResponseState ErrorStateStruct Command execution result. ErrorStateID = 0 (NoError) indicates success

Attributes

OperationalState Cluster has 6 application attributes. Click an attribute ID below to jump to its detailed description.

ID Name Type Group Description
0x0000 PhaseList list<string> / null Phase Info Operation phase list
0x0001 CurrentPhase uint8 / null Phase Info Current phase index
0x0002 CountdownTime elapsed_s / null Phase Info Remaining time (seconds)
0x0003 OperationalStateList list<OperationalStateStruct> Operational State All states supported by the device
0x0004 OperationalState OperationalStateEnum Operational State Current operational state
0x0005 OperationalError ErrorStateStruct Operational State Current error information

Phase Information (0x0000, 0x0001, 0x0002)

Describes the phase progress and remaining time of the current operation. For multi-phase devices (e.g., washing machines, dryers), these attributes let the app display precise progress.

ID Name Type Description
0x0000 PhaseList list<string> / null An ordered list of phase names for the device operation. E.g., a washing machine might use ["Soak", "Wash", "Rinse", "Spin"]. Nullable — null means the device does not support the phase concept (e.g., a simple on/off device). Maximum 32 entries
0x0001 CurrentPhase uint8 / null Index of the current phase in PhaseList (zero-based). Nullable — when PhaseList is null, this value is also null
0x0002 CountdownTime elapsed_s / null Estimated remaining time for the current operation, in seconds. The device periodically updates this value. Nullable — null means the device cannot estimate remaining time
Relationship Between Phase and Countdown

CountdownTime is the remaining time for the entire operation cycle, not a single phase. When the device transitions between phases, CurrentPhase updates, while CountdownTime continues counting down until the operation completes.

Operational State (0x0003, 0x0004, 0x0005)

Describes the device operational state and error information. This is the primary data source for device status in the app.

ID Name Type Description
0x0003 OperationalStateList list<OperationalStateStruct> All operational states supported by the device. Each entry has a state ID and optional localized label. Beyond standard states (0-3), devices may define extended states (ID ≥ 0x80)
0x0004 OperationalState OperationalStateEnum The device's current operational state; see OperationalStateEnum for possible values. This is the primary attribute for device status display in the app
0x0005 OperationalError ErrorStateStruct The device's current error state. When OperationalState is Error (3), this attribute contains the specific error information. When no error, ErrorStateID = 0 (NoError)

Enum Definitions

OperationalStateEnum

Operational state enumeration. The standard defines 4 base values; device-specific Clusters may extend 0x80-0xBF.

0
Stopped Stopped — device is idle; can accept Start command
1
Running Running — operation in progress; can be Paused or Stopped
2
Paused Paused — operation suspended; can be Resumed or Stopped
3
Error Error — fault occurred; check OperationalError for details

ErrorStateEnum

Error state enumeration. The standard defines 4 generic error codes; device-specific Clusters may extend 0x40-0x7F.

0
NoError No error — everything is normal
1
UnableToStartOrResume Unable to start or resume — the device cannot begin the operation
2
UnableToCompleteOperation Unable to complete operation — an unrecoverable problem occurred
3
CommandInvalidInState Command invalid in current state — e.g., calling Resume while Stopped

Data Structures

ErrorStateStruct

Describes the device's error information. Used for both the OperationalError attribute and command responses. Contains an error code, optional localized label, and detailed description.

FieldTypeRequiredDescription
ErrorStateID ErrorStateEnum Yes Error type code. 0 indicates no error
ErrorStateLabel string No Optional localized error label for app display. When ErrorStateID is outside the standard range, this field must be provided
ErrorStateDetails string No Optional detailed error description for diagnostics

OperationalStateStruct

Used in the OperationalStateList attribute to describe each operational state the device supports.

FieldTypeRequiredDescription
OperationalStateID uint8 Yes State code. 0-3 are standard; 0x80-0xBF are device-specific extensions
OperationalStateLabel string No Optional localized state label. For standard states (0-3), may be omitted; for extended states (≥0x80), must be provided

Events

OperationalState Cluster defines 2 events for notifying controllers of important state changes.

OperationalError Event

Triggered when the device enters an error state. Event priority is CRITICAL, ensuring controllers receive timely error notifications.

FieldTypeDescription
ErrorState ErrorStateStruct Current error information

OperationCompletion Event

Triggered when the device completes a full operation cycle. Event priority is INFO. This event carries time statistics for the app to display an operation report.

FieldTypeRequiredDescription
CompletionErrorCode ErrorStateEnum Yes Error code at completion. 0 (NoError) indicates normal completion
TotalOperationalTime elapsed_s / null No Total operation time (seconds) including pauses. null means device does not track time
PausedTime elapsed_s / null No Cumulative paused time (seconds). null means device does not track time
Actual Running Time

To calculate actual work time (excluding pauses), use TotalOperationalTime - PausedTime. For example, if a washer's total time is 90 minutes with 10 paused, the actual wash time is 80 minutes.

Example Data

Read result from an OperationalState Cluster on a running washing machine:

{
  // --- Phase Information ---
  "0x0000": ["Soak", "Wash", "Rinse", "Spin"],  // PhaseList (operation phase list)
  "0x0001": 1,                                   // CurrentPhase = 1(currently in "Wash" phase)
  "0x0002": 1620,                                // CountdownTime = 1620 seconds (27 min remaining)

  // --- Operational State ---
  "0x0003": [                                    // OperationalStateList (supported states)
    { "OperationalStateID": 0, "OperationalStateLabel": "Stopped" },
    { "OperationalStateID": 1, "OperationalStateLabel": "Running" },
    { "OperationalStateID": 2, "OperationalStateLabel": "Paused" },
    { "OperationalStateID": 3, "OperationalStateLabel": "Error" }
  ],
  "0x0004": 1,                                   // OperationalState = Running
  "0x0005": {                                    // OperationalError (no current error)
    "ErrorStateID": 0,
    "ErrorStateLabel": "",
    "ErrorStateDetails": ""
  }
}
Developer Tip

PhaseList, CurrentPhase, and CountdownTime are all Nullable. Simple devices may not support phases or countdowns and return null. The app must handle null when rendering the UI — hide the corresponding elements when the value is null.

Common Scenarios

Scenario 1: Complete Washing Machine Lifecycle

  1. The user selects a wash program; the app sends Start (0x02) command
  2. The washer state becomes Running (1); PhaseList returns ["Soak", "Wash", "Rinse", "Spin"] with CurrentPhase = 0 (Soak)
  3. The app subscribes to CurrentPhase and CountdownTime changes, updating progress bar and countdown in real time
  4. The washer progresses through phases: CurrentPhase goes 0 → 1 → 2 → 3
  5. On completion, the device becomes Stopped (0) and fires the OperationCompletion event
  6. The app shows a completion notification: "Wash complete, total: 65 minutes"

Scenario 2: Error Handling and Recovery

  1. The washing machine is running and detects a water inlet anomaly
  2. The device state becomes Error (3); OperationalError updates to:
    • ErrorStateID = 1 (UnableToStartOrResume)
    • ErrorStateLabel = "Water Inlet Error"
    • ErrorStateDetails = "Water flow below threshold; check if the faucet is open"
  3. The device fires the OperationalError event (CRITICAL); the app shows an error notification
  4. After fixing the inlet, send Stop (0x01) to clear the error state
  5. The device returns to Stopped (0); send Start (0x02) to begin a new cycle

Scenario 3: Progress Tracking and UI Display

  1. The app reads PhaseList and renders a progress indicator (e.g., a 4-step bar)
  2. Subscribe to CurrentPhase; highlight the corresponding step on change
  3. Subscribe to CountdownTime; update the countdown in real time
  4. Subscribe to OperationalState; switch UI based on state:
    • Stopped (0) —— show the "Start" button
    • Running (1) —— show "Pause" and "Stop" buttons with progress and countdown
    • Paused (2) —— show "Resume" and "Stop" buttons; countdown is paused
    • Error (3) —— show error information and a "Stop" button
  5. Handle PhaseList = null — do not show phase progress; display only state and countdown