diff --git a/index.d.ts.map b/index.d.ts.map index d92f159..18ce9ab 100644 --- a/index.d.ts.map +++ b/index.d.ts.map @@ -1 +1 @@ -{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AA6EA,eAAO,MAAM,KAAK,OAAQ,OAAO,SAAmB,CAAA;AAEpD,eAAO,MAAM,cAAc,uBAA8B,YAAY,KAAK,IAAI,kBAM7E,CAAA;AAED,eAAO,MAAM,aAAa,qBAKzB,CAAA;AAGD,oBAAY,YAAY,GAAG;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAA;CACf,CAAC"} \ No newline at end of file +{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["index.ts"],"names":[],"mappings":"AA+EA,eAAO,MAAM,KAAK,OAAQ,OAAO,SAAmB,CAAA;AAEpD,eAAO,MAAM,cAAc,uBAA8B,YAAY,KAAK,IAAI,kBAM7E,CAAA;AAED,eAAO,MAAM,aAAa,qBAKzB,CAAA;AAGD,oBAAY,YAAY,GAAG;IACvB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,KAAK,EAAE,MAAM,CAAA;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,CAAA;CACf,CAAC"} \ No newline at end of file diff --git a/index.js b/index.js index 0a18ec8..9718c00 100644 --- a/index.js +++ b/index.js @@ -5,16 +5,18 @@ var __importDefault = (this && this.__importDefault) || function (mod) { Object.defineProperty(exports, "__esModule", { value: true }); exports.stopDiscovery = exports.startDiscovery = exports.debug = void 0; const noble_1 = __importDefault(require("@abandonware/noble")); +process.env.NOBLE_REPORT_ALL_HCI_EVENTS = '1'; // needed on Linux including Raspberry Pi const h5075_uuid = "ec88"; const h5075_uuid_rev = "88ec"; const govee_bt_mac = "a4-c1-38"; +const govee_bt_mac_alt = "a4:c1:38"; let DEBUG = false; const validPeripheral = (peripheral) => { const { address, advertisement } = peripheral; if (!advertisement || !advertisement.manufacturerData) { return false; } - if (address && !address.toLowerCase().startsWith(govee_bt_mac)) { + if (address && (!address.toLowerCase().startsWith(govee_bt_mac) && !address.toLowerCase().startsWith(govee_bt_mac_alt))) { return false; } const hex = advertisement.manufacturerData.toString('hex'); diff --git a/package.json b/package.json index 71ae10c..a8a16b9 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "govee-bt-client", - "version": "1.0.1", + "version": "1.0.3", "description": "Govee H5075 Thermometer Hygrometer Bluetooth Client", "main": "index.js", "types": "index.d.ts",