The Library SysLibSocketsAsync.libΒΆ

This library offers the same functionality as The Library SysLibSockets.lib, however function blocks instead of functions are used and the processing is asynchronous.

Note

:strong:Restriction

This library is not supported for AC500_Product_Name V2 devices.

Note

- The opening/closing of sockets may take a long time if many sockets are to be opened/closed simultaneously.

- Using the asynchronous functions is recommended.

Corresponding to the parameters of the functions in SysLibSockets.lib the respective function blocks of SysLibSocketsAsync.lib have specific input parameters with identic impact.

Corresponding to the return values of the functions in SysLibSockets.lib the respective function blocks of SysLibSocketsAsync.lib have specific output parameters with identic impact.

Additionally the following input and output parameters are available in all function blocks:

Input: bEnable BOOL Rising edge: the function block starts the action.
Outputs: bDone BOOL TRUE indicates that the function block has completed processing.
  bBusy BOOL TRUE indicates that the function block is still processing.
  bError BOOL TRUE indicates that an error has occurred.
  wErrorId WORD Error number

Each function block will start the respective action as soon as a rising edge is detected at bEnable. Then it must be called cyclically until bDone=TRUE. Thereafter the outputs bError and wErrorId as well as the specific output parameters of the particular function block are in effect.

TCP specific:

UDP specific: