Amniotic: An ambient sound mixer for Home Assistant, for Sound Masking, Sleep Sounds, etc

Hi all!

I’ve finally released my first Home Assistant project, just as I’d long threatened! It’s published on GitHub and PyPI. If you happen to fall into its tiny niche of interest, check it out!

Amniotic

A multi-output ambient sound mixer for Home Assistant.

Amniotic lets you use a single device to create on-the-fly, custom ambient audio mixes - e.g. mixing Waterfall sounds with Birdsong on one set of speakers, while playing Fireplace sounds from a second audio device - to suit your tastes and environment.

The library integrates with Home Assistant via MQTT as a new device, allowing you to create and control ambient mixes from the Home Assistant interface.

The latest update allows installing as a Home Assistant Addon!

Home Assistant Addon

To add as an Addon, click here:

Open your Home Assistant instance and show the add add-on repository dialog with a specific repository URL pre-filled.

Why Would I Want Such a Thing?

I won’t explain the general reasons for introducing non-musical sounds into one’s environment, but if you find sound masking helps you concentrate in noisy environments, if you’re (as I am) slightly misophonic, if you use white noise machines to induce sleep or relaxation, or if you just think sound is an important factor in setting a pleasant ambience, then you might find Amniotic useful.

Can’t I do This with Spotify, Volumio, HifiBerry etc.?

Since those systems are intended for music, they aren’t designed for playing or mixing multiple streams simultaneously with a single device, even if set up in multi-room configurations. Also, the streaming services often won’t allow a single account to play multiple streams, even if multiple devices are used.

These limitations motivated me to create Amniotic.

Switching between Themes with the Theme pull-down, you’ll be able to enable/disable each one, set their relative volume and their output devices etc.

Since these controls are exposed as Home Assistant entities, you can also define and play custom mixes from scenes, scripts, automations, etc. - and anything else Home Assistant will allow.

8 Likes

Now updated to run as a Docker Image:

Docker Image

There’s also a pre-built Docker Image available, so you can run on a NAS or home server etc. To run in container, use this command to map through sound devices, audio and config files:

docker run --device /dev/snd --volume <local audio path>:/root/.local/share/amniotic --volume <local config path>:/root/.config/amniotic/ fmtr/amniotic:latest
1 Like

The latest update adds sensor entities to expose more information about the media currently playing within the selected Theme.

Update with pip install amniotic --upgrade

1 Like

The latest update exposes the updater to Home Assistant, so newer versions can be installed from there. Updating will restart automatically and the device will reappear running the latest version, so all quite seamless.

Update controls:

image

Update status (sensor):

image

1 Like

The latest update quite a major update one.

Themes can now be created and populated all via the Home Assistant interface (so you don’t need local files). I’ve added a YouTube link downloader, so you can build themes from YouTube ambient audio videos. Amniotic will split out the audio track and download it into your current Theme.

Is there a way to install it as a Supervisor addon? Because im running HassOS

1 Like

Hi!

This was on “the list” but wasn’t much of a priority as it’s not my personal use case. Even so, I’ve just had a look at what it would involve, and it would probably be a lot simpler than I’d imagined.

I’ll probably take a look at it fairly soon. Keep an eye on this thread!

The latest update allows installing as a Home Assistant Addon!

Home Assistant Addon

To add as an Addon, click here:

Open your Home Assistant instance and show the add add-on repository dialog with a specific repository URL pre-filled.

I just installed it as an addon but sadly it doesnt detect my Media players. Theres only Standard and Dummy. All my other Devices are Google cast Devices and available als media_player entities

Ah. So it doesn’t communicate with external media entities. The audio devices it lists in the Addon are directly connected to the HA instance. I’m assuming you don’t see any cos you don’t have any installed (or passed through).

So in my test use case, for example, the Pi running HA has a USB DAC and a USB Speaker connected, and Amniotic can output Themes to one (or more) of them.

1 Like

This is really nice. Can’t use it though, all my devices are also media players.

2 Likes

+1. All my home speakers are driven by Google chromecast audio devices.

2 Likes

Thanks for the feedback! Since it isn’t my use case, I hadn’t targeted media_player entities. Not sure how feasible it will be. But since there seems to be more interest in that, I’ll look at what it will involve.

4 Likes