Basic instructions
8.6 Move operations
S7-1200 Programmable controller
System Manual, V4.2, 09/2016, A5E02486680-AK
275
FILL_BLK (Fill block) and UFILL_BLK (Fill block uninterruptible)
Table 8- 80 FILL_BLK and UFILL_BLK instructions
in:=_variant_in,
count:=int,
out=>_variant_out);
Interruptible fill instruction: Fills an address range with copies of a
specified data element
in:=_variant_in,
count:=int,
out=>_variant_out);
Uninterruptible fill instruction: Fills an address range with copies of
a specified data element
Table 8- 81 Data types for parameters
IN SInt, Int, DInt, USInt, UInt, UDInt, Real, LReal, Byte, Word,
DWord, Time, Date, TOD, Char, WChar
Data source address
Number of data elements to copy
OUT SInt, Int, DInt, USInt, UInt, UDInt, Real, LReal, Byte, Word,
DWord, Time, Date, TOD, Char, WChar
Data destination address
Note
Rules for data fill operations
•
To fill with the BOOL data type, use SET_BF, RESET_BF, R, S, or output coil (LAD)
To fill with a single elementary data type, use MOVE
To fill an array with an elementary data type, use FILL_BLK or UFILL_BLK
To fill a single character in a string, use MOVE
The FILL_BLK and UFILL_BLK instructions cannot be used to fill arrays in the I, Q, or M
memory areas.
The FILL_BLK and UFILL_BLK instructions copy the source data element IN to the
destination where the initial address is specified by the parameter OUT. The copy process
repeats and a block of adjacent addresses is filled until the number of copies is equal to the
COUNT parameter.
FILL_BLK and UFILL_BLK instructions differ in how interrupts are handled:
● Interrupt events are
during FILL_BLK execution. Use the
FILL_BLK instruction when the data at the move destination address is not used within an
interrupt OB subprogram or, if used, the destination data does not have to be consistent.
● Interrupt events are
until UFILL_BLK execution is complete.
Use the UFILL_BLK instruction when the move operation must be completed and the
destination data consistent, before the execution of an interrupt OB subprogram.