@microtronics/studio-cli 0.61.0 → 0.62.0

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.
@@ -1,1061 +0,0 @@
1
- {
2
- "$schema": "http://json-schema.org/draft-07/schema#",
3
- "title": "Dynamic DDE Schema",
4
- "description": "Describe your data structure for Microtronics IoT devices",
5
- "type": "object",
6
- "additionalProperties": false,
7
- "properties": {
8
- "dde": {
9
- "type": "string",
10
- "default": "1.0.0",
11
- "readOnly": true,
12
- "description": "Version of the DDE schema. Do not modify this value.",
13
- "markdownDescription": "Version of the DDE schema.\n\n⚠️ **Do not modify this value.**"
14
- },
15
- "cloudProject": {
16
- "type": "boolean",
17
- "description": "Indicates whether this is a cloud project.",
18
- "markdownDescription": "Indicates whether this is a cloud project.\n\nWhen set to `false`, certain containers and top-level custom containers are restricted."
19
- },
20
- "constants": {
21
- "type": "object",
22
- "description": "Declare constants that can be used across the YAML file.",
23
- "markdownDescription": "Declare constants that can be referenced and used across the YAML file."
24
- },
25
- "state": {
26
- "$ref": "#/$defs/stateContainer"
27
- },
28
- "result": {
29
- "$ref": "#/$defs/resultContainer"
30
- },
31
- "volatile": {
32
- "$ref": "#/$defs/volatileContainer"
33
- },
34
- "timeseries": {
35
- "type": "object",
36
- "description": "Define time-series data channels for recording measurements.",
37
- "markdownDescription": "Define time-series data channels for recording measurements.\n\n**Limits:** Maximum 9 fields.\n\n**Naming rules:**\n- Must start with a letter or `_`\n- May contain letters, digits, and `_`\n- Names like `field0`, `ch0`, etc. are **not allowed**\n- Reserved names (`_id`, `id`, `_stamp`, `stamp`, `tag`, `_uid`, `customer_id`, `site_id`, `_rec_flags__`, `applog`) are **not allowed**",
38
- "additionalProperties": false,
39
- "maxProperties": 9,
40
- "errorMessage": {
41
- "maxProperties": "The timeseries container supports a maximum of 9 fields."
42
- },
43
- "properties": {
44
- "_id": {
45
- "not": {},
46
- "errorMessage": "'_id' is a reserved name and cannot be used as a timeseries field."
47
- },
48
- "id": {
49
- "not": {},
50
- "errorMessage": "'id' is a reserved name and cannot be used as a timeseries field."
51
- },
52
- "_stamp": {
53
- "not": {},
54
- "errorMessage": "'_stamp' is a reserved name and cannot be used as a timeseries field."
55
- },
56
- "stamp": {
57
- "not": {},
58
- "errorMessage": "'stamp' is a reserved name and cannot be used as a timeseries field."
59
- },
60
- "tag": {
61
- "not": {},
62
- "errorMessage": "'tag' is a reserved name and cannot be used as a timeseries field."
63
- },
64
- "_uid": {
65
- "not": {},
66
- "errorMessage": "'_uid' is a reserved name and cannot be used as a timeseries field."
67
- },
68
- "customer_id": {
69
- "not": {},
70
- "errorMessage": "'customer_id' is a reserved name and cannot be used as a timeseries field."
71
- },
72
- "site_id": {
73
- "not": {},
74
- "errorMessage": "'site_id' is a reserved name and cannot be used as a timeseries field."
75
- },
76
- "_rec_flags__": {
77
- "not": {},
78
- "errorMessage": "'_rec_flags__' is a reserved name and cannot be used as a timeseries field."
79
- },
80
- "applog": {
81
- "not": {},
82
- "errorMessage": "'applog' is a reserved name and cannot be used as a timeseries field."
83
- }
84
- },
85
- "patternProperties": {
86
- "^(?!.*^field\\d+$)(?!.*^ch\\d+$)[a-zA-Z_][0-9a-zA-Z_]*$": {
87
- "$ref": "#/$defs/timeseriesFields"
88
- }
89
- }
90
- },
91
- "aloha": {
92
- "type": "object",
93
- "description": "Special container to transport live data during put-into-operation procedures.",
94
- "markdownDescription": "Special container to transport **live data** during put-into-operation procedures.\n\nUsed for real-time data exchange between device and server during commissioning.",
95
- "$ref": "#/$defs/alohaContainer"
96
- },
97
- "setting": {
98
- "$ref": "#/$defs/settingContainer"
99
- },
100
- "command": {
101
- "$ref": "#/$defs/commandContainer"
102
- },
103
- "storage": {
104
- "$ref": "#/$defs/serverStorageContainer"
105
- },
106
- "relations": {
107
- "$ref": "#/$defs/serverRelationsContainer"
108
- }
109
- },
110
- "patternProperties": {
111
- "^(?!.*^field\\d+$)(?!.*^ch\\d+$)(?!(dde|cloudProject|constants|state|result|volatile|timeseries|aloha|setting|command|storage|relations))[a-zA-Z_][0-9a-zA-Z_]*$": {
112
- "type": "object",
113
- "description": "Custom configuration container. Field names must start with a letter or underscore and may contain letters, digits, and underscores.",
114
- "$ref": "#/$defs/configurationFields"
115
- }
116
- },
117
- "allOf": [
118
- {
119
- "if": {
120
- "properties": {
121
- "cloudProject": {
122
- "const": false
123
- }
124
- }
125
- },
126
- "then": {
127
- "type": "object",
128
- "additionalProperties": false,
129
- "errorMessage": {
130
- "additionalProperties": "Non-cloud projects only allow standard containers (state, result, volatile, timeseries, aloha, setting, command, storage, relations). Set 'cloudProject' to true to use custom top-level containers."
131
- },
132
- "properties": {
133
- "dde": {
134
- "type": "string",
135
- "default": "1.0.0",
136
- "readOnly": true,
137
- "description": "Version of the DDE schema. Do not modify this value."
138
- },
139
- "cloudProject": {
140
- "type": "boolean"
141
- },
142
- "constants": {
143
- "type": "object",
144
- "description": "Declare constants that can be used across the YAML file."
145
- },
146
- "state": {
147
- "$ref": "#/$defs/stateContainer"
148
- },
149
- "result": {
150
- "$ref": "#/$defs/resultContainer"
151
- },
152
- "volatile": {
153
- "$ref": "#/$defs/volatileContainer"
154
- },
155
- "timeseries": {
156
- "type": "object",
157
- "description": "Define time-series data channels for recording measurements.",
158
- "additionalProperties": false,
159
- "maxProperties": 9,
160
- "errorMessage": {
161
- "maxProperties": "The timeseries container supports a maximum of 9 fields."
162
- },
163
- "properties": {
164
- "_id": {
165
- "not": {},
166
- "errorMessage": "'_id' is a reserved name and cannot be used as a timeseries field."
167
- },
168
- "id": {
169
- "not": {},
170
- "errorMessage": "'id' is a reserved name and cannot be used as a timeseries field."
171
- },
172
- "_stamp": {
173
- "not": {},
174
- "errorMessage": "'_stamp' is a reserved name and cannot be used as a timeseries field."
175
- },
176
- "stamp": {
177
- "not": {},
178
- "errorMessage": "'stamp' is a reserved name and cannot be used as a timeseries field."
179
- },
180
- "tag": {
181
- "not": {},
182
- "errorMessage": "'tag' is a reserved name and cannot be used as a timeseries field."
183
- },
184
- "_uid": {
185
- "not": {},
186
- "errorMessage": "'_uid' is a reserved name and cannot be used as a timeseries field."
187
- },
188
- "customer_id": {
189
- "not": {},
190
- "errorMessage": "'customer_id' is a reserved name and cannot be used as a timeseries field."
191
- },
192
- "site_id": {
193
- "not": {},
194
- "errorMessage": "'site_id' is a reserved name and cannot be used as a timeseries field."
195
- },
196
- "_rec_flags__": {
197
- "not": {},
198
- "errorMessage": "'_rec_flags__' is a reserved name and cannot be used as a timeseries field."
199
- },
200
- "applog": {
201
- "not": {},
202
- "errorMessage": "'applog' is a reserved name and cannot be used as a timeseries field."
203
- }
204
- },
205
- "patternProperties": {
206
- "^(?!.*^field\\d+$)(?!.*^ch\\d+$)[a-zA-Z_][0-9a-zA-Z_]*$": {
207
- "$ref": "#/$defs/timeseriesFields"
208
- }
209
- }
210
- },
211
- "aloha": {
212
- "type": "object",
213
- "description": "Special container to transport live data during put-into-operation procedures.",
214
- "$ref": "#/$defs/alohaContainer"
215
- },
216
- "setting": {
217
- "$ref": "#/$defs/settingContainer"
218
- },
219
- "command": {
220
- "$ref": "#/$defs/commandContainer"
221
- },
222
- "storage": {
223
- "$ref": "#/$defs/serverStorageContainer"
224
- },
225
- "relations": {
226
- "$ref": "#/$defs/serverRelationsContainer"
227
- }
228
- }
229
- }
230
- }
231
- ],
232
- "$defs": {
233
- "stateContainer": {
234
- "type": "object",
235
- "title": "state - Transferred from the device",
236
- "description": "Use this container for low-frequency state changes. Data is transferred from the device to the server.",
237
- "markdownDescription": "**state** – Transferred from the device\n\nUse this container for **low-frequency state changes**.\n\nData is transferred from the device to the server.",
238
- "$ref": "#/$defs/configurationFields"
239
- },
240
- "resultContainer": {
241
- "type": "object",
242
- "title": "result - Transferred from the device",
243
- "description": "Use this container for higher-frequency changes, e.g. responses to an executed command. Data is transferred from the device to the server.",
244
- "markdownDescription": "**result** – Transferred from the device\n\nUse this container for **higher-frequency changes**, e.g. responses to an executed command.\n\nData is transferred from the device to the server.",
245
- "$ref": "#/$defs/configurationFields"
246
- },
247
- "volatileContainer": {
248
- "type": "object",
249
- "title": "volatile - Transferred from the device",
250
- "description": "Container is not persisted on the device. Common use case: transaction responses. Use 'DDE_volatile_persist()' to persist this data.",
251
- "markdownDescription": "**volatile** – Transferred from the device\n\nContainer is **not persisted** on the device.\n\nCommon use case: transaction responses.\n\nIf you want to persist this data, use `DDE_volatile_persist()`.",
252
- "$ref": "#/$defs/configurationFields"
253
- },
254
- "alohaContainer": {
255
- "type": "object",
256
- "title": "aloha - Transferred from the device",
257
- "description": "A special container to transport live data during put-into-operation procedures.",
258
- "markdownDescription": "**aloha** – Transferred from the device\n\nA special container to transport **live data** during put-into-operation procedures.",
259
- "$ref": "#/$defs/configurationFields"
260
- },
261
- "settingContainer": {
262
- "type": "object",
263
- "title": "setting - Transferred to the device",
264
- "description": "Use this container for low-frequency changes, e.g. application settings like a transfer interval. Data is transferred from the server to the device.",
265
- "markdownDescription": "**setting** – Transferred to the device\n\nUse this container for **low-frequency changes**, e.g. application settings like a transfer interval.\n\nData is transferred from the server to the device.",
266
- "$ref": "#/$defs/configurationFields"
267
- },
268
- "commandContainer": {
269
- "type": "object",
270
- "title": "command - Transferred to the device",
271
- "description": "Use this container for high-frequency changes, e.g. changing the state of a physical output. Data is transferred from the server to the device.",
272
- "markdownDescription": "**command** – Transferred to the device\n\nUse this container for **high-frequency changes**, e.g. changing the state of a physical output.\n\nData is transferred from the server to the device.",
273
- "$ref": "#/$defs/configurationFields"
274
- },
275
- "serverStorageContainer": {
276
- "type": "object",
277
- "title": "storage - Server only",
278
- "description": "Use this container to store any POV or BLO related settings. This data is only stored on the server and not transferred to the device.",
279
- "markdownDescription": "**storage** – Server only\n\nUse this container to store any **POV** or **BLO** related settings.\n\nThis data is only stored on the server and **not transferred** to the device.",
280
- "$ref": "#/$defs/configurationFields"
281
- },
282
- "serverRelationsContainer": {
283
- "type": "object",
284
- "title": "relations - Server only",
285
- "description": "Use this container to store field-related configuration. This data is only stored on the server.",
286
- "markdownDescription": "**relations** – Server only\n\nUse this container to store **field-related configuration**.\n\nThis data is only stored on the server.",
287
- "$ref": "#/$defs/configurationFields"
288
- },
289
- "configurationFields": {
290
- "type": "object",
291
- "description": "Fields of the container. Field names must start with a letter or underscore, and may contain letters, digits, and underscores. Names like 'field0', 'ch0', etc. are not allowed.",
292
- "markdownDescription": "Fields of the container.\n\n**Naming rules:**\n- Must start with a letter or `_`\n- May contain letters, digits, and `_`\n- Names like `field0`, `ch0`, etc. are **not allowed**\n- Reserved names (`_id`, `id`, `_stamp`, `stamp`, `tag`, `_uid`, `customer_id`, `site_id`, `_rec_flags__`, `applog`) are **not allowed**",
293
- "additionalProperties": false,
294
- "errorMessage": {
295
- "additionalProperties": "Invalid field name. Field names must start with a letter or underscore, may contain letters, digits, and underscores. Names matching 'fieldN' or 'chN' patterns and reserved names (_id, id, _stamp, stamp, tag, _uid, customer_id, site_id, _rec_flags__, applog) are not allowed."
296
- },
297
- "$ref": "#/$defs/reservedNamesFieldNames",
298
- "properties": {},
299
- "patternProperties": {
300
- "^(?!.*^field\\d+$)(?!.*^ch\\d+$)[a-zA-Z_][0-9a-zA-Z_]*$": {
301
- "allOf": [
302
- {
303
- "$ref": "#/$defs/defaultFieldProperties"
304
- },
305
- {
306
- "$ref": "#/$defs/configArrayDefinition"
307
- }
308
- ]
309
- }
310
- }
311
- },
312
- "timeseriesFields": {
313
- "type": "object",
314
- "description": "Timeseries fields of the container. Supports additional chart and channel properties compared to configuration fields.",
315
- "markdownDescription": "Timeseries fields of the container.\n\nSupports additional **chart** and **channel** properties compared to configuration fields.",
316
- "additionalProperties": false,
317
- "errorMessage": {
318
- "additionalProperties": "Invalid field name. Field names must start with a letter or underscore, may contain letters, digits, and underscores. Names matching 'fieldN' or 'chN' patterns and reserved names are not allowed."
319
- },
320
- "$ref": "#/$defs/reservedNamesFieldNames",
321
- "patternProperties": {
322
- "^(?!.*^field\\d+$)(?!.*^ch\\d+$)[a-zA-Z_][0-9a-zA-Z_]*$": {
323
- "allOf": [
324
- {
325
- "$ref": "#/$defs/defaultFieldProperties"
326
- },
327
- {
328
- "type": "object",
329
- "properties": {
330
- "channelMode": {
331
- "type": ["string", "number"],
332
- "description": "Defines how values are treated upon aggregation. Applies to numeric fields only.",
333
- "markdownDescription": "Defines how values are treated upon aggregation.\n\n**Applies to numeric fields only.**\n\nOptions:\n- `digital` – Treatment as digital value (0 or 1)\n- `day-counter` – Counter reset once per day\n- `interval-counter` – Counter reset on each recording\n- `analog` – (default) Normal measurement value\n- `infinite-counter` – Counter that is never reset\n- Relation link (`@container.field`)",
334
- "anyOf": [
335
- {
336
- "const": "digital",
337
- "description": "Treatment as digital value. The raw value should be 0 or 1."
338
- },
339
- {
340
- "const": "day-counter",
341
- "description": "A counter which is reset once per day"
342
- },
343
- {
344
- "const": "interval-counter",
345
- "description": "A counter which is reset on each recording"
346
- },
347
- {
348
- "const": "analog",
349
- "description": "(default) - A 'normal' measurement value. E.g. temperature"
350
- },
351
- {
352
- "const": "infinite-counter",
353
- "description": "A counter which is never reset, e.g. water- or electricity meter."
354
- },
355
- {
356
- "$ref": "#/$defs/relationLinkPattern"
357
- }
358
- ]
359
- },
360
- "chartAlarmLow": {
361
- "title": "Chart Alarm Low",
362
- "$ref": "#/$defs/chartAlarmWarn"
363
- },
364
- "chartAlarmHigh": {
365
- "title": "Chart Alarm High",
366
- "$ref": "#/$defs/chartAlarmWarn"
367
- },
368
- "chartWarningLow": {
369
- "title": "Chart Warning Low",
370
- "$ref": "#/$defs/chartAlarmWarn"
371
- },
372
- "chartWarningHigh": {
373
- "title": "Chart Warning High",
374
- "$ref": "#/$defs/chartAlarmWarn"
375
- },
376
- "chartHysteresis": {
377
- "title": "Chart Hysteresis",
378
- "type": ["number", "string"],
379
- "description": "The server uses this property to show a hysteresis in charts. The value is in %. Requires 'chartWarningX' and/or 'chartAlarmX'.",
380
- "markdownDescription": "The server uses this property to show a **hysteresis** in charts.\n\nThe value is in **%**.\n\n⚠️ Requires `chartWarningX` and/or `chartAlarmX` to be set.",
381
- "$ref": "#/$defs/relationLinkPattern"
382
- },
383
- "chartTriggerThreshold": {
384
- "title": "Chart Trigger Threshold",
385
- "type": ["number", "string"],
386
- "description": "The server uses this property to show a trigger threshold in charts.",
387
- "markdownDescription": "The server uses this property to show a **trigger threshold** in charts.",
388
- "$ref": "#/$defs/relationLinkPattern"
389
- },
390
- "chartTriggerRelation": {
391
- "title": "Chart Trigger Relation",
392
- "type": ["string"],
393
- "description": "Defines if the 'chartTriggerThreshold' displays as overshoot or undershoot. Requires 'chartTriggerThreshold' to be set.",
394
- "markdownDescription": "Defines if the `chartTriggerThreshold` displays as **overshoot** or **undershoot**.\n\n⚠️ Requires `chartTriggerThreshold` to be set.",
395
- "anyOf": [
396
- {
397
- "title": "Greater or equal",
398
- "description": "Highlights the measurement value if it is greater or equal the 'chartTriggerThreshold'.",
399
- "const": "greater-or-equal"
400
- },
401
- {
402
- "title": "Less or equal",
403
- "description": "Highlights the measurement value if it is less or equal the 'chartTriggerThreshold'.",
404
- "const": "less-or-equal"
405
- },
406
- {
407
- "$ref": "#/$defs/relationLinkPattern"
408
- }
409
- ]
410
- },
411
- "chartSetPoint": {
412
- "title": "Chart Set Point",
413
- "type": ["string"],
414
- "description": "Used to report the actual state of the referenced value. The server will display a pending information if the value is not transmitted yet.",
415
- "markdownDescription": "Used to report the actual state of the referenced value.\n\nThe server will display a **pending** indicator if the value has not been transmitted yet.",
416
- "$ref": "#/$defs/setPointRelationPattern"
417
- }
418
- },
419
- "dependencies": {
420
- "chartTriggerRelation": {
421
- "required": ["chartTriggerThreshold"],
422
- "errorMessage": "'chartTriggerRelation' requires 'chartTriggerThreshold' to also be defined."
423
- }
424
- }
425
- },
426
- {
427
- "$ref": "#/$defs/timeseriesArrayDefinition"
428
- }
429
- ]
430
- }
431
- }
432
- },
433
- "reservedNamesFieldNames": {
434
- "type": "object",
435
- "properties": {
436
- "_id": {
437
- "not": {},
438
- "errorMessage": "'_id' is a reserved name and cannot be used as a field name."
439
- },
440
- "id": {
441
- "not": {},
442
- "errorMessage": "'id' is a reserved name and cannot be used as a field name."
443
- },
444
- "_stamp": {
445
- "not": {},
446
- "errorMessage": "'_stamp' is a reserved name and cannot be used as a field name."
447
- },
448
- "stamp": {
449
- "not": {},
450
- "errorMessage": "'stamp' is a reserved name and cannot be used as a field name."
451
- },
452
- "tag": {
453
- "not": {},
454
- "errorMessage": "'tag' is a reserved name and cannot be used as a field name."
455
- },
456
- "_uid": {
457
- "not": {},
458
- "errorMessage": "'_uid' is a reserved name and cannot be used as a field name."
459
- },
460
- "customer_id": {
461
- "not": {},
462
- "errorMessage": "'customer_id' is a reserved name and cannot be used as a field name."
463
- },
464
- "site_id": {
465
- "not": {},
466
- "errorMessage": "'site_id' is a reserved name and cannot be used as a field name."
467
- },
468
- "_rec_flags__": {
469
- "not": {},
470
- "errorMessage": "'_rec_flags__' is a reserved name and cannot be used as a field name."
471
- },
472
- "applog": {
473
- "not": {},
474
- "errorMessage": "'applog' is a reserved name and cannot be used as a field name."
475
- }
476
- }
477
- },
478
- "defaultFieldProperties": {
479
- "type": "object",
480
- "additionalProperties": false,
481
- "properties": {
482
- "type": {
483
- "$ref": "#/$defs/dataTypes"
484
- },
485
- "title": {
486
- "type": "string",
487
- "description": "Title to describe the field's content within the portal.",
488
- "markdownDescription": "Title to describe the field's content within the portal.\n\nCan also reference a relation using `@container.field` syntax."
489
- },
490
- "description": {
491
- "type": "string",
492
- "description": "Description what this field is about."
493
- },
494
- "array": {
495
- "type": "number",
496
- "description": "Length of the array. Must be between 1 and 1024.",
497
- "markdownDescription": "Length of the array.\n\n**Range:** 1–1024",
498
- "minimum": 1,
499
- "inclusiveMaximum": 1024
500
- },
501
- "unit": {
502
- "type": "string",
503
- "description": "Unit information to be shown in the default POV (e.g. 'kg', '°C', 'V').",
504
- "markdownDescription": "Unit information to be shown in the default POV.\n\n**Examples:** `kg`, `°C`, `V`, `%`\n\nCan also reference a relation using `@container.field` syntax."
505
- },
506
- "hex": {
507
- "type": "boolean",
508
- "description": "Server-side processing. Declares if this field should be displayed as HEX string. The API will also process the field as HEX.",
509
- "markdownDescription": "Server-side processing. Declares if this field should be displayed as **HEX** string.\n\nThe API will also process the field as HEX."
510
- },
511
- "decimalPlaces": {
512
- "$ref": "#/$defs/decimalPlaces"
513
- },
514
- "writePermission": {
515
- "description": "User level required for editing. Applies for down containers only (setting, command).",
516
- "markdownDescription": "User level required for editing.\n\n**Applies for down containers only** (`setting`, `command`).\n\nSet to `read-only` to prevent editing.",
517
- "anyOf": [
518
- {
519
- "$ref": "#/$defs/userLevel"
520
- },
521
- {
522
- "const": "read-only",
523
- "title": "Read only",
524
- "description": "Field can not be edited."
525
- }
526
- ]
527
- },
528
- "readPermission": {
529
- "description": "User level required for viewing.",
530
- "markdownDescription": "User level required for viewing this field.",
531
- "$ref": "#/$defs/userLevel"
532
- },
533
- "bytes": true,
534
- "fields": true,
535
- "length": true,
536
- "defaultValue": true,
537
- "channelMode": true,
538
- "scale": true,
539
- "offset": true,
540
- "chartMinimum": true,
541
- "chartMaximum": true,
542
- "chartAlarmLow": true,
543
- "chartAlarmHigh": true,
544
- "chartWarningLow": true,
545
- "chartWarningHigh": true,
546
- "chartHysteresis": true,
547
- "chartTriggerThreshold": true,
548
- "chartTriggerRelation": true,
549
- "chartSetPoint": true,
550
- "utilsTransferInterval": true,
551
- "shadowFields": {
552
- "type": "object",
553
- "deprecated": true,
554
- "title": "DEPRECATED",
555
- "description": "Allows defining multiple fields within the same memory space. This property is deprecated and should not be used in new projects.",
556
- "markdownDescription": "⚠️ **DEPRECATED**\n\nAllows defining multiple fields within the same memory space.\n\nThis property is deprecated and should not be used in new projects.",
557
- "$ref": "#/$defs/configurationFields"
558
- },
559
- "bitmask": {
560
- "type": "string",
561
- "title": "Bitmask",
562
- "description": "Defines what bits of the according data type are used for storage. Must be a hex (0x...) or binary (0b...) string.",
563
- "markdownDescription": "Defines what bits of the according data type are used for storage.\n\n**Formats:**\n- Hexadecimal: `0xAB CD` (prefix `0x`, hex digits and spaces)\n- Binary: `0b1010 0101` (prefix `0b`, binary digits and spaces)",
564
- "anyOf": [
565
- {
566
- "default": "\"0x\"",
567
- "pattern": "^0x[0-9A-F ]+$",
568
- "patternErrorMessage": "Hexadecimal bitmask must start with '0x' followed by uppercase hex digits (0-9, A-F) and optional spaces (e.g. '0xFF' or '0xFF 00').",
569
- "description": "Bitmask defined as hexadecimal. Defines what bits of the according data type are used for storage."
570
- },
571
- {
572
- "default": "\"0b\"",
573
- "pattern": "^0b[0-1 ]+$",
574
- "patternErrorMessage": "Binary bitmask must start with '0b' followed by binary digits (0, 1) and optional spaces (e.g. '0b11110000' or '0b1111 0000').",
575
- "description": "Bitmask defined as binary. Defines what bits of the according data type are used for storage."
576
- }
577
- ]
578
- }
579
- },
580
- "required": ["type"],
581
- "errorMessage": {
582
- "required": {
583
- "type": "Every field must have a 'type' property specifying its data type."
584
- }
585
- },
586
- "allOf": [
587
- {
588
- "if": {
589
- "description": "Force the byte amount if datatype is binary",
590
- "properties": {
591
- "type": {
592
- "enum": ["binary"]
593
- }
594
- }
595
- },
596
- "then": {
597
- "properties": {
598
- "bytes": {
599
- "type": "number",
600
- "description": "Number of bytes for binary data. Required when type is 'binary'.",
601
- "markdownDescription": "Number of bytes for binary data.\n\n**Required** when type is `binary`."
602
- },
603
- "defaultValue": {
604
- "type": "string",
605
- "description": "Default value as hex (e.g. '0xFF 00'). Must start with '0x'.",
606
- "markdownDescription": "Default value as hex.\n\n**Format:** `0x` followed by uppercase hex digits and optional spaces.\n\n**Example:** `0xFF 00`",
607
- "pattern": "^0x[0-9A-F ]+$",
608
- "patternErrorMessage": "Default value for binary type must be a hex string starting with '0x' followed by uppercase hex digits (0-9, A-F) and optional spaces."
609
- }
610
- },
611
- "required": ["bytes"],
612
- "errorMessage": {
613
- "required": {
614
- "bytes": "The 'bytes' property is required when type is 'binary'. Specify the number of bytes."
615
- }
616
- }
617
- },
618
- "else": {
619
- "properties": {
620
- "bytes": {
621
- "not": {},
622
- "errorMessage": "The 'bytes' property is only allowed when type is 'binary'."
623
- }
624
- }
625
- }
626
- },
627
- {
628
- "if": {
629
- "description": "Special handling for string types",
630
- "properties": {
631
- "type": {
632
- "enum": ["astring", "nstring", "cstring", "wstring", "ustring"]
633
- }
634
- }
635
- },
636
- "then": {
637
- "properties": {
638
- "length": {
639
- "type": "number",
640
- "description": "Length of the string. Required for string types. Must be at least 1.",
641
- "markdownDescription": "Length of the string.\n\n**Required** for string types (`astring`, `nstring`, `cstring`, `wstring`, `ustring`).\n\n**Minimum:** 1",
642
- "minimum": 1
643
- },
644
- "defaultValue": {
645
- "type": "string",
646
- "description": "Default string value for this field."
647
- }
648
- },
649
- "required": ["length"],
650
- "errorMessage": {
651
- "required": {
652
- "length": "The 'length' property is required for string types (astring, nstring, cstring, wstring, ustring). Specify the string length."
653
- }
654
- }
655
- }
656
- },
657
- {
658
- "if": {
659
- "properties": {
660
- "type": {
661
- "enum": [
662
- "int8",
663
- "int16",
664
- "int32",
665
- "int64",
666
- "uint8",
667
- "uint16",
668
- "uint32",
669
- "float16",
670
- "float32",
671
- "float64"
672
- ]
673
- }
674
- }
675
- },
676
- "then": {
677
- "properties": {
678
- "decimalPlaces": {
679
- "$ref": "#/$defs/decimalPlaces"
680
- },
681
- "defaultValue": {
682
- "type": ["number", "string"],
683
- "description": "Default value for this field. Use a number or 'NaN'.",
684
- "markdownDescription": "Default value for this field.\n\nAccepts a **number** or the string `NaN`.",
685
- "pattern": "^NaN$",
686
- "patternErrorMessage": "String default values for numeric types must be 'NaN'. Use a number for other default values."
687
- },
688
- "chartMinimum": {
689
- "type": ["number", "string"],
690
- "description": "Disables auto scaling of lower range in POV charts.",
691
- "markdownDescription": "Disables **auto scaling** of the lower range in POV charts.\n\nAccepts a number or a relation link (`@container.field`).",
692
- "$ref": "#/$defs/relationLinkPattern"
693
- },
694
- "chartMaximum": {
695
- "type": ["number", "string"],
696
- "description": "Disables auto scaling of higher range in POV charts.",
697
- "markdownDescription": "Disables **auto scaling** of the higher range in POV charts.\n\nAccepts a number or a relation link (`@container.field`).",
698
- "$ref": "#/$defs/relationLinkPattern"
699
- },
700
- "scale": {
701
- "type": ["number", "string"],
702
- "title": "Scale the raw value",
703
- "description": "Server-side processing. Applies to POV and API. Formula: scaled = raw × scale + offset",
704
- "markdownDescription": "Server-side processing. Applies to POV and API.\n\n**Formula:** `scaled = raw × scale + offset`\n\nAccepts a number or a relation link (`@container.field`).",
705
- "$ref": "#/$defs/relationLinkPattern"
706
- },
707
- "offset": {
708
- "type": ["number", "string"],
709
- "title": "Add an offset to the raw value",
710
- "description": "Server-side processing. Applies to POV and API. Formula: scaled = raw × scale + offset",
711
- "markdownDescription": "Server-side processing. Applies to POV and API.\n\n**Formula:** `scaled = raw × scale + offset`\n\nAccepts a number or a relation link (`@container.field`).",
712
- "$ref": "#/$defs/relationLinkPattern"
713
- },
714
- "utilsTransferInterval": {
715
- "title": "Transfer Interval",
716
- "type": ["boolean"],
717
- "description": "Indicates the server that this field should be used for the remaining time until next connection. Field value has to be in seconds.",
718
- "markdownDescription": "Indicates the server that this field should be used for the **remaining time until next connection**.\n\nField value has to be in **seconds**."
719
- }
720
- }
721
- },
722
- "else": {
723
- "properties": {
724
- "decimalPlaces": {
725
- "not": {},
726
- "errorMessage": "'decimalPlaces' is only allowed for numeric types (int8, int16, int32, int64, uint8, uint16, uint32, float16, float32, float64)."
727
- },
728
- "chartMinimum": {
729
- "not": {},
730
- "errorMessage": "'chartMinimum' is only allowed for numeric types (int8, int16, int32, int64, uint8, uint16, uint32, float16, float32, float64)."
731
- },
732
- "chartMaximum": {
733
- "not": {},
734
- "errorMessage": "'chartMaximum' is only allowed for numeric types (int8, int16, int32, int64, uint8, uint16, uint32, float16, float32, float64)."
735
- },
736
- "scale": {
737
- "not": {},
738
- "errorMessage": "'scale' is only allowed for numeric types (int8, int16, int32, int64, uint8, uint16, uint32, float16, float32, float64)."
739
- },
740
- "offset": {
741
- "not": {},
742
- "errorMessage": "'offset' is only allowed for numeric types (int8, int16, int32, int64, uint8, uint16, uint32, float16, float32, float64)."
743
- }
744
- }
745
- }
746
- },
747
- {
748
- "if": {
749
- "description": "Enable regex relation validation if the string starts with @",
750
- "properties": {
751
- "title": {
752
- "pattern": "^(?=@)"
753
- }
754
- }
755
- },
756
- "then": {
757
- "properties": {
758
- "title": {
759
- "$ref": "#/$defs/relationLinkPattern"
760
- }
761
- }
762
- }
763
- },
764
- {
765
- "if": {
766
- "description": "Enable regex relation validation if the string starts with @",
767
- "properties": {
768
- "unit": {
769
- "pattern": "^(?=@)"
770
- }
771
- }
772
- },
773
- "then": {
774
- "properties": {
775
- "unit": {
776
- "$ref": "#/$defs/relationLinkPattern"
777
- }
778
- }
779
- }
780
- }
781
- ]
782
- },
783
- "dataTypes": {
784
- "type": "string",
785
- "description": "Data type of the field. Integer types: int8, int16, int32, int64, uint8, uint16, uint32. Float types: float16, float32, float64. Binary: binary. Timestamps: stamp32, stamp40. Strings: astring, nstring, cstring, wstring, ustring. Composite: array.",
786
- "markdownDescription": "Data type of the field.\n\n**Integer types:** `int8`, `int16`, `int32`, `int64`, `uint8`, `uint16`, `uint32`\n\n**Float types:** `float16`, `float32`, `float64`\n\n**Binary:** `binary`\n\n**Timestamps:** `stamp32`, `stamp40`\n\n**Strings:** `astring`, `nstring`, `cstring`, `wstring`, `ustring`\n\n**Composite:** `array`",
787
- "anyOf": [
788
- {
789
- "const": "int8",
790
- "title": "int8",
791
- "description": "Signed integer 8bit\nRange: -128 … 127"
792
- },
793
- {
794
- "const": "int16",
795
- "title": "int16",
796
- "description": "Signed integer 16bit\nRange: -32768 … 32767"
797
- },
798
- {
799
- "const": "int32",
800
- "title": "int32",
801
- "description": "Signed integer 32bit\nRange: -\u202D2147483648 … \u202D2147483647\u202C"
802
- },
803
- {
804
- "const": "int64",
805
- "title": "int64",
806
- "description": "Signed integer 64bit\nRange: -9.223e+15 … \u202D9.223e+15\nDLO natively supports s32 (a 'cell') only. Therefore s64\n- is implemented as binary buffer\n- u8[8] does not support maths"
807
- },
808
- {
809
- "const": "uint8",
810
- "title": "uint8",
811
- "description": "Unsigned integer 8bit\nRange: 0 … 255 (0xff)"
812
- },
813
- {
814
- "const": "uint16",
815
- "title": "uint16",
816
- "description": "Unsigned integer 16bit\nRange: 0 … 65535 (0xffff)"
817
- },
818
- {
819
- "const": "uint32",
820
- "title": "uint32",
821
- "description": "Unsigned integer 32bit\nRange: 0 … \u202D4294967295\u202C (0xffffffff)\nLimited support in DLO due to s32 cell size."
822
- },
823
- {
824
- "const": "float16",
825
- "title": "float16",
826
- "description": "Floating point 16bit\nRange: ±9.76e-4 … ±1.048e+6\n- half precision \n- 3 significant digits"
827
- },
828
- {
829
- "const": "float32",
830
- "title": "float32",
831
- "description": "Floating point 32bit\nRange: ±1.18e−38 … ±3.4e+38\n- single precision \n- approx. 7 significant digits"
832
- },
833
- {
834
- "const": "float64",
835
- "title": "float64",
836
- "description": "Floating point 64bit\nRange: ±2.23e−308 … ±1.80e+308\n- double precision \n- approx. 16 significant digits\nDLO natively supports f32 (a 'Float:cell') only. Therefore f64\n- is implemented as binary buffer\n- u8[8] does not support maths"
837
- },
838
- {
839
- "const": "binary",
840
- "title": "binary",
841
- "description": "Binary blob.\nPacks 4 bytes per 'cell'. Uses always a full multiple of 'cells' for storage."
842
- },
843
- {
844
- "const": "stamp32",
845
- "title": "stamp32",
846
- "description": "Timestamp UTC.\nResolution: 1 second\nSeconds since 1999-12-31 00:00:00 UTC"
847
- },
848
- {
849
- "const": "stamp40",
850
- "title": "stamp40",
851
- "description": "Timestamp UTC extended accuracy.\nResolution: 1/256 second\nSeconds since 1999-12-31 00:00:00 UTC"
852
- },
853
- {
854
- "const": "array",
855
- "title": "Array",
856
- "description": "Array of parameters. Requires 'length' and 'fields' properties."
857
- },
858
- {
859
- "const": "astring",
860
- "title": "astring",
861
- "description": "ANSI CP-1252 stored as 8bit ANSI.\nCharacter codes 0x01 … 0xFF are by default assigned to CP-1252 (0x00 is reserved for terminating zero).\nRequires the 'length' property."
862
- },
863
- {
864
- "const": "nstring",
865
- "title": "nstring",
866
- "description": "Named string type.\nRequires the 'length' property."
867
- },
868
- {
869
- "const": "cstring",
870
- "title": "cstring",
871
- "description": "ANSI with custom codepage stored as binary.\nRequires the 'length' property."
872
- },
873
- {
874
- "const": "wstring",
875
- "title": "wstring",
876
- "description": "Unicode utf-32 stored as utf-8.\nUse this type only if Unicode is required and your DLO routines insist on utf-32 encoded strings.\nRequires the 'length' property."
877
- },
878
- {
879
- "const": "ustring",
880
- "title": "ustring",
881
- "description": "Unicode utf-8 stored as utf-8.\nUse this type only if Unicode is required and your DLO routines (such as display drivers) are able to deal with utf-8 encoded strings.\nRequires the 'length' property."
882
- }
883
- ]
884
- },
885
- "userLevel": {
886
- "type": "string",
887
- "description": "User permission level. Ranges from UL1 (Customer operator) to UL7 (Administrator).",
888
- "markdownDescription": "User permission level.\n\n| Level | Role |\n|-------|------|\n| `UL1` | Customer operator |\n| `UL2` | Customer administrator |\n| `UL3` | Provider operator |\n| `UL4` | Provider administrator |\n| `UL6` | Rights administrator |\n| `UL7` | Administrator |\n| `UL8+` | Custom levels |",
889
- "anyOf": [
890
- {
891
- "const": "UL1",
892
- "title": "UL1 - Customer operator",
893
- "description": "Customer operator"
894
- },
895
- {
896
- "const": "UL2",
897
- "title": "UL2 - Customer administrator",
898
- "description": "Customer administrator"
899
- },
900
- {
901
- "const": "UL3",
902
- "title": "UL3 - Provider operator",
903
- "description": "Provider operator"
904
- },
905
- {
906
- "const": "UL4",
907
- "title": "UL4 - Provider administrator",
908
- "description": "Provider administrator"
909
- },
910
- {
911
- "const": "UL6",
912
- "title": "UL6 - Rights administrator",
913
- "description": "Rights administrator"
914
- },
915
- {
916
- "const": "UL7",
917
- "title": "UL7 - Administrator",
918
- "description": "Administrator"
919
- },
920
- {
921
- "pattern": "UL([7-9]|[1-9][0-9])",
922
- "patternErrorMessage": "Custom user level must match the pattern 'ULN' where N is 7 or higher (e.g. 'UL8', 'UL10').",
923
- "description": "Custom user level (UL7 or higher)"
924
- }
925
- ]
926
- },
927
- "configArrayDefinition": {
928
- "if": {
929
- "description": "Handle array definition",
930
- "properties": {
931
- "type": {
932
- "const": "array"
933
- }
934
- }
935
- },
936
- "then": {
937
- "properties": {
938
- "fields": {
939
- "$ref": "#/$defs/configurationFields"
940
- },
941
- "length": {
942
- "type": "number",
943
- "description": "Size of the array. Must be between 1 and 1024.",
944
- "markdownDescription": "Size of the array.\n\n**Range:** 1–1024",
945
- "minimum": 1,
946
- "inclusiveMaximum": 1024
947
- },
948
- "array": {
949
- "not": {},
950
- "errorMessage": "The 'array' property is not allowed when type is 'array'. Use 'length' to define the array size."
951
- },
952
- "title": {
953
- "not": {},
954
- "errorMessage": "The 'title' property is not allowed when type is 'array'."
955
- }
956
- },
957
- "required": ["length", "fields"],
958
- "errorMessage": {
959
- "required": {
960
- "length": "The 'length' property is required when type is 'array'. Specify the array size.",
961
- "fields": "The 'fields' property is required when type is 'array'. Define the array's sub-fields."
962
- }
963
- }
964
- },
965
- "else": {
966
- "properties": {
967
- "fields": {
968
- "not": {},
969
- "errorMessage": "The 'fields' property is only allowed when type is 'array'."
970
- }
971
- }
972
- }
973
- },
974
- "timeseriesArrayDefinition": {
975
- "if": {
976
- "description": "Handle array definition",
977
- "properties": {
978
- "type": {
979
- "const": "array"
980
- }
981
- }
982
- },
983
- "then": {
984
- "properties": {
985
- "fields": {
986
- "$ref": "#/$defs/timeseriesFields"
987
- },
988
- "length": {
989
- "type": "number",
990
- "description": "Size of the array. Must be between 1 and 1024.",
991
- "markdownDescription": "Size of the array.\n\n**Range:** 1–1024",
992
- "minimum": 1,
993
- "inclusiveMaximum": 1024
994
- },
995
- "array": {
996
- "not": {},
997
- "errorMessage": "The 'array' property is not allowed when type is 'array'. Use 'length' to define the array size."
998
- },
999
- "title": {
1000
- "not": {},
1001
- "errorMessage": "The 'title' property is not allowed when type is 'array'."
1002
- }
1003
- },
1004
- "required": ["length", "fields"],
1005
- "errorMessage": {
1006
- "required": {
1007
- "length": "The 'length' property is required when type is 'array'. Specify the array size.",
1008
- "fields": "The 'fields' property is required when type is 'array'. Define the array's sub-fields."
1009
- }
1010
- }
1011
- },
1012
- "else": {
1013
- "properties": {
1014
- "fields": {
1015
- "not": {},
1016
- "errorMessage": "The 'fields' property is only allowed when type is 'array'."
1017
- }
1018
- }
1019
- }
1020
- },
1021
- "decimalPlaces": {
1022
- "type": ["number", "string"],
1023
- "description": "Number of decimal places to show. Applies to POV and API. Only valid for numeric types.",
1024
- "markdownDescription": "Number of decimal places to show.\n\nApplies to POV and API. Only valid for numeric types.\n\nAccepts a number (≥ 0) or a relation link (`@container.field`).",
1025
- "minimum": 0,
1026
- "$ref": "#/$defs/relationLinkPattern"
1027
- },
1028
- "relationLinkPattern": {
1029
- "anyOf": [
1030
- {
1031
- "pattern": "^(@[a-zA-Z_][a-zA-Z0-9_]*\\.[a-zA-Z_][a-zA-Z0-9_]*(\\[[^\\]]+\\])?(\\.[a-zA-Z_][a-zA-Z0-9_]*)*|lib:[a-zA-Z0-9_-]+@[a-zA-Z_][a-zA-Z0-9_]*\\.[a-zA-Z_][a-zA-Z0-9_]*(\\[[^\\]]+\\])?(\\.[a-zA-Z_][a-zA-Z0-9_]*)*)$",
1032
- "patternErrorMessage": "Relation link must match the format '@container.field' or 'lib:library-name@container.field'. Optional array index '[index]' and nested paths are supported (e.g. '@setting.myField', '@state.data[0].value', 'lib:my-lib@setting.param')."
1033
- }
1034
- ]
1035
- },
1036
- "setPointRelationPattern": {
1037
- "anyOf": [
1038
- {
1039
- "pattern": "^(@[a-zA-Z_][a-zA-Z0-9_]*\\.[a-zA-Z_][a-zA-Z0-9_]*(\\[[^\\]]+\\])?(\\.[a-zA-Z_][a-zA-Z0-9_]*)*|lib:[a-zA-Z0-9_-]+@[a-zA-Z_][a-zA-Z0-9_]*\\.[a-zA-Z_][a-zA-Z0-9_]*(\\[[^\\]]+\\])?(\\.[a-zA-Z_][a-zA-Z0-9_]*)*)$",
1040
- "patternErrorMessage": "Set point relation must match the format '@container.field' or 'lib:library-name@container.field' (e.g. '@setting.targetTemperature')."
1041
- },
1042
- {
1043
- "const": "\"@setting.\"",
1044
- "description": "Relation link to container setting",
1045
- "title": "Relation link to container setting"
1046
- },
1047
- {
1048
- "const": "\"@command.\"",
1049
- "description": "Relation link to container control",
1050
- "title": "Relation link to container control"
1051
- }
1052
- ]
1053
- },
1054
- "chartAlarmWarn": {
1055
- "type": ["number", "string"],
1056
- "description": "The server uses this property to show the threshold in charts and gauges. Important: This does not activate any alarming. This must be done in the DLO.",
1057
- "markdownDescription": "The server uses this property to show the **threshold** in charts and gauges.\n\n⚠️ **Important:** This does not activate any alarming. Alarming must be implemented in the DLO.\n\nAccepts a number or a relation link (`@container.field`).",
1058
- "$ref": "#/$defs/relationLinkPattern"
1059
- }
1060
- }
1061
- }