DVP-15MC Series Motion Controller Operation Manual
8-338
Function Explanation
The SetBitOffsetValue instruction is used to set the value of the specific bit of the specified address to TRUE
or FALSE. The StartRegister parameter is a Pointer-type variable. The Offset parameter specifies the offset
value which regards the bit0 of the variable the StartRegister parameter points to as the reference. The Value
parameter shows the setting value of the specified bit, which is TRUE or FALSE. The bit which is specified
by StartRegister and Offset together can be set to TRUE or FALSE through this instruction.
If the specified offset value exceeds the range of the starting address of StartRegister, the operation will be
performed according to the corresponding offset address which regards the StartRegister as the starting
address.
See more in the following example.
Precautions for Correct Use
The StartRegister parameter of the SetBitOffsetValue instruction is a Pointer-type variable and needs to
use the ADR instruction to gain the address.
Programming Example
The variable table and program
SetBitOffsetValue
StartRegister
Offset
Value
EN ENO
SetBOV_Value
SetBOV_En
SetBOV_Offset
ADR(SetBOV_StartR)
Program Explanation
When the SetBOV_EN variable is TRUE, set the value of the specified bit to the value of SetBOV_Value
by changing the values of SetBOV_Offset and SetBOV_Value variables.
See the explanation below.
1. When SetBOV _Value is set to FALSE and the value of SetBOV _Offset is 2, the value of Bit2
of SetBOV _StartR(%MW0)is FALSE.
2. When SetBOV _Value is set to TRUE and the value of SetBOV _Offset is 2, the value of Bit2
of SetBOV _StartR(%MW0)is TRUE.
3. When SetBOV _Value is set to FALSE and the value of SetBOV _Offset is 16 (which regards
Bit0 of the variable that StartRegister points to as the reference bit ), the value of Bit1 of
%MW1 is FALSE.
4. When SetBOV _Value is set to TRUE and the value of SetBOV _Offset is 16 (which regards
Bit0 of the variable that StartRegister points to as the reference bit ), the value of Bit1 of
%MW1 is TRUE.