RSLogix5000 & Analog Input

gizmo

Member
Join Date
Aug 2002
Posts
95
I need some programming help with bringing an Analog Input (4-20mA) into a Control Logix Processor via analog input module(1794-IE8).

I'm tring to read 0-60 psig from a PT on a 4-20mA signal. What instruction block do I need to use?

Thanks
 
Assume the following:

1) The 0 to 60 is a tag called pressure.actual
2) The incoming 4-20mA is a tag called pressure.4_20
3) The flex module is on devicenet.

Now what i usually do is check the raw is within limits 6240 to 31208
and if it is compute the actual value.

Hence LIM 6242 pressure.4_20 31208 CPT pressure.actual ((pressure.raw-6240)div 24968)*60

Before this rung you could check for out of range values, i.e below 6240 and above 31208 and generate an alarm bit, for rsview or HMI.

Sorry can't post actual ladder!!
 
For any unit conversion on any PLC you can use four function math with the following, which asumes integer math:

DataOffset = Data in input register at 4 mA (or zero analog signal of whatever range - for example 0 VDC on a 0-10 VDC transmitter)

DataSPan = Data at 20 mA - Data @ 4 mA

FACTOR = arbitrary factor (multiple of 10) needed to get proper resolution and accuracy

EU = Engineering Units x FACTOR

EUOffset = Engineering Units @ 4 mA x FACTOR

EUSpan = (Engineering Units @ 20 mA - Engineering
Units @ 4 mA) x FACTOR

DATA = Actual data reading in input register

EU = ((EUSpan x (DATA - DataOffset))/DataSpan) + EUOffset

ProcessValue = EU / FACTOR

For Example, 0-60 psig from 4-20 mA with resolution of 0.1 psig:

FACTOR = 10
Data @ 4 mA = 6240
Data @ 20 mA = 31208
DataOffset = 6240
DataSpan = 31208 - 6240 = 24968
EUOffset = 0 x 10 = 0
EUSpan = (60 - 0) x 10 = 600

DATA = 18975

EU = ((600 x (18975 - 6240)) / 24968) + 0 = 306

Process Value = 306 / 10 = 30.6 psig

In the SLC and MicroLogix platforms there are specific functions for converting to engineering units, the SCP and SCL functions, but I don't know if the ControlLogix has them.

(Phil - is this a candidate for the proposed FAQ section?)
 
Thanks for the replies. Once again this site has been a great help!

I'm confused on where you got the raw data ranges (6240-31208 for 4mA-20mA). I trust your values but couldn't find them in the module's documentation.

You would think "ControlLogix" would be able to Convert to EU with somekind of scaling block?

Thanks Again for the greatly appreciated help!
 
The data values at 4 mA and 20 mA are a function of the individual PLC brand, the specific I/O card, and for some brands the way the card is configured. For many PLCs the input card is 12 bit, and the range of data is 0 at 4 mA and 4095 at 20 mA. For the SLC 500 series you can configure the I/O cards to show 4000 for 4 mA and 20000 for 20 mA, or you can set them up to the data ranges Kevin identified.

For the SLC platform the data ranges and set-up information is in a specific manual for the I/O cards, and not in the general manual. I don't have personal experience with ControlLogix, but I'm sure the same is true for them. You can probably download the manuals at http://www.ab.com/
 
From a previous post by gizmo:
I'm confused on where you got the raw data ranges (6240-31208 for 4mA-20mA). I trust your values but couldn't find them in the module's documentation.
http://www.ab.com/manuals/io/1794/1794652.pdf

Go to "book" page C2 - or "Adobe Reader" page 65 of 73. Note that this chart is in HEX format.
Using the 0-20mA mode column:
1860 hex = 6240 decimal
79E8 hex = 31208 decimal
 

Similar Topics

Hi Everyone, I am currently reverse engineering a hydraulic unit with a CompactLogix L35E and I have an issue with a Differential Pressure...
Replies
3
Views
4,234
from an email: this is a fairly common question - and since I'm swamped with other projects right now, I've decided to post my answer to...
Replies
7
Views
5,893
I'm trying to think of a logical way to clamp a group of 32 analog inputs so that if they ever go out of range, the program will clamp them at...
Replies
12
Views
3,359
hi folks! here i am with my debut in this forum. I am using Rslogix 5000 ver17.2,have a fast analog module(1769IF4XOF2F)to be added to my project...
Replies
5
Views
3,976
Hi! So my problem is a little funky, I had Studio 5000 v 24 and 30 installed, but forgot to install RSLogix (which I cannot go without). Is there...
Replies
2
Views
114
Back
Top Bottom