Skip to main content

Integration of Raumfeld into Home Assistant

Project description

hassfeld

CI CodeQL PyPI version

Python library for controlling Teufel Smart Speakers (Raumfeld multiroom system). Designed as the companion library for the teufel_raumfeld Home Assistant integration, but can be used standalone in any Python project.

The module provides both asynchronous (asyncio) and synchronous APIs.


Features

  • Media discovery — Find rooms, zones, and their playback capabilities via UPnP/DLNA
  • Media control — Play, pause, stop, next, previous, seek
  • Volume control — Per-room and per-zone
  • Source selection — Line-In, Spotify, Tidal, Internet radio, local music
  • Search — Search and play tracks across all sources
  • Zone management — Create, modify, and snapshot room groups
  • Web service API — Full access to the Raumfeld REST/SSDP services

Installation

pip install hassfeld

Usage

Async (recommended)

import asyncio
import aiohttp
import hassfeld


async def main():
    host = "teufel-host.example.com"
    port = 47365
    session = aiohttp.ClientSession()
    raumfeld = hassfeld.RaumfeldHost(host, port, session=session)

    asyncio.create_task(raumfeld.async_update_all(session))
    await raumfeld.async_wait_initial_update()

    zone = ["Master Bedroom"]

    media_info = await raumfeld.async_get_media_info(zone)
    print(f"Media info: {media_info}")

    await session.close()


asyncio.run(main())

Synchronous

import hassfeld

raumfeld_host = "teufel-host.example.com"
zone = ["Living room", "Kitchen"]

raumfeld = hassfeld.RaumfeldHost(raumfeld_host)
raumfeld.start_update_thread()
raumfeld.search_and_zone_play(zone, 'raumfeld:any contains "Like a Rolling Stone"')

Note: The synchronous API currently has known issues. See issue #3. Async usage is recommended.


Links

Source code GitHub
Issue tracker GitHub Issues
PyPI hassfeld on PyPI
teufel_raumfeld HA Integration

License

GNU General Public License v3 (GPLv3)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hassfeld-0.3.14.tar.gz (30.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

hassfeld-0.3.14-py3-none-any.whl (29.9 kB view details)

Uploaded Python 3

File details

Details for the file hassfeld-0.3.14.tar.gz.

File metadata

  • Download URL: hassfeld-0.3.14.tar.gz
  • Upload date:
  • Size: 30.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.25 {"installer":{"name":"uv","version":"0.11.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for hassfeld-0.3.14.tar.gz
Algorithm Hash digest
SHA256 d2dfdabce1b5c8e32b58cbb218a87c23f3e0553877f644bb60b4c577c77918a7
MD5 25b1e555ad85832d9296e07cae158c2d
BLAKE2b-256 ce7ceec6d8aaf0aac8c45c46424ab4d16772cc02685351b2e554392f463afad5

See more details on using hashes here.

File details

Details for the file hassfeld-0.3.14-py3-none-any.whl.

File metadata

  • Download URL: hassfeld-0.3.14-py3-none-any.whl
  • Upload date:
  • Size: 29.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.11.25 {"installer":{"name":"uv","version":"0.11.25","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for hassfeld-0.3.14-py3-none-any.whl
Algorithm Hash digest
SHA256 2c9111be65defa057f1fa582d3116d502f0748b1ef066c23d509accf93e22eef
MD5 ee96beae960b6026ebb7ef2edeb0a447
BLAKE2b-256 755f9f6b3a6062ed986ad7e4169a5b05b4ca9e80eb9ac7de7fa4811d7e8b1511

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page