Alarm Sounding and Silent

Sarah Khan

Member
Join Date
Feb 2018
Location
Karachi
Posts
1
I have 5 inputs; a hooter is needed to be sounded if any input is enabled and a lamp should glow on the Control Panel.
As soon as an input is enabled, hooter should be sounded and lamp will glow, however, if the acknowledged button is pressed once then hooter will become silent while lamp will keep on glowing until the input that caused the alarm is disabled.
Also, if Input 1 caused the hooter sound and glowing of lamp and then acknowledge button is pressed which silent the hooter while lamp is still on. If now another input is enabled, hooter should be sounded again and can be silent by the acknowledge button. This should be followed for all the inputs. I am new to ladder programming and I am using Studio5000 with ControlLogix system. Please help how to write a ladder logic for this? Thank you.
 
If it were me, I would use one rung with 5 branches to trigger a New Alarm OTE as well as an Alarm Present OTE. Another rung to acknowledge new alarms only. And a couple of rungs for turning the hooter and light on and off. This is one of those rare occasions that I would not mind if the OTL and OTU instructions were used. Personally I think the New Alarm rung would be good place for a latched bit.

Good luck!
Bubba.
 
Map each of the alarm conditions to a unique bit in a DINT ("ACTIVE_ALARMS"). Follow the convention of Alarm State = 1; OK = 0.

Your Lamp can be enabled whenever ACTIVE_ALARMS is non-zero.

Create a second DINT ("ACTIVE_ALARMS_LAST_SCAN"), and another ("ALARM_ONESHOTS").

Use a CPT block (or structured text) to compute:
ALARM_ONESHOTS = (ACTIVE_ALARMS AND NOT (ACTIVE_ALARMS_LAST_SCAN)).
That is, if, set the corresponding bit in ONE_SHOT that is set in ACTIVE but not yet set in LAST.

Now make ACTIVE and LAST equal, with a MOV ( ACTIVE_ALARMS, ACTIVE_ALARMS_LAST_SCAN)

What you now have is a DINT that, if it contains a non-zero value, means that a new alarm has occurred. This is perfect for triggering your Horn. Since the ACTIVE and LAST will be equal in a scan, ONS will revert to zero, so you need to seal your Horn on, breaking the seal with a Silence.


This solution is expandable up to 32 alarms. It can be expanded to hundreds of alarms by changing the DINT to a DINT array, the CPT instruction to a FAL, and the MOV to a COP.
 
Do the homework for the poster.
They'll appreciate it when they pass with honours.
They got it with zero effort because some posters wanted to look clever

But what happens when they have to do real programming on a potentially dangerous machine?
 
Agree Ronnie - I will just say use KEEP or SET and RSET and bit counters and compares for the results! So easy! Copy and paste stuff and change a few I/O numbers.
 
Many of you go around things the hard way really. The way I do it I can add alarms, mutes and the like without changing any other code. I have used my method up to 4000 alarms but it can be used up to the maximum number in a DINT - 65000 odd? Just have to make room in memory when programming. willxfmr and ardwizz - they are both hard ways around alarms for mine. I use Omron and that may make a difference to what functions are available as well. Have not used AB for years and no desire to do so although it is way better than Siemens and Schneider. That being said I have to tackle a very large Schneider job in the next few months - not looking forward to it - the software is too hard to use.
 
It's a fine line -- between showing off how smart we are, and not cheating someone out of the learning process that repeatedly beating one's head against a wall brings. This place is powered by "starving egos", as Terry Woods used to say, so you can't really blame anyone for succumbing to the temptation to show off from time to time.

This question feels less like a homework problem than most first-time posters bring (Car Park, Traffic Light, Elevator). I've seen it posted by more experienced (albeit still junior) programmers. I gave a generic, expandable solution, so that may help someone, not just Sarah, code this efficiently.

Yes, ideally I would have engaged Sarah in a game of 20 questions, leading her to create the code herself, and actually learn. But time zone differences, online availability, and just plain time don't always yield ideal results.

Answer if you want; don't answer if you want. But it's usually bad form to tell other people how to act, even if (or especially if) you're right.
 
I'd be curious to see your code. I collect code fragments the way that others collect stamps. It's a hobby (and a sickness).

I also don't see what's so "hard way" about my method. Once the code structure is in place, like you, I can add new alarms just by mapping the alarm condition to an unused bit, without affecting the beacon or horn logic in the slightest.

What I posted is only a fragment of how I manage alarms -- I usually also have "Enable" logic to prevent nuisance alarms, make & break timers and/or deadbands, acknowledgement logic to interface with HMIs (especially their canned "Alarm" pages, which are generally awful, from an ISA 18 standpoint), and much, much more.

Making the process work right is usually only half the job. The other half, the harder half, is bringing the system back when things go wrong.
 
Do the homework for the poster.
They'll appreciate it when they pass with honours.
They got it with zero effort because some posters wanted to look clever

But what happens when they have to do real programming on a potentially dangerous machine?

I tried to give enough information to get them started without too much detail. I guess I went a bit too far. Sorry.

@ Aardwizz... Bubba is not going to be happy having to dig through all of that at 2:00AM to find out why that friggen hooter is keeping him from his coffee. KISS is best IMHO.


Bubba.
 

Similar Topics

Hello, I made a change in alarm setup in factory view studio, where I changed a alarm message text. After that I made a run application and...
Replies
0
Views
70
I am trying to enable an external alarm via computer speakers for Factory Talk Network Distributed Edition. I am using Alarm and Events setup. I...
Replies
7
Views
126
FactoryTalk View ME running on PanelView Plus 7, connected to Compact GuardLogix 5380 PLC Customer is asking for a physical push button to be...
Replies
6
Views
169
Hi all. I´ve got a little problem with my FT View SE alarm window. On my PLC program, I have 200 SINT for alarms, in which every bit is for one...
Replies
2
Views
134
Hello, I have a compact Logix plc and I have been task with configuring alarms into our SCADA when an Analog signal stops moving. The analog...
Replies
6
Views
222
Back
Top Bottom