SIS function blocks > SIS Math Blocks > Logic Solver Calculation function block > Expressions in DeltaV SIS Software > Functions in Logic Solver Expressions

STBT function

STBT(i,b,n). Set the bit in position n of an integer value (i) to a given Boolean value (b).

Syntax:

'external reference' := STBT(integer value, boolean value, bit position);

Example:

'OUT1' := STBT(IN1, 1, 0);

Sets bit 0 in IN1 to 1. If IN1 is 0 (zero), OUT1 is 1.