In today's article I review how to add a PLC controlled “Start-up Splash Screen” to your FactoryTalk View Studio Machine Edition project.
Recently, one of our readers from TheAutomationForums asked how he could add a start-up splash screen to his PanelView Plus that would display his company's logo for a few seconds before switching to the projects main menu.
In today's article I'll demonstrate how to do this using a PLC, and in tomorrow's article I'll show how to do this without using a PLC.
Steps to be taken:
The steps we need to take to complete this project are as follows:
- We need to detect when the PanelView launches our project – we can do this by setting our start-up splash screen as the default display, and giving that display a unique “display number,” which in our example is 99.
- After the set period of time has elapsed, we need to command the HMI to display our “main” screen, which in this example will have a display number of 1 (no other displays can have a display number of 1 or 99 for our example to work)
- Once the main screen is displayed, we need to release screen control to the operators so they navigate the HMI.
Step 1) With your existing HMI project open in FactoryTalk View Studio, create and save your “Start-up Splash Screen” Graphic Display with a unique Display Number. In this example we named our start-up screen “LOGO” and gave it a display number of 99.
Step 2) Now open the screen you want to automatically replace the start-up screen (i.e. your “main” display,) and set its “Display Number.” In this example we display our “Main Menu” graphic display and gaven it a “Display Number” of 1.
NOTE: You'll want to insure your remaining screens all have unique display numbers, or at a very minimum do not have the same display number as your start-up and main screens.
Step 3) Now open the “Startup” settings and make your new start-up splash screen your “Initial Graphic,” and then click on “OK” to save your changes:
Step 4) Next open “Global Connections,” select the “Display” tab, and then:
- Provide a unique PLC Tag / Address for the “Replace Display Number.” The PanelView Plus will write the currently display Graphic Display number to this PLC tag.
- Provide a unique PLC Tag / Address for the “Remote Display Number.” The PanelView Plus will read this tag value and if it's a valid display number, the PVPlus will display the corresponding Graphic Display.
Step 5) Now that the HMI is configure, the next step is to add the control code to the PLC. Shown below are the two rungs used in this example:
NOTE: You can purchase “ad free” copies of our articles, videos, and sample code for $1 each here. Or become a “Patron” for as little as $1 a month and receive at least $3 worth of articles/videos/sample code free each month! Find out more here.
Step 6) The first rung detects when our startup screen is being displayed by comparing the “Replace Display Number” tag (N7:1) with a constant that represents the “Display Number” we gave our start-up screen (99.)
Note: By design we only display the start-up screen when the PanelView Plus first starts our application, as set in Step 2 above.
When our start-up graphic is being displayed, a timer starts for however long we want our start-up screen displayed:
Step 7) When the timer is done, the code calls for our main menu to be displayed by moving a 1 into the “Remote Display Number” tag (N7:0):
Step 8) When our second rung detects the code is commanding display 1 (N7:0,) and the PanelView Plus is also displaying that same screen (indicated by a 1 in the replace screen tag of N7:1) the rung then moves a 0 into the “Remote Display Number” tag (N7:0):
Step 9) And once the “Remote Display Number” tag (N7:0) is 0, the operator gains the ability to navigate HMI displays:
If you'd like to watch a video demonstration of the above, check out Episode 6 of The Automation Minute Season 4 below:
Have a question or comment? Please feel free to ask me here.
- First Look: MOXA Ethernet Switch, EDS-2005-EL - March 4, 2021
- New “Logix Live™” Online Training Course coming March 16th - March 1, 2021
- PLC Training: Free and Trial Programming Software - February 22, 2021