Code example
IF (REAL_TO_UINT(REAL_VARIABLE) MOD 2) >= 1 THEN
DO_CAP_CAMERA_PROG_BIT0:= TRUE;
END_IF
IF (REAL_TO_UINT(REAL_VARIABLE) MOD 4) >= 2 THEN
DO_CAP_CAMERA_PROG_BIT1:= TRUE;
END_IF
IF (REAL_TO_UINT(REAL_VARIABLE) MOD 8) >= 4 THEN
DO_CAP_CAMERA_PROG_BIT2:= TRUE;
END_IF
IF (REAL_TO_UINT(REAL_VARIABLE) MOD 16) >= 8 THEN
DO_CAP_CAMERA_PROG_BIT3:= TRUE;
END_IF
IF (REAL_TO_UINT(REAL_VARIABLE) MOD 32) >= 16 THEN
DO_CAP_CAMERA_PROG_BIT4:= TRUE;
END_IF