diff --git a/package.json b/package.json index 9587e89..00ae102 100644 --- a/package.json +++ b/package.json @@ -9,7 +9,7 @@ "name": "chameleon-ultra.js", "repository": "git@github.com:taichunmin/chameleon-ultra.js.git", "unpkg": "dist/iife/index.min.js", - "version": "0.1.17", + "version": "0.1.18", "bugs": { "url": "https://github.com/taichunmin/chameleon-ultra.js/issues" }, diff --git a/src/ChameleonUltra.ts b/src/ChameleonUltra.ts index ec2b23e..c5e6d81 100644 --- a/src/ChameleonUltra.ts +++ b/src/ChameleonUltra.ts @@ -7,7 +7,7 @@ import * as Decoder from './ResponseDecoder' const READ_DEFAULT_TIMEOUT = 5e3 const START_OF_FRAME = new Buffer(2).writeUInt16BE(0x11EF) -const VERSION_SUPPORTED = { gte: '1.0', lt: '2.0' } +const VERSION_SUPPORTED = { gte: '1.0', lt: '2.0' } as const /** * The core library of "chameleon-ultra.js". The instance of this class must use exactly one adapter plugin to communication to ChameleonUltra. @@ -62,14 +62,9 @@ export class ChameleonUltra { supportedCmds: Set = new Set() /** - * The firmware version of device. + * The supported version of SDK. */ - appVersion?: string - - /** - * The git version of firmware. - */ - gitVersion?: string + static VERSION_SUPPORTED = VERSION_SUPPORTED /** * Create a new instance of ChameleonUltra. @@ -227,8 +222,6 @@ export class ChameleonUltra { try { // clean up this.supportedCmds.clear() - this.appVersion = undefined - this.gitVersion = undefined // close port this.rxSink?.controller.abort(err)