homebridge-aqara
homebridge-aqara copied to clipboard
Plug Switch can't ON/OFF
hi,my firmware is 1.4.1_141.0141, and i success add V2 gateway to homekit , the Temperature,Humidity,Motion Sensor are working. but plug switch can't work. tap ON or OFF no status change. please help...
You need to write the gateway's password to config.json.
have you solved? I have the same issue, it is basically read only.
this is my .json file. I've tried with my password both uppercase and lowercase { "bridge": { "name": "Homebridge", "username": "CC:22:3D:E3:CE:30", "port": 51826, "pin": "031-45-154" },
"description": "This is an example configuration file with one fake accessory and one fake platform. You can use this as a template for creating your own configuration file containing devices you actually own.",
"platforms": [
{
"platform" : "yeelight",
"name":"yeelight",
"platform": "AqaraPlatform",
"sid": ["f0b4299ae9fe"],
"password": ["0F915A2F067743DF"]
}
]
}
@snOOrz i get right password to config.json
Hi guys, I also have the same issue with this firmware. All other sensors work as expected, but Plug Switch works only like read only. Password is correct. config.json here
{
"bridge": {
"name": "Homebridge",
"username": "CC:22:3D:E3:CE:30",
"port": 51826,
"pin": "031-45-154"
},
"platforms": [
{
"platform": "AqaraPlatform",
"sid": ["f0b429b3eeXX"],
"password": ["t8y3sk3ujq57f6XX"]
}]
}
What do wrong?
same here. fw 1.4.1_141.0141. can't turn on or off of switch.
I have the same issue with fw 1.4.1_141.0141. Plug state is read only, Any idea?
May I see your homebridge’s config.json?
On 10 Dec 2016, 15:44 +0800, superkam [email protected], wrote:
I have the same issue with fw 1.4.1_141.0141. Plug state is read only, Any idea?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/snOOrz/homebridge-aqara/issues/16#issuecomment-266187033, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ATm2YZmmWH5o5GrI_O9-eK32swRusjW7ks5rGlhdgaJpZM4K9ydP.
Here it is. Thank you~
{
"bridge": {
"name": "Homebridge",
"username": "B3:22:3D:E3:CE:30",
"port": 51826,
"pin": "610-00-126"
},
"platforms": [{
"platform": "yeelight",
"name": "yeelight"
}, {
"platform": "AqaraPlatform",
"name": "XiaoMi",
"sid": ["7073cbb34f01"],
"password": ["b7mbpgmx1r6vqkng"]
}]
}
The sid should be gateway's sid not the plugs.
2016年12月10日 下午6:06,"superkam" [email protected]写道:
Here it is. Thank you~
{ "bridge": { "name": "Homebridge", "username": "B3:22:3D:E3:CE:30", "port": 51826, "pin": "610-00-126" },
"platforms": [{ "platform": "yeelight", "name": "yeelight" }, { "platform": "AqaraPlatform", "name": "XiaoMi", "sid": ["7073cbb34f01"], "password": ["b7mbpgmx1r6vqkng"] }] }
— You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub https://github.com/snOOrz/homebridge-aqara/issues/16#issuecomment-266196422, or mute the thread https://github.com/notifications/unsubscribe-auth/ATm2YcX6lVxqszdKrCfiVenbaT3f75m3ks5rGnmXgaJpZM4K9ydP .
Same json and same problem for me, my json is shown a few posts above
@snOOrz The sid is indeed the gateway's, not the plug's.
OK. Is there “No password for xxx, please edit ~/.homebridge/config.json” in the output log? If no, that means the password is wrong, please check twice in your app or change to another password.
On 10 Dec 2016, 19:02 +0800, superkam [email protected], wrote:
@snOOrzhttps://github.com/snOOrz The sid is indeed the gateway's, not the plug's.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/snOOrz/homebridge-aqara/issues/16#issuecomment-266200277, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ATm2YXjqKnBwee57sNDW7jSqUt9STKXkks5rGobAgaJpZM4K9ydP.
Thank your for the tip. I'll try that.
On 10 Dec 2016, at 19:41, snOOrz [email protected] wrote:
OK. Is there “No password for xxx, please edit ~/.homebridge/config.json” in the output log? If no, that means the password is wrong, please check twice in your app or change to another password.
On 10 Dec 2016, 19:02 +0800, superkam [email protected], wrote:
@snOOrzhttps://github.com/snOOrz The sid is indeed the gateway's, not the plug's.
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/snOOrz/homebridge-aqara/issues/16#issuecomment-266200277, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ATm2YXjqKnBwee57sNDW7jSqUt9STKXkks5rGobAgaJpZM4K9ydP. — You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.
Hi @snOOrz,
I've tried what you suggested. but the plug still doesn't work, here is the error log, would you mind to have a look ? Thank you.
Sat, 10 Dec 2016 12:40:37 GMT Accessory [Homebridge] Setting Characteristic "On" to value 0
[12/10/2016, 8:40:37 PM] [XiaoMi] No password for 158d000114b610, please edit ~/.homebridge/config.json
Sat, 10 Dec 2016 12:40:37 GMT EventedHTTPServer [::ffff:10.0.1.2] Muting event '7.9' notification for this connection since it originated here.
Sat, 10 Dec 2016 12:40:37 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP Response is finished
Sat, 10 Dec 2016 12:40:37 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP request: /characteristics
Sat, 10 Dec 2016 12:40:37 GMT HAPServer [B5:23:3E:E3:CE:30] HAP Request: PUT /characteristics
Sat, 10 Dec 2016 12:40:37 GMT Accessory [Homebridge] Processing characteristic set: [{"aid":7,"iid":9,"value":1}]
Sat, 10 Dec 2016 12:40:37 GMT Accessory [Homebridge] Setting Characteristic "On" to value 1
Sat, 10 Dec 2016 12:40:37 GMT EventedHTTPServer [::ffff:10.0.1.2] Muting event '7.9' notification for this connection since it originated here.
Sat, 10 Dec 2016 12:40:37 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP Response is finished
Sat, 10 Dec 2016 12:41:05 GMT EventedHTTPServer [::ffff:10.0.1.2] Sending HTTP event '4.9' with data: {"characteristics":[{"aid":4,"iid":9,"value":false}]}
Sat, 10 Dec 2016 12:41:43 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP request: /characteristics
Sat, 10 Dec 2016 12:41:43 GMT HAPServer [B5:23:3E:E3:CE:30] HAP Request: PUT /characteristics
Sat, 10 Dec 2016 12:41:43 GMT Accessory [Homebridge] Processing characteristic set: [{"aid":7,"iid":9,"value":0}]
Sat, 10 Dec 2016 12:41:43 GMT Accessory [Homebridge] Setting Characteristic "On" to value 0
[12/10/2016, 8:41:43 PM] [XiaoMi] No password for 158d000114b610, please edit ~/.homebridge/config.json
Sat, 10 Dec 2016 12:41:43 GMT EventedHTTPServer [::ffff:10.0.1.2] Muting event '7.9' notification for this connection since it originated here.
Sat, 10 Dec 2016 12:41:43 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP Response is finished
...
And I found the property "Outlet In Use" is always "No" in Home app (Long press the plug icon then tap "Details"). Does it mean something?
I just published a new version of homebridge-aqara to npm. The new version will output the gatway’s sid instead of the devices’s sid.
Can you update and paste the log again?
On 10 Dec 2016, 20:45 +0800, superkam [email protected], wrote:
Hi @snOOrzhttps://github.com/snOOrz,
I've tried what you suggested. but the plug still doesn't work, here is errors, would you mind to have a look ? Thank you.
Sat, 10 Dec 2016 12:40:37 GMT Accessory [Homebridge] Setting Characteristic "On" to value 0 [12/10/2016, 8:40:37 PM] [XiaoMi] No password for 158d000114b610, please edit ~/.homebridge/config.json Sat, 10 Dec 2016 12:40:37 GMT EventedHTTPServer [::ffff:10.0.1.2] Muting event '7.9' notification for this connection since it originated here. Sat, 10 Dec 2016 12:40:37 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP Response is finished Sat, 10 Dec 2016 12:40:37 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP request: /characteristics Sat, 10 Dec 2016 12:40:37 GMT HAPServer [B5:23:3E:E3:CE:30] HAP Request: PUT /characteristics Sat, 10 Dec 2016 12:40:37 GMT Accessory [Homebridge] Processing characteristic set: [{"aid":7,"iid":9,"value":1}] Sat, 10 Dec 2016 12:40:37 GMT Accessory [Homebridge] Setting Characteristic "On" to value 1 Sat, 10 Dec 2016 12:40:37 GMT EventedHTTPServer [::ffff:10.0.1.2] Muting event '7.9' notification for this connection since it originated here. Sat, 10 Dec 2016 12:40:37 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP Response is finished Sat, 10 Dec 2016 12:41:05 GMT EventedHTTPServer [::ffff:10.0.1.2] Sending HTTP event '4.9' with data: {"characteristics":[{"aid":4,"iid":9,"value":false}]} Sat, 10 Dec 2016 12:41:43 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP request: /characteristics Sat, 10 Dec 2016 12:41:43 GMT HAPServer [B5:23:3E:E3:CE:30] HAP Request: PUT /characteristics Sat, 10 Dec 2016 12:41:43 GMT Accessory [Homebridge] Processing characteristic set: [{"aid":7,"iid":9,"value":0}] Sat, 10 Dec 2016 12:41:43 GMT Accessory [Homebridge] Setting Characteristic "On" to value 0 [12/10/2016, 8:41:43 PM] [XiaoMi] No password for 158d000114b610, please edit ~/.homebridge/config.json Sat, 10 Dec 2016 12:41:43 GMT EventedHTTPServer [::ffff:10.0.1.2] Muting event '7.9' notification for this connection since it originated here. Sat, 10 Dec 2016 12:41:43 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP Response is finished ...
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/snOOrz/homebridge-aqara/issues/16#issuecomment-266205398, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ATm2YYHypJFZp04jZU_i4zqYHzuC7PaEks5rGp7TgaJpZM4K9ydP.
Here it is:
Sat, 10 Dec 2016 13:56:16 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP request: /characteristics
Sat, 10 Dec 2016 13:56:16 GMT HAPServer [B5:23:3E:E3:CE:30] HAP Request: PUT /characteristics
Sat, 10 Dec 2016 13:56:16 GMT Accessory [Homebridge] Processing characteristic set: [{"aid":7,"iid":9,"value":1}]
Sat, 10 Dec 2016 13:56:16 GMT Accessory [Homebridge] Setting Characteristic "On" to value 1
Sat, 10 Dec 2016 13:56:16 GMT EventedHTTPServer [::ffff:10.0.1.35] Sending HTTP event '7.9' with data: {"characteristics":[{"aid":7,"iid":9,"value":1}]}
Sat, 10 Dec 2016 13:56:16 GMT EventedHTTPServer [::ffff:10.0.1.2] Muting event '7.9' notification for this connection since it originated here.
Sat, 10 Dec 2016 13:56:16 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP Response is finished
Sat, 10 Dec 2016 13:56:21 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP request: /characteristics
Sat, 10 Dec 2016 13:56:21 GMT HAPServer [B5:23:3E:E3:CE:30] HAP Request: PUT /characteristics
Sat, 10 Dec 2016 13:56:21 GMT Accessory [Homebridge] Processing characteristic set: [{"aid":7,"iid":9,"value":0}]
Sat, 10 Dec 2016 13:56:21 GMT Accessory [Homebridge] Setting Characteristic "On" to value 0
[12/10/2016, 9:56:21 PM] [XiaoMi] No password for gateway f0b429cbe4d3, please edit ~/.homebridge/config.json
Sat, 10 Dec 2016 13:56:21 GMT EventedHTTPServer [::ffff:10.0.1.35] Sending HTTP event '7.9' with data: {"characteristics":[{"aid":7,"iid":9,"value":0}]}
Sat, 10 Dec 2016 13:56:21 GMT EventedHTTPServer [::ffff:10.0.1.2] Muting event '7.9' notification for this connection since it originated here.
Sat, 10 Dec 2016 13:56:21 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP Response is finished
Your gatway’s sid is f0b429cbe4d3, but in your config.json it’s 7073cbb34f01. Please modify your config.json, it should work.
On 10 Dec 2016, 21:57 +0800, superkam [email protected], wrote:
Here it is:
Sat, 10 Dec 2016 13:56:16 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP request: /characteristics Sat, 10 Dec 2016 13:56:16 GMT HAPServer [B5:23:3E:E3:CE:30] HAP Request: PUT /characteristics Sat, 10 Dec 2016 13:56:16 GMT Accessory [Homebridge] Processing characteristic set: [{"aid":7,"iid":9,"value":1}] Sat, 10 Dec 2016 13:56:16 GMT Accessory [Homebridge] Setting Characteristic "On" to value 1 Sat, 10 Dec 2016 13:56:16 GMT EventedHTTPServer [::ffff:10.0.1.35] Sending HTTP event '7.9' with data: {"characteristics":[{"aid":7,"iid":9,"value":1}]} Sat, 10 Dec 2016 13:56:16 GMT EventedHTTPServer [::ffff:10.0.1.2] Muting event '7.9' notification for this connection since it originated here. Sat, 10 Dec 2016 13:56:16 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP Response is finished Sat, 10 Dec 2016 13:56:21 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP request: /characteristics Sat, 10 Dec 2016 13:56:21 GMT HAPServer [B5:23:3E:E3:CE:30] HAP Request: PUT /characteristics Sat, 10 Dec 2016 13:56:21 GMT Accessory [Homebridge] Processing characteristic set: [{"aid":7,"iid":9,"value":0}] Sat, 10 Dec 2016 13:56:21 GMT Accessory [Homebridge] Setting Characteristic "On" to value 0 [12/10/2016, 9:56:21 PM] [XiaoMi] No password for gateway f0b429cbe4d3, please edit ~/.homebridge/config.json Sat, 10 Dec 2016 13:56:21 GMT EventedHTTPServer [::ffff:10.0.1.35] Sending HTTP event '7.9' with data: {"characteristics":[{"aid":7,"iid":9,"value":0}]} Sat, 10 Dec 2016 13:56:21 GMT EventedHTTPServer [::ffff:10.0.1.2] Muting event '7.9' notification for this connection since it originated here. Sat, 10 Dec 2016 13:56:21 GMT EventedHTTPServer [::ffff:10.0.1.2] HTTP Response is finished
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/snOOrz/homebridge-aqara/issues/16#issuecomment-266210373, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ATm2YegYbWIi8SEQDys69qCkNQCCgCkhks5rGq_igaJpZM4K9ydP.
Bravo! @snOOrz, I use the gateway id to replace sid in config.json. It works!
When got the information of gateway from Android smartphone. I used the wrong mac address from property "gw_mac", the right one should be property "mac". You are the hero, snOOrz!
You are welcome.
On 10 Dec 2016, 22:12 +0800, superkam [email protected], wrote:
When got the information of gateway from Android smartphone. I used the wrong mac address from property "gw_mac", the right one should be property "mac". You are the hero, snOOrz!
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHubhttps://github.com/snOOrz/homebridge-aqara/issues/16#issuecomment-266211419, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ATm2YZH2ikeY30946bHyI5yhRBRc5Gptks5rGrNZgaJpZM4K9ydP.
Hi SnOOrz
here is my log can you please help me? thanks a lot f
[12/11/2016, 9:00:38 AM] [homebridge-yeelight.yeelight] DidFinishLaunching [12/11/2016, 9:00:38 AM] [XiaoMi] Aqara server is listening on port 9898. EventedHTTPServer Server listening on port 51826 +0ms [12/11/2016, 9:00:38 AM] Homebridge is running on port 51826. add to multicast group listen on 0.0.0.0 no did or loc found! [12/11/2016, 9:00:38 AM] [homebridge-yeelight.yeelight] cached accessory: 0x0000000002be18b4 [12/11/2016, 9:00:38 AM] [homebridge-yeelight.yeelight] cached accessory: 0x0000000002dfc439 already in device list! already in device list! connect ok! [12/11/2016, 9:00:38 AM] [homebridge-yeelight.yeelight] accesseory reachable [12/11/2016, 9:00:38 AM] [homebridge-yeelight.yeelight] dev connected 0x0000000002be18b4 true connect ok! [12/11/2016, 9:00:38 AM] [homebridge-yeelight.yeelight] accesseory reachable [12/11/2016, 9:00:38 AM] [homebridge-yeelight.yeelight] dev connected 0x0000000002dfc439 true [12/11/2016, 9:00:40 AM] [XiaoMi] warn plug(sid:158d00010c57ec):status's state is unknown, ignore it.
and this is my config { "bridge": { "name": "Homebridge", "username": "CC:22:3D:E3:CE:30", "port": 51826, "pin": "031-45-154" },
"description": "This is an example configuration file with one fake accessory and one fake platform. You can use this as a template for creating your own configuration file containing devices you actually own.",
"platforms": [
{
"platform" : "yeelight",
"name":"yeelight",
"platform": "AqaraPlatform",
"name": "XiaoMi",
"sid": ["f0b4299ae9fe"],
"password": ["0f915a2f067743df"]
}
]
}
@sballoz 正确的格式: { "bridge": { "name": "Homebridge", "username": "CC:22:3D:E3:CE:30", "port": 51826, "pin": "031-45-154" },
"description": "This is an example configuration file with one fake accessory and one fake platform. You can use this as a template for creating your own configuration file containing devices you actually own.",
"platforms": [{
"platform": "yeelight",
"name": "yeelight"
}, {
"platform": "AqaraPlatform",
"sid": ["f0b4299ae9fe"],
"password": ["0F915A2F067743DF"]
}]
}
@disist 试试这个: { "bridge": { "name": "Homebridge", "username": "CC:22:3D:E3:CE:30", "port": 51826, "pin": "031-45-154" },
"platforms": [{
"platform": "AqaraPlatform",
"sid": ["f0b429b3eeXX"],
"password": ["t8y3sk3ujq57f6XX"]
}]
}
thanks. I am on holiday for 2 weeks but I will try as soon as I get home
Hi @easycoco I try to find difference between my previous comment, but i can't, could you please point what exactly need to change. Thank you.
same here. fw 1.4.1_141.0141. can't turn on or off of switch.
{
"platform": "AqaraPlatform",
"name": "Aqara Platform",
"sid": [
"286c07f08b1b"
],
"password": [
"174e0a83d1d1486e"
]
}
EventedHTTPServer [::ffff:192.168.2.23] HTTP request: /characteristics +4s
HAPServer [05:FC:F1:ED:B6:3E] HAP Request: PUT /characteristics +1ms
Accessory [Homebridge] Processing characteristic set: [{"aid":4,"iid":9,"value":1}] +3ms
Accessory [Homebridge] Setting Characteristic "On" to value 1 +1ms
EventedHTTPServer [::ffff:192.168.2.23] Muting event '4.9' notification for this connection since it originated here. +4ms
EventedHTTPServer [::ffff:192.168.2.23] HTTP Response is finished +1ms
some more debug info
EventedHTTPServer [::ffff:192.168.2.23] HTTP request: /characteristics +1m
HAPServer [05:FC:F1:ED:B6:3E] HAP Request: PUT /characteristics +2ms
Accessory [Homebridge] Processing characteristic set: [{"aid":4,"iid":9,"value":1}] +3ms
Accessory [Homebridge] Setting Characteristic "On" to value 1 +2ms
[7/16/2017, 1:01:40 AM] [Aqara Platform] platform: [object Object]
[7/16/2017, 1:01:40 AM] [Aqara Platform] cipher gateway 286c07f08b1b, device 158d00012dd324, password 174e0a83d1d1486e
[7/16/2017, 1:01:40 AM] [Aqara Platform] sendCommand {"cmd":"write","model":"plug","sid":"158d00012dd324","data":"{\"status\":\"on\", \"key\": \"90d1dbd75cfd37dfe21526b48f225937\"}"}
[7/16/2017, 1:01:40 AM] [Aqara Platform] send {"cmd":"write","model":"plug","sid":"158d00012dd324","data":"{\"status\":\"on\", \"key\": \"90d1dbd75cfd37dfe21526b48f225937\"}"} to 192.168.2.30:9898
EventedHTTPServer [::ffff:192.168.2.23] Muting event '4.9' notification for this connection since it originated here. +37ms
EventedHTTPServer [::ffff:192.168.2.23] HTTP Response is finished +2ms
[7/16/2017, 1:01:40 AM] [Aqara Platform] recv {"cmd":"write_ack","sid":"158d00012dd324","data":"{\"error\":\"Invalid key\"}"}(79 bytes) from client 192.168.2.30:9898
[7/16/2017, 1:01:40 AM] [Aqara Platform] Recv { cmd: 'write_ack',
sid: '158d00012dd324',
data: '{"error":"Invalid key"}' }
I solved by change the password to upper case.......