HMI pushbutton requires two presses?

Join Date
Sep 2015
Location
Grand Rapids, Michigan
Posts
18
-Please see attached code samples-
On my HMI I have a maintained pushbutton that toggles the tag "RecipeDeletePB". When this is pressed, it toggles the bit "RecipeDeleteMSG" which controls the visibility animation of a small popup window with yes and no maintained pushbuttons. These pushbuttons toggle the tags "RecipeDeleteAckPB" and "RecipeDeleteCancelPB" respectively and so either initiate the copy instruction or close the popup window. For some reason, I have to press the PB that toggles RecipeDeletePB twice EVERY time. I changed the code to the second set of rungs and now it works. I just can't figure out why. Any ideas? Also, it does the same thing on the HMI or running the client on my laptop. I am using RSlogix 5000 ver. 20.1 and FactoryTalk View ME 7.0
:confused:

Don't Work.jpg Works.jpg
 
I am not 100% sure, but I seem to remember an issue with the Push Button Toggle on an older Panel View version that would toggle it from the last state that the Panel View put it in, rather than the state that the bit was in?

So pushing it to toggle it on, then logically unlatching, would screw things up for me. The panel view would turn off the bit, but it was already turned off, and I'd have to hit it again to turn it back on.

This may have been a bug in a specific version, and possibly even Panelbuilder32, it just sticks out in my memory at the moment.

Of course, in your case I would think that such a bug would cause problems in both logic examples. Like yourself, I cannot see anything functionally different between those two examples. Unless there is something odd with the logic scan and the asynchronous IO/Comms updates. But even then I cannot imagine it acting that way.
 
One of the reasons I hate using HMI's for logic.
Your best bet is to just use momentary buttons on the HMI, and handle all toggling or whatever logic in the PLC. Even then, it is often a good idea (with any Rockwell product anyway) to add a forcible unlatch instruction in the PLC after it takes action on the HMI PB.
 
Your best bet is to just use momentary buttons on the HMI, and handle all toggling or whatever logic in the PLC.
That's the best answer for any HMI.

But if you want to use a maintained push button, make sure you have the settings below to avoid what Tharon is talking about. I'm not certain it resolves your double-press problem, but it's a good idea to use this anyway.

MPB indicate.jpg
MPB value.jpg


More than you asked...
Some HMIs do not have a maintained push button, because they don't really exist. A physical push button maintains the wires (un)connected. An HMI "maintained" push button writes to a tag just one time.

The PanelView will write a value (set) when you press, then write a second value (clear) when you press it again. What happens in between in the PLC logic could be anything. But the PanelView certainly does not "maintain" the set value.

Some HMIs will perform a continuous/repeated write to the PLC to help ensure that the tag stays set. But that writes at a rate of once every 100ms, 200ms, etc. ? What happens in between in the PLC logic could be anything.
 
Last edited:
That last little item in your snippet "State settings Next state based on:" ... That thing had me chasing my tail for some time on my first PV+ job. I am not sure why they think you should by default have the OIT lie to the operators, but it is after all, a Factory Balk family product.
 
if you can, change the pushbutton type to momentary instead of maintained. Common pushbutton code looks for an on and off to change the P-B status to ON. Then it looks for another on and off to change the PB status to OFF. When you use a maintained button, your 1st push turns it on. Your 2nd push turns it off and that is when the PB status changes. That is most likely WHY you see the effect you are seeing.
 
Necroing this because apparently I've been carrying over and modifying old work for so long that I forgot this was even a thing when I encountered it on actually new work. Absolutely mental that the default setting is to blindly alternate latch and unlatch commands and you have to go out of your way to make it toggle the current value like everyone would expect.

To touch on all the comments in the thread about only using momentary buttons, why write my own toggle code when there is a built in button type that does it? That's just the talk of people traumatized by Rockwell's overcomplicated implementation of it. 80% of the time, I want an HMI button to set a bit to true, maybe 15% of the time I want to toggle it, and only about 5% of the time do I actually want a momentary push button and almost all of those are for manual jog control (which they tell you not to do with momentary buttons on an HMI).
 

Similar Topics

Sorry for the basic question: On my HMI, I've created a button labelled SAVE to save the current values (distances in mm). It's not linked to any...
Replies
22
Views
2,269
I have a 1756-L73 controller hooked to a C-More T15CL HMI. On one of the screens, there is a momentary push button to activate a process.This...
Replies
18
Views
6,695
Good Afternoon , I'm doing a FactoryTalk View application ME, and I have a Momentary Pushbutton that I have the correct tag attached to it...
Replies
5
Views
2,129
Hello, I was discussing some of the changes we're making to our conveyor system (for education) with one of my coworkers today. There are 5...
Replies
13
Views
4,483
i have a cutler hammer panelmate epro hmi that is connected to my AB slc 5/05. the problem i am having is that random buttons from the panelmate...
Replies
20
Views
7,579
Back
Top Bottom