Mode switch position graphical indication in RS Logic 5000 program

Pradeepkumar

Member
Join Date
Aug 2011
Location
Salem Tamilnadu
Posts
5
Dear Sir

How the Run Mode, Remote Run Mode and Program Mode color of Green and Blue get change in the RS Logix 5000 PLC program IDE Left Hand Side Top when we select the modes through the key on the PLC CPU.
Similarly we could also see the graphical switch changing indication in the program IDE top. pl let me know, What is the Bit status changes is used in the Color and switch position indication of the program. If is known, then we can use it for HMI. I traced it in the Controller Program Tag. But i Could not find. Pl help me

Pradeepkumar Salem India
 
You can read the keyswitch positon with a GSV instruction in your code, and the GSV help will lead you to believe you can retrieve this information.....

BUT ! the code needs to be running to be able to do this, so you will only ever see RUN and REM (when in Remote Run mode) positions.

Obviously this is only half of what you want.
 
If your HMI is using RSLinx Classic as the data server, there is an @Mode built-in object that should give you the processor mode, even for ControlLogix. It's not perfect (I always have to look up the caveats and details) but it's possible.

What HMI software are you using, Pradeepkumar ?
 
If you are familiar with CIP (class/instance/attribute), you can get this information using Class 1, Instance 1, Attribute 5. Reading this will return a 16 bit value. Bits 12-13 represent the mode.

If your HMI doesn't read generic CIP, then you could put a MSG instruction to read the value into a tag, then have the HMI read the tag.

For further information on the status word, this details the bits under the Processor Status:

http://advancedhmi.com/documentation/index.php?title=Class_Codes_for_ControlLogix
 
If you are familiar with CIP (class/instance/attribute), you can get this information using Class 1, Instance 1, Attribute 5. Reading this will return a 16 bit value. Bits 12-13 represent the mode.

If your HMI doesn't read generic CIP, then you could put a MSG instruction to read the value into a tag, then have the HMI read the tag.

For further information on the status word, this details the bits under the Processor Status:

http://advancedhmi.com/documentation/index.php?title=Class_Codes_for_ControlLogix

That won't work Archie, the MSG would not get executed to read any of the PROG or Rem PROG modes...
 
One way to do "read" RUN/PROG mode (not switch position) is to create a Produced tag, made from a UDT that includes a CONNECTION_STATUS element as it's first element.

That element contains a bit that tells you if the processor is running.

Now all you need is to either consume the tag (if your hmi supports produced/consumed tags), or to read it as normal.

This will continue to work even in Program Mode, because Produced tags are always kept updated, and produced.

The picture shows an example UDT....

2017-01-05_125755.jpg
 
Good point. I kind of made that suggestion without thinking it out very well.

Don't worry, you're not the first, and won't be the last, to make that small mistake....

Anyway, my last post about Producing a tag works a treat, as can be seen by the attached pictures...

2017-01-05_134606.jpg 2017-01-05_134625.jpg
 
daba...just tried your solution...works great! After tons of searching finally found a way to determine PROG mode for HMI display purposes. Thanks for sharing! (y)
 

Similar Topics

Hi, I am curious to know what will happen to a Running 1756 ControlLogix L73 controller if the keyswitch is changed from Remote Run to Program...
Replies
3
Views
1,606
Greetings! One of my shop's Micrologix 1500 processor's mode selector switch(soldered on the PCB) has broken off. Currently, it is stuck in RUN...
Replies
2
Views
2,319
I'm facing a problem with twincat system in WinCE that I want to switch twincat system to run mode, but everytime I restart it. It shows in config...
Replies
12
Views
32,021
I have a new CJ2M-CPU31 with one DO Card, one DI Card, and 1 Analog Card. I have the ethernet IP set to default 192.168.250.1 Node 0 I have not...
Replies
6
Views
8,202
I have 16 slot 1771AD chassis for PLC5/40. My program is set as single slot addressing. How to set the 8 dip switch of 1771AD.Which side take...
Replies
5
Views
7,272
Back
Top Bottom