homebridge-irobot
Version:
A homebridge plugin for controlling iRobot devices
67 lines (66 loc) • 2.63 kB
TypeScript
import { PlatformAccessory, CharacteristicValue } from 'homebridge';
import { iRobotPlatform } from './platform';
import { Robot } from './getRoombas';
/**
* Platform Accessory
* An instance of this class is created for each accessory your platform registers
* Each accessory may expose multiple services of different service types.
*/
export declare class iRobotPlatformAccessory {
private readonly platform;
private readonly accessory;
private readonly device;
private service;
private battery;
private stuck;
private binFilter;
private binContact;
private binMotion;
private shutdown;
private binConfig;
private roomba;
private active;
private lastStatus;
private lastCommandStatus;
private state;
private binfull;
private batteryStatus;
private stuckStatus;
private roomByRoom;
constructor(platform: iRobotPlatform, accessory: PlatformAccessory, device: Robot);
configureRoomba(): Promise<void>;
updateRoombaState(data: any): void;
updateMap(lastCommand: any): void;
updateRooms(): void;
getHomekitActive(cleanMissionStatus: any): boolean;
getEveInactive(cleanMissionStatus: any): boolean;
/**
* Handle the "GET" requests from HomeKit
* These are sent when HomeKit wants to know the current state of the accessory, for example, checking if a Light bulb is on.
*
* GET requests should return as fast as possbile. A long delay here will result in
* HomeKit being unresponsive and a bad user experience in general.
*
* If your device takes time to respond you should update the status of your device
* asynchronously instead using the `updateCharacteristic` method instead.
* @example
* this.service.updateCharacteristic(this.platform.Characteristic.On, true)
*/
get(): Promise<CharacteristicValue>;
getState(): Promise<CharacteristicValue>;
getBinfull(): Promise<CharacteristicValue>;
getBinfullBoolean(): Promise<CharacteristicValue>;
getBatteryLevel(): Promise<CharacteristicValue>;
getBatteryStatus(): Promise<CharacteristicValue>;
getChargeState(): Promise<CharacteristicValue>;
getMode(): Promise<CharacteristicValue>;
getStuck(): Promise<CharacteristicValue>;
identify(): Promise<void>;
/**
* Handle "SET" requests from HomeKit
* These are sent when the user changes the state of an accessory, for example, changing the Brightness
*/
set(value: CharacteristicValue): Promise<void>;
setMode(value: CharacteristicValue): Promise<void>;
}
//# sourceMappingURL=platformAccessory.d.ts.map