RSLogix 5000 - Alarms and EventsRS_Alarms_and_Events.swf
RSLogix 5000 version 16, paired with V5.0 of FactoryTalk View SE introduced a new architecture to handle alarming for your process or machine.
This new architecture moves the alarming system from a traditional HMI centric design, to a controller centric architecture. This new design has several benefits including:
Reducing polling by reporting alarms by exception from the controller only when the alarm occurs. This saves network bandwidth as well as reduces overhead on the controller servicing those communications.
Improves accuracy of time stamps by time stamping the alarm when it occurs at the controller instead of time stamping alarms when the HMI detects them.
Reduces HMI effort by not requiring alarming tags created in the controller to be associated to corresponding tags at the HMI. Alarms are automatically transported to the HMI as a subscription service.
In the instruction tool bar, a new tab has been created for alarming. This tab contains two new instructions.
The alarm digital instruction is used to monitor transition of Boolean events.
The alarm analog instruction will test a value against a threshold, or test for a rate of change of a value.
While alarms are available in all languages supported by RSLogix 5000, we’re going to start by adding a simple digital alarm to Ladder Logic.
To add a digital alarm to the system, click on the digital alarm to select it. Then, drag it onto an empty rung in your ladder logic display.
Next we need a backing tag for our alarm. This backing tag is used to handle communications with the alarming subsystem, store information about the alarm, as well as provide a program interface to the alarm.
To create a new backing tag for the digital alarm, click on the question mark and type in the tag name. For this demo we’ll call it ALM_MotorContactor.
Right click on the name and scroll to select New “ALM_MotorContactor” in the dialog box. Note the new data type called AlarmDigital. Click OK and the digital alarm tag is created.
As you can see, the instruction for the digital alarm also makes available 4 members of the backing tag. Program Acknowledge, Program reset, Program disable, and program enable. These 4 members of the backing tag are exposed here as they are the most commonly used members for programmatic interaction with the alarm. To access these in the program we’ll need to assign tags to them.
We have already created these boolean tags for these members. To assign them, click the question mark. If you know the name of the tag, type it in the field.
You can also search available tags by clicking on the down arrow. This opens the tag database and you can scroll to the appropriate tag.
The last thing we’re going to configure on this instruction is the minimum duration. This value determines how many milliseconds the alarm condition must be active before the alarm is actually triggered. We’ll enter 500, for 500 milliseconds. Leave the accum value at zero.
Now that we’ve added our digital alarm instruction, let’s configure the alarm itself.
Click on the ellipse button to open the digital alarm properties dialog. This dialog is designed to provide a quick easy way to configure your alarms.
The condition selects whether the digital alarm is active when the input rung goes true or false.
Severity lets you define, from 1 to 1000, how important that alarm is to the operator. Later, the operator display can be customized based on the severity assigned to an alarm. The operator can also filter based on an alarm’s severity.
Duration allows you to set how long the alarm condition must be true before it actually triggers. This is the same duration we already entered on the instruction back in ladder code.
The associated tag section allows us to create or enter additional tags that are important to this alarm. The value of these tags will be passed to the alarming system when the alarm goes active.
First we’ll add a tag called ContactorNumber, which we created earlier. Note this tag is a DINT data type.
Next we’ll add a string called ContactorName. You can use any native Logix data type as an associated alarm tag.
Just above the associated tags is the message field, where you can create the messages that will appear on the HMI when the alarm is triggered. There are two ways to enter messages.
You can type the message in yourself. Or, you can use the alarm message editor to build the message. Access the message editor by clicking on the ellipse button.
We type in “motor contactor” then a space and then we’ll add the associated tag so it shows up in the operator description. Click the drop down arrow in the add variable window, and scroll to the appropriate variable…in this case Tag 1 ContactorNumber.
Select add. To include it in the message.
Add another space and type fault, space, dash. Now we are ready to add of string tag.
Go back to the dropdown and scroll to Tag2 ContactorName. Highlight it and click the add button.
Click OK. Now when the operator sees the alarm, it will read, “MotorContactor…value of tag one (our motor contactor number)…fault…dash … the value of tag 2, which equates to the contactor name.
Next we’ll enter the alarm class. Alarm class allows you to associate multiple alarms by class so the operator can later request all alarms associated in that class. For example, we’ll enter Pump1 for our alarm class here. This allows the operator to later look at all alarms associated with the Pump1 alarm class.
The next field we’ll enter is the FactoryTalk View Command field. This field allows you to configure any Factory Talk View commands that an operator may wish to execute when this alarm is active. Lets configure our alarm to call a specific FactoryTalk View screen called Contactor by entering “display ContactorScreen.”
This alarm configuration also provides a method to configure default values and look at current values of the members for the backing tag.
Click on the parameters tab and you will see elements or members of your backing tag. All of these parameters are accessible in the program using the following naming convention: “Alarm tag.Member name.” In this case, we’ll use ALM_MotorContactor.OperSuppress to access the tag.
The exception to the rule is that in ladder logic, the tags we have included on the faceplate of the instruction are already associated to the backing tag on the ladder block.
Click OK to complete the configuration of the digital alarm.
The last thing to do with a digital alarm is to create the condition that will cause the alarm to trigger.
From the favorites tab, select the XIC instruction and drag it to the ladder rung.
Click the question mark to highlight the tag field. Here you can either type in the name or click the down arrow to scroll to the appropriate tag. For this example, we’ll select ContactorFused.
Now, when this ContactorFused bit goes high from whatever evaluation code we have on the contactor, the digital alarm will trigger.
That’s how you set up a digital alarm instruction in ladder logic.
Alarm digital and alarm analog are available in RSLogix 5000 for Ladder Logic, Function Block, Sequential Function Chart and Structured Text programming languages.
Now we will add an analog alarm instruction in Function Block.
Click on the Alarms tab, select Alarms Analog and drag it to the function block routine.
Rename the alarm. Right click on the Alarm name and select Edit Alarm_04 Properties from the task window.
In the Tag Properties window, type in the new name, “ALM_Tank1_Level. And select OK.
As you can see. The Input pins are on the left side and the output pins are on the right.
Now we can add an input reference. Click the input and drag it to the program. This represents the Analog level for our tank alarm.
Connect the input reference to the input pin.
Click on the question mark to type in the tag name or to scroll to it. We have already created a tag for this example called, AnalogLevel_Tank1. Click to select.
Click on the ellipse button to open the analog alarm properties dialog.
In the input level section, you can see the types of alarms that can be triggered. As well as the minimum duration or how long the alarms have to be at a certain state before triggering. You can also set up a deadband for the analog level alarms.
In the Rate of Change section we can set the rate at which a value changes, positive or negative, over a certain period of time.
For this example, we’ll set the High high to 1000, the high to 90, the low to 20 and the Low low to 10.
We can also set the severity of the event. So we will set the severity for the High high to 1000. We’ll leave the High and Low at the default 500 and set the Low low to 100. This prioritizes the alarms’ importance for the operator.
We can also add an alarm class and a FactoryTalk View command, just like with Digital alarms.
We’ll match this to the previous alarm we created and call it Pump1. Now both alarms will be associated with the Pump1 class for sorting purposes.
Next we’ll set up the rate of change. Let’s say that is the value changes by more than 100 counts in a second, it will trigger the rate of change alarm. So, we set both the positive and negative limit to 100 and the period to 1.
Next click the message tab, so we can enter the message strings for the alarms themselves.
As you can see there are areas for all the different alarm levels and rate of change alarms. And, just like the digital alarms, there is a section where we can add tags related to this alarm that we want passed on to the operator when the alarm occurs.
Instead of just typing in the alarm string, let’s use the Alarm Message editor window to build our alarm message.
Simply type the beginning of the message – for example, “Tank 1 Level is” – and add a space. Then click the variable drop-down arrow and scroll to Condition Name. Click the ADD button.
Type the next part of the message: “:and currently at”, add a space and select the variable drop down again. This time scroll to Input value. Click the add button again.
Let's copy this alarm message to the rest of the level alarms using Control C” and “Control V”. The “Condition Name” variable we added to our string should differentiate the different level alarms for the operator.
Now we can enter the rate of change messages. Let’s enter these directly, for example: Tank 1 filling too fast and Tank 1 draining too fast.
Next select the parameters tab to see the backing tags for this analog alarm.
In Function Block, we also have a column to turn visibility on for different pins. To show how this works, click the checkbox next to the ProgAckAll pin.
Select OK to save the changes.
As you can see, the new input pin is now visible in the Function Block.
Let’s tie this input pin to an actual tag. Add an input reference to our function block sheet and tie it to the new input pin.
Next, we’ll assign a tag to the input reference by clicking the question mark, hitting the down arrow and scrolling to the tag ACK_Tank1_LevelAll.
Now we need to test both our digital and analog alarms.
We’ll assume you’ve already downloaded your program to the controller and are currently online with our Logix5000 project in RUN mode.
Now we are going to try and exercise our Digital alarm that we already added. Open your ladder logic to see the digital alarm block.
We’re going to trigger this alarm by toggling the alarm condition manually. Select the instruction and press “Control T” to toggle the bit on.
As you can see, the Boolean indictor tells us we are in alarm.
To view the alarm status information, click the ellipse button and select the status tab.
This will give you information such as the last time this alarm was triggered and when it was acknowledged…showing time stamp from the controller.
And since the time stamp is taken when the alarm condition occurs, rather than when it is reported to the HMI, the time stamp accuracy is a function of your code execution.
At the bottom of the screen are buttons to directly exercise the alarms without the HMI client being connected. You can do things like Acknowledge or suppress alarms here from the Logix5000 environment.
Okay, now we have finished down at the controller, let’s see how we start annunciating these alarms to a real operator using FT View SE version 5.0.
We assume you have already created a default FactoryTalk View SE project. We’re going to open FactoryTalk View SE and configure it to see our alarms.
First we need to enable alarms and events in our FactoryTalk View SE Application.
Right-click on the RSLinx Enterprise configuration on the View Studio Explorer window and select properties.
Click the Alarms and events tab.
And click the checkbox to enable Alarms and Events, which tells the server it should start looking for alarms coming in from controllers.
From this window, you can also select the database definition that describes where alarm and event information will be logged.
Once you’ve en enabled the alarms, you can double-click the communication setup icon and select a shortcut to designate which controllers you want this project to subscribe to for alarms.
For this demo, we have already created a shortcut to the softLogix controller we used for this demo. You’ll have to build your own shortcut that points to the controller you’re using.
Open the shortcut, by clicking on it to see what controller it targets and to enable alarms and events.
That’s the entire configuration you need to do to make the alarming system work in this Factory Talk View SE project.
Now we need to add objects to the display so the operator can see the actual alarms.
Open an existing or create a new display under the Graphics folder. This display will be the container for our alarm object.
There are four new objects used to visualize alarms. An Alarm and Event Summary, Alarm Banner, Alarm Log Viewer, and a Status Explorer. We're going to focus on the alarm summary object.
To add the alarm summary object, select the alarm summary from the tools dialog or just click on the icon from the toolbar. Then, click in the display and drag to create a window large enough to see the Alarms Summary view. We’ll choose to fill the entire graphic.
When we test-run the display, by clicking the Test Display button in the toolbar, any alarms FT Linx Enterprise has subscribed to will become available to the FT View SE application and display them on our alarm summary.
This icon in the bottom left tells you the status of the control connection …in this case, we see we are connected.
As you can see the first alarm that came up was the digital alarm we created in the controller that we previously triggered.
When you select an alarm in the summary, you can see all the statistics on that alarm, such as when it was last tripped and all the details on its current status.
Now that we have our alarm summary running, we’ll trigger some more alarms.
Let’s return to RSLogix 5000.
You can see the alarm instruction for the digital alarm. Open up the function block routine that contained our analog alarm.
Open a watch window for the routine and change the input value from 50 to 150. That should trigger both the high and rate of change alarms for this block.
Return to Factory Talk View SE. You can see the alarms we just tripped have shown up in the alarm summary display.
Refer to the online help for Factory Talk View SE for details on implementing the other alarm objects.
A Factory Talk Alarms and Events Quick start guide is also available for download from the Rockwell Automation literature library - Publication FTAE-QS001.