This library contains functions to control and manage, read and write fieldbus I/Os.
- Note
- The IoLib functions trace their debug information mainly into module the MLPI_IO_LIB and in addition, into the modules CMP_OPENCTRL and MLPI_BASE_MODULES. For further information, see also the detailed description of the library TraceLib and the notes about Using the Trace for debugging.
The table shows the PLC data types within the IEC61131 environment 'IndraLogic' and the corresponding data types within the C/C++ environment (e.g. 'Workbench OEM') of the MLPI. On reading or writing fieldbus I/Os, on default, you use the functions below named after the MLPI data type like mlpiIoWriteFieldbusIoUchar. If you include the header mlpiIoHelper.h, you can also use the equivalent functions named after the IEC61131 data types like mlpiIoWriteFieldbusIoByte or like mlpiIoWriteFieldbusIoUsint.
Number of Bits | Data types of PLC | Data types of MLPI |
8 | BOOL | BOOL8 |
8 | SINT | CHAR |
16 | INT | SHORT |
32 | DINT | LONG |
64 | LINT | LLONG |
8 | USINT | UCHAR |
16 | UINT | USHORT |
32 | UDINT | ULONG |
64 | ULINT | ULLONG |
8 | BYTE | UCHAR |
16 | WORD | USHORT |
32 | DWORD | ULONG |
64 | LWORD | ULLONG |
32 | REAL | FLOAT |
64 | LREAL | DOUBLE |
8n | STRING | WCHAR16 |
16n | WSTRING | WCHAR16 |