ignore if variable changes in one direction

Discuss issues and ideas you have to configuring displays with PowerVision
verschuren
Posts: 79
Joined: Wed Oct 28, 2015 8:40 am

ignore if variable changes in one direction

Post by verschuren » Thu Feb 04, 2016 11:24 am

Hi,

I have popups being triggered by DEF level at 0, 5, 10 and 15 %. I would like them not to popup when I'm refilling the tank. I did build my program in Activity Program, see picture.
Def Level.png
Def Level.png (81.58 KiB) Viewed 114 times
Any ideas?

Mario
Mario Verschuren
Controls Integration
stalley
Enovation Controls Development
Enovation Controls Development
Posts: 618
Joined: Tue Mar 18, 2014 12:57 pm

Re: ignore if variable changes in one direction

Post by stalley » Thu Feb 04, 2016 5:31 pm

Hello verschuren,

Nice activity program!

I would think the user would want to see the pop ups as the levels change no matter if they are depleting the tank or filling it. If the tank is low at whatever level, they need to see the status. Just my opinion.:)

What ideas have tried? You could try using a flag variable, but when do you set it?
Sara Talley
Software Engineer
Enovation Controls
verschuren
Posts: 79
Joined: Wed Oct 28, 2015 8:40 am

Re: ignore if variable changes in one direction

Post by verschuren » Fri Feb 05, 2016 7:49 am

Hi Sara,

I think it would not be a big deal either, but some people think it's annoying. I was thinking to use a filter and tried to put one in front of the multi decision block. It's just a timer of maybe a minute? I was hoping to delay it long enough to avoid a popup during fill up, but short enough to still be relatively responsive once it the tank goes empty. Length of the timer should be determined with some testing.

Is there a delay timer function that I can just put in front of the multi decision block? It seems to fire the event right away with what I tried.
Def Level with filter.png
Def Level with filter.png (69.34 KiB) Viewed 105 times
Mario Verschuren
Controls Integration
stalley
Enovation Controls Development
Enovation Controls Development
Posts: 618
Joined: Tue Mar 18, 2014 12:57 pm

Re: ignore if variable changes in one direction

Post by stalley » Fri Feb 05, 2016 8:17 am

Hi verschuren,

Activity programs are processed from start to stop, no time slicing or multiprocessing, so timers IN an activity program can be a problem. If you put a five minute timer in an activity program, everthing on the display waits on the timer to end.

Try putting the timer on the Run On Event that initiates the activity program.

Another way might be to check whether the tank level is increasing or decreasing. You would need to account for the tank sloshing.
Sara Talley
Software Engineer
Enovation Controls
verschuren
Posts: 79
Joined: Wed Oct 28, 2015 8:40 am

Re: ignore if variable changes in one direction

Post by verschuren » Fri Feb 05, 2016 8:55 am

I already have a timer on the run on event. This will make the popup reappear after a couple minutes, so the operator gets a reminder.

I would be more interested in checking if the tank level is increasing. How would I accomplish that?
Mario Verschuren
Controls Integration
stalley
Enovation Controls Development
Enovation Controls Development
Posts: 618
Joined: Tue Mar 18, 2014 12:57 pm

Re: ignore if variable changes in one direction

Post by stalley » Fri Feb 05, 2016 9:42 am

Hello verschuren,

You will need some method of keeping track of the levels in the tank over some period of time. If you are configuring a color display, you can use a list. If you have a monochrome display you would need multiple database variables.

Maybe someone has an efficient design to accomplish what you need?
Sara Talley
Software Engineer
Enovation Controls
verschuren
Posts: 79
Joined: Wed Oct 28, 2015 8:40 am

Re: ignore if variable changes in one direction

Post by verschuren » Mon Feb 08, 2016 8:47 am

If anyone has a nice example, let me know. I'm using a color display, the PV480.
Mario Verschuren
Controls Integration