diff --git a/package-lock.json b/package-lock.json index b729f4f..9bceac4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,15 +1,15 @@ { "name": "homebridge-teslemetry", + "version": "0.1.0", "lockfileVersion": 3, "requires": true, - "version": "0.1.0", "packages": { "": { "name": "homebridge-teslemetry", - "license": "Apache-2.0", "version": "0.1.0", + "license": "Apache-2.0", "dependencies": { - "tesla-fleet-api": "^0.0.18" + "tesla-fleet-api": "^0.1.0" }, "devDependencies": { "@types/node": "^20.12.13", @@ -3139,9 +3139,9 @@ } }, "node_modules/tesla-fleet-api": { - "version": "0.0.18", - "resolved": "https://registry.npmjs.org/tesla-fleet-api/-/tesla-fleet-api-0.0.18.tgz", - "integrity": "sha512-0ibleIbNTzc5uzU7KUCJyPpk3jxUj7NrIBBcOychkerz07e6gMHQMlLzjARO+y3aNegEM7j9wIMlUq6FOZAAUA==" + "version": "0.1.0", + "resolved": "https://registry.npmjs.org/tesla-fleet-api/-/tesla-fleet-api-0.1.0.tgz", + "integrity": "sha512-suFNaiYrO/4DUSYvbjej6mbpuU6rBQ2NAd1PnMLgddBqVpWsSJAHeovBfEkm0GR7Yldga79p4ZBT4v3/6NQ/qQ==" }, "node_modules/text-table": { "version": "0.2.0", diff --git a/package.json b/package.json index 0498221..b9be0b1 100644 --- a/package.json +++ b/package.json @@ -39,6 +39,6 @@ "typescript": "^5.4.5" }, "dependencies": { - "tesla-fleet-api": "^0.0.18" + "tesla-fleet-api": "^0.1.0" } } diff --git a/src/vehicle-services/battery.ts b/src/vehicle-services/battery.ts index 29631c5..cbb0451 100644 --- a/src/vehicle-services/battery.ts +++ b/src/vehicle-services/battery.ts @@ -7,15 +7,12 @@ export class BatteryService extends BaseService { const batteryLevel = this.service .getCharacteristic(this.parent.platform.Characteristic.BatteryLevel); - //.onGet(this.getLevel.bind(this)); const chargingState = this.service .getCharacteristic(this.parent.platform.Characteristic.ChargingState); - //.onGet(this.getChargingState.bind(this)); const lowBattery = this.service .getCharacteristic(this.parent.platform.Characteristic.StatusLowBattery); - //.onGet(this.getLowBattery.bind(this)); this.parent.emitter.on("vehicle_data", (data) => { batteryLevel.updateValue(this.getLevel(data)); diff --git a/src/vehicle-services/chargecurrent.ts b/src/vehicle-services/chargecurrent.ts index 7439bfd..df8233d 100644 --- a/src/vehicle-services/chargecurrent.ts +++ b/src/vehicle-services/chargecurrent.ts @@ -13,11 +13,9 @@ export class ChargeCurrentService extends BaseService { const on = this.service .getCharacteristic(this.parent.platform.Characteristic.On); - //.onGet(this.getOn.bind(this)); const level = this.service .getCharacteristic(this.parent.platform.Characteristic.Brightness) - //.onGet(this.getLevel.bind(this)) .onSet(debounce((value) => this.setLevel(value, level), 3000)); this.parent.emitter.on("vehicle_data", (data) => { diff --git a/src/vehicle-services/chargeport.ts b/src/vehicle-services/chargeport.ts index fb9c639..80c6383 100644 --- a/src/vehicle-services/chargeport.ts +++ b/src/vehicle-services/chargeport.ts @@ -1,4 +1,3 @@ -import { Characteristic, CharacteristicValue } from "homebridge"; import { VehicleAccessory } from "../vehicle.js"; import { BaseService } from "./base.js"; diff --git a/src/vehicle-services/climate.ts b/src/vehicle-services/climate.ts index 72f3688..ff7cd7d 100644 --- a/src/vehicle-services/climate.ts +++ b/src/vehicle-services/climate.ts @@ -1,6 +1,6 @@ // https://developers.homebridge.io/#/service/Thermostat -import { Characteristic, CharacteristicValue } from "homebridge"; +import { CharacteristicValue } from "homebridge"; import { VehicleAccessory } from "../vehicle.js"; import { BaseService } from "./base.js"; diff --git a/src/vehicle-services/door.ts b/src/vehicle-services/door.ts index 6e7bc9b..3b8d321 100644 --- a/src/vehicle-services/door.ts +++ b/src/vehicle-services/door.ts @@ -1,6 +1,5 @@ //https://developers.homebridge.io/#/service/Door -import { Characteristic, CharacteristicValue } from "homebridge"; import { VehicleAccessory } from "../vehicle.js"; import { BaseService } from "./base.js"; diff --git a/src/vehicle-services/lock.ts b/src/vehicle-services/lock.ts index dca224a..ca2f7b7 100644 --- a/src/vehicle-services/lock.ts +++ b/src/vehicle-services/lock.ts @@ -1,4 +1,3 @@ -import { Characteristic, CharacteristicValue } from "homebridge"; import { VehicleAccessory } from "../vehicle.js"; import { BaseService } from "./base.js"; diff --git a/src/vehicle-services/windows.ts b/src/vehicle-services/windows.ts index e911355..fd69038 100644 --- a/src/vehicle-services/windows.ts +++ b/src/vehicle-services/windows.ts @@ -10,7 +10,6 @@ export class WindowService extends BaseService { const currentPosition = this.service .getCharacteristic(this.parent.platform.Characteristic.CurrentPosition); - //.onGet(this.getPosition.bind(this)); /*const positionState = this.service .getCharacteristic(this.parent.platform.Characteristic.PositionState) @@ -18,7 +17,6 @@ export class WindowService extends BaseService { const targetPosition = this.service .getCharacteristic(this.parent.platform.Characteristic.TargetPosition) - //.onGet(this.getPosition.bind(this)) .onSet((value) => this.setPosition(value, targetPosition)); this.parent.emitter.on("vehicle_data", (data) => {