Sign in to follow this  
Followers 0
Charlie Maher

DF1 into CH0 of CLX

10 posts in this topic

Hello, I hope someone can assist on this. I have a Logix 5561S safety PLC and a third party device (TPD) that is communicating DF1 protocol RS422. The TPD is the DF1 master and the CLX is the slave. This was working through a ProSoft serial in-rack card, but the transfer rates were deemed too slow. The task is now to try the same thing through the CLX serial port. I have a 422->232 converter and the TX & RX lights show activity, so I feel it is working. My question is....How do I map the data that is trying to arrive via DF1 into a CLX. I am trying the PLC-2, -3, -5/SLC Mapping function, but I think the TPD is addressing the data to a decimal # not a file #. I have been trying various combinations and settings of MSG and get errors on the MSG. The TPD maker states that the device is doing PLC5 typed read/write. I am stuck, none of the MSG settings seem to do anything different. Thanks in advance for your comments, Charlie

Share this post


Link to post
Share on other sites
First question: is the TPD using DF1 Full Duplex or DF1 Half Duplex ? Second, let's check the port configuration of both the TPD and the ControlLogix. First thing to check is the Error Checking mode, to be sure both are using BCC or both are using CRC. If the TPD is performing PLC-5 style reads and writes, you need to configure tag arrays of the same data type as the TDP is expecting, with File Numbers that correspond with the PLC-5 data files the TPD is reading and writing. For example, if the TPD is reading and writing N10:0 through N10:99, you need to create an array (call it TPD_Data) of data type INT[100]. In the PLC/SLC mapping function in RSLogix 5000, you correlate File 10 with array tag TPD_Data. If the TPD is the message initiator, you do not need to have MSG instructions in the controller. If you can run a serial data capture (look into Docklight and SerMon by HHD Software) you can get a direct look at the data being sent by the TPD.

Share this post


Link to post
Share on other sites
Full Duplex, which I have CLX setup for DF1 Point to Point I had one in BCC and one in CRC, now both are in CRC and the 422->232 converter TX & RX lights are blinking crazily. The TPD is writing to decimal address 0 thru 455 and reading from 600 thru 1263. Which is a throwback from the Prosoft's internal database structure. I have tried several mapping versions using the 0 & 600 for the file#, but that isn't working. I am guessing this is where the problem is. I did download the Docklight, and hooked directly to the TPD, I am getting DLE and ENQ over and over.

Share this post


Link to post
Share on other sites
Good investigative work, Charlie. We're going to have to dig a little deeper. Do you have any records of how the Prosoft module was configured ? PLC-5 style addressing always has a Data Type and a File Number associated with it. Old PLC-2 style reads and writes, aka "Unprotected" addressing just uses a memory offset value. The PLC/SLC mapping function in RSLogix 5000 lets you define a PLC-2 addressing tag; make it a big INT array, like TPD_Data[1500]. We can tell for certain what the TPD uses by capturing the command data it is sending out. The fact that you're only capturing DLE ENQ repeatedly from the TPD tells me that it's repeating a retransmission request. Try hooking up Docklight and cycling power or restarting the TPD to see if you can get some kind of message request from it. Edited by Ken Roach

Share this post


Link to post
Share on other sites
Ken, I have attached the screen shot with the DFCM settings. This was the startup size of registers, which contained the 'whole' data amount. This large amount was used to pass config data to the TPD. After the config was accepted, the read and write register counts where changed to 200 each still starting at 0 & 600. This was an effort to reduce tx/rx times. I am working on you other suggestions, and will reply with info. The Manuf'r did state that the messages were PLC5 typed messages. Should I be able to read these as PLC2? I thought the header or addressing units were different between the types? Thanks, Charlie Edited by Charlie Maher

Share this post


Link to post
Share on other sites
That configuration shows us that the MVI56-DFCM was configured to emuate 200-element data files, beginning with File 7, and continuing to File 57. If this did work with the TPD, then the TPD was reading from and writing to the following numbered PLC-5 style Data Files: Data File 7 (DFCM database registers 0 - 199) Data File 8 (DFCM database registers 200-399) Data File 9 (DFCM database registers 400-599) Data File 10 (DFCM database registers 600-799) Data File 11 (DFCM database registers 800-999) Data File 12 (DFCM database registers 1000-1199) Data File 13 (DFCM database registers 1200-1399) To make the ControlLogix emulate all of these data files, you're going to have to create seven INT[200] type data arrays, probably named DataFile_7[200], DataFile_8[200], DataFile_9[200], and so on. In the PLC/SLC mapping tool in RSLogix 5000, you'll set them up as follows: File Number Tag Name 7 DataFile_7 8 DataFile_8 9 DataFile_9 10 DataFile_10 11 DataFile_11 12 DataFile_12 13 DataFile_13

Share this post


Link to post
Share on other sites
Ken, I spoke with the TPD manuf'r and they are addressing it as a decimal number ranging from 0-1263. After looking at their message format and the DF1 manual, they appear to be using the PLC2 format. Just like you said. After a day of testing with DockLight and other utils, it seems that the CLX ch0 is not replying quickly enough to the first message, so the TPD is resending it again and again.... I am in the process if getting updated firmware for the TPD to see if slowing it down helps. Thanks, Charlie

Share this post


Link to post
Share on other sites
Great work, Charlie. I seldom trust what a TPD vendor says about their DF1 implementation until I see it on the wire. Since the TPD is sending a PLC-2 style Unprotected command, you don't need those File -> Array mappings for PLC-5/SLC mapping but rather just one INT[1300] array tag that is entered into the "PLC-2 Addressing" field in the RSLogix 5000 PLC/SLC mapping window. I am surprised that the TPD times out so quickly; usually it's the other way around because they built the driver and tested it with PLC-2 or PLC-5 controllers years or decades ago and are accustomed to those turnaround times. I did a little test and found the ControlLogix replying after about 20 milliseconds to a request for 10 words of data using PLC-2 style addressing. Does the TPD maker really expect data faster than that through the serial port ? Edited by Ken Roach

Share this post


Link to post
Share on other sites
Ken, Can you describe your setup a little more, where you have a 20 msec reply. The TPD was resending the msg if the CLX didn't reply within 55 msec. They provided newer firmware the waits longer before timeout. I now do have the two talking and the PLC2 mapping is working. Do you know if the CLX mapping creates delays?

Share this post


Link to post
Share on other sites
I was setting up just a little test rig, with a 1756-L61 v16 and my PC running RSLinx Professional with Excel as a DDE client. I was using timestamps from my HHD Software Serial Monitor, which I think timestamps the beginning of each transmission. No matter if I used Logix encapsulation of PCCC (about 40 bytes in the request) or straight DF1 (16 bytes in the request), the controller didn't respond until about 20 milliseconds had elapsed from the data read request. I'm not running any application code, so the housekeeping task has all the time in the world to execute. You're running your actual control application, so housekeeping (and unscheduled communication, including the serial port) is in the background. You might get better DF1 comms responsiveness with a greater Communications Timeslice value; I think the default is 20%, and I sometimes turn it up to 40% when I have a lot of HMI traffic. Edited by Ken Roach

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0