@fa_yoshinobu/node-red-contrib-plc-comm-slmp 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,185 @@
1
+ [
2
+ {
3
+ "id": "tab-slmp-array-string",
4
+ "type": "tab",
5
+ "label": "SLMP Array And String",
6
+ "disabled": false,
7
+ "info": "Update the connection host, port, and safe array/string addresses before deploy."
8
+ },
9
+ {
10
+ "id": "comment-slmp-array-string",
11
+ "type": "comment",
12
+ "z": "tab-slmp-array-string",
13
+ "name": "TCP array and string examples using ,count and DSTR",
14
+ "info": "",
15
+ "x": 270,
16
+ "y": 40,
17
+ "wires": []
18
+ },
19
+ {
20
+ "id": "inject-array-read",
21
+ "type": "inject",
22
+ "z": "tab-slmp-array-string",
23
+ "name": "Read array + string",
24
+ "props": [
25
+ {
26
+ "p": "payload"
27
+ }
28
+ ],
29
+ "repeat": "",
30
+ "crontab": "",
31
+ "once": false,
32
+ "onceDelay": 0.1,
33
+ "topic": "",
34
+ "payloadType": "date",
35
+ "x": 120,
36
+ "y": 120,
37
+ "wires": [
38
+ [
39
+ "read-array-string"
40
+ ]
41
+ ]
42
+ },
43
+ {
44
+ "id": "read-array-string",
45
+ "type": "slmp-read",
46
+ "z": "tab-slmp-array-string",
47
+ "name": "Read array + float array + string",
48
+ "connection": "cfg-slmp-array-string",
49
+ "addresses": "D300,10\nD200:F,2\nDSTR320,10",
50
+ "addressesType": "str",
51
+ "outputMode": "array",
52
+ "errorHandling": "output2",
53
+ "x": 380,
54
+ "y": 120,
55
+ "wires": [
56
+ [
57
+ "debug-array-read-ok"
58
+ ],
59
+ [
60
+ "debug-array-read-error"
61
+ ]
62
+ ]
63
+ },
64
+ {
65
+ "id": "inject-array-write",
66
+ "type": "inject",
67
+ "z": "tab-slmp-array-string",
68
+ "name": "Write array + string",
69
+ "props": [
70
+ {
71
+ "p": "payload",
72
+ "v": "{\"D300,10\":[0,1,2,3,4,5,6,7,8,9],\"D200:F,2\":[1.25,-2.5],\"DSTR320,10\":\"HELLO12345\"}",
73
+ "vt": "json"
74
+ }
75
+ ],
76
+ "repeat": "",
77
+ "crontab": "",
78
+ "once": false,
79
+ "onceDelay": 0.1,
80
+ "topic": "",
81
+ "x": 120,
82
+ "y": 200,
83
+ "wires": [
84
+ [
85
+ "write-array-string"
86
+ ]
87
+ ]
88
+ },
89
+ {
90
+ "id": "write-array-string",
91
+ "type": "slmp-write",
92
+ "z": "tab-slmp-array-string",
93
+ "name": "Write array + float array + string",
94
+ "connection": "cfg-slmp-array-string",
95
+ "updates": "",
96
+ "updatesType": "str",
97
+ "errorHandling": "output2",
98
+ "x": 380,
99
+ "y": 200,
100
+ "wires": [
101
+ [
102
+ "debug-array-write-ok"
103
+ ],
104
+ [
105
+ "debug-array-write-error"
106
+ ]
107
+ ]
108
+ },
109
+ {
110
+ "id": "debug-array-read-ok",
111
+ "type": "debug",
112
+ "z": "tab-slmp-array-string",
113
+ "name": "Read OK",
114
+ "active": true,
115
+ "tosidebar": true,
116
+ "console": false,
117
+ "tostatus": false,
118
+ "complete": "true",
119
+ "targetType": "full",
120
+ "x": 640,
121
+ "y": 100,
122
+ "wires": []
123
+ },
124
+ {
125
+ "id": "debug-array-read-error",
126
+ "type": "debug",
127
+ "z": "tab-slmp-array-string",
128
+ "name": "Read Error",
129
+ "active": true,
130
+ "tosidebar": true,
131
+ "console": false,
132
+ "tostatus": false,
133
+ "complete": "true",
134
+ "targetType": "full",
135
+ "x": 650,
136
+ "y": 140,
137
+ "wires": []
138
+ },
139
+ {
140
+ "id": "debug-array-write-ok",
141
+ "type": "debug",
142
+ "z": "tab-slmp-array-string",
143
+ "name": "Write OK",
144
+ "active": true,
145
+ "tosidebar": true,
146
+ "console": false,
147
+ "tostatus": false,
148
+ "complete": "true",
149
+ "targetType": "full",
150
+ "x": 640,
151
+ "y": 180,
152
+ "wires": []
153
+ },
154
+ {
155
+ "id": "debug-array-write-error",
156
+ "type": "debug",
157
+ "z": "tab-slmp-array-string",
158
+ "name": "Write Error",
159
+ "active": true,
160
+ "tosidebar": true,
161
+ "console": false,
162
+ "tostatus": false,
163
+ "complete": "true",
164
+ "targetType": "full",
165
+ "x": 650,
166
+ "y": 220,
167
+ "wires": []
168
+ },
169
+ {
170
+ "id": "cfg-slmp-array-string",
171
+ "type": "slmp-connection",
172
+ "name": "PLC TCP 4E",
173
+ "host": "192.168.250.100",
174
+ "port": "1025",
175
+ "transport": "tcp",
176
+ "timeout": "3000",
177
+ "plcSeries": "iqr",
178
+ "frameType": "4e",
179
+ "monitoringTimer": "16",
180
+ "network": "0",
181
+ "station": "255",
182
+ "moduleIO": "03FF",
183
+ "multidrop": "0"
184
+ }
185
+ ]
@@ -0,0 +1,185 @@
1
+ [
2
+ {
3
+ "id": "tab-slmp-basic",
4
+ "type": "tab",
5
+ "label": "SLMP Basic Read Write",
6
+ "disabled": false,
7
+ "info": "Update the connection host, port, and safe device addresses before deploy."
8
+ },
9
+ {
10
+ "id": "comment-slmp-basic",
11
+ "type": "comment",
12
+ "z": "tab-slmp-basic",
13
+ "name": "Basic TCP read/write using safe scalar addresses",
14
+ "info": "",
15
+ "x": 260,
16
+ "y": 40,
17
+ "wires": []
18
+ },
19
+ {
20
+ "id": "inject-basic-read",
21
+ "type": "inject",
22
+ "z": "tab-slmp-basic",
23
+ "name": "Read snapshot",
24
+ "props": [
25
+ {
26
+ "p": "payload"
27
+ }
28
+ ],
29
+ "repeat": "",
30
+ "crontab": "",
31
+ "once": false,
32
+ "onceDelay": 0.1,
33
+ "topic": "",
34
+ "payloadType": "date",
35
+ "x": 120,
36
+ "y": 120,
37
+ "wires": [
38
+ [
39
+ "read-basic"
40
+ ]
41
+ ]
42
+ },
43
+ {
44
+ "id": "read-basic",
45
+ "type": "slmp-read",
46
+ "z": "tab-slmp-basic",
47
+ "name": "Read scalar + float + bit",
48
+ "connection": "cfg-slmp-basic",
49
+ "addresses": "D300\nD301\nD200:F\nD302.3",
50
+ "addressesType": "str",
51
+ "outputMode": "object",
52
+ "errorHandling": "output2",
53
+ "x": 340,
54
+ "y": 120,
55
+ "wires": [
56
+ [
57
+ "debug-basic-read-ok"
58
+ ],
59
+ [
60
+ "debug-basic-read-error"
61
+ ]
62
+ ]
63
+ },
64
+ {
65
+ "id": "inject-basic-write",
66
+ "type": "inject",
67
+ "z": "tab-slmp-basic",
68
+ "name": "Write values",
69
+ "props": [
70
+ {
71
+ "p": "payload",
72
+ "v": "{\"D300\":123,\"D301\":456,\"D200:F\":1.25,\"D302.3\":true}",
73
+ "vt": "json"
74
+ }
75
+ ],
76
+ "repeat": "",
77
+ "crontab": "",
78
+ "once": false,
79
+ "onceDelay": 0.1,
80
+ "topic": "",
81
+ "x": 110,
82
+ "y": 200,
83
+ "wires": [
84
+ [
85
+ "write-basic"
86
+ ]
87
+ ]
88
+ },
89
+ {
90
+ "id": "write-basic",
91
+ "type": "slmp-write",
92
+ "z": "tab-slmp-basic",
93
+ "name": "Write scalar + float + bit",
94
+ "connection": "cfg-slmp-basic",
95
+ "updates": "",
96
+ "updatesType": "str",
97
+ "errorHandling": "output2",
98
+ "x": 340,
99
+ "y": 200,
100
+ "wires": [
101
+ [
102
+ "debug-basic-write-ok"
103
+ ],
104
+ [
105
+ "debug-basic-write-error"
106
+ ]
107
+ ]
108
+ },
109
+ {
110
+ "id": "debug-basic-read-ok",
111
+ "type": "debug",
112
+ "z": "tab-slmp-basic",
113
+ "name": "Read OK",
114
+ "active": true,
115
+ "tosidebar": true,
116
+ "console": false,
117
+ "tostatus": false,
118
+ "complete": "true",
119
+ "targetType": "full",
120
+ "x": 580,
121
+ "y": 100,
122
+ "wires": []
123
+ },
124
+ {
125
+ "id": "debug-basic-read-error",
126
+ "type": "debug",
127
+ "z": "tab-slmp-basic",
128
+ "name": "Read Error",
129
+ "active": true,
130
+ "tosidebar": true,
131
+ "console": false,
132
+ "tostatus": false,
133
+ "complete": "true",
134
+ "targetType": "full",
135
+ "x": 590,
136
+ "y": 140,
137
+ "wires": []
138
+ },
139
+ {
140
+ "id": "debug-basic-write-ok",
141
+ "type": "debug",
142
+ "z": "tab-slmp-basic",
143
+ "name": "Write OK",
144
+ "active": true,
145
+ "tosidebar": true,
146
+ "console": false,
147
+ "tostatus": false,
148
+ "complete": "true",
149
+ "targetType": "full",
150
+ "x": 580,
151
+ "y": 180,
152
+ "wires": []
153
+ },
154
+ {
155
+ "id": "debug-basic-write-error",
156
+ "type": "debug",
157
+ "z": "tab-slmp-basic",
158
+ "name": "Write Error",
159
+ "active": true,
160
+ "tosidebar": true,
161
+ "console": false,
162
+ "tostatus": false,
163
+ "complete": "true",
164
+ "targetType": "full",
165
+ "x": 590,
166
+ "y": 220,
167
+ "wires": []
168
+ },
169
+ {
170
+ "id": "cfg-slmp-basic",
171
+ "type": "slmp-connection",
172
+ "name": "PLC TCP 4E",
173
+ "host": "192.168.250.100",
174
+ "port": "1025",
175
+ "transport": "tcp",
176
+ "timeout": "3000",
177
+ "plcSeries": "iqr",
178
+ "frameType": "4e",
179
+ "monitoringTimer": "16",
180
+ "network": "0",
181
+ "station": "255",
182
+ "moduleIO": "03FF",
183
+ "multidrop": "0"
184
+ }
185
+ ]
@@ -0,0 +1,211 @@
1
+ [
2
+ {
3
+ "id": "tab-slmp-control-error",
4
+ "type": "tab",
5
+ "label": "SLMP Control And Error",
6
+ "disabled": false,
7
+ "info": "Update the connection host, port, and msg-provided addresses before deploy."
8
+ },
9
+ {
10
+ "id": "comment-slmp-control-error",
11
+ "type": "comment",
12
+ "z": "tab-slmp-control-error",
13
+ "name": "Control messages, msg source, and second-output error routing",
14
+ "info": "",
15
+ "x": 280,
16
+ "y": 40,
17
+ "wires": []
18
+ },
19
+ {
20
+ "id": "inject-control-connect",
21
+ "type": "inject",
22
+ "z": "tab-slmp-control-error",
23
+ "name": "Connect",
24
+ "props": [
25
+ {
26
+ "p": "connect",
27
+ "v": "true",
28
+ "vt": "bool"
29
+ }
30
+ ],
31
+ "repeat": "",
32
+ "crontab": "",
33
+ "once": false,
34
+ "onceDelay": 0.1,
35
+ "topic": "",
36
+ "x": 90,
37
+ "y": 100,
38
+ "wires": [
39
+ [
40
+ "read-control-error"
41
+ ]
42
+ ]
43
+ },
44
+ {
45
+ "id": "inject-control-reinit",
46
+ "type": "inject",
47
+ "z": "tab-slmp-control-error",
48
+ "name": "Reinitialize",
49
+ "props": [
50
+ {
51
+ "p": "reinitialize",
52
+ "v": "true",
53
+ "vt": "bool"
54
+ }
55
+ ],
56
+ "repeat": "",
57
+ "crontab": "",
58
+ "once": false,
59
+ "onceDelay": 0.1,
60
+ "topic": "",
61
+ "x": 100,
62
+ "y": 140,
63
+ "wires": [
64
+ [
65
+ "read-control-error"
66
+ ]
67
+ ]
68
+ },
69
+ {
70
+ "id": "inject-control-disconnect",
71
+ "type": "inject",
72
+ "z": "tab-slmp-control-error",
73
+ "name": "Disconnect",
74
+ "props": [
75
+ {
76
+ "p": "disconnect",
77
+ "v": "true",
78
+ "vt": "bool"
79
+ }
80
+ ],
81
+ "repeat": "",
82
+ "crontab": "",
83
+ "once": false,
84
+ "onceDelay": 0.1,
85
+ "topic": "",
86
+ "x": 100,
87
+ "y": 180,
88
+ "wires": [
89
+ [
90
+ "read-control-error"
91
+ ]
92
+ ]
93
+ },
94
+ {
95
+ "id": "inject-control-read-good",
96
+ "type": "inject",
97
+ "z": "tab-slmp-control-error",
98
+ "name": "Read via msg.lookup",
99
+ "props": [
100
+ {
101
+ "p": "lookup",
102
+ "v": "D300,4\nDSTR320,10",
103
+ "vt": "str"
104
+ }
105
+ ],
106
+ "repeat": "",
107
+ "crontab": "",
108
+ "once": false,
109
+ "onceDelay": 0.1,
110
+ "topic": "",
111
+ "x": 120,
112
+ "y": 260,
113
+ "wires": [
114
+ [
115
+ "read-control-error"
116
+ ]
117
+ ]
118
+ },
119
+ {
120
+ "id": "inject-control-read-bad",
121
+ "type": "inject",
122
+ "z": "tab-slmp-control-error",
123
+ "name": "Bad address",
124
+ "props": [
125
+ {
126
+ "p": "lookup",
127
+ "v": "BAD100",
128
+ "vt": "str"
129
+ }
130
+ ],
131
+ "repeat": "",
132
+ "crontab": "",
133
+ "once": false,
134
+ "onceDelay": 0.1,
135
+ "topic": "",
136
+ "x": 100,
137
+ "y": 300,
138
+ "wires": [
139
+ [
140
+ "read-control-error"
141
+ ]
142
+ ]
143
+ },
144
+ {
145
+ "id": "read-control-error",
146
+ "type": "slmp-read",
147
+ "z": "tab-slmp-control-error",
148
+ "name": "Read from msg.lookup",
149
+ "connection": "cfg-slmp-control-error",
150
+ "addresses": "lookup",
151
+ "addressesType": "msg",
152
+ "outputMode": "array",
153
+ "errorHandling": "output2",
154
+ "x": 360,
155
+ "y": 260,
156
+ "wires": [
157
+ [
158
+ "debug-control-ok"
159
+ ],
160
+ [
161
+ "debug-control-error"
162
+ ]
163
+ ]
164
+ },
165
+ {
166
+ "id": "debug-control-ok",
167
+ "type": "debug",
168
+ "z": "tab-slmp-control-error",
169
+ "name": "OK",
170
+ "active": true,
171
+ "tosidebar": true,
172
+ "console": false,
173
+ "tostatus": false,
174
+ "complete": "true",
175
+ "targetType": "full",
176
+ "x": 580,
177
+ "y": 240,
178
+ "wires": []
179
+ },
180
+ {
181
+ "id": "debug-control-error",
182
+ "type": "debug",
183
+ "z": "tab-slmp-control-error",
184
+ "name": "Error",
185
+ "active": true,
186
+ "tosidebar": true,
187
+ "console": false,
188
+ "tostatus": false,
189
+ "complete": "true",
190
+ "targetType": "full",
191
+ "x": 590,
192
+ "y": 280,
193
+ "wires": []
194
+ },
195
+ {
196
+ "id": "cfg-slmp-control-error",
197
+ "type": "slmp-connection",
198
+ "name": "PLC TCP 4E",
199
+ "host": "192.168.250.100",
200
+ "port": "1025",
201
+ "transport": "tcp",
202
+ "timeout": "3000",
203
+ "plcSeries": "iqr",
204
+ "frameType": "4e",
205
+ "monitoringTimer": "16",
206
+ "network": "0",
207
+ "station": "255",
208
+ "moduleIO": "03FF",
209
+ "multidrop": "0"
210
+ }
211
+ ]