FB_GetRouterStatusInfo
The function block FB_GetRouterStatusInfo reads the TwinCAT Router status information (available memory, number of registered ports... ).
VAR_INPUT
VAR_INPUT
sNetId : T_AmsNetID := '';
bExecute : BOOL;
tTimeout : TIME := DEFAULT_ADS_TIMEOUT;
END_VAR
sNetId: Here a string containing the network address of the TwinCAT Computer can be given, whose TwinCAT Router status information should be read. The string can also be empty for the local computer.
bExecute: The function block is activated by a positive edge at this input.
tTimeOut: States the length of the timeout that may not be exceeded by execution of the ADS command.
VAR_OUTPUT
VAR_OUTPUT
bBusy :BOOL;
bError :BOOL;
nErrId :UDINT;
info :ST_TcRouterStatusInfo;
END_VAR
bBusy: When the function block is activated this output is set. It remains set until and acknowledgement is received.
bError: If an ADS error should occur during the transfer of the command, then this output is set once the bBusy output is reset.
nErrId: Supplies the ADS error code when the bError output is set.
info: Struct variable with TwinCAT Router status info.
Requirements
Development environment | Target System | PLC libraries to include |
---|---|---|
TwinCAT v2.9.0 Build > 1031 TwinCAT v2.10.0 Build > 1235 | PC or CX (x86) | TcUtilities.Lib ( Standard.Lib; TcBase.Lib; TcSystem.Lib are included automatically ) |
TwinCAT v2.10.0 Build >= 1301 | CX (ARM) |