Message Type Instructions
Message type motion instructions send one or more messages to the servo module.
Examples of message type instructions include the:
- MotionDirect DriveOn (MDO) instruction
- Motion Redefine Position (MRP) instruction
Message type instruction work as follows:
- When the rung that contains the motion instruction becomes true, the controller:
- Sets the enable (EN) bit.
- Clears the done (DN) bit.
- Clears the error (ER) bit.
- The controller begins to execute the instruction by setting up a message request to the servo module.TIP:The remainder of the instruction executes in parallel to the program scan.
- The controller checks if the servo module is ready to receive a new message.
- The controller places the results of the check in the message status word of the control structure.
- When the module is ready, the controller constructs and transmits the message to the module.TIP:This process may repeat several times if the instruction requires multiple messages.
- The instruction executes.If the controller:Then:Does not detect an error when the instruction executesThe controller sets the .DN bit.Detects an error when the instruction executesThe controller sets the .ER bit and stores an error code in the control structure.
- The next time the rung becomes false after either the .DN or .ER bit sets, the controller clears the .EN bit.
- When the rung becomes true, the controller can execute the instruction again.
Provide Feedback