forked from kubeedge/mappers-go
-
Notifications
You must be signed in to change notification settings - Fork 0
/
modbusrtu-device-instance.yaml
60 lines (60 loc) · 1.25 KB
/
modbusrtu-device-instance.yaml
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
apiVersion: devices.kubeedge.io/v1alpha2
kind: Device
metadata:
name: modbusrtu-device
labels:
description: TISimplelinkSensorTag
manufacturer: TexasInstruments
model: CC2650
spec:
deviceModelRef:
name: modbus-sample-model
protocol:
modbus:
slaveID: 1
common:
com:
serialPort: '/dev/ttyS0'
baudRate: 9600
dataBits: 8
parity: even
stopBits: 1
customizedValues:
serialType: "RS232"
nodeSelector:
nodeSelectorTerms:
- matchExpressions:
- key: ''
operator: In
values:
- test
propertyVisitors:
- propertyName: temperature
modbus:
register: CoilRegister
offset: 2
limit: 1
scale: 1
isSwap: true
isRegisterSwap: true
- propertyName: temperature-enable
modbus:
register: CoilRegister
offset: 3
limit: 1
scale: 1.0
isSwap: true
isRegisterSwap: true
status:
twins:
- propertyName: temperature-enable
reported:
metadata:
timestamp: '1550049403598'
type: integer
value: "1"
desired:
metadata:
timestamp: '1550049403598'
type: integer
value: "1"