Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

sony-cisip2

Python 3.12+ CI License

HA-agnostic async Python client for Sony CIS-IP2 over Ethernet/IP (TCP port 33336). Control power, volume, inputs, and other features on compatible Sony AVRs and soundbars on your local network.

The GitHub repository is named sony-cispy. The PyPI package and import are sony-cisip2 / sony_cisip2.

CIS stands for Custom Installation Services (or Solutions) — the Sony-specific local control protocol used by custom-install systems.

This is a protocol library, not a Home Assistant integration. Integrations that speak CIS-IP2 can depend on this package.

Status

Alpha (0.1.0a1 on PyPI). APIs may change before 1.0. See CHANGELOG.md.

Features

  • Universal get_feature() / set_feature() API for any CIS-IP2 feature
  • Command ID tracking with futures for reliable request/response matching
  • Real-time notification callbacks
  • JSON stream decoding with remainder across TCP read fragments
  • Auto-reconnect with exponential backoff after unexpected drops
  • Full command catalog via commands_dict
  • Stdlib only (no runtime dependencies)
  • Async/await (Python 3.12+)

Device compatibility

Enable IP/network control on the device (menu names vary: "External Control", "Simple IP Control", "IP Control", etc.). Quick check with netcat:

netcat <IP_ADDRESS> 33336
{"id":3, "type":"get","feature":"main.power"}

A JSON result for main.power means the port is reachable and control is on.

Install

Requires Python 3.12+.

pip install sony-cisip2

From a checkout:

pip install -e ".[dev]"

Quickstart

import asyncio
from sony_cisip2 import SonyCISIP2

async def main():
    async with SonyCISIP2(host="192.168.1.100") as client:
        power = await client.get_feature("main.power")
        if power is None:
            print("get main.power timed out or failed")
            return
        print(f"Power: {power}")
        result = await client.set_feature("main.volumestep", 50)
        print(f"set volume: {result}")

asyncio.run(main())

See example.py and src/sony_cisip2/README.md for notifications, command discovery, and more features.

Requirements

  • Python: 3.12 or higher
  • Dependencies: none (standard library only)

Project layout

sony-cispy/                 # GitHub repo root
├── src/sony_cisip2/        # Installable package
│   ├── client.py           # SonyCISIP2
│   ├── commandset.py
│   ├── constants.py
│   └── variables.py
├── tests/
├── tools/live_smoke.py     # Manual device smoke (CISIP2_HOST; not in CI)
├── reference/              # Historical sources (not shipped in the wheel)
├── example.py
└── pyproject.toml

Development

pip install -e ".[dev]"
ruff check . && ruff format --check .
mypy
pytest -q
python -m build && twine check dist/*

Optional live smoke against a device on your LAN (not run in CI):

CISIP2_HOST=<device-ip> CISIP2_SKIP_EXEC=1 python tools/live_smoke.py
CISIP2_HOST=<device-ip> python tools/live_smoke.py

Release process: docs/releasing.md.

License

MIT — see LICENSE.

Disclaimer

This library is not affiliated with or endorsed by Sony. Use on hardware you own. Protocol support varies by model and firmware.

Metadata

Release files for sony-cisip2 0.1.0a1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for sony-cisip2 0.1.0a1
File Size Uploaded
sony_cisip2-0.1.0a1.tar.gz 32.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for sony-cisip2 0.1.0a1
File Interpreter ABI Platform
sony_cisip2-0.1.0a1-py3-none-any.whl Python 3 none any Details

Total release size: 49.0 kB

Release files / sony_cisip2-0.1.0a1.tar.gz

Download URL sony_cisip2-0.1.0a1.tar.gz
Size 32.6 kB
Tags Source
SHA-256 checksum
How to use checksums
40c3a220dfa3eb6da5568800b0f09be278b8519d33ca548a63b2c6247c81189f
BLAKE2b-256 checksum
How to use checksums
b946921c84570690ec1a69d981184da75c827415783646dbd6dc1af3b00e97ab
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 26, 2026.

Transparency log

Release files / sony_cisip2-0.1.0a1-py3-none-any.whl

Download URL sony_cisip2-0.1.0a1-py3-none-any.whl
Size 16.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
ada68f13a0eada05e69f7bda5eb4cd85171fba67aa5675bbba440b517920c502
BLAKE2b-256 checksum
How to use checksums
51be232ad9e740199331317d16f40a47a025d9a6f22a4353cf7497c5a66f0569
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Jul 26, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.0a1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page