Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

miiocli plug does not show the USB power status #344

Closed
ghost opened this issue Jun 18, 2018 · 2 comments
Closed

miiocli plug does not show the USB power status #344

ghost opened this issue Jun 18, 2018 · 2 comments
Assignees

Comments

@ghost
Copy link

ghost commented Jun 18, 2018

Description

miiocli plug does not display the USB power state for Xiaomi Smart Socket enhanced version (with two USB charging ports).

Steps to reproduce

Run:

miiocli plug --token <PLUG_TOKEN> --ip 192.168.1.100 status

Actual output

Power: True
USB Power: None
Temperature: 41 °C
Load power: None
WiFi LED: None

Expected output

Power: True
USB Power: True
Temperature: 41 °C
Load power: True
WiFi LED: True

Notes:

Also missing outputs for:

  • Load power
  • WiFi LED

miiocli plug usb_off/usb_on work as expected

Plug info

Output of miiocli plug --ip 192.168.1.100 --token <TOKEN> info:

Model: chuangmi.plug.v3
Hardware version: ESP8266
Firmware version: 1.3.0_92

Xiaomi Smart Socket enhanced with 2 USB charging ports:
https://www.aliexpress.com/item/Xiaomi-socket-pro-home-WIFI-multifunction-USB-remote-control-home-electricity-statistics-Xiaomi-smart-socket-enhanced/32863730667.html

xiaomi-smart-plug-specs

xiaomi-smart-plug-sku0

@syssi
Copy link
Collaborator

syssi commented Jun 20, 2018

The background: The ChuangmiPlug implementation supports four hardware versions of the device. If you use the library you can select a specific model. The miiocli uses a version without USB ports as default at the moment and the model cannot be changed.

For a good UX some issues should be fixed:

  1. Make the device model selectable (--model chuangmi.plug.v3)
  2. Auto-detect the device model on demand (--model auto)
  3. List only supported properties at the status output (currently all known properties are listed)

@syssi syssi self-assigned this Jun 20, 2018
@ghost
Copy link
Author

ghost commented Jun 23, 2018

@syssi:

Thanks for the hint! I realized that for my model the correct command is miiocli plugv3 and not miiocli plug as I tried originally.

With plugv3 everything works fine:

# miiocli plugv3

Power: True
USB Power: True
Temperature: 39 °C
Load power: 14.0
WiFi LED: True

The output above is as expected, so this ticket can be closed, unless you see the need to improve the invocation syntax or update the documentation.

@syssi syssi closed this as completed Jun 23, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant