Skip to content

Commit

Permalink
v2.0.2 (#223)
Browse files Browse the repository at this point in the history
## [2.0.2](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v2.0.2) (2024-02-09)

### What's Changed
- Fix various 2.0.0 issues [#224](#224), Thanks [@dnicolson](https://github.com/dnicolson)
- Code Cleanup [#225](#225) [#226](#226), Thanks [@dnicolson](https://github.com/dnicolson)
- Housekeeping and update dependencies

**Full Changelog**: v2.0.1...v2.0.2
  • Loading branch information
donavanbecker authored Feb 10, 2024
1 parent 3877620 commit 678103e
Show file tree
Hide file tree
Showing 19 changed files with 707 additions and 670 deletions.
51 changes: 30 additions & 21 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,19 @@

All notable changes to this project will be documented in this file. This project uses [Semantic Versioning](https://semver.org/)

## [2.0.2](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v2.0.2) (2024-02-09)

### What's Changed
- Fix various 2.0.0 issues [#224](https://github.com/OpenWonderLabs/node-switchbot/pull/224), Thanks [@dnicolson](https://github.com/dnicolson)
- Code Cleanup [#225](https://github.com/OpenWonderLabs/node-switchbot/pull/225) [#226](https://github.com/OpenWonderLabs/node-switchbot/pull/226), Thanks [@dnicolson](https://github.com/dnicolson)
- Housekeeping and update dependencies

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v2.0.1...v2.0.2

## [2.0.1](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v2.0.1) (2024-02-06)

### What's Changed
- Fix async constructor, Thanks [@dnicolson](https://github.com/dnicolson) [#229](https://github.com/OpenWonderLabs/node-switchbot/pull/220)
- Fix async constructor [#220](https://github.com/OpenWonderLabs/node-switchbot/pull/220), Thanks [@dnicolson](https://github.com/dnicolson)
- Housekeeping and update dependencies

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v2.0.0...v2.0.1
Expand All @@ -14,17 +23,17 @@ All notable changes to this project will be documented in this file. This projec

### What's Changed
- Rewrite into Typescript and Convert CommonJS to ES Module
- Fix Linting, Thanks [@dnicolson](https://github.com/dnicolson) [#216](https://github.com/OpenWonderLabs/node-switchbot/pull/216)
- Code Cleaup, Thanks [@dnicolson](https://github.com/dnicolson) [#217](https://github.com/OpenWonderLabs/node-switchbot/pull/217)
- Fix Linting [#216](https://github.com/OpenWonderLabs/node-switchbot/pull/216), Thanks [@dnicolson](https://github.com/dnicolson)
- Code Cleaup [#217](https://github.com/OpenWonderLabs/node-switchbot/pull/217), Thanks [@dnicolson](https://github.com/dnicolson)
- Housekeeping and update dependencies

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v1.10.0...v2.0.0

## [1.10.0](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v1.10.0) (2024-01-05)

### What's Changed
- Fix reversed bot state reporting, Thanks [@grelca](https://github.com/grelca) [#207](https://github.com/OpenWonderLabs/node-switchbot/pull/207)
- Add support for Curtain 3, Thanks [@tsia](https://github.com/tsia) [#209](https://github.com/OpenWonderLabs/node-switchbot/pull/209)
- Fix reversed bot state reporting [#207](https://github.com/OpenWonderLabs/node-switchbot/pull/207), Thanks [@grelca](https://github.com/grelca)
- Add support for Curtain 3 [#209](https://github.com/OpenWonderLabs/node-switchbot/pull/209), Thanks [@tsia](https://github.com/tsia)
- Housekeeping and update dependencies

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v1.9.1...v1.10.0
Expand All @@ -39,28 +48,28 @@ All notable changes to this project will be documented in this file. This projec
## [1.9.0](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v1.9.0) (2023-09-16)

### What's Changed
- Add support for the Indoor/Outdoor Thermo-Hygrometer (WoIOSensorTH), Thanks [@moritzmhmk](https://github.com/moritzmhmk) [#200](https://github.com/OpenWonderLabs/node-switchbot/pull/200)
- Handle noble not being "poweredOn" on init, Thanks [@moritzmhmk](https://github.com/moritzmhmk) [#199](https://github.com/OpenWonderLabs/node-switchbot/pull/199)
- Add support for the Indoor/Outdoor Thermo-Hygrometer (WoIOSensorTH) [#200](https://github.com/OpenWonderLabs/node-switchbot/pull/200), Thanks [@moritzmhmk](https://github.com/moritzmhmk)
- Handle noble not being "poweredOn" on init [#199](https://github.com/OpenWonderLabs/node-switchbot/pull/199), Thanks [@moritzmhmk](https://github.com/moritzmhmk)
- Housekeeping and update dependencies

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v1.8.2...v1.9.0

## [1.8.2](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v1.8.2) (2023-07-25)

### What's Changed
- Added Lint Script, Thanks [@dnicolson](https://github.com/dnicolson) [#195](https://github.com/OpenWonderLabs/node-switchbot/pull/195)
- Fixed a Linting Issues, Thanks [@dnicolson](https://github.com/dnicolson) [#196](https://github.com/OpenWonderLabs/node-switchbot/pull/196)
- Fixed 'TypeError: Assignment to constant variable', Thanks [@banboobee](https://github.com/banboobee) [#194](https://github.com/OpenWonderLabs/node-switchbot/pull/194)
- Fix issue of re-assigning to constant for Temperature, Thanks [@gravity-addiction](https://github.com/gravity-addiction) [#191](https://github.com/OpenWonderLabs/node-switchbot/pull/191)
- Added Lint Script [#195](https://github.com/OpenWonderLabs/node-switchbot/pull/195), Thanks [@dnicolson](https://github.com/dnicolson)
- Fixed a Linting Issues [#196](https://github.com/OpenWonderLabs/node-switchbot/pull/196), Thanks [@dnicolson](https://github.com/dnicolson)
- Fixed 'TypeError: Assignment to constant variable' [#194](https://github.com/OpenWonderLabs/node-switchbot/pull/194), Thanks [@banboobee](https://github.com/banboobee)
- Fix issue of re-assigning to constant for Temperature [#191](https://github.com/OpenWonderLabs/node-switchbot/pull/191), Thanks [@gravity-addiction](https://github.com/gravity-addiction)
- Housekeeping and update dependencies

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v1.8.1...v1.8.2

## [1.8.1](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v1.8.1) (2023-04-08)

### What's Changed
- Use const keyword for immutable variables, Thanks [@dnicolson](https://github.com/dnicolson/). [#184](https://github.com/OpenWonderLabs/node-switchbot/pull/184)
- Use Error object for promise rejection, Thanks [@dnicolson](https://github.com/dnicolson/). [#181](https://github.com/OpenWonderLabs/node-switchbot/pull/181)
- Use const keyword for immutable variables [#184](https://github.com/OpenWonderLabs/node-switchbot/pull/184), Thanks [@dnicolson](https://github.com/dnicolson/)
- Use Error object for promise rejection [#181](https://github.com/OpenWonderLabs/node-switchbot/pull/181), Thanks [@dnicolson](https://github.com/dnicolson/)
- Housekeeping and update dependencies

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v1.8.0...v1.8.1
Expand All @@ -70,7 +79,7 @@ All notable changes to this project will be documented in this file. This projec
### What's Changed

- Add Support for BlindTilt (Read Only)
- Use Error object for promise rejection, Thanks [@dnicolson](https://github.com/dnicolson/). [#181](https://github.com/OpenWonderLabs/node-switchbot/pull/181)
- Use Error object for promise rejection [#181](https://github.com/OpenWonderLabs/node-switchbot/pull/181), Thanks [@dnicolson](https://github.com/dnicolson/)
- Housekeeping and update dependencies

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v1.7.3...v1.8.0
Expand All @@ -79,7 +88,7 @@ All notable changes to this project will be documented in this file. This projec

### What's Changed

- Improve error handling, Thanks [@dnicolson](https://github.com/dnicolson/). [#175](https://github.com/OpenWonderLabs/node-switchbot/pull/175)
- Improve error handling [#175](https://github.com/OpenWonderLabs/node-switchbot/pull/175), Thanks [@dnicolson](https://github.com/dnicolson/)
- Housekeeping and update dependencies

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v1.7.2...v1.7.3
Expand Down Expand Up @@ -275,40 +284,40 @@ All notable changes to this project will be documented in this file. This projec

### What's Changed

- Modify Curtain's action command to support group and running mode. (Thanks to [@SwitchBot-Wonderlabs](https://github.com/OpenWonderLabs/node-switchbot/pull/7/))
- Modify Curtain's action command to support group and running mode [#7](https://github.com/OpenWonderLabs/node-switchbot/pull/7), Thanks [@SwitchBot-Wonderlabs](https://github.com/SwitchBot-Wonderlabs)

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v0.1.0...v0.2.0

## [0.1.0](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v0.1.0) (2020-10-28)

### What's Changed

- Added support for SwitchBot Curtain. (Thanks to [@SwitchBot-Wonderlabs](https://github.com/OpenWonderLabs/node-switchbot/pull/6/))
- Added support for running on the Raspberry Pi Zero W. (Thanks to [@zizi4n5](https://github.com/OpenWonderLabs/node-switchbot/pull/5))
- Added support for SwitchBot Curtain [#6](https://github.com/OpenWonderLabs/node-switchbot/pull/6), Thanks [@SwitchBot-Wonderlabs](https://github.com/SwitchBot-Wonderlabs)
- Added support for running on the Raspberry Pi Zero W [#5](https://github.com/OpenWonderLabs/node-switchbot/pull/5), Thanks [@Szizi4n5](https://github.com/zizi4n5)

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v0.0.5...v0.1.0

## [0.0.5](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v0.0.5) (2020-02-19)

### What's Changed

- Improved the stability of discovering the BLE characteristics. (Thanks to [@dnicolson](https://github.com/OpenWonderLabs/node-switchbot/issues/3))
- Improved the stability of discovering the BLE characteristics [#3](https://github.com/OpenWonderLabs/node-switchbot/pull/3), Thanks [@dnicolson](https://github.com/dnicolson)

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v0.0.4...v0.0.5

## [0.0.4](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v0.0.4) (2020-02-11)

### What's Changed

- Fixed the bug that temperature value lower than 0 degC could not be handled. (Thanks to [@musimasami](https://github.com/OpenWonderLabs/node-switchbot/issues/2))
- Fixed the bug that temperature value lower than 0 degC could not be handled [#2](https://github.com/OpenWonderLabs/node-switchbot/pull/2), Thanks [@musimasami](https://github.com/musimasami)

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v0.0.3...v0.0.4

## [0.0.3](https://github.com/OpenWonderLabs/node-switchbot/releases/tag/v0.0.3) (2020-02-10)

### What's Changed

- Now the characteristic UUID `0x2a00` (Device Name) is not mandatory. Some models of Bot don't seem to support the characteristic. (Thanks to [@dnicolson](https://github.com/OpenWonderLabs/node-switchbot/issues/1))
- Now the characteristic UUID `0x2a00` (Device Name) is not mandatory. Some models of Bot don't seem to support the characteristic [#3](https://github.com/OpenWonderLabs/node-switchbot/pull/1), Thanks [@dnicolson](https://github.com/dnicolson)
- Fixed the bug that the `turnOn()` method returns an error if the "Press mode" is selected on the Bot.

**Full Changelog**: https://github.com/OpenWonderLabs/node-switchbot/compare/v0.0.2...v0.0.3
Expand Down
15 changes: 7 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ Monitoring the advertising packets, you can find your devices and know the lates
```Typescript
// Load the node-switchbot and get a `Switchbot` constructor object
import { SwitchBot } from 'node-switchbot';
// Create an `Switchbot` object
// Create a `Switchbot` object
const switchbot = new SwitchBot();

(async () => {
Expand All @@ -138,7 +138,7 @@ The [`startScan()`](#startscan-method) and [`wait()`](#Switchbot-wait-method) me
```Typescript
// Load the node-switchbot and get a `Switchbot` constructor object
const Switchbot = require("node-switchbot");
// Create an `Switchbot` object
// Create a `Switchbot` object
const switchbot = new Switchbot();

// Start to monitor advertisement packets
Expand Down Expand Up @@ -214,7 +214,7 @@ This sample discovers a Bot (WoHand), then put the Bot's arm down, finally put i
```Typescript
// Load the node-switchbot and get a `Switchbot` constructor object
import { SwitchBot } from 'node-switchbot';
// Create an `Switchbot` object
// Create a `Switchbot` object
const switchbot = new SwitchBot();

(async () => {
Expand Down Expand Up @@ -249,7 +249,7 @@ In order to use the node-switchbot, you have to load the node-switchbot module a
import { SwitchBot } from 'node-switchbot';
```

You can get an `SwitchBot` constructor from the code above. Then you have to create an `SwitchBot` object from the `SwitchBot` constructor as follows:
You can get an `SwitchBot` constructor from the code above. Then you have to create a `SwitchBot` object from the `SwitchBot` constructor as follows:

```typescript
const switchbot = new SwitchBot();
Expand Down Expand Up @@ -303,9 +303,8 @@ If you want a quick response, you can set the `quick` property to `true`.

```Typescript
switchbot.discover({
duration: 5000,
quick: true
});
duration: 5000,
quick: true
}).then((device_list) => {
// Do something...
}).catch((error) => {
Expand Down Expand Up @@ -749,7 +748,7 @@ Actually, the `WoCurtain` is an object inherited from the [`SwitchbotDevice`](#S

### `open()` method

The `open()` method sends a open command to the Curtain. This method returns a `Promise` object. Nothing will be passed to the `resove()`.
The `open()` method sends an open command to the Curtain. This method returns a `Promise` object. Nothing will be passed to the `resove()`.

If no connection is established with the device, this method automatically establishes a connection with the device, then finally closes the connection. You don't have to call the [`connect()`](#SwitchbotDevice-connect-method) method in advance.

Expand Down
18 changes: 9 additions & 9 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "node-switchbot",
"version": "2.0.1",
"version": "2.0.2",
"description": "The node-switchbot is a Node.js module which allows you to control your Switchbot Devices through Bluetooth (BLE).",
"homepage": "https://github.com/OpenWonderLabs/node-switchbot",
"author": "OpenWonderLabs (https://github.com/OpenWonderLabs)",
Expand Down Expand Up @@ -42,7 +42,7 @@
"@abandonware/bluetooth-hci-socket": "^0.5.3-10"
},
"devDependencies": {
"@types/node": "^20.11.16",
"@types/node": "^20.11.17",
"@typescript-eslint/eslint-plugin": "^6.21.0",
"@typescript-eslint/parser": "^6.21.0",
"eslint": "^8.56.0",
Expand Down
Loading

0 comments on commit 678103e

Please sign in to comment.