CPC G05B 19/056 (2013.01) [G05B 19/058 (2013.01)] | 4 Claims |
1. A control device including a first program in a first execution format in which an entirety of the first program is executed per a predetermined control cycle, and a second program in a second execution format in which parts of the second program are sequentially executed by an interpreter, the device comprising:
a first processor configured to execute the first program in the first execution format per the predetermined control cycle (i) to calculate a first command value for controlling a first control target and (ii) to control a second control target;
a second processor configured to execute the second program in the second execution format to calculate a second command value for controlling the second control target per the predetermined control cycle in accordance with an intermediate code generated by the interpreter interpreting at least a part of the second program in the second execution format, and to calculate the second command value for controlling the second control target in response to the first processor executing the first program in the first execution format; and
an interface configured to output the first command value and the second command value per the predetermined control cycle,
wherein the second processor is configured to permit, in response to an overlap between a time to execute the first program in the first execution format and a time to execute the second program in the second execution format for controlling the second control target, execution of one of the first program or the second program that issued an occupation request to the second processor earlier than the other one of the first program or the second program per the predetermined control cycle.
|