@sensebox/sketch-templater
Advanced tools
Comparing version 1.6.1 to 1.7.0-beta
@@ -5,8 +5,5 @@ # node-sketch-templater Changelog | ||
## v1.6.1 | ||
- Add Wire.begin() to BME680 setup and replace Serial.println with DEBUG | ||
## v1.7.0-beta | ||
- Add TTN Transformer to insert and transform keys | ||
## v1.6.0 | ||
- Use bsec library for BME680 | ||
## v1.5.5 | ||
@@ -13,0 +10,0 @@ - Added delay to BME gas reading in lora sketch |
{ | ||
"name": "@sensebox/sketch-templater", | ||
"version": "1.6.1", | ||
"version": "1.7.0-beta", | ||
"description": "nodejs library to create senseBox Arduino Sketches", | ||
@@ -5,0 +5,0 @@ "main": "src/index.js", |
@@ -63,3 +63,6 @@ 'use strict'; | ||
ssid, | ||
password | ||
password, | ||
devEui, | ||
appEui, | ||
appKey | ||
}) { | ||
@@ -78,3 +81,6 @@ return Object.assign( | ||
PASSWORD: password, | ||
SENSORS: sensors | ||
SENSORS: sensors, | ||
DEV_EUI: devEui, | ||
APP_EUI: appEui, | ||
APP_KEY: appKey | ||
} | ||
@@ -81,0 +87,0 @@ ); |
@@ -55,3 +55,17 @@ 'use strict'; | ||
return Number(portNumber) + Number(offset); | ||
}, | ||
transformTTNID(eui, lsb = false) { | ||
if (eui === undefined || (eui.length !== 16 && eui.length !== 32)) { | ||
return '{ }'; | ||
} | ||
// split eui into chunks of two | ||
let chunks = eui.match(/.{1,2}/g); | ||
if (lsb) { | ||
chunks = chunks.reverse(); | ||
} | ||
return `{${chunks.map(c => ` 0x${c}`)} }`; | ||
} | ||
}; |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
257
99702
2