Remote Program and Remote Run

Cfordit

Member
Join Date
May 2011
Location
Cleveland
Posts
6
Is there a way with a Controllogix to find a tag that contains whether the plc is in remote program or remote run? The RSLogix software shows "rem program" or "rem run" when keyswitch gets turned.
 
Is there a way with a Controllogix to find a tag that contains whether the plc is in remote program or remote run? The RSLogix software shows "rem program" or "rem run" when keyswitch gets turned.

GSV instruction

Controller Device Object
 
Thanks for the replies.
I do a search in RSLogix 5000 and it doesn't return any tags with "GSV" in it. I tried searching all routines and the search didn't return anything. Am I doing something wrong?
 
GSV stands for "Get System Variable". It's an instruction, not a tag. You will need to assign a tag to it once you have the correct parameters enterd.
 
If what you're trying to do is display the keyswitch mode in an HMI, you're going to find out in a bit that of course the GSV doesn't execute when you're in PROG or REM PROG, so you can't use it to determine those two modes.

RSLinx Classic and RSLinx Enterprise both include "pre-defined items" that directly query the controller's Mode Object and will tell you what mode the controller is in. Look up "@Mode" or "Pre-Defined Item" in the RSLinx online help or the Knowledgebase.

Any other HMI is going to need a generic CIP Object query (it's not a Tag that you can read with an ordinary Tag Read service) and I haven't seen any that support that function.
 
Here is a snapshot of a section of a program I use. It will tell you the keyswitch position if the program is in RUN or REM RUN. I use it as a quick and dirty debugging switch. What it won't tell you is if the PLC is in program mode, and since the program must be running there isn't anything you can do programmatically that will directly indicate that a program is running. You can program a heart beat bit and monitor it via an HMI program to see if the program is running, if the HMI doesn't detect a change of state withing a certain period of time it decides that the program must not be running.

A051911-1.JPG
 
If what you're trying to do is display the keyswitch mode in an HMI, you're going to find out in a bit that of course the GSV doesn't execute when you're in PROG or REM PROG, so you can't use it to determine those two modes.

RSLinx Classic and RSLinx Enterprise both include "pre-defined items" that directly query the controller's Mode Object and will tell you what mode the controller is in. Look up "@Mode" or "Pre-Defined Item" in the RSLinx online help or the Knowledgebase.

Any other HMI is going to need a generic CIP Object query (it's not a Tag that you can read with an ordinary Tag Read service) and I haven't seen any that support that function.


That is so obvious, makes you wonder why Rockwell would include the key switch in program mode.
 
Alaric....Thanks.

I entered the code example that you included and it worked. I am new to plc programming and wouldn't have got that without your example. Thanks again.
 
You can use the GSV with another PLC to query yours... That's why it's available.

No you can't use GSV to do this.

If you look at TConnolly's post, you will see that the "Instance" field in the GSV instruction is blank.

YOU can only GSV and SSV the system values in your own controller, not a remote one, even if you put it in the I/O Configuration

What you CAN do, however is get your controller to Produce a tag that is a UDT, the first element of which is an element (e.g."ConnectionStatus"), of data-type = CONNECTION_STATUS - see the pic for an example.

You can then consume that tag in another controller, and in the ConnectionStatus tag is a BOOL "RunMode".

This works well because Produce/Consume tags do not require the controller to be in run mode.

2016-10-27_014700.jpg
 
Further to my last post, I'm wondering if you could produce a tag with Connection_Status attached, not consume it by any other PLC, but just Read that produced tag with the HMI.... In there will be that BOOL that says the controller is actually in Run mmode....

Can't see why it won't work....
 
RSLinx Classic and RSLinx Enterprise both include "pre-defined items" that directly query the controller's Mode Object and will tell you what mode the controller is in. Look up "@Mode" or "Pre-Defined Item" in the RSLinx online help or the Knowledgebase.

Ken, I found this in the RSLinx v3.90 help under "DDE/OPC predefined items"

RSLinx Classic can obtain general processor information or trigger events using DDE/OPC predefined items.

The following are predefined items to use with all PLC types:

@Mode returns the current mode of the processor as a string (Run, Program, Remote Run, or Remote Program).
@ProcessorName returns the name of the program running in the processor.
@Revision returns the firmware version of the processor as a string.
@PLCType returns the processor type as a string.
@Status returns the current status of the processor as a string (Ok or Faulted).
@StatusNumber returns the current status of the processor as a number.
@SwitchTopic is used to switch between alias topics in OPC clients.

The following are predefined items to use with Logix5000 family processors:

@FreeMem returns total unused memory (I/O + data table + general).
@FreeMemDT returns unused data table memory (not applicable to 1756-L1).
@FreeMemGM returns unused general memory (applicable to 1756-L55M16 only).
@FreeMemIO returns unused I/O memory.
@TotalMem returns total available memory (I/O + data table + general).
@TotalMemDT returns total available data table memory (not applicable to 1756-L1).
@TotalMemGM returns total available general memory (applicable to 1756-L55M16 only).
@TotalMemIO returns total available I/O memory.
@CLTagUpdateAddressSpace forces RSLinx Classic to update its' Logix5000 tag database.
@RedundancyMode monitors the processor state in a ControlLogix redundant system.
@IsPresent allows you to check if your ControlLogix processor is available prior to performing reads or writes. The time out value is consistent with the communication timeout value in the configured PLC-5 topic.
 

Similar Topics

For my first time, I put a copy of Studio 5000 and Factory Talk Activation Manager on my customer's machine (On-logic Windows PC), then use remote...
Replies
3
Views
2,436
Doing a remote online with a customer on a 1756-L62 (NOT "S"!) in RemoteRun mode. Project is ver16.04 To reset faults the easiest way is put in...
Replies
4
Views
1,776
Rockwell CompactLogix or ControlLogix 5x70 or 5x80 series: Is it possible to determine if a Remote PLC is in Program Mode from another PLC...
Replies
13
Views
3,692
Good morning all. I looked through previous posts and didn't find any help on my exact problem. I have a 1769-L33ER PLC running a water jet...
Replies
4
Views
1,811
I should know this by now but have never been given a straight answer...seems like they almost do the same thing. I am using Studio 5000 by the way.
Replies
7
Views
4,066
Back
Top Bottom