class
Matter::CommissioningWindow
- Matter::CommissioningWindow
- Reference
- Object
Overview
CommissioningWindow manages the state of the commissioning window
The commissioning window is a time-limited period during which a device accepts incoming PASE (Password-Authenticated Session Establishment) sessions for onboarding new administrators or updating credentials.
There are two types of commissioning windows:
- Basic: Uses the device's default setup PIN
- Enhanced: Uses a dynamically-generated PAKE verifier
Matter Core Spec §5.5 - Commissioning Flows Matter Core Spec §11.19 - Administrator Commissioning Cluster
Defined in:
matter/commissioning_window.crConstant Summary
-
Log =
::Log.for("matter.commissioning_window")
Constructors
Instance Method Summary
-
#admin_fabric_index : UInt8 | Nil
Fabric index of the administrator who opened the window
-
#admin_fabric_index=(admin_fabric_index : UInt8 | Nil)
Fabric index of the administrator who opened the window
-
#admin_vendor_id : UInt16 | Nil
Vendor ID of the administrator who opened the window
-
#admin_vendor_id=(admin_vendor_id : UInt16 | Nil)
Vendor ID of the administrator who opened the window
-
#check_timeout : Nil
Handle window timeout
-
#close : Nil
Close the commissioning window
-
#closed? : Bool
Check if window is closed
-
#discriminator : UInt16 | Nil
Discriminator used for discovery (12-bit value)
-
#discriminator=(discriminator : UInt16 | Nil)
Discriminator used for discovery (12-bit value)
-
#expired? : Bool
Check if window has expired
-
#expires_at : Time | Nil
Timeout expiry time
-
#expires_at=(expires_at : Time | Nil)
Timeout expiry time
-
#open(status : Status, admin_fabric_index : UInt8 | Nil, admin_vendor_id : UInt16 | Nil, discriminator : UInt16, timeout_seconds : UInt16, timeout_callback : Proc(Nil) | Nil = nil) : Nil
Open a commissioning window
-
#open? : Bool
Check if window is open
-
#statistics : Hash(String, String | Bool | Int32 | UInt8 | UInt16 | Nil)
Get window statistics
-
#status : Status
Current window status
-
#status=(status : Status)
Current window status
-
#time_remaining : Time::Span | Nil
Get time remaining on window
Constructor Detail
Instance Method Detail
Fabric index of the administrator who opened the window
Vendor ID of the administrator who opened the window
Handle window timeout
This should be called periodically by a timer or when checking window status. If the window has expired, it closes the window and invokes the timeout callback.
Close the commissioning window
This method is called:
- When commissioning completes successfully
- When RevokeCommissioning command is received
- During failsafe rollback
- When the window times out
Open a commissioning window
@param status Window status (Basic or Enhanced) @param admin_fabric_index Fabric index of administrator opening window @param admin_vendor_id Vendor ID of administrator @param discriminator Discriminator for DNS-SD advertising @param timeout_seconds Window timeout in seconds @param timeout_callback Callback invoked when window times out