Locking competing clients

Executing the #LOCK command gives a client exclusive access. Locking access for all other clients (of the same Job Manager group) is cancelled with #UNLOCK.
It is not permitted to use further #LOCK commands within a locked block or to use further #UNLOCK commands outside the lock block.

If a lock block is still active at the end of the main program (M30), it is implicitly terminated and a warning is output.

Syntax:

#LOCK

Enable exclusive access

#UNLOCK

Disable exclusive access

Notice

notice

The lock block only affects specific Job Manager commands. All other CNC commands continue to be executed regardless of this.

Properties of the #LOCK command:

Every new incoming #LOCK receives an initial timestamp in the controller. This timestamp is used to prioritise several (possibly already waiting) #LOCK requests. The channel with the oldest #LOCK timestamp is granted access and the lock property. If another #LOCK is pending after an #UNLOCK, the timestamp prioritisation takes effect again and enables the next oldest #LOCK.
If they occur simultaneously, the channel with the lowest configuration number ‘j’ in the parameter master[j].log_id has priority (P-STUP-00206).