Can you change the HMI Graphic image by process?

Using the HMI Builder and creating custom interfaces for the BCS.
Post Reply
spvisd
Posts: 2
Joined: Sun Jan 29, 2012 10:13 am
Bot?: No

Can you change the HMI Graphic image by process?

Post by spvisd »

I understand how you can assign the HMI Image under settings and assign widgets. I'd like to be able to change the image everytime my process changes so that I can graphically display the different hose configurations and water flow as the process change. Can this be done? Thank you in advance for any direction.
JonW
Site Admin
Posts: 1726
Joined: Sun Jul 18, 2010 7:51 am
Bot?: No
Location: Huntington Beach, CA
Contact:

Re: Can you change the HMI Graphic image by process?

Post by JonW »

Can it be done? Technically, yes, but the BCS unit does not support it.

See my thread regarding doing a custom user interface here: http://www.embeddedcc.com/forum/phpBB3/ ... ?f=4&t=372

In a nutshell, if you run either a local proxy (Fiddler web debugger, Charles proxy or IIS w/ ARR & URL rewrite), you can do file substitution with customized HTML and JS files to get any interface you want.

If you look at the image of my customized interface, the center of the screen has push buttons that allow you to select the active process to view and the active state within the process. Those little green dots highlight to show which process you are viewing. You could easily modify that code to change the HMI graphic when the process is highlighted.

Be sure to click on the link to see the full size image referenced above as the one shown in the message post is scaled down and difficult to view.
User avatar
Baron Ken
Posts: 99
Joined: Fri Jan 15, 2010 2:50 pm
Bot?: No

Re: Can you change the HMI Graphic image by process?

Post by Baron Ken »

An alternative to doing a custom interface (sorry Jon, some of us just aren't that advanced yet ;)) is to just modify your external.js file (and enable its use on the settings page) by adding widgets that are drawings of the hose configurations, etc. Using registers that are enabled/disabled by processes, you can 'turn on/off' those hose widgets.

Another alternative would be to overload the upd_cp() function and have it replace the HMI graphic whenever a process changes (make it dependent upon whichever process is displayed). I haven't done this but it sounds very doable.
JonW
Site Admin
Posts: 1726
Joined: Sun Jul 18, 2010 7:51 am
Bot?: No
Location: Huntington Beach, CA
Contact:

Re: Can you change the HMI Graphic image by process?

Post by JonW »

Don't sell yourself short Ken! Your customizations are every bit as advanced as mine. My method pre-dates the ability to have an external.js file and the HMI graphic. If I were starting over, I could do 90% of my customizations using that method.

I think Ken's suggestion here is probably a better solution.
spvisd
Posts: 2
Joined: Sun Jan 29, 2012 10:13 am
Bot?: No

Re: Can you change the HMI Graphic image by process?

Post by spvisd »

Jon & Ken,

Thank you very much for the replies. It may be a little out of my pay grade, not a java guy. Possible to get any sample work from anyone to give directions on how to try it? Really appreciate your time thanks again! -Scott
Post Reply