How to Enter Instructions in FBD (GS 4.4)

This topic discusses several ways to insert an FBD instruction:

Instruction Tree: Drag and Drop

Instruction Tree: Double-Click

Toolbar Button

Function Key

You may also need the following information from this topic when you insert instructions:

Correct Placement of Instructions

How to Draw Lines

Insert versus Overstrike Mode

Related Topics:

Negating Boolean Inputs

Making Boolean Inputs or Outputs Immediate

Adding or Removing Extra Inputs (AND/OR only)

Correct Placement of Instructions: Work from Left to Right

Back to Top

Always work from left to right when you create FBD networks, in order to take advantage of the Program Editor's special features:

·Automatic connection of boxes (when the insertion cursor is placed correctly on the same row as the open output >> of a preceding box)

·Automatic adjustment of box location (when the insertion cursor is placed correctly on the same row as the open output >> of a preceding box)

·Automatic adjustment of box size (to enable the input of the box that you are inserting to line up with and connect to the open output >> of a preceding box)

When you work from left to right and place instructions appropriately (with the insertion cursor on the same row as the output >> of the previous instruction), the Program Editor automatically connects and arranges the instructions for you.

Leave Room for Parameters

Think of the FBD Program Editor as a grid composed of columns and rows.

You cannot place instructions in the top row of a network; your cursor must be on the second row or lower. In addition, if an instruction has inputs on the left side, you cannot place the instruction in the first column of the Program Editor, because there would be no room for the parameters.

Tip: Watch the FBD toolbar when you work in the Program Editor; the line tools and instruction buttons are automatically disabled if you place your cursor in an area of the Program Editor where it is not valid to drop a given type of line or instruction.

Note: When you connect one instruction to another, you do not have to leave extra space between them. You can drop the second instruction directly on the appropriate output parameter (>>) of the first.

Changing an Output Assignment to a Connection

If you assign a parameter value to the >> output of an instruction, but decide later that you would prefer to connect the instruction to another instruction instead, you can simply drop the second instruction directly on the output of the first. The value (for example, Q0.1) that you had assigned previously to that output parameter is overwritten automatically and the output is connected instead to the replacement instruction.

Drawing Lines

Back to Top

You can use the horizontal and vertical lines from the Program toolbar, or hold down the CTRL key and press the LEFT, RIGHT, UP, or DOWN ARROW key on your keyboard, to draw lines between the elements of your network when necessary (for example, to create branches).

Insert Versus Overstrike Mode

Back to Top

STEP 7-Micro/WIN 32 allows you to toggle the INSERT key on your keyboard to switch between two editing modes:

·In insert mode (selected when you press the INSERT key), if you drop an instruction onto another instruction, the Program Editor moves the existing instruction over to make room for the new one.

·In overstrike mode (the default when the INSERT key has not been pressed), if you drop an instruction onto another instruction, the Program Editor deletes the existing instruction and replaces it with the new one.

Parameter Retention in Overstrike Mode

·If you replace (overstrike) one instruction with another box that has the same profile, any assignments that you made to the old parameters are transferred to the new parameters. (That is to say, if the second instruction has the same number of logic flow inputs, the same number of input address parameters, the same number of logic flow outputs, and the same number of output address parameters as the first instruction, then the parameter assignments are retained when you overstrike the first instruction with the second.)

·For AND boxes and OR boxes, the old parameters are retained even if you had modified the original box to add extra inputs. (For example, if you have four inputs assigned to an AND box, and you overstrike the AND box with an OR box, the OR box automatically inherits the four existing inputs.)

Drag and Drop from the Instruction Tree

Back to Top

1.Select instruction.

Note: A red dot before an IEC instruction indicates that the instruction is a non-standard extension to the standard IEC instructions, provided for compatibility because a similar instruction is part of the SIMATIC instruction set.

2.Drag instruction to desired location.

3.Drop instruction in desired location by releasing the mouse button

Note: The cursor automatically prevents you from dropping an instruction at an illegal location (such as into the first column, onto a network title, or onto the parameter of another instruction).

Double-click from the Instruction Tree

Back to Top

1.Place cursor at desired location in Program Editor window. A selection box appears around the location.

2.In the Instruction Tree, navigate to the desired instruction and double-click on it.

After you double click, the instruction appears in the Program Editor window.

Use Toolbar Button or Function Key

Back to Top

1.Place cursor at desired location in Program Editor window. A selection box appears around the location.

2.Either click the appropriate toolbar button…

or use the appropriate function key (F4=AND, F6=OR, F9=generic box) to insert an instruction.

Note: You cannot assign values to the parameters of this generic instruction box; you must select a specific instruction type as shown in Step 3.

3.A drop-down list appears. Scroll or type the first few letters to navigate to the desired instruction. Double-click on the desired instruction, or use the ENTER key, in order to insert it. (If you do not choose to select the specific instruction type at this time, you can return to the network and click the mnemonic area of the generic instruction (which contains ??? instead of a mnemonic), or you can select the instruction and press the ENTER key, to bring the list back up.)