GeSRTPNetReadBoolAsync 方法 (String, UInt16) |
按照位为单位,批量从指定的地址里读取 bool 数组数据,不支持 AI,AQ,R 地址类型,地址比如从1开始,例如 I1,Q1,M1,T1,SA1,SB1,SC1,S1,G1
In units of bits, read bool array data from the specified address in batches. AI, AQ,
R address types are not supported. For example, the address starts from 1, such as I1, Q1, M1, T1, SA1, SB1, SC1, S1, G1
命名空间:
HslCommunication.Profinet.GE
程序集:
HslCommunication (在 HslCommunication.dll 中) 版本:12.1.2.0 (12.1.2.0)
语法 public override Task<OperateResult<bool[]>> ReadBoolAsync(
string address,
ushort length
)
Public Overrides Function ReadBoolAsync (
address As String,
length As UShort
) As Task(Of OperateResult(Of Boolean()))
public:
virtual Task<OperateResult<array<bool>^>^>^ ReadBoolAsync(
String^ address,
unsigned short length
) override
abstract ReadBoolAsync :
address : string *
length : uint16 -> Task<OperateResult<bool[]>>
override ReadBoolAsync :
address : string *
length : uint16 -> Task<OperateResult<bool[]>>
参数
- address
- 类型:SystemString
PLC的地址信息,例如 M1, G1 - length
- 类型:SystemUInt16
读取的长度信息,按照位为单位
返回值
类型:
TaskOperateResultBoolean包含是否读取成功的bool数组
实现
IReadWriteNetReadBoolAsync(String, UInt16)参见