-
Notifications
You must be signed in to change notification settings - Fork 5
Expand file tree
/
Copy pathdevice.yml
More file actions
62 lines (62 loc) · 1.68 KB
/
device.yml
File metadata and controls
62 lines (62 loc) · 1.68 KB
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
%YAML 1.1
---
# yaml-language-server: $schema=https://raw.githubusercontent.com/harp-tech/reflex-generator/main/schema/device.json
device: device
whoAmI: 0000
firmwareVersion: "0.1"
hardwareTargets: "0.1"
registers:
DigitalInputState:
address: 32
access: Event
type: U8
maskType: DigitalInputs
description: Reports the state of the digital input lines.
DigitalInputMode:
address: 33
access: Write
type: U8
maskType: DigitalInputs
description: Reports the state of the digital input lines.
AnalogData:
address: 44
type: S16
length: 3
access: Event
description: Reports the current values of the analog input lines.
AnalogDataPayloadSpec:
address: 44
type: S16
length: 3
access: Event
description: Reports the current values of the analog input lines.
payloadSpec:
AnalogInput0:
offset: 0
description: The voltage at the output of the ADC channel 0.
Encoder:
offset: 1
description: The quadrature counter value on Port 2
AnalogInput1:
offset: 2
description: The voltage at the output of the ADC channel 1.
bitMasks:
DigitalInputs:
description: Specifies the state of the digital input lines.
bits:
DI0: 0x1
DI1: 0x2
DI2: 0x4
DI3: 0x8
StateFlowStyle:
description: Specifies the state of the digital input lines.
bits:
Enabled: {value: 0x0, description: The state is False}
Disabled: {value: 0x1, description: The state is True}
groupMasks:
InputMode:
description: Specifies when the device reports the state of digital input lines.
values:
Rising: 0
Falling: 1
Both: 2