Skip to content

Commit

Permalink
Merge pull request #77 from artem-barysh-dev/rewrite-converters
Browse files Browse the repository at this point in the history
Change debugMode to (debugFailures, debugAll, debugAllUntil)
  • Loading branch information
ViacheslavKlimov authored Nov 28, 2024
2 parents 4936145 + a9a9bfa commit 4cae99c
Show file tree
Hide file tree
Showing 178 changed files with 534 additions and 178 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "ChirpStack Uplink Decoder for Bosch parking lot sensor",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "Loriot Uplink Decoder for Bosch parking lot sensor",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": "// Decode an uplink message from a buffer\n// payload - array of bytes\n// metadata - key/value object\n\n/** Decoder **/\n\n// decode payload to string\nvar payloadStr = decodeToString(payload);\n\n// decode payload to JSON\n// var data = decodeToJson(payload);\n\nvar deviceName = 'Device A';\nvar deviceType = 'thermostat';\nvar customerName = 'Customer C';\nvar groupName = 'thermostat devices';\nvar manufacturer = 'Example corporation';\n// use assetName and assetType instead of deviceName and deviceType\n// to automatically create assets instead of devices.\n// var assetName = 'Asset A';\n// var assetType = 'building';\n\n// Result object with device/asset attributes/telemetry data\nvar result = {\n// Use deviceName and deviceType or assetName and assetType, but not both.\n deviceName: deviceName,\n deviceType: deviceType,\n// assetName: assetName,\n// assetType: assetType,\n// customerName: customerName,\n groupName: groupName,\n attributes: {\n model: 'Model A',\n serialNumber: 'SN111',\n integrationName: metadata['integrationName'],\n manufacturer: manufacturer\n },\n telemetry: {\n temperature: 42,\n humidity: 80,\n rawData: payloadStr\n }\n};\n\n/** Helper functions **/\n\nfunction decodeToString(payload) {\n return String.fromCharCode.apply(String, payload);\n}\n\nfunction decodeToJson(payload) {\n // covert payload to string.\n var str = decodeToString(payload);\n\n // parse string to JSON\n var data = JSON.parse(str);\n return data;\n}\n\nreturn result;",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Community Uplink Decoder for Bosch parking lot sensor",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Industries Uplink Decoder for Bosch parking lot sensor",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2/ChirpStack/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "ChirpStack Uplink Decoder for Elsys ERS2 Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2/LORIOT/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "Loriot Uplink Decoder for Elsys ERS2 Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": "// Decode an uplink message from a buffer\n// payload - array of bytes\n// metadata - key/value object\n\n/** Decoder **/\n\n// decode payload to string\nvar payloadStr = decodeToString(payload);\n\n// decode payload to JSON\n// var data = decodeToJson(payload);\n\nvar deviceName = 'Device A';\nvar deviceType = 'thermostat';\nvar customerName = 'Customer C';\nvar groupName = 'thermostat devices';\nvar manufacturer = 'Example corporation';\n// use assetName and assetType instead of deviceName and deviceType\n// to automatically create assets instead of devices.\n// var assetName = 'Asset A';\n// var assetType = 'building';\n\n// Result object with device/asset attributes/telemetry data\nvar result = {\n// Use deviceName and deviceType or assetName and assetType, but not both.\n deviceName: deviceName,\n deviceType: deviceType,\n// assetName: assetName,\n// assetType: assetType,\n// customerName: customerName,\n groupName: groupName,\n attributes: {\n model: 'Model A',\n serialNumber: 'SN111',\n integrationName: metadata['integrationName'],\n manufacturer: manufacturer\n },\n telemetry: {\n temperature: 42,\n humidity: 80,\n rawData: payloadStr\n }\n};\n\n/** Helper functions **/\n\nfunction decodeToString(payload) {\n return String.fromCharCode.apply(String, payload);\n}\n\nfunction decodeToJson(payload) {\n // covert payload to string.\n var str = decodeToString(payload);\n\n // parse string to JSON\n var data = JSON.parse(str);\n return data;\n}\n\nreturn result;",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Community Uplink Decoder for Elsys ERS2 Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Industries Uplink Decoder for Elsys ERS2 Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2_CO2/ChirpStack/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "ChirpStack Uplink Decoder for Elsys ERS2 С02 Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2_CO2/LORIOT/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "Loriot Uplink Decoder for Elsys ERS2 C02 Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": "// Decode an uplink message from a buffer\n// payload - array of bytes\n// metadata - key/value object\n\n/** Decoder **/\n\n// decode payload to string\nvar payloadStr = decodeToString(payload);\n\n// decode payload to JSON\n// var data = decodeToJson(payload);\n\nvar deviceName = 'Device A';\nvar deviceType = 'thermostat';\nvar customerName = 'Customer C';\nvar groupName = 'thermostat devices';\nvar manufacturer = 'Example corporation';\n// use assetName and assetType instead of deviceName and deviceType\n// to automatically create assets instead of devices.\n// var assetName = 'Asset A';\n// var assetType = 'building';\n\n// Result object with device/asset attributes/telemetry data\nvar result = {\n// Use deviceName and deviceType or assetName and assetType, but not both.\n deviceName: deviceName,\n deviceType: deviceType,\n// assetName: assetName,\n// assetType: assetType,\n// customerName: customerName,\n groupName: groupName,\n attributes: {\n model: 'Model A',\n serialNumber: 'SN111',\n integrationName: metadata['integrationName'],\n manufacturer: manufacturer\n },\n telemetry: {\n temperature: 42,\n humidity: 80,\n rawData: payloadStr\n }\n};\n\n/** Helper functions **/\n\nfunction decodeToString(payload) {\n return String.fromCharCode.apply(String, payload);\n}\n\nfunction decodeToJson(payload) {\n // covert payload to string.\n var str = decodeToString(payload);\n\n // parse string to JSON\n var data = JSON.parse(str);\n return data;\n}\n\nreturn result;",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Community Uplink Decoder for Elsys ERS2 C02 Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Industries Uplink Decoder for Elsys ERS2 CO2 Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2_CO2_Lite/ChirpStack/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "ChirpStack Uplink Decoder for Elsys ERS2 С02 Lite Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2_CO2_Lite/LORIOT/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "Loriot Uplink Decoder for Elsys ERS2 C02 Lite Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": "// Decode an uplink message from a buffer\n// payload - array of bytes\n// metadata - key/value object\n\n/** Decoder **/\n\n// decode payload to string\nvar payloadStr = decodeToString(payload);\n\n// decode payload to JSON\n// var data = decodeToJson(payload);\n\nvar deviceName = 'Device A';\nvar deviceType = 'thermostat';\nvar customerName = 'Customer C';\nvar groupName = 'thermostat devices';\nvar manufacturer = 'Example corporation';\n// use assetName and assetType instead of deviceName and deviceType\n// to automatically create assets instead of devices.\n// var assetName = 'Asset A';\n// var assetType = 'building';\n\n// Result object with device/asset attributes/telemetry data\nvar result = {\n// Use deviceName and deviceType or assetName and assetType, but not both.\n deviceName: deviceName,\n deviceType: deviceType,\n// assetName: assetName,\n// assetType: assetType,\n// customerName: customerName,\n groupName: groupName,\n attributes: {\n model: 'Model A',\n serialNumber: 'SN111',\n integrationName: metadata['integrationName'],\n manufacturer: manufacturer\n },\n telemetry: {\n temperature: 42,\n humidity: 80,\n rawData: payloadStr\n }\n};\n\n/** Helper functions **/\n\nfunction decodeToString(payload) {\n return String.fromCharCode.apply(String, payload);\n}\n\nfunction decodeToJson(payload) {\n // covert payload to string.\n var str = decodeToString(payload);\n\n // parse string to JSON\n var data = JSON.parse(str);\n return data;\n}\n\nreturn result;",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Community Uplink Decoder for Elsys ERS2 C02 Lite Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Industries Uplink Decoder for Elsys ERS2 CO2 Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2_Lite/ChirpStack/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "ChirpStack Uplink Decoder for Elsys ERS2 Lite Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2_Lite/LORIOT/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "Loriot Uplink Decoder for Elsys ERS2 Lite Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": "// Decode an uplink message from a buffer\n// payload - array of bytes\n// metadata - key/value object\n\n/** Decoder **/\n\n// decode payload to string\nvar payloadStr = decodeToString(payload);\n\n// decode payload to JSON\n// var data = decodeToJson(payload);\n\nvar deviceName = 'Device A';\nvar deviceType = 'thermostat';\nvar customerName = 'Customer C';\nvar groupName = 'thermostat devices';\nvar manufacturer = 'Example corporation';\n// use assetName and assetType instead of deviceName and deviceType\n// to automatically create assets instead of devices.\n// var assetName = 'Asset A';\n// var assetType = 'building';\n\n// Result object with device/asset attributes/telemetry data\nvar result = {\n// Use deviceName and deviceType or assetName and assetType, but not both.\n deviceName: deviceName,\n deviceType: deviceType,\n// assetName: assetName,\n// assetType: assetType,\n// customerName: customerName,\n groupName: groupName,\n attributes: {\n model: 'Model A',\n serialNumber: 'SN111',\n integrationName: metadata['integrationName'],\n manufacturer: manufacturer\n },\n telemetry: {\n temperature: 42,\n humidity: 80,\n rawData: payloadStr\n }\n};\n\n/** Helper functions **/\n\nfunction decodeToString(payload) {\n return String.fromCharCode.apply(String, payload);\n}\n\nfunction decodeToJson(payload) {\n // covert payload to string.\n var str = decodeToString(payload);\n\n // parse string to JSON\n var data = JSON.parse(str);\n return data;\n}\n\nreturn result;",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Community Uplink Decoder for Elsys ERS2 Lite Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Industries Uplink Decoder for Elsys ERS2 Lite Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2_Sound/ChirpStack/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "ChirpStack Uplink Decoder for Elsys ERS2 Sound Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2_Sound/LORIOT/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "Loriot Uplink Decoder for Elsys ERS2 Sound Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": "// Decode an uplink message from a buffer\n// payload - array of bytes\n// metadata - key/value object\n\n/** Decoder **/\n\n// decode payload to string\nvar payloadStr = decodeToString(payload);\n\n// decode payload to JSON\n// var data = decodeToJson(payload);\n\nvar deviceName = 'Device A';\nvar deviceType = 'thermostat';\nvar customerName = 'Customer C';\nvar groupName = 'thermostat devices';\nvar manufacturer = 'Example corporation';\n// use assetName and assetType instead of deviceName and deviceType\n// to automatically create assets instead of devices.\n// var assetName = 'Asset A';\n// var assetType = 'building';\n\n// Result object with device/asset attributes/telemetry data\nvar result = {\n// Use deviceName and deviceType or assetName and assetType, but not both.\n deviceName: deviceName,\n deviceType: deviceType,\n// assetName: assetName,\n// assetType: assetType,\n// customerName: customerName,\n groupName: groupName,\n attributes: {\n model: 'Model A',\n serialNumber: 'SN111',\n integrationName: metadata['integrationName'],\n manufacturer: manufacturer\n },\n telemetry: {\n temperature: 42,\n humidity: 80,\n rawData: payloadStr\n }\n};\n\n/** Helper functions **/\n\nfunction decodeToString(payload) {\n return String.fromCharCode.apply(String, payload);\n}\n\nfunction decodeToJson(payload) {\n // covert payload to string.\n var str = decodeToString(payload);\n\n // parse string to JSON\n var data = JSON.parse(str);\n return data;\n}\n\nreturn result;",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Community Uplink Decoder for Elsys ERS2 Sound Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Industries Uplink Decoder for Elsys ERS2 Sound Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2_VOC/ChirpStack/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "ChirpStack Uplink Decoder for Elsys ERS2 VOC Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Elsys/ERS2_VOC/LORIOT/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "Loriot Uplink Decoder for Elsys ERS2 VOC Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": "// Decode an uplink message from a buffer\n// payload - array of bytes\n// metadata - key/value object\n\n/** Decoder **/\n\n// decode payload to string\nvar payloadStr = decodeToString(payload);\n\n// decode payload to JSON\n// var data = decodeToJson(payload);\n\nvar deviceName = 'Device A';\nvar deviceType = 'thermostat';\nvar customerName = 'Customer C';\nvar groupName = 'thermostat devices';\nvar manufacturer = 'Example corporation';\n// use assetName and assetType instead of deviceName and deviceType\n// to automatically create assets instead of devices.\n// var assetName = 'Asset A';\n// var assetType = 'building';\n\n// Result object with device/asset attributes/telemetry data\nvar result = {\n// Use deviceName and deviceType or assetName and assetType, but not both.\n deviceName: deviceName,\n deviceType: deviceType,\n// assetName: assetName,\n// assetType: assetType,\n// customerName: customerName,\n groupName: groupName,\n attributes: {\n model: 'Model A',\n serialNumber: 'SN111',\n integrationName: metadata['integrationName'],\n manufacturer: manufacturer\n },\n telemetry: {\n temperature: 42,\n humidity: 80,\n rawData: payloadStr\n }\n};\n\n/** Helper functions **/\n\nfunction decodeToString(payload) {\n return String.fromCharCode.apply(String, payload);\n}\n\nfunction decodeToJson(payload) {\n // covert payload to string.\n var str = decodeToString(payload);\n\n // parse string to JSON\n var data = JSON.parse(str);\n return data;\n}\n\nreturn result;",
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Community Uplink Decoder for Elsys ERS2 VOC Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "The Things Stack Industries Uplink Decoder for Elsys ERS2 VOC Device",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
4 changes: 3 additions & 1 deletion VENDORS/Milesight/AM102/ChirpStack/uplink/converter.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
{
"name": "ChirpStack uplink converter for Milesight AM102",
"type": "UPLINK",
"debugMode": true,
"debugFailures" : false,
"debugAll" : true,
"debugAllUntil": 0,
"configuration": {
"scriptLang": "TBEL",
"decoder": null,
Expand Down
Loading

0 comments on commit 4cae99c

Please sign in to comment.