MicroLogix 1200 Modbus RTU Slave how fast

g.mccormick

Lifetime Supporting Member
Join Date
Jul 2012
Location
IN
Posts
960
I am just getting information about a need that a site has.

They currently have a machine that has a ML1200 and is being interfaced to by a WindowsPC running a LabView program of some sorts. Their customer is demanding that the data be read/logged at 10hz (100ms). The original equipment manufacturer says it can't be done.

So, we are looking at replacing the LabView PC with a Linux PC running our DAQ software. I will either be replacing the ML1200 with Opto22 Snapio IO, or if I can get the data rates needed, I would just keep the ML1200 in place as intellegent IO (and with enough code in place to atleast take over and safely shutdown the machine if the comms drops out).

I have never use AB before, what I konw is the the project (I have a PDF of current project), is configured for:
CHANNEL 0 (SYSTEM) - Driver: Modbus RTU Slave
CHANNEL 0 (SYSTEM) - Driver: Modbus RTU Slave Edit Resource/Owner Timeout: 60
CHANNEL 0 (SYSTEM) - Driver: Modbus RTU Slave Passthru Link ID: 1
CHANNEL 0 (SYSTEM) - Driver: Modbus RTU Slave Write Protected: No
CHANNEL 0 (SYSTEM) - Driver: Modbus RTU Slave Comms Servicing Selection: No
CHANNEL 0 (SYSTEM) - Driver: Modbus RTU Slave Message Servicing Selection: No
CHANNEL 0 (SYSTEM) - Driver: Modbus RTU Slave 1st AWA Append Character: \d
CHANNEL 0 (SYSTEM) - Driver: Modbus RTU Slave 2nd AWA Append Character: \a
Node : 1 (decimal)
Baud: 19200
Parity: NONE
File Number for Coils: 0
File Number for Contacts: 0
File Number for Input Registers: 0
File Number for Holding Registers: 7
Expanded: No
Control Line : No Handshaking
InterCharacter Timeout(x1 ms): 0
Pre Transmit Delay(x1 ms): 0

The IO is:
0 Bul.1762 MicroLogix 1200 Series C (1 or 2 C
1 1762-OF4 4-Channel Analog I/V Output Module
2 1762-IF4 Analog 4 Chan. Input
3 1762-IF4 Analog 4 Chan. Input
4 1762-IT4 4-Channel Thermocouple Input Module
5 1762-IT4 4-Channel Thermocouple Input Module


I need to look through the programming better but assuming the N7 data files that I would need to read/write are:
(5modules * 4 channels)=20 words of analog IO
4 words of statuses/digital IO (I am just guessing)

So I would estimate(ie. SWAG) that I may need 24 words of data read and perhaps 6 written.

If I program all of the data that needs to be read/written nto continuous registers, that would mean 1 read/write command.

Should I be able to get equal to or better than 10hz data throughput at 19200 baud?
 
Should be able to do it, no problem. How old is the LabView computer? I'm guessing that's where the bottleneck is for the data logging...

I don't know anything about the LabView system other than it is being referred to as "LabView".
 
Wanting to get data at 10hz seems ridiculous?
Well, something doesn't make sense.

PLC is not designed for high speed data acquisition. Factors like PLC scan time, IO delay, and modbus master/slave response makes data collected in such manner meaningless. IMO.
 
Harryting is spot on. Given that the PLC is likely doing other things the only way to know for certain is to test it under normal operating conditions.
 
Should I be able to get equal to or better than 10hz data throughput at 19200 baud?

I think so.

Modbus RTU protocol to read 24 Holding Registers would take just 8 bytes for the poll command and 56 bytes for the response.

At 19200 bits/second and 10-bit data frames (8/N/1), 64 bytes requires a wire time of 640/19200 = 33 milliseconds.

That gives you 67 milliseconds for the controller to respond and still hit your 100 ms poll rate requirement. In my experience it seldom takes more than 10 or 20 ms for a MicroLogix to respond to a comms request.

I have not load-tested Modbus RTU on the MicroLogix 1200, but of all the protocols and interfaces in our industry, it's probably the most straightforward to do.

If you do any serial protocol analysis, your toolbox should feature a Stratus Engineering EZ-Tap or EZ-Tap Pro. Their motto should be "for when you get tired of guessing".
 
I need to look through the programming better but assuming the N7 data files that I would need to read/write are:
(5modules * 4 channels)=20 words of analog IO
4 words of statuses/digital IO (I am just guessing)
Can you map all the analog I/O values to contiguous registers?

Are the status words holding register values that can mapped to registers adjacent to the analog I/O?

If it's not all contiguous data registers, there might be multiple reads or longer reads (more bytes) to fetch the needed data.
 
I think so.

Modbus RTU protocol to read 24 Holding Registers would take just 8 bytes for the poll command and 56 bytes for the response.

At 19200 bits/second and 10-bit data frames (8/N/1), 64 bytes requires a wire time of 640/19200 = 33 milliseconds.

That gives you 67 milliseconds for the controller to respond and still hit your 100 ms poll rate requirement. In my experience it seldom takes more than 10 or 20 ms for a MicroLogix to respond to a comms request.

I have not load-tested Modbus RTU on the MicroLogix 1200, but of all the protocols and interfaces in our industry, it's probably the most straightforward to do.

If you do any serial protocol analysis, your toolbox should feature a Stratus Engineering EZ-Tap or EZ-Tap Pro. Their motto should be "for when you get tired of guessing".


I was trying to figure out those numbers. It seems to me like it should work also, thank you.




Can you map all the analog I/O values to contiguous registers?

Are the status words holding register values that can mapped to registers adjacent to the analog I/O?

If it's not all contiguous data registers, there might be multiple reads or longer reads (more bytes) to fetch the needed data.

If I can get RS500, and modify the project I will rework to get all of the data into continuous registers. I have a PDF of the project, but the way it it, I cannot read all of the register data numbers. I have what is suppose to be the prject, if anyone want to re-pdf for me that would be great.
 
A quick question:

I do not have view of the hardware yet, but I am attempting to learn about the ML1200 now (and ordering the comms cable and RS500 software). I see that the controllers ending in R have a secondary port for HMI/Programming. I do not know the complete model number of the controller I will be messing with, but the project file lists the Prog/HMI port in the info.:
Prog/HMI Port - Driver: DF1 Full Duplex
Source ID: 1 (decimal)
Baud: 19200
Parity: NONE
Control Line : No Handshaking
Error Detection: CRC
Embedded Responses: Auto Detect
Duplicate Packet Detect: Yes
ACK Timeout(x20 ms): 50
NAK Retries: 3
ENQ Retries: 3

This was from the PDFd version of the project. Does the fact that it lists the info mean that the port is actually there, or is that just like a default info regardless if the controller actually has the port or not?
 

Similar Topics

Hi, I've got a ML 1200 C series with only 1 port and would like to connect to our DCS via Modbus. Since there's only one port, I've decided to...
Replies
1
Views
1,424
I know there are many threads about Modbus with the Micrologix but I cant find a specific answer to my query. I have a MLX 1200 single port...
Replies
3
Views
1,980
Hello I encountered a problem when connecting a Micrologix to a Siemens S7-1200 CPU using MODBUS RTU. HW configuration is: Siemens S7-1200 with...
Replies
4
Views
6,695
Hello people.Thank you in advance. Below is a java application which I try to communicate my java application with ml 1200 through the Modbus...
Replies
0
Views
3,810
In micrologix1200 I have only one communication channel so that I do not unable to configure the PLC with Modbus rtu slave driver without losing...
Replies
9
Views
4,214
Back
Top Bottom