HMI

In this section we will show you how to connect the Grafcet logic to a HMI (Human Machine Interface) (S7-300/400 or S7-1200/1500).

This describes how to use a Button from a HMI image in the Grafcet chart.

All Grafcet symbols are stored in a data block. The data block number differs between S7-300/400 and S7-1200/1500 systems:

PLC Data Block
S7-300/400 DB490
S7-1200/1500 DB20101

In this example, an HMI is used for an S7-1200. For this reason, data block DB20101 must be used.

First you create the boolean variable HMI_BUTTON (name is random) in the symbol table within Grafcet-Studio in the Data area. The DB address column now displays the address within the DB where the HMI_BUTTON symbol is stored in the data block. In this case it contains D150.0.

In the HMI the variable HMI_Button01 must now be set to DB20101.DBX154.0 (4 must always be added).

Picture Grafcet Studio:

Configuration of the HMI variable in the TIA PORTAL:

If the button is pressed in the HMI screen, the bit "%DB20101.DBX154.0" is set to TRUE. Then the Grafcet symbol HMI_BUTTON is set to TRUE at the same time.

If required, you can also use the Grafcet symbol within a transition condition to make the condition for the next step dependent on the HMI variable.