lock
The lock command protects one or more devices from configuration and routing changes. While a device is locked, commands that would modify it, including connect, disconnect, deviceswitch, MultiView routing, USB 2.0 pair/unpair/role changes, preset application, and applying saved settings, are rejected with an error. Locking does not interrupt existing routes; it only prevents new changes.
The unlock command returns the device(s) to the unlocked state.
lock is a convenience alias over the dev.Locked device configuration item: locking a device is equivalent to config set <device> dev.Locked true. Clients receive the same configurations notification produced by the config command.
Locking is idempotent: locking an already-locked device succeeds without making a change or emitting a notification.
| Command Type | DisplayNet |
| Minimum Version | 4.6 |
Usage
lock <target>
Arguments
target is a single device ID, a comma-separated list of device IDs, or a device group:
| Value | Locks |
|---|---|
<device_id> | A single device |
ALL | All devices |
ALL_TX | All transmitter devices |
ALL_RX | All receiver devices |
With a group or a list, each resolvable device is processed independently and the result reports the outcome per device.
State and side effects
- The lock is stored as device configuration, not as session state, so it survives a server restart and applies to every client: telnet, SSH, WebSocket, REST and DisplayNet Manager alike.
- It gates routing and device mutation:
connect,disconnect,usb2pairing, and the mutating SDVoE verbs (start,stop,join,leave,switch,unicast,multicast,set,factory,reboot) are all refused against a locked device. - Reads are never gated. A lock protects a device from being changed; it does not hide it or interrupt a link that is already up.
- A refused command returns the
DEVICE_LOCKEDreason.
Notifications
Locking devices that change state raises NOTIFICATION messages carrying the updated device configuration. See Requests and Events for more information.
Return value
The result contains a lock array with one entry per processed device. Each entry reports the device's actual locked state after the operation and a status of locked (state changed), unchanged (already locked), or skipped (the change could not be applied).
lock room_projector{
"status" : "SUCCESS",
"request_id" : null,
"result" : {
"lock" : [
{ "device_id" : "001ec0f04d9c", "locked" : true, "status" : "locked" }
]
},
"error" : null
}
REST API
| Endpoint type | DisplayNet API command |
|---|---|
| Address | POST /api/displaynet/<operation>, or name the operation in the body of a POST /api/displaynet. See Sending commands. |
| Role | User |
| Operation | Parameters |
|---|---|
lock | targets |