Chapter 3 Programming
3
– 65
Event task
If rising or falling edge is detected, then corresponding event task will be executed immediately, which leads POU
(FUNCTION) under the task called accordingly. Desired program can be written in this FUNCTION. Event task is
configured as follows.
Double click on “Task Configuration” or right click and choose “Edit Object”. Task Configuration window appears.
Click “System Events” tab.
Click “Add Event Handler…” then Add Event Handler window appears. Choose an interrupt event from Interrupt 1
to 5 in “Event” and enter a name in “Function to call”. Click OK button, then FUNCTION will be created.
When new FUNCTION is created, a variable “EventPrm” (type:STRUCT EVTPARAM_Interrupt) is automatically
defined in the FUNCTION. This variable contains no data.
(Library IoDrvHIES is implicitly added to Library Manager, and this STRUCT is defined in it.)
Create your program in this FUNCTION accordingly. Functions contain no internal state information. Use global
variables including local I/O (external I/O) in functions.
Local I/O (external I/O) used only in functions is not updated. Make sure to use in other programs or function
blocks also.
Содержание EH-A14EDR
Страница 6: ...MEMO ...
Страница 10: ...MEMO ...
Страница 141: ...Chapter 3 Programming 3 81 Program ...
Страница 166: ...Chapter 5 Maintenance 5 4 MEMO ...
Страница 170: ...Appendix A1 4 MEMO ...