Skip to main content

bitXIsEqualTo

Short summary​

This assertion method checks if the selected bit of current value is equal to the expected value

Parameters​

NameTypeCommentKind
currentValueBYTEcurrent value to checkinput
numberBitNumberBytenumber of bit to checkinput
expectedValueBOOLexpected value of bitinput
messageAssertMessagemessage if the assertion is falseinput

Code​

Declaration​

METHOD bitXIsEqualTo
VAR_INPUT
(* current value to check *)
currentValue :BYTE;
(* number of bit to check *)
number :BitNumberByte;
(* expected value of bit *)
expectedValue :BOOL;
(* message if the assertion is false *)
message :AssertMessage;
END_VAR