EasyManua.ls Logo

JUMO LOGOSCREEN 700 - Bit Sequence Functions

JUMO LOGOSCREEN 700
64 pages
Print Icon
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
8 Functions
40
8.4 Bit sequence functions
Admissible data types
Argument: UINT, UDINT
Result: UINT, UDINT
SHL (IN, n)
Moves the bit sequence of the IN argument to the left by n bits. Subsequent digits are filled with 0 from
the right.
Example:
IN := 255; (* 0000 0000 1111 1111 *)
OUT := SHL(IN, 4); (* 0000 1111 1111 0000; OUT = 4080 *)
SHR (IN, n)
Moves the bit sequence of the IN argument to the right by n bits. Subsequent digits are filled with 0 from
the left.
Example:
IN := 255; (* 0000 0000 1111 1111 *)
OUT := SHR(IN, 4); (* 0000 0000 0000 1111; OUT = 15 *)
ROL (IN, n)
Rotates the bit sequence of the IN argument to the left by n bits in a circle.
Example:
IN := 43690; (* 1010 1010 1010 1010 *)
OUT := ROL(IN, 1); (* 0101 0101 0101 0101; OUT = 21845 *)
ROR (IN, n)
Rotates the bit sequence of the IN argument to the right by n bits in a circle.
Example:
IN := 21845; (* 0101 0101 0101 0101 *)
OUT := ROR(IN, 1); (* 1010 1010 1010 1010; OUT = 43690 *)

Other manuals for JUMO LOGOSCREEN 700

Related product manuals