9.3 Using the Color Box Tag Drawing Method

In the lesson 8, you created 1 digital input tag and 3 digital output tags, all related to the booster pump. You did not use any drawing methods to display these tags or to provide operators with control, as you had not yet created a control panel to place them on. Now that "Booster Pump Control" has been established, you can use the tag drawing methods to add control objects for these tags.

 

Along with controls, it is also convenient for operators to be able to see the current status of the equipment. Therefore, before adding any controls, you will add both Status and Mode indicators to display whether or not the booster pump is running, and whether it is currently in auto or manual mode.

 

1.  Click the Tag Browser button to open the Tag Browser.

2.  Select "DI10_1 Booster Pump Status" from the tag list.

3.  Click the Draw button. The digital input tag drawing methods are displayed. (Figure 109)

Figure 109

Operators should be able to immediately determine whether or not the booster pump is running, with a glance at the control panel. The Color Box drawing method changes color according to the value of the digital input tag with which it is associated; therefore it is a good choice as an indicator for the status of the booster pump.

 

4.  Click the ColorBox button.  A sample color box appears attached to the cursor. Place this within the Booster Pump Control window as shown.  The Graphic Editor for the Color Box will then open.

Figure 110

Figure 111

Figure 111 shows the Color Box graphic editor dialog with the default colors for each state

State 2 and State 3 do not apply to this tag as it is not a double-bit input.  If required, Black is used to indicating when the value of the tag is invalid.

5.  Click the OK button.

The color box will change color as the status of the booster pump is changed by the simulated data from the virtual Modicon PLC.