-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathasa.environment.targettemperature.json
More file actions
99 lines (99 loc) · 2.87 KB
/
asa.environment.targettemperature.json
File metadata and controls
99 lines (99 loc) · 2.87 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
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
91
92
93
94
95
96
97
98
99
{
"id": "http://openinterconnect.org/asamapping/schemas/asa.environment.targettemperature.json#",
"$schema": "http://json-schema.org/draft-04/schema#",
"description" : "Copyright (c) 2017 Open Connectivity Foundation, Inc. All rights reserved.",
"title": "Target Temperature",
"definitions": {
"asa.environment.targettemperature": {
"type": "object",
"properties": {
"targetvalue": {
"type": "number",
"description": "Measured value",
"x-ocf-conversion": {
"x-ocf-alias": "oic.r.temperature",
"x-to-ocf": [
"temperature = targetvalue",
"units = C"
],
"x-from-ocf": {
"oneOf": [
{
"properties": {
"units": "string",
"enum": ["C"]
},
"x-from-ocf": [
"targetvalue = temperature"
]
},
{
"properties": {
"units": "string",
"enum": ["F"]
},
"x-from-ocf": [
"targetvalue = (temperature-32)*5/9"
]
},
{
"properties": {
"units": "string",
"enum": ["K"]
},
"x-from-ocf": [
"targetvalue = temperature-273.15"
]
}
]
}
}
},
"minvalue": {
"type": "number",
"x-ocf-conversion": {
"x-ocf-alias": "oic.r.temperature",
"x-to-ocf": [
"range[0] = minvalue"
],
"x-from-ocf": [
"minvalue = range[0]",
"otherwise: minvalue = -MAXINT"
]
}
},
"maxvalue": {
"type": "number",
"x-ocf-conversion": {
"x-ocf-alias": "oic.r.temperature",
"x-to-ocf": [
"range[1] = maxvalue"
],
"x-from-ocf": [
"maxvalue = range[1]",
"otherwise: maxvalue = MAXINT"
]
}
},
"step": {
"type": "number",
"x-ocf-conversion": {
"x-ocf-alias": "oic.r.temperature",
"x-to-ocf": [
"ocf.step = step"
],
"x-from-ocf": [
"step = ocf.step",
"otherwise: step = undefined (0x00)"
]
}
}
}
}
},
"type": "object",
"allOf": [
{"$ref": "#/definitions/asa.environment.targettemperature"}
],
"required": [ "targetvalue","minvalue","maxvalue","step" ]
}