|
Type
| Function |
|
Description
| Performs a bitwise left shift operation on the WORD operand connected to the input IN. N specifies the number of bits to be shifted. |
|
Notes
|
- The empty bit positions resulting from the shift operation are filled with zeros.
- When shifting with N < 0, the function delivers the output value 0 because the parameter N is always considered as an unsigned integer value.
- The function does not support execution control with EN/ENO.
|
|
Parameters
| Inputs
IN
| Data type: | WORD |
| Description: | Input value. |
N
| Data type: | INT |
| Description: | Number of bits to be shifted. |
Output
OUT
| Data type: | WORD |
| Description: | Output value. |
|
| Error behavior | Error behavior
The following table shows the errors which may occur while executing the function and the value returned by the function in the corresponding error case.
| Error case | Output value |
| N < 0 | 0 |
|
|
Example
| Bitwise left shifting of 3 bits
|