-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathBack8.cs
90 lines (85 loc) · 1.73 KB
/
Back8.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace comTest
{
public class Back8 : Back
{
public byte[] DataBytes { get; set; }
public override int Length
{
get
{
return 31;
}
}
public byte codeId
{
get
{
return DataBytes[0];
}
}
//频段号
public byte 频段号
{
get
{
return DataBytes[1];
}
}
//体重传感器数值
public float 体重
{
get
{
return BitConverter.ToSingle(DataBytes, 2);
}
}
//通道类型,未使用 1
//通道1系统
public float 阻抗1
{
get
{
return BitConverter.ToSingle(DataBytes, 7);
}
}
public float 阻抗2
{
get
{
return BitConverter.ToSingle(DataBytes, 11);
}
}
public float 阻抗3
{
get
{
return BitConverter.ToSingle(DataBytes, 15);
}
}
public float 阻抗4
{
get
{
return BitConverter.ToSingle(DataBytes, 19);
}
}
public float 阻抗5
{
get
{
return BitConverter.ToSingle(DataBytes, 23);
}
}
public float 阻抗6
{
get
{
return BitConverter.ToSingle(DataBytes, 27);
}
}
}
}