Mitsubishi Electric MELIPC MI5000 Series Programming Manual page 78

Vxworks
Hide thumbs Also See for MELIPC MI5000 Series:
Table of Contents

Advertisement

CCPU_WaitSwitchEvent
Waits for a switch interruption event to occur.
Format
short CCPU_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 reported when this function is executed, this function immediately ends normally.
• If the same switch interrupt event has been reported several times at a time when this function is executed, the user
program executes processing as a single switch interrupt event.
• The specified timeout value is rounded to tick unit. Specify a timeout value of one tick or more.
Return value
Return value
0(0000H)
-231(FF19H)
-234(FF16H)
-257(FEFFH)
For details on error codes, refer to the following section.
Page 116 Function error codes
3 DETAILS OF FUNCTIONS
76
3.1 C Controller Module Dedicated Functions
Name
Switch interrupt event type
Timeout
Description
Normal
Event timeout error
Event wait error
Interrupt type specification error
Description
Specify a switch interrupt event type.
• 0: MAIN RUN switch interrupt event
• 1: STOP switch interrupt event
If a value other than the above-mentioned is specified, an error is returned.
Specify the timeout value in milliseconds. (0H to FFFFFFFFH)
(When 'FFFFFFFFH' is specified, the function waits for an event infinitely.)
IN/OUT
IN
IN

Advertisement

Table of Contents
loading

Table of Contents