FB_RAIDGetInfo
This function block returns RAID info, which includes number of RAID controller sets and maximum number of drives per set.
![]() | Calling this function block only once in PLC program fulfills the need. System performance can be dramatically affected due to cyclic call of this function block. |
VAR_INPUT
sNETID : T_AmsNetId;
bWrtRd : BOOL;
nRAIDCntlrID : UDINT;
tTimeOut : TIME := DEFAULT_ADS_TIMEOUT;
sNETID: Is a string containing the AMS network identifier of the target device to which the ADS command is directed.
bWrtRd: The ADS command is triggered by a rising edge at this input.
nRAIDCntlrID: The RAID controller ID. (Hint: Can be read using FB_RAIDCntlrFind)
tTimeOut: States the time before the function is cancelled.
VAR_OUTPUT
stRAIDInfo : ST_RAIDInfo;
nBytesRead : UDINT;
bBusy : BOOL;
bError : BOOL;
nErrorID : UDINT;
stRAIDInfo: returns RAID info, which includes number of RAID controller sets and maximum number of drives per set.
nBytesRead: Number of succesfully returned data bytes.
bBusy: This output remains TRUE until the block has executed a command, but at the longest for the duration supplied to the ‘Timeout’ input. While Busy = TRUE, no new command will be accepted at the inputs. Please note that it is not the execution of the service but its acceptance whose time is monitored.
bError: This output is switched to TRUE if an error occurs during the execution of a command. The command-specific error code is contained in ‘nErrorId’. If the block has a timeout error, ‘bError’ is TRUE and ‘nErrorId’ is 1861 (hexadecimal 0x745). Is reset to FALSE by the execution of a command at the inputs.
nErrorID: Contains the command-specific error code of the most recently executed command. Is reset to 0 by the execution of a command at the inputs.