Within the script of the parent device, it is possible to declare this relationship with the following command:
set_children childDevice1 [[childDevice2] [...]]
After this command is issued, the scripting engine will automatically call the deviceName_update procedure each time a child motor moves. This procedure must be written by the script writer and should re-calculate and set the parent motor's new position. With the setting of the new position the scripting engine will then call all of the deviceName_update procedures for all scripted devices that are parents of this parent motor. Therefore, a single updated position from a child motor will cause all of the parents in the hierarchy to re-calculate their own new positions.