From 46c856a8656365b3d790e996f9be7384ea07354e Mon Sep 17 00:00:00 2001 From: Andreas Holstenson Date: Sat, 22 Apr 2017 08:52:52 +0200 Subject: [PATCH] Adding more documentation about missing devices --- README.md | 3 ++- docs/devices/README.md | 27 ++--------------------- docs/missing-devices.md | 48 +++++++++++++++++++++++++++++++++++++++++ 3 files changed, 52 insertions(+), 26 deletions(-) create mode 100644 docs/missing-devices.md diff --git a/README.md b/README.md index f326062..5d4c95f 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,8 @@ This library requires at least Node 6.0.0. The intent of this library is to support all miIO-compatible devices and to provide an easy to use API for them. The library maps specific device models to -generic device types to simplify interacting with them. +generic device types with well defined capabilities to simplify interacting with +them. Currently supported devices are: diff --git a/docs/devices/README.md b/docs/devices/README.md index c61e899..11308f7 100644 --- a/docs/devices/README.md +++ b/docs/devices/README.md @@ -38,7 +38,7 @@ column can be one of the following: If your device: -* Is not in this list, it might still be a miIO-device and at least have generic support. See the next section for details about how to find out if that is the case. +* Is not in this list, it might still be a miIO-device and at least have generic support. See [Missing devices](../missing-devices.md) for information about how to find out. * Needs a manual token and the table says it should not, something has probably changed in the firmware, please open an issue so the table can be adjusted. * Is marked as Untested you can help by testing the implementation is this library and opening an issue with information about the result. @@ -87,7 +87,7 @@ Id | Type | Capabilities `chuangmi.plug.v1` | `switch` | `power-channels` | Yes | Good | `chuangmi.plug.v2` | `switch` | `power-channels` | Yes | Good | `qmi.powerstrip.v1` | `switch` | `power-channels` | Yes | Untested | -`zimi.powerstrip.v1` | `switch` | `power-channels` | Yes | Untested | +`zimi.powerstrip.v2` | `switch` | `power-channels` | Yes | Untested | `rockrobo.vaccum.v1` | `vacuum` | | No | Basic | DND, timers and mapping features are not supported. `lumi.gateway.v1` | `generic` | | Yes | Generic | API used to access sub devices not supported. `lumi.gateway.v2` | `gateway` | | Yes | Basic | @@ -96,29 +96,6 @@ Id | Type | Capabilities `yeelink.light.mono1` | `light` | `power`, `color:temperature` | No | Good | `yeelink.light.color1` | `light` | `power`, `color:temperature`, `color:full` | No | Untested | Setting colors has not been tested. -## Finding devices on your network - -In certain cases your device might not be listed under models but still be a -miIO-device, for example if it's a new device or something that no one using -the library has tested yet. - -The command line application can help with discovery of devices. Get started by -install the command line application: - -`npm install -g miio` - -Run the app in discovery mode to list devices on your network: - -`miio --discover` - -This will start outputting all of the devices found, with their address, -identifiers, models and tokens (if found). If your device can be supported it -will show up in this list. - -If the device shows up feel free to open an issue about supporting the device. -Be sure to include the name of the device model and the model id output by the -discover command. - ## Generic devices The `generic` type is used when a device is of an unknown model. All properties diff --git a/docs/missing-devices.md b/docs/missing-devices.md new file mode 100644 index 0000000..37ef408 --- /dev/null +++ b/docs/missing-devices.md @@ -0,0 +1,48 @@ +# Missing devices + +This library does not yet support all Mi Home devices that speak the +miIO protocol. + +## Can my device be supported? + +The command line application can help with discovering if a device speaks the +miIO protocol. Get started by installing the command line application: + +`npm install -g miio` + +Run the app in discovery mode to list devices on your network: + +`miio --discover` + +This will start outputting all of the devices found, with their address, +identifiers, models and tokens (if found). If your device can be supported it +will show up in this list. You might need to figure out if the IP of your device +to be able to find it easily. + +If the device shows up feel free to open an issue about supporting the device. +Include this information: + +* The name of the device model - such Mi Air Purifier or Mi Smart Power Strip 2 +* The model id from the output +* If the token for the device displayed N/A or a hex value (don't include the hex value) + +## Implementing a device + +If a device can be supported the next step is to figure out what commands the +device supports. You can help by either forking this repository and +implementing the device or by opening an issue with information about what +the device seems to support. + +In certain cases its possible to find documentation or someone that has already +done most of the work figuring out what commands a device supports. + +Most often this involves more advanced steps like packet capturing via a local +Android emulator. Details about that can be found under [Protocol and commands](protocol.md) +if you feel up for it. + +## Donating devices + +If you really want a device to be supported it's possible to contact the author +of this library to discuss donating a device. Be aware that this should is not +a guarantee that this library will support the device as sometimes it might +not be possible to figure out how to support a device.