Motion Control... and More.
RMCTools Online Help
Using 
 Allen-Bradley Controllers via Message Block

Using Allen-Bradley Controllers via Message Block

Using Allen-Bradley Controllers via Message Block

Most Allen-Bradley PLCs and PC-based controllers (ControlLogix, CompactLogix, SLC5/05, PLC-5, SoftLogix, etc.) support serial RS-232 and Ethernet communications, either built-in or through an add-on module.

This topic describes how to communicate with the RMC from the Allen-Bradley PLCs via the Message (MSG) block. For information on using EtherNet/IP I/O with the Logix PLCs, see the Using Allen-Bradley Controllers via EtherNet/IP topic. For details on using Allen-Bradley's RSView operator interface with the RMC, see the RSView with the RMC topic.

The Allen-Bradley PLCs can read or write from registers in compatible remote devices such as other Allen-Bradley PLCs or the RMC. The RMC contains floating point (F) files, all of which are accessible over serial or Ethernet from the Allen-Bradley PLCs. See the Register Maps for details on those registers and their addresses.

If you need help setting up your Ethernet network, either consult your network administrator, or for simple stand-alone networks, see Setting Up a Standalone TCP/IP Network.

For setting up the RMC75S serial settings, see the Configuring Serial Communications topic. For setting up the RMC75E or RMC150E Ethernet, see the RMC Ethernet Setup topic.

Example Programs

Delta provides example PLC programs to help you quickly set up the communications between your PLC and the RMC. See the downloads section of Delta's website at www.deltamotion.com.

Message (MSG) Block

The Allen Bradley PLCs and controllers listed above all use the same ladder logic block to communicate over Ethernet: the Message (MSG) block. This block takes a number of parameters, which are briefly described below. For a complete description of the parameters, refer to Allen-Bradley's Instruction Set Reference Manual for the appropriate PLC.

MSG Parameters

The MSG block parameters differ slightly depending on the controller and programming software. The parameters used by RSLogix 5 version 3.2.0.0, RSLogix 500 version 6.30.00, and RSLogix 5000 version 17.00.00 for the PLC-5, SLC 5/05, ControlLogix and CompactLogix controllers respectively are described below. The SoftLogix 5 parameters are similar.

ControlLogix and CompactLogix MSG Block Parameters

SLC 5/05 MSG Block Parameters

PLC-5 MSG Block Parameters

MicroLogix MSG Parameters

Using the MSG Block in Ladder Logic

The Allen-Bradley MSG block takes multiple ladder scans to complete. Therefore, it is important to enable the MSG block for the correct amount of time. Specifically, the MSG block must be energized until the message control's enable (EN) bit turns on. Delta has found some aspects of this to be difficult and therefore has provided the following ladder samples:

Read or Write Continuously

Using the Examine If Open instruction as shown below fulfills two requirements of continuous MSG transactions. First, it will keep the block energized until the EN turns on, and second, it de-energizes the MSG block once the transactions is started so that when the transaction is completed (EN goes low again), the MSG block sees a rising edge on its input, thus repeating the transaction:

 

Read or Write Once

This sample takes care to keep the MSG block energized until the MSG block starts, as indicated by the enable (EN) bit turning on. Once this happens, the application-controlled TriggerOnce coil is turned off. The message control's Done (DN) or Error (ER) bits can be used to process the results of the transaction.

 

 

Reading DWORDs from the RMC

All items in the RMC have F-file addresses. Allen-Bradley defines F file data as 32-floating point values. All the RMC registers have F-file addresses, even if they are DWORDs or DINTs. For example, the Status Bits and Error Bits in the RMC are DWORDS. To read these values, read them using their F addresses as given in the RMC. Then, in the PLC, use the COP instruction (RSLogix5000), or CPW instruction (RSlogix500) to copy the data to a register or tag of the correct data type, for example, an N register, L register, or DINT tag. The COP instruction preserves all the bits correctly, and the resulting values will be correct.

If the PLC must write a DINT or DWORD in the RMC, use a similar method.

 

See Also

Ethernet Overview | RMC70 Register Map | RMC150 Register Map | RSView with the RMC


Copyright (c) 2005-2012 by Delta Computer Systems, Inc.