cflurin / xiaomi-mqtt

A Bridge between the Xiaomi Mi Smart Home Gateway and the Mqtt broker.
Apache License 2.0
50 stars 14 forks source link

model: "ctrl_neutral1" #4

Closed iChUdY closed 6 years ago

iChUdY commented 6 years ago

Hi,

my wall switch on topic xiaomi/from: { "cmd":"read_ack", "model":"ctrl_neutral1", "sid":"158d0001828xxx", "short_id":30115, "data":{ "voltage":3300, "channel_0":"off" } }

I will try control this device to xiaomi/to/write by: {"cmd":"write","model":"ctrl_neutral1","sid":"158d0001828xxx","short_id":30115,"data":{"channel_0":"on"}}

and always return msg: "{"cmd":"xm","msg":"invalid JSON format >[object Object]<"}"

Control gateway LED by this metod works fine: {"cmd":"write","model":"gateway","sid":"7811dcaf3xxx","data":{"rgb":"ffff0000"}}

cflurin commented 6 years ago

Hi, I don't own this device but I tried to implement the write-cmd. Please install the latest version 0.3.5 and let me know whether it works.

iChUdY commented 6 years ago

Great. Now works fine 👌🏻

Thx

{"cmd":"write","model":"ctrl_neutral1","sid":"158d0001828xxx","short_id":30115,"data":{"channel_0":"on"}}

{"cmd":"write","model":"ctrl_neutral1","sid":"158d0001828xxx","short_id":30115,"data":{"channel_0":"off"}}