Mitsubishi Electric MELSEC iQ-R Series Manual page 64

Intelligent function module
Hide thumbs Also See for MELSEC iQ-R Series:
Table of Contents

Advertisement

CITL_WaitSwitchEvent
This function waits for a switch interrupt event of a C intelligent function module to occur.
■ Format
short CITL_WaitSwitchEvent(short sSwitch, unsigned long ulTimeout)
■ Argument
Argument
sSwitch
ulTimeout
■ Description
• This function waits for a switch interrupt event specified to the switch interrupt event type (sSwitch).
• If an interrupt event has already been notified at the time when this function is called, this function returns immediately.
• If the same switch interrupt event has been notified several times at the time of calling the CITL_WaitSwitchEvent function,
it is treated as a single switch interrupt event.
• The specified timeout value is rounded to the tick unit. Specify a timeout value of one tick or more.
Precautions
For the MODE switch interrupt event, an event issuance status cannot be judged from the appearance. To check the issued
status of MODE switch interrupt event, implement the processing such as receiving a switch interrupt event using the
CITL_WaitSwitchEvent function and making the USER LED turn ON.
■ Return value
Return value
0 (0000H)
Other than 0 (0000H)
■ Relevant function
Page 39 CITL_GetLEDStatus
3 DETAILS OF FUNCTION
62
3.1 C Intelligent Function Module Dedicated Functions
Name
Switch interrupt event type
Timeout
Description
Normal
Error
For details on the error, refer to the following chapter.
Page 108 ERROR CODE LIST
Description
Specify the switch interrupt event type.
• 0: Reserved
• 1: Reserved
• 2: MODE switch interrupt event
Specify the timeout value in ms units (0H to FFFFFFFFH).
(When FFFFFFFFH is specified, the function waits for an event infinitely.)
IN/OUT
IN
IN

Advertisement

Table of Contents
loading

This manual is also suitable for:

Melsec iq-r c

Table of Contents