FB_RAIDGetInfo

FB_RAIDGetInfo 1:

This function block returns a RAID info. containing the number of RAID controller sets and the maximum number of drives per set.

Notice

The function block should be called once only in a PLC program!

The system performance can be dramatically affected by the cyclic calling of this function block.

VAR_INPUT

VAR_INPUT
    sNETID       : T_AmsNetId;
    bWrtRd       : BOOL;
    nRAIDCntlrID : UDINT;
    tTimeOut     : TIME := DEFAULT_ADS_TIMEOUT;
END_VAR

sNETID: A string containing the AMS network ID of the target device to which the ADS command is sent (type: T_AmsNetID).

bWrtRd: The ADS command is triggered by the rising edge of this input.

nRAIDCntlrID: The RAID controller ID. (Note: can be read with FB_RAIDCntlrFind)

tTimeOut: States the length of the timeout that may not be exceeded during execution of the command.

VAR_OUTPUT

VAR_OUTPUT
    stRAIDInfo   : ST_RAIDInfo;
    nBytesRead   : UDINT;
    bBusy        : BOOL;
    bError       : BOOL;
    nErrorID     : UDINT;
END_VAR

stRAIDInfo: Returns a RAID info. containing the number of RAID controller sets and the maximum number of drives per set (type: ST_RAIDInfo).

nBytesRead: Number of successfully returned data bytes.

bBusy: This output remains TRUE until the block has executed a command, but no longer than the time present at the ‘Timeout’ input. No new command will be accepted at the inputs as long as bBusy = TRUE. Please note that it is not the execution of the service, but the time during which it be may executed that is monitored here.

bError: This output is set to TRUE if an error occurs during the execution of a command. The command-specific error code is located in ‘nErrorId’. If the block has an timeout error, ‘bError’ is set to TRUE and ‘nErrorId’ is 1861 (hexadecimal 0x745). It is set to FALSE if a command is executed at the inputs.

nErrorID: Contains the command-specific error code of the commands executed last; it is reset to 0 by a command at the inputs.

Requirements

Development environment

Target platform

PLC libraries to be integrated (category group)

TwinCAT v3.1.0

PC or CX (x86, x64, ARM)

Tc2_IoFunctions (IO)