Exported Consts
This commit is contained in:
parent
e0a6694bd9
commit
ac9d17da92
1
hub.ts
1
hub.ts
@ -6,7 +6,6 @@ import { Port } from "./port";
|
||||
import * as Consts from "./consts";
|
||||
|
||||
import Debug = require("debug");
|
||||
import { METHODS } from "http";
|
||||
const debug = Debug("hub");
|
||||
|
||||
|
||||
|
4
lpf2.ts
4
lpf2.ts
@ -4,6 +4,8 @@ import { Hub } from "./hub";
|
||||
import { LPF2Hub } from "./lpf2hub";
|
||||
import { WeDo2Hub } from "./wedo2hub";
|
||||
|
||||
import * as Consts from "./consts";
|
||||
|
||||
import { EventEmitter} from "events";
|
||||
|
||||
import Debug = require("debug");
|
||||
@ -135,4 +137,4 @@ export class LPF2 extends EventEmitter {
|
||||
}
|
||||
|
||||
export default LPF2;
|
||||
export { Hub, WeDo2Hub, LPF2Hub };
|
||||
export { Hub, WeDo2Hub, LPF2Hub, Consts };
|
||||
|
@ -17,7 +17,7 @@ export class WeDo2Hub extends Hub {
|
||||
|
||||
|
||||
public static IsWeDo2Hub (peripheral: Peripheral) {
|
||||
return (peripheral.advertisement.localName === Consts.BLENames.WEDO2_SMART_HUB_NAME && peripheral.advertisement.serviceUuids.indexOf(Consts.BLEServices.WEDO2_SMART_HUB) >= 0);
|
||||
return (peripheral.advertisement.serviceUuids.indexOf(Consts.BLEServices.WEDO2_SMART_HUB) >= 0);
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user