Instructions pour le cube magique Xiaomi

xiaomi magic cube

Clusters disponibles

EndPoint: 0x01
Profile ID: 0x0104 (ZigBee HA)
Device ID: 0x5F01 (Unknown)
Input Cluster Count: 4
Cluster 0: Cluster ID: 0x0000 (General: Basic)
Cluster 1: Cluster ID: 0x0003 (General: Identify)
Cluster 2: Cluster ID: 0x0019 (General: OTA)
Cluster 3: Cluster ID: 0x0012 (Unknown)
Output Cluster Count: 6
Cluster 0: Cluster ID: 0x0000 (General: Basic)
Cluster 1: Cluster ID: 0x0003 (General: Identify)
Cluster 2: Cluster ID: 0x0019 (General: OTA)
Cluster 3: Cluster ID: 0x0012 (Unknown)
Cluster 4: Cluster ID: 0xCC19 (Unknown)
Cluster 5: Cluster ID: 0x001A (Unknown)

EndPoint: 0x02
Profile ID: 0x0104 (ZigBee HA)
Device ID: 0x5F02 (Unknown)
Input Cluster Count: 2
Cluster 0: Cluster ID: 0x0003 (General: Identify)
Cluster 1: Cluster ID: 0x0012 (Unknown)
Output Cluster Count: 4
Cluster 0: Cluster ID: 0x0003 (General: Identify)
Cluster 1: Cluster ID: 0x0012 (Unknown)
Cluster 2: Cluster ID: 0xDB72 (Unknown)
Cluster 3: Cluster ID: 0x5F63 (Unknown)

EndPoint: 0x03
Profile ID: 0x0104 (ZigBee HA)
Device ID: 0x5F03 (Unknown)
Input Cluster Count: 2
Cluster 0: Cluster ID: 0x0003 (General: Identify)
Cluster 1: Cluster ID: 0x000C (Unknown)
Output Cluster Count: 4
Cluster 0: Cluster ID: 0x0003 (General: Identify)
Cluster 1: Cluster ID: 0x000C (Unknown)
Cluster 2: Cluster ID: 0xDB72 (Unknown)
Cluster 3: Cluster ID: 0x5F63 (Unknown)

Suivre la procédure pour mettre la ZiGate en mode « écoute » :

Puis appuyer sur le bouton (sur le dessus du capteur) pendant 5 secondes. La led bleue se met à clignoter puis envoie les données suivantes :

Device announce

Le message est traitée deux fois :

ZiGate ← 01 00 4D 00 0C 46 1E D6 00 15 8D 00 01 02 51 61 80 E4 03
ZiGate ← 01 00 4D 00 0C 46 1E D6 00 15 8D 00 01 02 51 61 80 E4 03

Header

01 = Start
00 4D = Message type (device announce)
00 0C = Taille message
46 = Checksum

Message (Device announce):

1E D6 = Short address ( adresse utilisé dans le réseau)
00 15 8D 00 01 02 51 61 = Adresse MAC IEEE
80 = Mac capability

Footer

E4 = Qualité du signal
03 = End

Décodage :

Type: 0x004D (End Device Announce)
Short Address: 0x1ED6
Extended Address: 0x158D0001025161
MAC Capability: 0x80
Alternate PAN Coordinator: False
Device Type: End Device
Power Source: Battery
Receiver On When Idle: False
Security Capability: Standard
Allocate Address: True

Route Discovery Confirm

ZiGate ← 01 87 01 00 03 45 00 00 C0 03

Décodage :

Type: 0x8701 (Route Discovery Confirm)
SQN: 0x00
Status: 0x00
Network Status: 0xC0

Démarrage après appairage

ZiGate ← 01 81 02 00 1D D6 00 1E D6 01 00 00 00 05 00 42 00 10 6C 75 6D 69 2E 73 65 6E 73 6F 72 5F 63 75 62 65 BD 03

Décodage :

Type: 0x8102 (Attribute Report)
SQN: 0x00
Src Addr: 0x1ED6
Src Ep: 0x01
Cluster ID: 0x0000 (General: Basic)
Attribute ID: 0x0005
Attribute Size: 0x0010
Attribute Type: 0x42 (Character String)
Attribute Data (Len – 16): lumi.sensor_cube
Status: 0x00

ZiGate ← 01 81 02 00 0E DA 00 1E D6 01 00 00 00 01 00 20 00 01 03 BD 03

Décodage :

Type: 0x8102 (Attribute Report)
SQN: 0x00
Src Addr: 0x1ED6
Src Ep: 0x01
Cluster ID: 0x0000 (General: Basic)
Attribute ID: 0x0001
Attribute Size: 0x0001
Attribute Type: 0x20 (UINT8)
Attribute Data: 0x03
Status: 0x00

Commandes

Le magic cube est en quelque sorte une télécommande avec plusieurs fonctions

Shake (secouez moi)

ZiGate <- 01 81 02 00 0F 61 04 A4 EB 02 00 12 00 55 00 21 00 02 00 00 C0 03

Décodage :

Type: 0x8102 (Attribute Report)
SQN: 0x04
Src Addr: 0xA4EB
Src Ep: 0x02
Cluster ID: 0x0012 (Unknown)
Attribute ID: 0x0055
Attribute Size: 0x0002
Attribute Type: 0x21 (UINT16)
Attribute Data: 0x0000
Status: 0x00

Slide (glissez moi)

ZiGate <- 01 81 02 00 0F 7C 05 A4 EB 02 00 12 00 55 00 21 00 02 01 03 DE 03

Type: 0x8102 (Attribute Report)
SQN: 0x05
Src Addr: 0xA4EB
Src Ep: 0x02
Cluster ID: 0x0012 (Unknown)
Attribute ID: 0x0055
Attribute Size: 0x0002
Attribute Type: 0x21 (UINT16)
Attribute Data: 0x0103
Status: 0x00

Rotation (plan horizontal)

ZiGate <- 01 81 02 00 0F 0C 08 A4 EB 03 00 0C FF 05 00 21 00 02 01 F4 E4 03

Type: 0x8102 (Attribute Report)
SQN: 0x08
Src Addr: 0xA4EB
Src Ep: 0x03
Cluster ID: 0x000C (Unknown)
Attribute ID: 0xFF05
Attribute Size: 0x0002
Attribute Type: 0x21 (UINT16)
Attribute Data: 0x01F4
Status: 0x00

ZiGate <- 01 81 02 00 11 56 08 A4 EB 03 00 0C 00 55 00 39 00 04 C2 C2 C2 C2 E4 03

Type: 0x8102 (Attribute Report)
SQN: 0x08
Src Addr: 0xA4EB
Src Ep: 0x03
Cluster ID: 0x000C (Unknown)
Attribute ID: 0x0055
Attribute Size: 0x0004
Attribute Data : 0xC2C2C2C
2
Attribute Type: 0x39 (Unknown)
Status: 0x00

Rotation (plan vertical)

ZiGate <- 01 81 02 00 0F F5 0D A4 EB 02 00 12 00 55 00 21 00 02 00 83 DE 03

Type: 0x8102 (Attribute Report)
SQN: 0x0D
Src Addr: 0xA4EB
Src Ep: 0x02
Cluster ID: 0x0012 (Unknown)
Attribute ID: 0x0055
Attribute Size: 0x0002
Attribute Type: 0x21 (UINT16)
Attribute Data: 0x0083
Status: 0x00

0x0083 = 131 = degré rotation

TAP (Tapez moi)

ZiGate <- 01 81 02 00 0F 6C 14 A4 EB 02 00 12 00 55 00 21 00 02 02 04 DB 03

Type: 0x8102 (Attribute Report)
SQN: 0x14
Src Addr: 0xA4EB
Src Ep: 0x02
Cluster ID: 0x0012 (Unknown)
Attribute ID: 0x0055
Attribute Size: 0x0002
Attribute Type: 0x21 (UINT16)
Attribute Data: 0x0204
Status: 0x00

 

Translate »