show the entry list
STEP 7 -- Creating S7 programs -- Executing operations
How in STEP 7 V5.x do you program signal generation (rectangle, sawtooth, triangle, sinus) using the cyclic interrupts?
How do you determine the velocity, acceleration and distance?
How can you address I/O bytes and individual bits via the I/O?
How do you implement numerical differentiation in STEP 7 V5.5?
How can you convert a hexadecimal number into ASCII characters with STEP 7 V5.5?
What should you watch out for with the display of negative integer values in the LAD/STL/FBD editor when monitoring?
Information on the topic of "Executing operations"
How do you calculate power, exponential, root, polynomial, logarithm and linear values and how do you convert trigonometric functions into degrees?
How can you convert a number value of the data type INT into a string in S5TIME, or into the data types BCD and REAL?
How can you delay the output signal in relation to the input signal?
How can you accumulate physical flow measurements (e.g. mass flow rate, flow velocity) to an overall value?
How do you monitor a 32-bit field, evaluate the position of an active bit and access individual bits of a double-word?
How can you link variables and block parameters with each other?
How do you check real numbers for parity?
How is numerical integration programmed in S7-SCL and STEP 7?
When is there a first scan in logic operation sequences?
What does the NOP statement in the STL editor mean in STEP 7?
How accurately can I calculate with REAL numbers that are used in extensive formulas?
Which functions and IEC standard functions exist in STEP 7 for converting and comparing string variables?
How do you program a shift register with the LAD/FBD statements in STEP 7 V5.5 and STEP 7 (TIA-Portal)?
STEP 7 (TIA Portal) -- Creating S7 programs -- Executing operations
How is numerical integration for the S7-1200/1500 programmed in STEP 7 (TIA Portal)?
How do you standardize and destandardize analog values with STEP 7 (TIA Portal)?
How do you filter only the places before and after the decimal point from a real value in STEP 7 (TIA Portal) V11?
How do you calculate the linear values for the y-coordinate of point P in STEP 7 (TIA Portal) V11?
How can you add together physical flow measurements (mass flow rate, for example) to a total value in STEP 7 (TIA Portal)?
How do you implement numerical differentiation in STEP 7 (TIA Portal) V11?
How do you convert data types in the TIA Portal for the S7-1200/1500?
How can you convert a hexadecimal number into ASCII characters with STEP 7 (TIA Portal)?
How can you determine the bit position of an active bit in a marker word with STEP 7 (TIA Portal) and monitor a 32-bit field?
How can you delay the output signal in relation to the input signal in STEP 7 (TIA Portal) V11?
In STEP 7 (TIA Portal) V11, how can you scale integer values in real numbers and real values in integer numbers for analog measurements?
How do you copy memory areas in STEP 7 (TIA Portal)?
How do you program the overlapping of tags with the keyword "AT" in the TIA Portal V11?
How do you program a pulse encoder in STEP 7 (TIA Portal)?
How do you program a shift register with the LAD/FBD statements in STEP 7 V5.5 and STEP 7 (TIA-Portal)?
What properties do you have to watch out for in STEP 7 V11 when you are inserting characters into a string with the "INSERT" statement?
How do you program a shift register with the LAD/FBD statements in STEP 7 V5.5 and STEP 7 (TIA-Portal)?
Part number:

Description
Using the shift and rotate statements, you can shift or rotate the bits 0 to 32 of an input value by a specific number of bits to the left or right. The table below gives an overview of the shift and rotate statements in STEP 7 V5.5 and STEP 7 (TIA-Portal):
 
Shit and rotate statements

STEP 7 V5.5

STEP 7 (TIA-Portal)
SHR_I Shift integer (16-bit) to the right SHR* Shift to the right
SHL_DI Shift integer (32-bit) to the left SHL* Shift left 
SHL_W Shift 16 bits to the left * Shift left 
SHR_W Shift 16 bits to the right * Shift to the right
SHL_DW Shift 32 bits to the left * Shift left 
SHR_DW Shift 32 bits to the right * Shift to the right
ROL_DW Rotate 32 bits to the left ROL* Rotate left
ROR_DW Rotate 32 bits to the right ROR* Rotate right
* In STEP 7 V11 the statement boxes have a drop-down list box from which you can select the data type (USint, UInt, Word, DWord, Byte, UDint, SInt, Int and DInt) for the statement. Click the statement in the LAD/FDB editor and move the mouse pointer over the field with the three question marks until the "▼" symbol appears. Click the "▼" symbol to open the drop-down list box.

Sample programming with the right shift registers in STEP 7 V5.5 and STEP 7 (TIA-Portal)
The two right shift registers in STEP 7 V5.5 and V11 shown below are activated by the positive edge at marker M0.0. The marker word MW40 is shifted by 1 bit to the right and the result is stored in the marker word MW50.


Fig. 01 - "SHR_W": Shift 16 bits to the right in STEP 7 V5.5

Fig. 02 - "SHR": Shift right in STEP 7 (TIA-Portal)

Note
More information about shift registers is available in the STEP 7 Online Help. Mark the statement box and press the "F1" key.

Creation environment
The screens in this FAQ response were created with STEP 7 V5.5 and STEP 7 (TIA Portal) V12.

 Entry ID:17811407   Date:2013-11-18 
I regard this article....as helpfulas not helpful                                 
mySupport
My Documentation Manager 
Newsletter 
CAx-Download-Manager 
Support Request
To this entry
Print
Create PDF 
Send to a friend
QuickLinks
Compatibility tool 
Themen
Help
Online Help
Guided Tour