Attention
IronPLC can only run very simple programs. The steps described are accurate but many language features are not yet supported.
RESOURCE¶
A resource represents a processing unit within a configuration, typically corresponding to a CPU or processing module.
IEC 61131-3 |
Section 2.7.1 |
Support |
Supported |
Syntax¶
RESOURCE resource_name ON resource_type
task_declarations
program_associations
global_variable_declarations
END_RESOURCE
Example¶
RESOURCE DefaultResource ON PLC
TASK MainTask(INTERVAL := T#20ms, PRIORITY := 1);
TASK FastTask(INTERVAL := T#5ms, PRIORITY := 0);
PROGRAM main WITH MainTask : MainProgram;
PROGRAM fast WITH FastTask : FastProgram;
END_RESOURCE
A resource contains task declarations and associates programs with those tasks.
See Also¶
CONFIGURATION — parent container
TASK — execution scheduling
PROGRAM — executable unit