FC_SetSubModuleIds - General Information
Type: |
Function |
Available as of: |
V1.0.4.0 |
Automatic setting of the module IDs of subordinate modules.
The function generates the ModuleIds of the submodules as follows:
SubmoduleId = MainModuleId x 100 + Index
The index runs from 1 to n = NumberOfSubModules.
Input |
Data type |
Description |
---|---|---|
i_udiMainModuleId |
UDINT |
ID of the node in which subordinate modules exist. |
i_pstSubModulesItf |
POINTER TO ST_StandardModuleInterface |
Array of the default interfaces of the submodules. |
i_udiNumberOfSubModules |
UDINT |
Number of submodules in the array at the i_pstSubModulesItf input. |
Output |
Data type |
Description |
---|---|---|
q_etDiag |
General, library-independent statement on the diagnostic. A value not equal to ET_Diag.Ok corresponds to an error message. |
|
q_etDiagExt |
POU-specific output on the diagnostic. q_etDiag = ET_Diag.Ok -> Status message q_etDiag <> ET_Diag.Ok -> Error message |
q_etDiag |
q_etDiagExt |
Enumeration value |
Description |
---|---|---|---|
OK |
0 |
Ok |
|
InputParameterInvalid |
97 |
The pointer SubModulesItf is invalid |
Enumeration name: |
Ok |
Enumeration value: |
0 |
Description: |
Ok |
The function SetSubModuleIds works without exceptions
Enumeration name: |
PointerSubModulesItfInvalid |
Enumeration value: |
97 |
Description: |
The pointer SubModulesItf is invalid |
Issue |
Cause |
Solution |
---|---|---|
- |
The pointer SubModulesItf is invalid |
The pointer SubMoulesItf must be >0 |