beautypg.com

Msg_tst_mask – Rockwell Automation 1771-DMC_DMC1_DMC4_DXPS Control Coprocessor User Manual User Manual

Page 231

background image

API Library of Routines

Appendix B

MSG_TST_MASK

B-100

Tests the bit associated with the specified message number.

C Syntax

#include

status = MSG_TST_MASK (mask,msg_num)

unsigned *mask;
unsigned msg_num;

Parameters

mask

Address of the read or write mask used with the MSG_WAIT function.
This function will test the bit corresponding to the message number.

msg_num

Number of the PLC-5 programmable-controller message (0-31).

Returns

Value

Meaning

1
0

Returns 1 if the corresponding bit is set
Returns 0 if the corresponding bit is reset or msg_num is not 0Ć31

Description

Use the MSG_TST_MASK function to test bits in the message
read/write masks.

C Example

See MSG_WAIT on page B-102 for a complete example of asynchronous
message processing.

MSG_TST_MASK