CfgRead3DAxisIds
The block CfgRead3DAxisIds reads the axis configuration of a 3D group. The ID of the 3D group is supplied to input nGroupId. The address of the variables into which the block will write the AchsIds of the group assignment is supplied to input pAddr. This variable is an array with three elements of type UDINT.
The command is executed with a rising edge at the input bExecute.
The bBusy output remains TRUE until the block has executed a command, although only for as long as the time specified at the tTimeOut input. While bBusy = TRUE, no new instruction will be accepted at the inputs.
The output bErr goes TRUE if an error occurs as the command is being executed. The command-specific error code is contained in nErrId. The outputs are reset by carrying out a command at the inputs.
Interface
VAR_INPUT
bExecute : BOOL;
nGroupId : UDINT;
pAddr : DWORD;
tTimeOut : TIME;
END_VAR
VAR_OUTPUT
bBusy : BOOL;
bErr : BOOL;
nErrId : UDINT;
END_VAR
Sample:
VAR
(* instance *)
ReadAxIds : CfgRead3DAxisIds;
AxIds : ARRAY[1..3] OF UDINT;
END_VAR
ReadAxIds( bExecute := TRUE,
nGroupId := 4,
pAddr := ADR( AxIds ),
tTimeOut := T#1s );
AxIds now contains the three axis IDs for the 3D group with the group ID 4.