1.1.5 • Published 8 months ago

homebridge-sc v1.1.5

Weekly downloads
-
License
Apache-2.0
Repository
github
Last release
8 months ago

Homebridge SC

Downloads Version Homebridge Discord verified-by-homebridge

GitHub issues GitHub pull requests JavaScript Style Guide

Homebridge plugin for SOMA Connect

Copyright © 2021-2023 Erik Baauw. All rights reserved.

Note: This plugin is no longer being maintained.

This Homebridge plugin exposes SOMA Smart Shades 2 and SOMA Tilt 2 devices, connected to a SOMA Connect, to Apple's HomeKit.

This plugin does not depend on Bluetooth Low Energy (BLE) support on the server running Homebridge. It uses the HTTP API of the SOMA Connect to interact with the SOMA devices. Note that this API is currently in beta.

Note that the SOMA Connect provides native Homebridge support. However, I find that support lacking:

  • It doesn't expose the battery;
  • It doesn't expose the solar panel light level;
  • It exposes Close Upwards and Morning Mode as write-only characteristics, which most HomeKit apps don't like;
  • It doesn't report in which direction ("up" or "down") the blinds are closed;
  • It doesn't support specifying which devices to expose, which might be needed when you have multiple SOMA Connect servers for better BLE signal coverage, but some devices are seen by both Connect servers.

This plugin is my proof-of-concept how better to expose the SOMA Tilt. I hope to feedback my findings to Wazombi Labs for inclusion in the SOMA Connect.

SOMA Connect

SOMA Connect is available as a Raspberry Pi image here. It can also be written to an SD card using the Raspberry Pi Imager. The image provides the light version of PiOS, without the graphical environment. I'm now running it on a Pi 3B+, connected to the network wired over Ethernet, after some stability issues using a Pi Zero W, over WiFi.

SSH access is disabled by default, but easily enabled by placing an ssh file in the boot partition of the SD card, see Remote Access. That way, you don't need to connect a monitor and keyboard. After installing pigpio, the Pi can be monitored remotely by Homebridge RPi.

It looks like the SOMA Connect software is based on HAP-NodeJS alright, but, unfortunately, it's not open source. They seem to have packaged NodeJS, HAP-NodeJS and the SOMA-specific Javascript code into a single soma-connect executable. There doesn't seem to be an easy way to enhance their Javascript code. The executable runs as root, probably to interact with the Bluetooth Low Energy hardware. It looks like soma-connect opens the mDNS port exclusively, so running Homebridge on the same Raspberry Pi as SOMA Connect doesn't seem feasible.

Command-Line Tool

Homebridge SC include a command-line tool, sc, to interact with the SOMA Connect from the command line. It takes a -h or --help argument to provide a brief overview of its functionality and command-line arguments.

Configuration

In Homebridge's config.json you need to specify Homebridge SC as a platform plugin, and provide the IP address of the SOMA Connect.

  "platforms": [
    {
      "platform": "SC",
      "hosts": [
        {
          "host": "192.168.x.x"
        }        
      ]
    }
  ]

If you have multiple SOMA Connect servers, for better Bluetooth signal coverage, you might need to whitelist which devices are exposed through which SOMA Connect:

"platforms": [
  {
    "platform": "SC",
    "hosts": [
      {
        "host": "192.168.x.x",
        "shades": [
          "AA:AA:AA:AA:AA:AA",
          "BB:BB:BB:BB:BB:BB"
        ]
      },
      {
        "host": "192.168.x.y",
        "shades": [
          "CC:CC:CC:CC:CC:CC"
        ]
      }      
    ]
  }
]
1.1.5

8 months ago

1.1.4

9 months ago

1.1.3

10 months ago

1.1.2

11 months ago

1.1.1

1 year ago

1.1.0

1 year ago

1.1.0-3

1 year ago

1.1.0-2

1 year ago

1.1.0-1

1 year ago

1.1.0-0

1 year ago

1.0.22

1 year ago

1.0.21

1 year ago

1.0.24

1 year ago

1.0.23

1 year ago

1.0.19

1 year ago

1.0.20

1 year ago

1.0.18

2 years ago

1.0.17

2 years ago

1.0.16

2 years ago

1.0.17-0

2 years ago

1.0.15-2

2 years ago

1.0.15-1

2 years ago

1.0.15-0

2 years ago

1.0.15

2 years ago

1.0.14

2 years ago

1.0.13

2 years ago

1.0.12

2 years ago

1.0.11

2 years ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.10

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

3 years ago

1.0.1

3 years ago

1.0.0

3 years ago

0.0.6

3 years ago

0.0.5

3 years ago

0.0.4

3 years ago

0.0.3

3 years ago

0.0.2

3 years ago

0.0.1

3 years ago

0.0.0

3 years ago