RSLogix / designer - Analogs status values

dalporto

Lifetime Supporting Member
Join Date
Jun 2021
Location
Montreal, QC
Posts
258
Hi.


Which of these system bits should I use to know that a particular AI or AO channel is faulted? Like I lost the 4-20mA loop, or the input is busted only on that particular input.


The screenshot comes from a live PLC without that card installed.


So, Local:8:I.In0Fault looks like it's kind doing its job, while Local:8:I.In[0].ChanFault is not, probably because the module isn't actually there.



I cannot find the difference between both of them, so right now I'm just using both.


Which ones are you using?


Thanks.

Sans titreAI.jpg
 
Hi.
Which ones are you using?

I don't know the difference between the two faults. The nice thing about 4 - 20mA is your normal values should be between 4mA and 20mA, so anything outside of that range is a fault. Of course you could extend that range a bit for normal tolerance errors.

It's also platform independent. Rockwell and Siemens are very extensive with their diagnostics.
 
Ok, maybe I wasn't clear enough.


I create a quality bit, let say Temperature_QUAL, and an alarm bit, let say Temperature_F.


I use the _QUAL to block things in the PLC, like I don't want to trip if the temperature is low IF the signal is fail, I only want to pop the alarm to let the operator know that its temperature value is bad and decide by himself what to do.


Since I see that system bits are available, I just want to use them to create these 2 BOOLs for each AI (second is the opposite of the first, I just like to alarm on 1 on screens), I don't want to start creating more code to check if each AI is withing the range when that information already exists. I'm doing that for TC or RTD when I have no other choice but it looks like Rockwell system bits cover for that here.


I just won't have the AI/AO modules before commissioning since we're re-using them, so I cannot test it to see what really happens.
 
Status bit is updated from module memory. If no module, no status.

ChannelFaults is updated by controller. If no module, all ones.

InXFault is aliased to bits in ChannelFaults.

Anyway, here's how to do it:

GSV(Module,XXX_IF8,EntryStatus,Value16)

If the upper 4 bits of Value16 come back as 4 you know the module is present and running, then check your .ChanFault
 
GSV(Module,XXX_IF8,EntryStatus,Value16)

If the upper 4 bits of Value16 come back as 4 you know the module is present and running, then check your .ChanFault


Thank you very much.


So let say GSV(Module,AI_AO_01,EntryStatus,AI_AO_01_QUAL), where AI_AO_01_QUAL in an Integer displayed as a Binary.


Then I need to check if AI_AO_01_QUAL is over 61440 to know if my module is healthy? Right now it's flashing mostly 4096 (2#0001_0000_0000_0000) and a couple higher values.


Am I right or I'm completely off with my understanding? I'd really like to have that module right now, would be much easier.



What would be the proper way to compare 2#0001_0000_0000_0000 against 2#1111_XXXX_XXXX_XXXX?


I bumped into this not long ago but i forgot where and how. I'll Google it but if someone can point me to the right direction that would be appreciated.



Thanks.
 
More like that I guess, eh?


Specifies the current state of the specified map entry. The lower 12 bits should be masked when performing a comparison operation. Only bits 12...15 are valid. Each value has a specific meaning:

16#0000. Standby. The controller is powering up.
16#1000. Faulted. Any of the Module object’s connections to the associated module fail. This value should not be used to determine if the module failed because the Module object leaves this state periodically when trying to reconnect to the module. Instead, test for Running state (16#4000). Check for FaultCode not equal to 0 to determine if a module is faulted. When Faulted, the FaultCode and FaultInfo attributes are valid until the fault condition is corrected.
16#2000. Validating. The Module object is verifying Module object integrity prior to establishing connections to the module.
16#3000. Connecting. The Module object is initiating connections to the module.
16#4000. Running. All connections to the module are established and data is transferring.
16#5000. Shutting down. The Module object is in the process of shutting down all connections to the module.
16#6000. Inhibited. The Module object is inhibited (the inhibit bit in the Mode attribute is set).
16#7000. Waiting. The parent object upon which this Module object depends is not running.
16#9000. Firmware Updating. Firmware supervisor is attempting to flash the module.
16#A000. Configuring. Controller is downloading configuration to the module.
 
That's right, if the result of the MEQ is true, the module is running. Rockwell is pretty clear about only testing for running because when faulted, the controller periodically attempts to reconnect.

MEQ(EntryStatus, 16#F000, 16#4000)
 
F means compare in 16#? While it would be 1 in 2#? Because it's the "highest" available value of the data type?


And 0 would be "don't compare".


Thank you very much, very helpful, I was trying to figure out the syntax.


Still not 100% completely sure why, but it's working.


Then I could also use MEQ(EntryStatus, 16#FFFF, 16#4000)?
 
No, you only want to compare bits 12-15. If the mask is 16#FFFF you're comparing all bits. The GSV instruction can return other status in those bits, you're only interested in bits 12-15, which should be 4.

Another way to do this would be:

BTD(EntryStatus,12,Value,0,4) EQU(Value,4) OTE(Running)

ed: 16#F000 is the same as 2#1111_0000_0000_0000
 

Similar Topics

Hi. Not the fist time I'm saying this but just to give a background. 95% of my PLC programming has used Schneider over the last 10 years on...
Replies
66
Views
4,986
Hi. I'll say it again, I worked mostly with Unity Pro for the last 12 years and I'm trying to convert our FBD standard to Rockwell Logix...
Replies
13
Views
1,506
So I have a question, How would I convert or transfer a program from Logix Designer to Rslogix 500. Im going to be taking said program and putting...
Replies
6
Views
1,615
Hello everyone! I am new to PLC programming and am using Studio 5000 to work with AB PLCs. My company uses VMware to allow me to remotely...
Replies
3
Views
1,324
All, Please help. I'm reaching the end of my rope with this thing... I can find tech notes galore on fatal errors with logix 5000 for everything...
Replies
7
Views
5,288
Back
Top Bottom