CanUpdateServerBeReached

Read TwinCAT TIA

ns=2;s=DEPRAG Smart/SoftwareItemIdentification/CanUpdateServerBeReached

Indicates whether the update server is reachable.

Examples:

In addition to the parameters already explained, the following variables must be created / transferred for the implementation in TwinCAT 3:

Beckhoff parameter:

    bCanUpdateServerBeReached
    A boolean variable that can be used to trigger the execution of the CanUpdateServerBeReached command.
    OutputDataCanUpdateServerBeReached
    A Boolean variable to which the return value of the CanUpdateServerBeReached property is written.
    hrCanUpdateServerBeReached
    This can be used to monitor the execution of the command. Error codes have the type "HRESULT".
    fbSoftwareItemIdentification
    An instance of the "FB_SoftwareItemId" function block supplied with the DEPRAG Smart library.
    ConnectionHandle
    "ConnectionHandle" received when establishing a connection between DEPRAG Smart Server and your OPC UA client.


VAR
   bCanUpdateServerBeReached    : BOOL;
   OutputCanUpdateServerBeReached : BOOL;
   hrCanUpdateServerBeReached   : HRESULT;

   fbSoftwareItemIdentification : FB_SoftwareItemId;
END_VAR

hrCanUpdateServerBeReached := fbSoftwareItemIdentification.CanUpdateServerBeReached(
      bExecute := bCanUpdateServerBeReached
      ConnectionHandle  := depragSmartConnection.ConnectionHandle,
      OutputData   => OutputCanUpdateServerBeReached);

IF hrCanUpdateServerBeReached <> S_FALSE THEN 
   bCanUpdateServerBeReached := FALSE;
END_IF
                                                    

For examples and explanations regarding the calls of nodes via Siemens TIA Portal please refer to the sub-menu "Siemens TIA Portal" in section "Getting Started".