rsmp 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/rsmp/version.rb +1 -1
- data/lib/rsmp_schema/schema/core/aggregated_status.json +25 -0
- data/lib/rsmp_schema/schema/core/alarm.json +55 -0
- data/lib/rsmp_schema/schema/core/command_request.json +24 -0
- data/lib/rsmp_schema/schema/core/command_response.json +34 -0
- data/lib/rsmp_schema/schema/core/core.json +35 -0
- data/lib/rsmp_schema/schema/core/definitions.json +47 -0
- data/lib/rsmp_schema/schema/core/message_ack.json +11 -0
- data/lib/rsmp_schema/schema/core/message_not_ack.json +15 -0
- data/lib/rsmp_schema/schema/core/rsmp.json +124 -0
- data/lib/rsmp_schema/schema/core/status.json +21 -0
- data/lib/rsmp_schema/schema/core/status_request.json +5 -0
- data/lib/rsmp_schema/schema/core/status_response.json +30 -0
- data/lib/rsmp_schema/schema/core/status_subscribe.json +27 -0
- data/lib/rsmp_schema/schema/core/status_unsubscribe.json +5 -0
- data/lib/rsmp_schema/schema/core/status_update.json +30 -0
- data/lib/rsmp_schema/schema/core/version.json +47 -0
- data/lib/rsmp_schema/schema/core/watchdog.json +9 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0001.json +7 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0002.json +7 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0003.json +7 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0004.json +7 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0005.json +7 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0006.json +7 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0007.json +7 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0008.json +19 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0009.json +7 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0101.json +7 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0201.json +20 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0202.json +20 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0301.json +48 -0
- data/lib/rsmp_schema/schema/tlc/alarms/A0302.json +58 -0
- data/lib/rsmp_schema/schema/tlc/alarms/alarms.json +68 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0001.json +48 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0002.json +38 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0003.json +38 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0004.json +29 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0005.json +38 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0006.json +38 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0007.json +29 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0008.json +38 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0010.json +29 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0011.json +29 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0012.json +29 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0013.json +29 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0014.json +38 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0015.json +38 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0016.json +29 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0017.json +29 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0018.json +38 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0019.json +47 -0
- data/lib/rsmp_schema/schema/tlc/commands/M0103.json +39 -0
- data/lib/rsmp_schema/schema/tlc/commands/command_requests.json +7 -0
- data/lib/rsmp_schema/schema/tlc/commands/command_responses.json +7 -0
- data/lib/rsmp_schema/schema/tlc/commands/commands.json +85 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0001.json +44 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0002.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0003.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0004.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0005.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0006.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0007.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0008.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0009.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0010.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0011.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0012.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0013.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0014.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0015.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0016.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0017.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0018.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0019.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0020.json +27 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0021.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0022.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0023.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0024.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0025.json +80 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0026.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0027.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0028.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0029.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0091.json +28 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0092.json +28 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0095.json +17 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0096.json +62 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0201.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0202.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0203.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0204.json +98 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0205.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0206.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0207.json +26 -0
- data/lib/rsmp_schema/schema/tlc/statuses/S0208.json +98 -0
- data/lib/rsmp_schema/schema/tlc/statuses/statuses.json +177 -0
- data/lib/rsmp_schema/schema/tlc/sxl.json +24 -0
- data/rsmp.gemspec +13 -0
- metadata +98 -1
@@ -0,0 +1,26 @@
|
|
1
|
+
{
|
2
|
+
"allOf" : [
|
3
|
+
{ "properties" : {
|
4
|
+
"description": "Traffic Counting: Vehicle speed",
|
5
|
+
"n" : { "enum" : ["starttime", "speed"] }
|
6
|
+
}},
|
7
|
+
{
|
8
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "starttime" }}},
|
9
|
+
"then" : { "properties" : {
|
10
|
+
"v" : {
|
11
|
+
"$description": "Time stamp for start of measuring. Format according to W3C XML dateTime with a resolution of 3 decimal places. All time stamps in UTC. E.g. 2009-10-02T14:34:34.341Z",
|
12
|
+
"type" : "string"
|
13
|
+
}
|
14
|
+
}}
|
15
|
+
},
|
16
|
+
{
|
17
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "speed" }}},
|
18
|
+
"then" : { "properties" : {
|
19
|
+
"v" : {
|
20
|
+
"$description": "Average speed in km/h (integer)",
|
21
|
+
"$ref": "../../core/definitions.json#/integer"
|
22
|
+
}
|
23
|
+
}}
|
24
|
+
}
|
25
|
+
]
|
26
|
+
}
|
@@ -0,0 +1,26 @@
|
|
1
|
+
{
|
2
|
+
"allOf" : [
|
3
|
+
{ "properties" : {
|
4
|
+
"description": "Traffic Counting: Occupancy",
|
5
|
+
"n" : { "enum" : ["starttime", "occupancy"] }
|
6
|
+
}},
|
7
|
+
{
|
8
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "starttime" }}},
|
9
|
+
"then" : { "properties" : {
|
10
|
+
"v" : {
|
11
|
+
"$description": "Time stamp for start of measuring. Format according to W3C XML dateTime with a resolution of 3 decimal places. All time stamps in UTC. E.g. 2009-10-02T14:34:34.341Z",
|
12
|
+
"type" : "string"
|
13
|
+
}
|
14
|
+
}}
|
15
|
+
},
|
16
|
+
{
|
17
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "occupancy" }}},
|
18
|
+
"then" : { "properties" : {
|
19
|
+
"v" : {
|
20
|
+
"$description": "Occupancy in percent (0-100%) (integer)",
|
21
|
+
"$ref": "../../core/definitions.json#/integer"
|
22
|
+
}
|
23
|
+
}}
|
24
|
+
}
|
25
|
+
]
|
26
|
+
}
|
@@ -0,0 +1,98 @@
|
|
1
|
+
{
|
2
|
+
"allOf" : [
|
3
|
+
{ "properties" : {
|
4
|
+
"description": "Traffic Counting: Number of vehicles of given classification",
|
5
|
+
"n" : { "enum" : ["starttime", "P", "PS", "L", "LS", "B", "SP", "MC", "C", "F"] }
|
6
|
+
}},
|
7
|
+
{
|
8
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "starttime" }}},
|
9
|
+
"then" : { "properties" : {
|
10
|
+
"v" : {
|
11
|
+
"$description": "Time stamp for start of measuring. Format according to W3C XML dateTime with a resolution of 3 decimal places. All time stamps in UTC. E.g. 2009-10-02T14:34:34.341Z",
|
12
|
+
"type" : "string"
|
13
|
+
}
|
14
|
+
}}
|
15
|
+
},
|
16
|
+
{
|
17
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "P" }}},
|
18
|
+
"then" : { "properties" : {
|
19
|
+
"v" : {
|
20
|
+
"$description": "Number of cars",
|
21
|
+
"$ref": "../../core/definitions.json#/integer"
|
22
|
+
}
|
23
|
+
}}
|
24
|
+
},
|
25
|
+
{
|
26
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "PS" }}},
|
27
|
+
"then" : { "properties" : {
|
28
|
+
"v" : {
|
29
|
+
"$description": "Number of cars with trailers",
|
30
|
+
"$ref": "../../core/definitions.json#/integer"
|
31
|
+
}
|
32
|
+
}}
|
33
|
+
},
|
34
|
+
{
|
35
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "L" }}},
|
36
|
+
"then" : { "properties" : {
|
37
|
+
"v" : {
|
38
|
+
"$description": "Number of trucks",
|
39
|
+
"$ref": "../../core/definitions.json#/integer"
|
40
|
+
}
|
41
|
+
}}
|
42
|
+
},
|
43
|
+
{
|
44
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "LS" }}},
|
45
|
+
"then" : { "properties" : {
|
46
|
+
"v" : {
|
47
|
+
"$description": "Number of trucks with trailers",
|
48
|
+
"$ref": "../../core/definitions.json#/integer"
|
49
|
+
}
|
50
|
+
}}
|
51
|
+
},
|
52
|
+
{
|
53
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "B" }}},
|
54
|
+
"then" : { "properties" : {
|
55
|
+
"v" : {
|
56
|
+
"$description": "Number of busses",
|
57
|
+
"$ref": "../../core/definitions.json#/integer"
|
58
|
+
}
|
59
|
+
}}
|
60
|
+
},
|
61
|
+
{
|
62
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "SP" }}},
|
63
|
+
"then" : { "properties" : {
|
64
|
+
"v" : {
|
65
|
+
"$description": "Number of trams",
|
66
|
+
"$ref": "../../core/definitions.json#/integer"
|
67
|
+
}
|
68
|
+
}}
|
69
|
+
},
|
70
|
+
{
|
71
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "MC" }}},
|
72
|
+
"then" : { "properties" : {
|
73
|
+
"v" : {
|
74
|
+
"$description": "Number of motor cycles",
|
75
|
+
"$ref": "../../core/definitions.json#/integer"
|
76
|
+
}
|
77
|
+
}}
|
78
|
+
},
|
79
|
+
{
|
80
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "C" }}},
|
81
|
+
"then" : { "properties" : {
|
82
|
+
"v" : {
|
83
|
+
"$description": "Number of bicycles",
|
84
|
+
"$ref": "../../core/definitions.json#/integer"
|
85
|
+
}
|
86
|
+
}}
|
87
|
+
},
|
88
|
+
{
|
89
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "F" }}},
|
90
|
+
"then" : { "properties" : {
|
91
|
+
"v" : {
|
92
|
+
"$description": "Number of pedestrians",
|
93
|
+
"$ref": "../../core/definitions.json#/integer"
|
94
|
+
}
|
95
|
+
}}
|
96
|
+
}
|
97
|
+
]
|
98
|
+
}
|
@@ -0,0 +1,26 @@
|
|
1
|
+
{
|
2
|
+
"allOf" : [
|
3
|
+
{ "properties" : {
|
4
|
+
"description": "Traffic Counting: Number of vehicles",
|
5
|
+
"n" : { "enum" : ["start", "vehicles"] }
|
6
|
+
}},
|
7
|
+
{
|
8
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "start" }}},
|
9
|
+
"then" : { "properties" : {
|
10
|
+
"v" : {
|
11
|
+
"$description": "Time stamp for start of measuring. Format according to W3C XML dateTime with a resolution of 3 decimal places. All time stamps in UTC. E.g. 2009-10-02T14:34:34.341Z",
|
12
|
+
"type" : "string"
|
13
|
+
}
|
14
|
+
}}
|
15
|
+
},
|
16
|
+
{
|
17
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "vehicles" }}},
|
18
|
+
"then" : { "properties" : {
|
19
|
+
"v" : {
|
20
|
+
"$description": "Number of vehicles<br> Value expressed as an integer with a range of 0-65535.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
21
|
+
"type" : "string"
|
22
|
+
}
|
23
|
+
}}
|
24
|
+
}
|
25
|
+
]
|
26
|
+
}
|
@@ -0,0 +1,26 @@
|
|
1
|
+
{
|
2
|
+
"allOf" : [
|
3
|
+
{ "properties" : {
|
4
|
+
"description": "Traffic Counting: Vehicle speed",
|
5
|
+
"n" : { "enum" : ["start", "speed"] }
|
6
|
+
}},
|
7
|
+
{
|
8
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "start" }}},
|
9
|
+
"then" : { "properties" : {
|
10
|
+
"v" : {
|
11
|
+
"$description": "Time stamp for start of measuring. Format according to W3C XML dateTime with a resolution of 3 decimal places. All time stamps in UTC. E.g. 2009-10-02T14:34:34.341Z",
|
12
|
+
"type" : "string"
|
13
|
+
}
|
14
|
+
}}
|
15
|
+
},
|
16
|
+
{
|
17
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "speed" }}},
|
18
|
+
"then" : { "properties" : {
|
19
|
+
"v" : {
|
20
|
+
"$description": "Average speed in km/h (integer)<br> Value expressed as an integer with a range of 0-65535.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
21
|
+
"type" : "string"
|
22
|
+
}
|
23
|
+
}}
|
24
|
+
}
|
25
|
+
]
|
26
|
+
}
|
@@ -0,0 +1,26 @@
|
|
1
|
+
{
|
2
|
+
"allOf" : [
|
3
|
+
{ "properties" : {
|
4
|
+
"description": "Traffic Counting: Occupancy",
|
5
|
+
"n" : { "enum" : ["start", "occupancy"] }
|
6
|
+
}},
|
7
|
+
{
|
8
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "start" }}},
|
9
|
+
"then" : { "properties" : {
|
10
|
+
"v" : {
|
11
|
+
"$description": "Time stamp for start of measuring. Format according to W3C XML dateTime with a resolution of 3 decimal places. All time stamps in UTC. E.g. 2009-10-02T14:34:34.341Z",
|
12
|
+
"type" : "string"
|
13
|
+
}
|
14
|
+
}}
|
15
|
+
},
|
16
|
+
{
|
17
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "occupancy" }}},
|
18
|
+
"then" : { "properties" : {
|
19
|
+
"v" : {
|
20
|
+
"$description": "Occupancy in percent (%) (0-100)<br> Value expressed as an integer with a range of 0-100.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
21
|
+
"type" : "string"
|
22
|
+
}
|
23
|
+
}}
|
24
|
+
}
|
25
|
+
]
|
26
|
+
}
|
@@ -0,0 +1,98 @@
|
|
1
|
+
{
|
2
|
+
"allOf" : [
|
3
|
+
{ "properties" : {
|
4
|
+
"description": "Traffic Counting: Number of vehicles of given classification",
|
5
|
+
"n" : { "enum" : ["start", "P", "PS", "L", "LS", "B", "SP", "MC", "C", "F"] }
|
6
|
+
}},
|
7
|
+
{
|
8
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "start" }}},
|
9
|
+
"then" : { "properties" : {
|
10
|
+
"v" : {
|
11
|
+
"$description": "Time stamp for start of measuring. Format according to W3C XML dateTime with a resolution of 3 decimal places. All time stamps in UTC. E.g. 2009-10-02T14:34:34.341Z",
|
12
|
+
"type" : "string"
|
13
|
+
}
|
14
|
+
}}
|
15
|
+
},
|
16
|
+
{
|
17
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "P" }}},
|
18
|
+
"then" : { "properties" : {
|
19
|
+
"v" : {
|
20
|
+
"$description": "Number of cars<br> Value expressed as an integer with a range of 0-65535.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
21
|
+
"type" : "string"
|
22
|
+
}
|
23
|
+
}}
|
24
|
+
},
|
25
|
+
{
|
26
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "PS" }}},
|
27
|
+
"then" : { "properties" : {
|
28
|
+
"v" : {
|
29
|
+
"$description": "Number of cars with trailers<br> Value expressed as an integer with a range of 0-65535.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
30
|
+
"type" : "string"
|
31
|
+
}
|
32
|
+
}}
|
33
|
+
},
|
34
|
+
{
|
35
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "L" }}},
|
36
|
+
"then" : { "properties" : {
|
37
|
+
"v" : {
|
38
|
+
"$description": "Number of trucks<br> Value expressed as an integer with a range of 0-65535.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
39
|
+
"type" : "string"
|
40
|
+
}
|
41
|
+
}}
|
42
|
+
},
|
43
|
+
{
|
44
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "LS" }}},
|
45
|
+
"then" : { "properties" : {
|
46
|
+
"v" : {
|
47
|
+
"$description": "Number of trucks with trailers<br> Value expressed as an integer with a range of 0-65535.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
48
|
+
"type" : "string"
|
49
|
+
}
|
50
|
+
}}
|
51
|
+
},
|
52
|
+
{
|
53
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "B" }}},
|
54
|
+
"then" : { "properties" : {
|
55
|
+
"v" : {
|
56
|
+
"$description": "Number of busses<br> Value expressed as an integer with a range of 0-65535.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
57
|
+
"type" : "string"
|
58
|
+
}
|
59
|
+
}}
|
60
|
+
},
|
61
|
+
{
|
62
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "SP" }}},
|
63
|
+
"then" : { "properties" : {
|
64
|
+
"v" : {
|
65
|
+
"$description": "Number of trams<br> Value expressed as an integer with a range of 0-65535.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
66
|
+
"type" : "string"
|
67
|
+
}
|
68
|
+
}}
|
69
|
+
},
|
70
|
+
{
|
71
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "MC" }}},
|
72
|
+
"then" : { "properties" : {
|
73
|
+
"v" : {
|
74
|
+
"$description": "Number of motor cycles<br> Value expressed as an integer with a range of 0-65535.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
75
|
+
"type" : "string"
|
76
|
+
}
|
77
|
+
}}
|
78
|
+
},
|
79
|
+
{
|
80
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "C" }}},
|
81
|
+
"then" : { "properties" : {
|
82
|
+
"v" : {
|
83
|
+
"$description": "Number of bicycles<br> Value expressed as an integer with a range of 0-65535.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
84
|
+
"type" : "string"
|
85
|
+
}
|
86
|
+
}}
|
87
|
+
},
|
88
|
+
{
|
89
|
+
"if" : { "required" : ["n"], "properties" : { "n" : { "const" : "F" }}},
|
90
|
+
"then" : { "properties" : {
|
91
|
+
"v" : {
|
92
|
+
"$description": "Number of pedestrians<br> Value expressed as an integer with a range of 0-65535.<br> Contains data from all detector logics. Each detector logic is separated with a colon. <br> The value is set to “-1” if no data could be measured (e.g. detector fault)<br>",
|
93
|
+
"type" : "string"
|
94
|
+
}
|
95
|
+
}}
|
96
|
+
}
|
97
|
+
]
|
98
|
+
}
|
@@ -0,0 +1,177 @@
|
|
1
|
+
{
|
2
|
+
"properties" : {
|
3
|
+
"sS" : {
|
4
|
+
"items" : {
|
5
|
+
"allOf" : [
|
6
|
+
{
|
7
|
+
"properties": { "sCI" : { "enum": ["S0001", "S0002", "S0003", "S0004", "S0005", "S0006", "S0007", "S0008", "S0009", "S0010", "S0011", "S0012", "S0013", "S0014", "S0015", "S0016", "S0017", "S0018", "S0019", "S0020", "S0021", "S0022", "S0023", "S0024", "S0025", "S0026", "S0027", "S0028", "S0029", "S0091", "S0092", "S0095", "S0096", "S0201", "S0202", "S0203", "S0204", "S0205", "S0206", "S0207", "S0208"] }}
|
8
|
+
},
|
9
|
+
{
|
10
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0001" }}},
|
11
|
+
"then" : { "$ref" : "S0001.json" }
|
12
|
+
},
|
13
|
+
{
|
14
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0002" }}},
|
15
|
+
"then" : { "$ref" : "S0002.json" }
|
16
|
+
},
|
17
|
+
{
|
18
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0003" }}},
|
19
|
+
"then" : { "$ref" : "S0003.json" }
|
20
|
+
},
|
21
|
+
{
|
22
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0004" }}},
|
23
|
+
"then" : { "$ref" : "S0004.json" }
|
24
|
+
},
|
25
|
+
{
|
26
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0005" }}},
|
27
|
+
"then" : { "$ref" : "S0005.json" }
|
28
|
+
},
|
29
|
+
{
|
30
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0006" }}},
|
31
|
+
"then" : { "$ref" : "S0006.json" }
|
32
|
+
},
|
33
|
+
{
|
34
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0007" }}},
|
35
|
+
"then" : { "$ref" : "S0007.json" }
|
36
|
+
},
|
37
|
+
{
|
38
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0008" }}},
|
39
|
+
"then" : { "$ref" : "S0008.json" }
|
40
|
+
},
|
41
|
+
{
|
42
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0009" }}},
|
43
|
+
"then" : { "$ref" : "S0009.json" }
|
44
|
+
},
|
45
|
+
{
|
46
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0010" }}},
|
47
|
+
"then" : { "$ref" : "S0010.json" }
|
48
|
+
},
|
49
|
+
{
|
50
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0011" }}},
|
51
|
+
"then" : { "$ref" : "S0011.json" }
|
52
|
+
},
|
53
|
+
{
|
54
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0012" }}},
|
55
|
+
"then" : { "$ref" : "S0012.json" }
|
56
|
+
},
|
57
|
+
{
|
58
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0013" }}},
|
59
|
+
"then" : { "$ref" : "S0013.json" }
|
60
|
+
},
|
61
|
+
{
|
62
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0014" }}},
|
63
|
+
"then" : { "$ref" : "S0014.json" }
|
64
|
+
},
|
65
|
+
{
|
66
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0015" }}},
|
67
|
+
"then" : { "$ref" : "S0015.json" }
|
68
|
+
},
|
69
|
+
{
|
70
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0016" }}},
|
71
|
+
"then" : { "$ref" : "S0016.json" }
|
72
|
+
},
|
73
|
+
{
|
74
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0017" }}},
|
75
|
+
"then" : { "$ref" : "S0017.json" }
|
76
|
+
},
|
77
|
+
{
|
78
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0018" }}},
|
79
|
+
"then" : { "$ref" : "S0018.json" }
|
80
|
+
},
|
81
|
+
{
|
82
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0019" }}},
|
83
|
+
"then" : { "$ref" : "S0019.json" }
|
84
|
+
},
|
85
|
+
{
|
86
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0020" }}},
|
87
|
+
"then" : { "$ref" : "S0020.json" }
|
88
|
+
},
|
89
|
+
{
|
90
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0021" }}},
|
91
|
+
"then" : { "$ref" : "S0021.json" }
|
92
|
+
},
|
93
|
+
{
|
94
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0022" }}},
|
95
|
+
"then" : { "$ref" : "S0022.json" }
|
96
|
+
},
|
97
|
+
{
|
98
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0023" }}},
|
99
|
+
"then" : { "$ref" : "S0023.json" }
|
100
|
+
},
|
101
|
+
{
|
102
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0024" }}},
|
103
|
+
"then" : { "$ref" : "S0024.json" }
|
104
|
+
},
|
105
|
+
{
|
106
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0025" }}},
|
107
|
+
"then" : { "$ref" : "S0025.json" }
|
108
|
+
},
|
109
|
+
{
|
110
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0026" }}},
|
111
|
+
"then" : { "$ref" : "S0026.json" }
|
112
|
+
},
|
113
|
+
{
|
114
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0027" }}},
|
115
|
+
"then" : { "$ref" : "S0027.json" }
|
116
|
+
},
|
117
|
+
{
|
118
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0028" }}},
|
119
|
+
"then" : { "$ref" : "S0028.json" }
|
120
|
+
},
|
121
|
+
{
|
122
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0029" }}},
|
123
|
+
"then" : { "$ref" : "S0029.json" }
|
124
|
+
},
|
125
|
+
{
|
126
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0091" }}},
|
127
|
+
"then" : { "$ref" : "S0091.json" }
|
128
|
+
},
|
129
|
+
{
|
130
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0092" }}},
|
131
|
+
"then" : { "$ref" : "S0092.json" }
|
132
|
+
},
|
133
|
+
{
|
134
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0095" }}},
|
135
|
+
"then" : { "$ref" : "S0095.json" }
|
136
|
+
},
|
137
|
+
{
|
138
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0096" }}},
|
139
|
+
"then" : { "$ref" : "S0096.json" }
|
140
|
+
},
|
141
|
+
{
|
142
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0201" }}},
|
143
|
+
"then" : { "$ref" : "S0201.json" }
|
144
|
+
},
|
145
|
+
{
|
146
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0202" }}},
|
147
|
+
"then" : { "$ref" : "S0202.json" }
|
148
|
+
},
|
149
|
+
{
|
150
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0203" }}},
|
151
|
+
"then" : { "$ref" : "S0203.json" }
|
152
|
+
},
|
153
|
+
{
|
154
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0204" }}},
|
155
|
+
"then" : { "$ref" : "S0204.json" }
|
156
|
+
},
|
157
|
+
{
|
158
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0205" }}},
|
159
|
+
"then" : { "$ref" : "S0205.json" }
|
160
|
+
},
|
161
|
+
{
|
162
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0206" }}},
|
163
|
+
"then" : { "$ref" : "S0206.json" }
|
164
|
+
},
|
165
|
+
{
|
166
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0207" }}},
|
167
|
+
"then" : { "$ref" : "S0207.json" }
|
168
|
+
},
|
169
|
+
{
|
170
|
+
"if": { "required" : ["sCI"], "properties" : { "sCI": { "const": "S0208" }}},
|
171
|
+
"then" : { "$ref" : "S0208.json" }
|
172
|
+
}
|
173
|
+
]
|
174
|
+
}
|
175
|
+
}
|
176
|
+
}
|
177
|
+
}
|
@@ -0,0 +1,24 @@
|
|
1
|
+
{
|
2
|
+
"description": "A schema validatating message against the RSMP SXL for Traffic Light Controllers",
|
3
|
+
"allOf" : [
|
4
|
+
{
|
5
|
+
"$ref": "../core/rsmp.json"
|
6
|
+
},
|
7
|
+
{
|
8
|
+
"if" : { "required" : ["type"], "properties" : { "type" : { "const" : "CommandRequest" }}},
|
9
|
+
"then" : { "$ref" : "commands/command_requests.json" }
|
10
|
+
},
|
11
|
+
{
|
12
|
+
"if" : { "required" : ["type"], "properties" : { "type" : { "const" : "CommandResponse" }}},
|
13
|
+
"then" : { "$ref" : "commands/command_responses.json" }
|
14
|
+
},
|
15
|
+
{
|
16
|
+
"if" : { "required" : ["type"], "properties" : { "type" : { "enum" : ["StatusRequest","StatusResponse","StatusSubscribe","StatusUnsubscribe","StatusUpdate"] }}},
|
17
|
+
"then" : { "$ref" : "statuses/statuses.json" }
|
18
|
+
},
|
19
|
+
{
|
20
|
+
"if" : { "required" : ["type"], "properties" : { "type" : { "const" : "Alarm" }}},
|
21
|
+
"then" : { "$ref" : "alarms/alarms.json" }
|
22
|
+
}
|
23
|
+
]
|
24
|
+
}
|
data/rsmp.gemspec
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
lib = File.expand_path("lib", __dir__)
|
2
2
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
3
3
|
require "rsmp/version"
|
4
|
+
require 'pathname'
|
4
5
|
|
5
6
|
Gem::Specification.new do |spec|
|
6
7
|
spec.name = "rsmp"
|
@@ -22,6 +23,18 @@ Gem::Specification.new do |spec|
|
|
22
23
|
spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
|
23
24
|
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
24
25
|
end
|
26
|
+
|
27
|
+
# Add schema files in rsmp_schema submodule
|
28
|
+
gem_dir = Pathname.new(__dir__).expand_path
|
29
|
+
submodule_path = File.expand_path 'lib/rsmp_schema/schema'
|
30
|
+
Dir.chdir(submodule_path) do
|
31
|
+
submodule_relative_path = Pathname.new(submodule_path).relative_path_from(gem_dir)
|
32
|
+
`git ls-files`.split($\).each do |filename|
|
33
|
+
# for each git file, prepend relative submodule path and add to spec
|
34
|
+
spec.files << submodule_relative_path.join(filename).to_s
|
35
|
+
end
|
36
|
+
end
|
37
|
+
|
25
38
|
spec.bindir = "exe"
|
26
39
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
27
40
|
spec.require_paths = ["lib"]
|