点击或拖拽改变大小

SoftBasicByteToBoolArray 方法 (Byte, Int32, Byte)

从Byte数组中提取位数组,length代表位数,例如数组 01 00 长度10转为 [true,false]

命名空间:  HslCommunication.BasicFramework
程序集:  HslCommunication (在 HslCommunication.dll 中) 版本:12.0.0.0 (12.0.0.0)
语法
public static bool[] ByteToBoolArray(
	byte[] inBytes,
	int length,
	byte trueValue
)

参数

inBytes
类型:SystemByte
原先的字节数组
length
类型:SystemInt32
想要转换的长度,如果超出自动会缩小到数组最大长度
trueValue
类型:SystemByte
当为true时对应的byte值

返回值

类型:Boolean
转换后bool数组
参见