# Making an alarm on a value that rises "x" amount in "x" time

**URL:** <https://forum.inductiveautomation.com/t/making-an-alarm-on-a-value-that-rises-x-amount-in-x-time/83332>\
**Category:** Ignition\
**Tags:** ignition81, perspective\
**Created:** [December 19, 2023, 9:03pm UTC](https://forum.inductiveautomation.com/t/making-an-alarm-on-a-value-that-rises-x-amount-in-x-time/83332 "2023-12-19T21:03:27Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![mjohnson0238](https://avatars.discourse-cdn.com/v4/letter/m/4bbf92/32.png) [@mjohnson0238](https://forum.inductiveautomation.com/u/mjohnson0238)\
**Post date:** [December 19, 2023, 9:03pm UTC](https://forum.inductiveautomation.com/t/making-an-alarm-on-a-value-that-rises-x-amount-in-x-time/83332/1 "2023-12-19T21:03:27Z")

</div>

Is there a way to make an alarm happen if I have a value that rises more than, lets say 10, in 5 seconds?

Example, chilled water value is 65 degrees and if it rises to 75 degrees within 5 seconds it triggers an alarm.

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [December 19, 2023, 9:11pm UTC](https://forum.inductiveautomation.com/t/making-an-alarm-on-a-value-that-rises-x-amount-in-x-time/83332/2 "2023-12-19T21:11:10Z")

</div>

You'd need to take the derivative of that signal, then put bounds on the derivative. Taking a derivative requires doing math with prior values. Just using `previousValue` and `currentValue` on a change event is an option, but tends to be jittery for most purposes.

I tend to use the `recorder()` function from my Integration Toolkit to have a well-defined, not quite short, sliding sample window in memory. And use first and last entries for the math, to have less jitter.

---

<div class="post-metadata">

**Author:** ![mjohnson0238](https://avatars.discourse-cdn.com/v4/letter/m/4bbf92/32.png) [@mjohnson0238](https://forum.inductiveautomation.com/u/mjohnson0238)\
**Post date:** [December 19, 2023, 9:17pm UTC](https://forum.inductiveautomation.com/t/making-an-alarm-on-a-value-that-rises-x-amount-in-x-time/83332/3 "2023-12-19T21:17:06Z")

</div>

Thanks, I will see what I can do. Thats a good idea.

I take it the recorder() function isnt something I have access to?

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [December 19, 2023, 9:18pm UTC](https://forum.inductiveautomation.com/t/making-an-alarm-on-a-value-that-rises-x-amount-in-x-time/83332/4 "2023-12-19T21:18:09Z")

</div>

Install my Integration Toolkit module. It's free. Has lots of stuff that's generally useful.

---

<div class="post-metadata">

**Author:** ![mjohnson0238](https://avatars.discourse-cdn.com/v4/letter/m/4bbf92/32.png) [@mjohnson0238](https://forum.inductiveautomation.com/u/mjohnson0238)\
**Post date:** [December 19, 2023, 9:22pm UTC](https://forum.inductiveautomation.com/t/making-an-alarm-on-a-value-that-rises-x-amount-in-x-time/83332/5 "2023-12-19T21:22:35Z")

</div>

Will do sir.

---

<div class="post-metadata">

**Author:** ![mjohnson0238](https://avatars.discourse-cdn.com/v4/letter/m/4bbf92/32.png) [@mjohnson0238](https://forum.inductiveautomation.com/u/mjohnson0238)\
**Post date:** [December 19, 2023, 9:25pm UTC](https://forum.inductiveautomation.com/t/making-an-alarm-on-a-value-that-rises-x-amount-in-x-time/83332/6 "2023-12-19T21:25:34Z")

</div>

@pturmel , this one right?  
 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/8/7/870d341bb8ffe55ef8bad7591576ff7ab4a71f39.png)

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [December 19, 2023, 9:26pm UTC](https://forum.inductiveautomation.com/t/making-an-alarm-on-a-value-that-rises-x-amount-in-x-time/83332/7 "2023-12-19T21:26:45Z")

</div>

Yeah, I changed the name from Simulation Aids after ICC this year, by popular demand.
