Rockwell Automation Allen-Bradley ControlLogix 1756-MVI Programming Reference Manual page 39

Multi-vendor interface module
Hide thumbs Also See for Allen-Bradley ControlLogix 1756-MVI:
Table of Contents

Advertisement

MVIbp_SendMessage
The MVIbp_SendMessage function copies the message data into a
buffer to be retrieved by the processor via a MSG instruction. The MSG
instruction must be configured as shown in table 3.F. The MSG
instruction implements a "get attribute" command to the MVI module's
assembly object. The MSG instruction will fail if a message has not
already been written by the application via MVIbp_SendMessage.
Table 3.F - Send MSG Instruction Configuration
Field
Value
Message Type
CIP Generic
Service Code
OE (Hex)
Object Type
4
Object ID
7
Object Attribute
3
Num Elements
application dependent
Path
application dependent
Return Value:
MVI_SUCCESS
MVI_ERR_NOACCESS
MVI_ERR_TIMEOUT
MVI_ERR_BADPARAM
MVI_ERR_BADCONFIG
Example:
MVIHANDLE
Handle;
int
rc;
WORD
buffer[250];
// Wait 5 seconds for the message to be sent
rc = MVIbp_SendMessage(Handle, buffer, 250, 5000);
if (rc = = MVI_SUCCESS)
printf("Message sent\n");
See Also:
MVIbp_GetIOConfig
MVIbp_ReceiveMessage
Description
Specify CIP message type
Get_Attribute_Single service
Assembly object class code
Output message instance number
Data attribute
Size of message to be written
Path to MVI module
a message has been received
handle does not have access
timeout occurred before the message was
transferred
a parameter is invalid
send messaging is not enabled
Publication 1756-RM004B-EN-P - October 2000
MVI Backplane API
3-17

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents