More BLE for the Somfy Sonesse2 Zigbee Motors
I've had people reach out and ask if I knew anything about other commands for configuring the Sonesse2 motors without the offical app. So I've dug through the source I have here, and this is what I've found.
First of all, I'm pretty sure you need to perform an Authentication first in all cases.
Setting up a blind
To set up a blind without access to the Tahoma Pro app, you need todo the following.
On iOS I used "BT Inspector", needed the paid for version but worth it!
- Authentication - Pin code to authenticate.
- Identify - Just to be sure that you have correctly authenticated.
- Configure Range - Just use "Start" unless you have range limits.
- Set Direction - Set it to clockwise.
- Move Up - See if your blind moves down.
- Set Direction - If the blind moved down, set it to counter-clockwise.
- Move Up - Keep repeating until you get to the upper point for your blind.
- Set Limit - Set the upper limit.
- Move Down - Keep repeating until you get to the lower point of your blind.
- Set Limit - Set the lower limit.
- Leave Network - The blind will now look for a zigbee network.
Commands
Authentication✅
Open access to the motors configuration system.
What | Description |
---|---|
Endpoint | 0000000b-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | Pin code for motor, as a 3 byte int, in little-endian. |
Delivery Mode ✅
Switches the motor off, until the button is physically pressed on the tube.
What | Description |
---|---|
Endpoint | 0000000a-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x01 |
Leave Network ✅
Causes a factory default motor to leave its own Zigbee network and start polling to join another.
What | Description |
---|---|
Endpoint | 00020001-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x01 |
Identify✅
Cause the blind to dance to help identify which blind is being accessed.
What | Description |
---|---|
Endpoint | 00000001-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x01 |
Open⚠️
May be for venetian blinds, doesn't exist on roller - Open the blind.
What | Description |
---|---|
Endpoint | 0000000d-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x01 |
Close⚠️
May be for venetian blinds, doesn't exist on roller - Close the blind.
What | Description |
---|---|
Endpoint | 0000000e-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x01 |
Stop✅
Stop the blind.
What | Description |
---|---|
Endpoint | 00000006-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x01 |
Configure Range✅
Enable the blind to configure its range, this is needed before any Move command when the blind has yet to have limits defined. Start seemed to be enough for my blinds.
What | Description |
---|---|
Endpoint | 0001000B-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x0000 = "Start", 0x0002 = "Half", 0x0001 = "Full". |
Move Up✅
Move the blind up manually.
What | Description |
---|---|
Endpoint | 00010009-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x???? , 16 bit, 1-500, little endian, 1 small step, 500 larger. |
Move Down✅
Move the blind down manually.
What | Description |
---|---|
Endpoint | 00010008-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x01 moves large amount, 0xf401 moves a small amount |
Go To Position✅
Move the blind to a specific position, 0-32767 calibrated against limits set!
What | Description |
---|---|
Endpoint | 00000005-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x???? , 16 bit, 0 (open) - 32767 (closed), little endian |
Set Limit✅
Set's the limits of the blind.
What | Description |
---|---|
Endpoint | 00010007-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x00 to set upper limit, 0x01 to set lower limit |
Set Direction✅
Set the direction of the blind.
What | Description |
---|---|
Endpoint | 00010005-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x00 - Counter Clockwise, 0x01 - Clockwise |
Reset to factory defaults✅
Reset the blind to factory defaults.
What | Description |
---|---|
Endpoint | 00010001-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | 0x01 |
Write Data🚨
This is also the way the firmware is uploaded, I don't think that you can upload a corrupt firmware... but you might be able to.
YOU HAVE BEEN WARNED!
Read and write configuration data from the blind, this appears to be needed to configure the blind in some circumstances.
What | Description |
---|---|
Endpoint | 00040001-cad9-46c6-a2ea-2ca16d57b4a5 |
Parameters | No simple parameter, it's a protocol. |
It appears that WriteData allows interacting with multiple different "files" on the motor, not all files may be present on all Somfy devices.
Different commands can be sent to open the files.
These files can be opened in different modes.
Configuration seems to be sent a Concise Binary Object Representation (CBOR), a binary format that was inspired by JSON.
A file open command, seemed to be something like:
00 - Open File
C4 00 - Motor config file
00 - Mode
Nothing - Additional content (maybe for write)
The write suceeds, an immediate read after errors.
Then read the file contents with:
03 - Read File
C4 00 - Motor config file
00 - Mode
Nothing - Additional content (maybe for write)
Which returns:
Motor file:
Type file:
Radio file:
HMI file appears to be empty.