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

Salus SP600 not detected at all for pairing #2240

Closed
gausie opened this issue Oct 31, 2019 · 20 comments
Closed

Salus SP600 not detected at all for pairing #2240

gausie opened this issue Oct 31, 2019 · 20 comments

Comments

@gausie
Copy link
Contributor

gausie commented Oct 31, 2019

Bug Report

What happened

Using hassio-zigbee2mqtt (edge), while other Zigbee devices will connect, the SP600 doesn't register in any way and will not pair. I have tried the various reset states for the SP600, holding the button as you plug it in to trigger the three colour reset, and holding the button down for 10 seconds to unpair.

What did you expect to happen

The SP600 to pair with zigbee2mqtt!

How to reproduce it (minimal and precise)

Set permit_join to true and restart zigbee2mqtt, plug in an SP600 next to the CC2531. Wait!

Debug Info

Debug information
-----
-----
{
  "data_path": "/share/zigbee2mqtt",
  "devices": "devices.yaml",
  "groups": "groups.yaml",
  "homeassistant": true,
  "permit_join": true,
  "mqtt": {
    "base_topic": "zigbee2mqtt",
    "server": "mqtt://core-mosquitto:1883",
    "user": "mqtt",
    "password": "mqtt"
  },
  "serial": {
    "port": "/dev/serial/by-id/usb-Texas_Instruments_TI_CC2531_USB_CDC___0X00124B000BE8A09E-if00"
  },
  "advanced": {
    "pan_id": 6754,
    "channel": 11,
    "network_key": [
      1,
      3,
      5,
      7,
      9,
      11,
      13,
      15,
      0,
      2,
      4,
      6,
      8,
      10,
      12,
      13
    ],
    "availability_blacklist": []
  },
  "ban": [],
  "whitelist": [],
  "queue": {},
  "socat": {
    "enabled": false,
    "master": "pty,raw,echo=0,link=/dev/ttyZ2M,mode=777",
    "slave": "tcp-listen:8485,keepalive,nodelay,reuseaddr,keepidle=1,keepintvl=1,keepcnt=5",
    "restartdelay": 1.0,
    "initialdelay": 1.0,
    "options": "-d -d",
    "log": false
  }
}Debug information end
./run.sh: line 24: [Info] Configuration backup found in /share/zigbee2mqtt/.configuration.yaml.bk. Skipping config backup.: No such file or directory
[Info] Socat is DISABLED and not started
2019-10-31T15:57:04: PM2 log: Launching in no daemon mode
2019-10-31T15:57:04: PM2 log: App [npm:0] starting in -fork mode-
2019-10-31T15:57:05: PM2 log: App [npm:0] online
> [email protected] start /app
> node index.js
zigbee2mqtt:info  2019-10-31T15:57:15: Logging to directory: '/share/zigbee2mqtt/log/2019-10-31.15-57-14'
zigbee2mqtt:info  2019-10-31T15:57:16: Starting zigbee2mqtt version 1.6.0 (commit #36c7a27e6c632e0450db18279fc46a1d01365579)
zigbee2mqtt:info  2019-10-31T15:57:16: Starting zigbee-herdsman...
zigbee2mqtt:info  2019-10-31T15:57:19: zigbee-herdsman started
zigbee2mqtt:info  2019-10-31T15:57:19: Coordinator firmware version: '{"type":"zStack12","meta":{"transportrev":2,"product":0,"majorrel":2,"minorrel":6,"maintrel":3,"revision":20190608}}'
zigbee2mqtt:info  2019-10-31T15:57:19: Currently 1 devices are joined:
zigbee2mqtt:info  2019-10-31T15:57:19: 0x00158d0004458653 (0x00158d0004458653): MCCGQ11LM - Xiaomi Aqara door & window contact sensor (EndDevice)
zigbee2mqtt:warn  2019-10-31T15:57:19: `permit_join` set to  `true` in configuration.yaml.
zigbee2mqtt:warn  2019-10-31T15:57:19: Allowing new devices to join.
zigbee2mqtt:warn  2019-10-31T15:57:19: Set `permit_join` to `false` once you joined all devices.
zigbee2mqtt:info  2019-10-31T15:57:19: Zigbee: allowing new devices to join.
zigbee2mqtt:info  2019-10-31T15:57:19: Connecting to MQTT server at mqtt://core-mosquitto:1883
zigbee2mqtt:info  2019-10-31T15:57:21: Connected to MQTT server
zigbee2mqtt:info  2019-10-31T15:57:21: MQTT publish: topic 'zigbee2mqtt/bridge/state', payload 'online'
zigbee2mqtt:info  2019-10-31T15:57:21: MQTT publish: topic 'zigbee2mqtt/0x00158d0004458653', payload '{"contact":true,"linkquality":0,"battery":100,"voltage":3125}'
zigbee2mqtt:info  2019-10-31T15:57:21: MQTT publish: topic 'zigbee2mqtt/bridge/config', payload '{"version":"1.6.0","commit":"36c7a27e6c632e0450db18279fc46a1d01365579","coordinator":{"type":"zStack12","meta":{"transportrev":2,"product":0,"majorrel":2,"minorrel":6,"maintrel":3,"revision":20190608}},"log_level":"info","permit_join":true}'
@wjcloudy
Copy link

In case it helps, my SP600 was unpaired from factory, and joined instantly without being at all close to the coordinator. I've not tried a reset condition. Are you sure you don't have any other nearby zigbee networks accepting it?

@gausie
Copy link
Contributor Author

gausie commented Oct 31, 2019

The only thing that possibly could have accepted it is the Hue bridge, but I disconnected it at the mains and repeated the process with no luck. They're also both just flashing red forever which I believe means they are trying to pair.

@wjcloudy
Copy link

Just re-paired one of mine to check (held down button for 10 seconds) and it rejoined fine. Have you just got the one to test? can it pair with the hue hub?

@gausie
Copy link
Contributor Author

gausie commented Oct 31, 2019 via email

@gausie
Copy link
Contributor Author

gausie commented Nov 3, 2019

Ok the Hive plug has arrived now and also isn't detected by my setup. What could cause some ZigBee devices to be added no problem but for others to not show up at all in the logs, as if they didn't exist?

@Koenkk
Copy link
Owner

Koenkk commented Nov 3, 2019

  • Is your CC2531 connected via an extension cable? (to rule out interference)
  • When trying to pair, can you share the log when running zigbee2mqtt with DEBUG=zigbee-herdsman:controller* npm start?

@gausie
Copy link
Contributor Author

gausie commented Nov 3, 2019 via email

@Koenkk
Copy link
Owner

Koenkk commented Nov 3, 2019

You can, for hassio edge addon just set "zigbee_herdsman_debug": true in the config.

@gausie
Copy link
Contributor Author

gausie commented Nov 4, 2019

Ah, well got it set up on my laptop before I saw that! Anyway, nothing useful I can see with the debug environment variable set

zigbee2mqtt:info  2019-11-04T11:09:36: Logging to directory: '/media/gausie/Shared (ext4)/Projects/zigbee2mqtt/data/log/2019-11-04.11-09-36'
zigbee2mqtt:debug 2019-11-04T11:09:36: Loaded state from file /media/gausie/Shared (ext4)/Projects/zigbee2mqtt/data/state.json
zigbee2mqtt:info  2019-11-04T11:09:36: Starting zigbee2mqtt version 1.6.0 (commit #2fb4e20)
zigbee2mqtt:info  2019-11-04T11:09:36: Starting zigbee-herdsman...
zigbee2mqtt:debug 2019-11-04T11:09:36: Using zigbee-herdsman with settings: '{"network":{"panID":6754,"extenedPanID":[221,221,221,221,221,221,221,221],"channelList":[11],"networkKey":"HIDDEN"},"databasePath":"/media/gausie/Shared (ext4)/Projects/zigbee2mqtt/data/database.db","backupPath":"/media/gausie/Shared (ext4)/Projects/zigbee2mqtt/data/coordinator_backup.json","serialPort":{"baudRate":115200,"rtscts":true,"path":"/dev/ttyACM0"}}'
  zigbee-herdsman:controller:log Starting with options '{"network":{"networkKeyDistribute":false,"networkKey":[1,3,5,7,9,11,13,15,0,2,4,6,8,10,12,13],"panID":6754,"extenedPanID":[221,221,221,221,221,221,221,221],"channelList":[11]},"serialPort":{"baudRate":115200,"rtscts":true,"path":"/dev/ttyACM0"},"databasePath":"/media/gausie/Shared (ext4)/Projects/zigbee2mqtt/data/database.db","backupPath":"/media/gausie/Shared (ext4)/Projects/zigbee2mqtt/data/coordinator_backup.json"}' +0ms
  zigbee-herdsman:controller:log Started with result 'resumed' +1s
  zigbee-herdsman:controller:log Injected database: true, adapter: true +1ms
zigbee2mqtt:info  2019-11-04T11:09:37: zigbee-herdsman started
zigbee2mqtt:info  2019-11-04T11:09:37: Coordinator firmware version: '{"type":"zStack12","meta":{"transportrev":2,"product":0,"majorrel":2,"minorrel":6,"maintrel":3,"revision":20190608}}'
zigbee2mqtt:debug 2019-11-04T11:09:37: Zigbee network parameters: {"panID":6754,"extendedPanID":"0xdddddddddddddddd","channel":11}
zigbee2mqtt:info  2019-11-04T11:09:37: Currently 1 devices are joined:
zigbee2mqtt:info  2019-11-04T11:09:37: 0x00158d0004458653 (0x00158d0004458653): MCCGQ11LM - Xiaomi Aqara door & window contact sensor (EndDevice)
zigbee2mqtt:warn  2019-11-04T11:09:37: `permit_join` set to  `true` in configuration.yaml.
zigbee2mqtt:warn  2019-11-04T11:09:37: Allowing new devices to join.
zigbee2mqtt:warn  2019-11-04T11:09:37: Set `permit_join` to `false` once you joined all devices.
zigbee2mqtt:info  2019-11-04T11:09:37: Zigbee: allowing new devices to join.
  zigbee-herdsman:controller:log Permit joining +10ms
zigbee2mqtt:info  2019-11-04T11:09:37: Connecting to MQTT server at mqtt://hassio.local:1883
zigbee2mqtt:info  2019-11-04T11:09:39: Connected to MQTT server
zigbee2mqtt:info  2019-11-04T11:09:39: MQTT publish: topic 'zigbee2mqtt/bridge/state', payload 'online'
zigbee2mqtt:info  2019-11-04T11:09:39: MQTT publish: topic 'zigbee2mqtt/0x00158d0004458653', payload '{"battery":100,"voltage":3085,"contact":false,"linkquality":70}'
zigbee2mqtt:info  2019-11-04T11:09:39: MQTT publish: topic 'zigbee2mqtt/bridge/config', payload '{"version":"1.6.0","commit":"2fb4e20","coordinator":{"type":"zStack12","meta":{"transportrev":2,"product":0,"majorrel":2,"minorrel":6,"maintrel":3,"revision":20190608}},"log_level":"debug","permit_join":true}'

@gausie
Copy link
Contributor Author

gausie commented Nov 4, 2019

I restarted everything and expanded the debug namespace to all of zigbee-herdsman and got this. Could it be relevant?

  zigbee-herdsman:controller:log Permit joining +3m
  zigbee-herdsman:adapter:zStack:znp:SREQ --> ZDO - mgmtPermitJoinReq - {"addrmode":15,"dstaddr":65532,"duration":254,"tcsignificance":0} +3m
  zigbee-herdsman:adapter:zStack:unpi:writer --> frame [254,5,37,54,15,252,255,254,0,228] +3m
  zigbee-herdsman:adapter:zStack:unpi:parser <-- [254,1,101,54,0,82] +3m
  zigbee-herdsman:adapter:zStack:unpi:parser --- parseNext [254,1,101,54,0,82] +1ms
  zigbee-herdsman:adapter:zStack:unpi:parser --> parsed 1 - 3 - 5 - 54 - [] - 82 +0ms
  zigbee-herdsman:adapter:zStack:znp:SRSP <-- ZDO - mgmtPermitJoinReq - {"status":0} +3m
  zigbee-herdsman:adapter:zStack:unpi:parser --- parseNext [] +0ms
  zigbee-herdsman:adapter:zStack:unpi:parser <-- [254,3,69,182,0,0,0,240] +9ms
  zigbee-herdsman:adapter:zStack:unpi:parser --- parseNext [254,3,69,182,0,0,0,240] +0ms
  zigbee-herdsman:adapter:zStack:unpi:parser --> parsed 3 - 2 - 5 - 182 - [] - 240 +0ms
  zigbee-herdsman:adapter:zStack:znp:AREQ <-- ZDO - mgmtPermitJoinRsp - {"srcaddr":0,"status":0} +3m
  zigbee-herdsman:adapter:zStack:unpi:parser --- parseNext [] +0ms
  zigbee-herdsman:controller:log Permit joining +3m
(node:14043) UnhandledPromiseRejectionWarning: Error: Cannot request when znp has not been initialized yet
    at Znp.request (/media/gausie/Shared (ext4)/Projects/zigbee2mqtt/node_modules/zigbee-herdsman/dist/adapter/z-stack/znp/znp.js:173:19)
    at ZStackAdapter.<anonymous> (/media/gausie/Shared (ext4)/Projects/zigbee2mqtt/node_modules/zigbee-herdsman/dist/adapter/z-stack/adapter/zStackAdapter.js:124:32)
    at Generator.next (<anonymous>)
    at /media/gausie/Shared (ext4)/Projects/zigbee2mqtt/node_modules/zigbee-herdsman/dist/adapter/z-stack/adapter/zStackAdapter.js:8:71
    at new Promise (<anonymous>)
    at __awaiter (/media/gausie/Shared (ext4)/Projects/zigbee2mqtt/node_modules/zigbee-herdsman/dist/adapter/z-stack/adapter/zStackAdapter.js:4:12)
    at Object.queue.execute [as func] (/media/gausie/Shared (ext4)/Projects/zigbee2mqtt/node_modules/zigbee-herdsman/dist/adapter/z-stack/adapter/zStackAdapter.js:122:44)
    at Queue.<anonymous> (/media/gausie/Shared (ext4)/Projects/zigbee2mqtt/node_modules/zigbee-herdsman/dist/utils/queue.js:29:46)
    at Generator.next (<anonymous>)
    at /media/gausie/Shared (ext4)/Projects/zigbee2mqtt/node_modules/zigbee-herdsman/dist/utils/queue.js:8:71
(node:14043) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 54)

@gausie
Copy link
Contributor Author

gausie commented Nov 5, 2019

Ran it again today and I no longer get that error. I really have no idea why this type of device just doesn't work for me. Could it be an issue with my CC2531?

@Koenkk
Copy link
Owner

Koenkk commented Nov 5, 2019

Could it be that it pairs to another network? Are any other zigbee devices on which are in a different network?

@gausie
Copy link
Contributor Author

gausie commented Nov 5, 2019

It's still in pairing mode (flashing orange button) so I don't think that's the case. But I unplugged the Hue bridge and started again with no luck.

@Koenkk
Copy link
Owner

Koenkk commented Nov 5, 2019

I have no clue what is going on honestly. If they also dont pair with the hue bridge it would indicate that something else (really strange) is going on.

@gausie
Copy link
Contributor Author

gausie commented Nov 5, 2019 via email

@Koenkk
Copy link
Owner

Koenkk commented Nov 5, 2019

A last thing to try would be to pair it at a different location (e.g. different house), perhaps there is some heavy interference.

@gausie
Copy link
Contributor Author

gausie commented Nov 19, 2019

I ended up buying a tasmota compatible smart plug and abandoning doing it through zigbee

@gausie gausie closed this as completed Nov 19, 2019
@elmopl
Copy link

elmopl commented Nov 29, 2019

I seem to have the same problem.
I have CC2531 connected to Raspberry Pi with "Z-Stack_Home_1.2 (default)" (from https://github.com/Koenkk/Z-Stack-firmware/tree/master/coordinator).

I also tried using "Z-Stack_Home_1.2 (source_routing)". Same results.

Today I received my Salus SP600 Smart Plug and when I plug it in it seems to make no trace on output from zigbee2mqtt.
As if it was not there at all.

I have paired Xiaomi button, and Ikea motion sensor so far without any problems and they work fine.

I run zigbee2mqtt through systemctl (not that it would make much difference) and I have also tried it with:

[Service]
Environment=DEBUG=zigbee-herdsman:*

which did add more levels of debugging, however there is no trace related to plugging in my plug.

I have no other coordinators at home other the one running on Raspberry Pi.

The plug seems to go through 3 stages of flashing when plugged in:

  • flashing green
  • flashing 3 x red -> pause -> 3 x red -> pause ...
  • after a while it changes to continuous flashing of red

Do you have any suggestions on how I could try checking what is going on with that plug? Is there some program (and firmware?) that would use that CC2531 to scan and debug devices trying to pair? (I have a second CC2531 dongle which I could easily flash with something else or use in parallel to the one used by zigbee2mqtt).

For completeness log from startup:

Nov 29 19:58:44 raspberrypi npm[28421]: #033[32mzigbee2mqtt:info #033[39m 2019-11-29 19:58:44: Starting zigbee2mqtt version 1.7.1+dev (commit #546a72f)
Nov 29 19:58:44 raspberrypi npm[28421]: #033[32mzigbee2mqtt:info #033[39m 2019-11-29 19:58:44: Starting zigbee-herdsman...
Nov 29 19:58:44 raspberrypi npm[28421]: #033[34mzigbee2mqtt:debug#033[39m 2019-11-29 19:58:44: Using zigbee-herdsman with settings: '{"network":{"panID":6754,"extendedPanID":[221,221,221,221,221,221,221,221],"channelList":[11],"networkKey":"HIDDEN"},"databasePath":"/home
/pi/zigbee2mqtt/data/database.db","databaseBackupPath":"/home/pi/zigbee2mqtt/data/database.db.backup","backupPath":"/home/pi/zigbee2mqtt/data/coordinator_backup.json","serialPort":{"baudRate":115200,"rtscts":true,"path":"/dev/ttyACM0"}}'
Nov 29 19:58:44 raspberrypi npm[28421]: 2019-11-29T19:58:44.954Z zigbee-herdsman:adapter Path '/dev/ttyACM0' is valid for 'ZStackAdapter
[...]
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.184Z zigbee-herdsman:adapter:zStack:unpi:parser --- parseNext []
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.189Z zigbee-herdsman:adapter:zStack:unpi:parser <-- [254,15,69,133,0,0,0,0,0,9,110,11,8,6,5,4,3,2,1,172]
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.189Z zigbee-herdsman:adapter:zStack:unpi:parser --- parseNext [254,15,69,133,0,0,0,0,0,9,110,11,8,6,5,4,3,2,1,172]
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.190Z zigbee-herdsman:adapter:zStack:unpi:parser --> parsed 15 - 2 - 5 - 133 - [0,0,0,0,0,9,110,11,8,6,5,4,3,2,1] - 172
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.190Z zigbee-herdsman:adapter:zStack:znp:AREQ <-- ZDO - activeEpRsp - {"srcaddr":0,"status":0,"nwkaddr":0,"activeepcount":9,"activeeplist":[110,11,8,6,5,4,3,2,1]}
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.191Z zigbee-herdsman:adapter:zStack:unpi:parser --- parseNext []
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.191Z zigbee-herdsman:adapter:zStack:startZnp Endpoint '1' already registered
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.191Z zigbee-herdsman:adapter:zStack:startZnp Endpoint '2' already registered
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.191Z zigbee-herdsman:adapter:zStack:startZnp Endpoint '3' already registered
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.191Z zigbee-herdsman:adapter:zStack:startZnp Endpoint '4' already registered
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.191Z zigbee-herdsman:adapter:zStack:startZnp Endpoint '5' already registered
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.191Z zigbee-herdsman:adapter:zStack:startZnp Endpoint '6' already registered
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.191Z zigbee-herdsman:adapter:zStack:startZnp Endpoint '8' already registered
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.192Z zigbee-herdsman:adapter:zStack:startZnp Endpoint '11' already registered
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.192Z zigbee-herdsman:adapter:zStack:startZnp Endpoint '110' already registered
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.192Z zigbee-herdsman:controller:log Started with result 'resumed'
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.192Z zigbee-herdsman:controller:log Injected database: true, adapter: true
Nov 29 19:58:46 raspberrypi npm[28421]: #033[32mzigbee2mqtt:info #033[39m 2019-11-29 19:58:46: zigbee-herdsman started
Nov 29 19:58:46 raspberrypi npm[28421]: #033[32mzigbee2mqtt:info #033[39m 2019-11-29 19:58:46: Coordinator firmware version: '{"type":"zStack12","meta":{"transportrev":2,"product":0,"majorrel":2,"minorrel":6,"maintrel":3,"revision":20190608}}'
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.202Z zigbee-herdsman:adapter:zStack:znp:SREQ --> ZDO - extNwkInfo - {}
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.202Z zigbee-herdsman:adapter:zStack:unpi:writer --> frame [254,0,37,80,117]
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.206Z zigbee-herdsman:adapter:zStack:unpi:parser <-- [254,24,101,80,0,0,9,98,26,0,0,221,221,221,221,221,221,221,221,0,0,0,0,0,0,0,0,11,87]
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.206Z zigbee-herdsman:adapter:zStack:unpi:parser --- parseNext [254,24,101,80,0,0,9,98,26,0,0,221,221,221,221,221,221,221,221,0,0,0,0,0,0,0,0,11,87]
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.206Z zigbee-herdsman:adapter:zStack:unpi:parser --> parsed 24 - 3 - 5 - 80 - [0,0,9,98,26,0,0,221,221,221,221,221,221,221,221,0,0,0,0,0,0,0,0,11] - 87
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.206Z zigbee-herdsman:adapter:zStack:znp:SRSP <-- ZDO - extNwkInfo - {"shortaddr":0,"devstate":9,"panid":6754,"parentaddr":0,"extendedpanid":"0xdddddddddddddddd","parentextaddr":"0x0000000000000000","channel":11}
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.207Z zigbee-herdsman:adapter:zStack:unpi:parser --- parseNext []
Nov 29 19:58:46 raspberrypi npm[28421]: #033[34mzigbee2mqtt:debug#033[39m 2019-11-29 19:58:46: Zigbee network parameters: {"panID":6754,"extendedPanID":"0xdddddddddddddddd","channel":11}
Nov 29 19:58:46 raspberrypi npm[28421]: #033[32mzigbee2mqtt:info #033[39m 2019-11-29 19:58:46: Currently 2 devices are joined:
Nov 29 19:58:46 raspberrypi npm[28421]: #033[32mzigbee2mqtt:info #033[39m 2019-11-29 19:58:46: 0x00158d000312d0d5 (0x00158d000312d0d5): WXKG03LM - Xiaomi Aqara single key wireless wall switch (EndDevice)
Nov 29 19:58:46 raspberrypi npm[28421]: #033[32mzigbee2mqtt:info #033[39m 2019-11-29 19:58:46: 0x14b457fffe6b1f06 (0x14b457fffe6b1f06): E1525 - IKEA TRADFRI motion sensor (EndDevice)
Nov 29 19:58:46 raspberrypi npm[28421]: #033[33mzigbee2mqtt:warn #033[39m 2019-11-29 19:58:46: `permit_join` set to  `true` in configuration.yaml.
Nov 29 19:58:46 raspberrypi npm[28421]: #033[33mzigbee2mqtt:warn #033[39m 2019-11-29 19:58:46: Allowing new devices to join.
Nov 29 19:58:46 raspberrypi npm[28421]: #033[33mzigbee2mqtt:warn #033[39m 2019-11-29 19:58:46: Set `permit_join` to `false` once you joined all devices.
Nov 29 19:58:46 raspberrypi npm[28421]: #033[32mzigbee2mqtt:info #033[39m 2019-11-29 19:58:46: Zigbee: allowing new devices to join.
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.218Z zigbee-herdsman:controller:log Permit joining
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.219Z zigbee-herdsman:adapter:zStack:znp:SREQ --> ZDO - mgmtPermitJoinReq - {"addrmode":15,"dstaddr":65532,"duration":254,"tcsignificance":0}
Nov 29 19:58:46 raspberrypi npm[28421]: 2019-11-29T19:58:46.219Z zigbee-herdsman:adapter:zStack:unpi:writer --> frame [254,5,37,54,15,252,255,254,0,228]
Nov 29 19:58:46 raspberrypi npm[28421]: #033[32mzigbee2mqtt:info #033[39m 2019-11-29 19:58:46: Connecting to MQTT server at mqtt://localhost

@elmopl
Copy link

elmopl commented Nov 30, 2019

I did more checks. I used CC2531 with firmware that comes with packet sniffer from Texas Instrument
and used their software to capture traffic.

That is on default channel 11 (2405MHz).

I moved my laptop with dongle and my Salus SP600 plug to a furthest point from all other devices to be able to reduce amount of noise in traffic.

As far as I can see I was consistently getting a packets (which seemed to be also very much in sync with flashing of the plug, every time a sequence of 3 red flashes started a packet appeared):

+----------------------------------------------------+----------------- - - -
|     Packet sniffer frame header                    |
+----+-------------+-------------------------+-------+
|info| Packet nbr. | Time stamp              | Length|  Packet data
+----+-------------+-------------------------+-------+----------------- - - -
| 13 | 08 00 00 00 | F0 B6 F8 B2 01 00 00 00 | 0B 00 | 0A 03 08 B8 FF FF FF FF 07 34 BC
| 13 | 09 00 00 00 | D0 E3 84 BC 01 00 00 00 | 0B 00 | 0A 03 08 C8 FF FF FF FF 07 34 BC
| 13 | 0B 00 00 00 | 6C 9A 0E C6 01 00 00 00 | 0B 00 | 0A 03 08 D8 FF FF FF FF 07 34 BC
| 13 | 0C 00 00 00 | AC 9F 9A CF 01 00 00 00 | 0B 00 | 0A 03 08 E8 FF FF FF FF 07 3C BC
+----+-------------+-------------------------+-------+----------------- - - -

Unfortunately I know nothing about ZigBee so it tells me nothing.
I guess next step for me is to read up on what those packets mean.

I run Packet Sniffer from TI in ZigBee mode and pretty sure that below packets are coming from the Smart Plug:

image

The details of them are:

+----------------------------------------------------+----------------- - - -
|     Packet sniffer frame header                    |
+----+-------------+-------------------------+-------+
|info| Packet nbr. | Time stamp              | Length|  Packet data
+----+-------------+-------------------------+-------+----------------- - - -
| 03 | 0F 00 00 00 | E0 83 DD 70 00 00 00 00 | 0B 00 | 0A 03 08 DF FF FF FF FF 07 19 EC
| 03 | 10 00 00 00 | 40 6E DF 70 00 00 00 00 | 1D 00 | 1C 00 80 75 62 1A 00 00 FF CF 00 00 00 22 84 DD DD DD DD DD DD DD DD FF FF FF 00 09 EC
| 03 | 11 00 00 00 | 68 61 67 7A 00 00 00 00 | 0B 00 | 0A 03 08 EF FF FF FF FF 07 18 EC
| 03 | 12 00 00 00 | 1C 95 68 7A 00 00 00 00 | 1D 00 | 1C 00 80 76 62 1A 00 00 FF CF 00 00 00 22 84 DD DD DD DD DD DD DD DD FF FF FF 00 09 EC
| 03 | 13 00 00 00 | AC 2E F4 83 00 00 00 00 | 0B 00 | 0A 03 08 FF FF FF FF FF 07 22 EC
| 03 | 14 00 00 00 | E4 74 F5 83 00 00 00 00 | 1D 00 | 1C 00 80 77 62 1A 00 00 FF CF 00 00 00 22 84 DD DD DD DD DD DD DD DD FF FF FF 00 08 EC
+----+-------------+-------------------------+-------+----------------- - - -

@elmopl
Copy link

elmopl commented Nov 30, 2019

More investigation.
Turning the CC2531 acting as controller I can see that Beacon request is not followed by anything.
That would suggest that CC2531/zigbee2mqtt is actually responding to beacon request.

I am not sure what is missing from the response that stops SP600 Smart Plug from connecting.

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

4 participants