Jessica Journals

  • 🏠 Home
  • πŸšͺ Rooms
  • πŸ“ƒ Posts
  • 🏷️ Tags
  • πŸ‘© Me
  • πŸ““ Now
  • πŸ–₯️ Uses
  • 🌐 Website
  • πŸ“° RSS

Adding Radio To An Ambient Music Server

2509 Words β€” Estimated Reading Time: 12 Minutes
Created: 2025-07-09

Table of Contents

  • A Type Of Choice Paralysis
  • Ersatz TV (For Radio?)
  • Setting Up
    • Songs Metadata
    • Songs Fallback Metadata
  • Clients
  • Future

Earlier this year, I wrote about expanding my ambient music server, using AudioBookShelf to play both podcasts and audio content downloaded from YouTube via PinchFlat - mostly relaxing music, guided meditations and ASMR sounds. In this post, I’ll go into a recent addition to this setup: creating themed “radio” stations of what I downloaded from YouTube.

A Type Of Choice Paralysis

Since adding PinchFlat to my setup, I’ve gathered a collection of all sorts of various sounds, including ASMR, nature and relaxing hums at various frequencies. The issue I soon encountered was that while these were nice, and I knew roughly what sort of sound I was intending to listen to, deciding exactly which file to play became a bit overwhelming. It reached a point where I spend more time choosing what to play than actually listening to it.

Furthermore, I had also expanded into some more upbeat generic “elevator” type music, which relaxed my brain in a different way, and I found to be good focus music when undertaking a task as background music or simply when getting ready in the morning. This also suffered from my sort of choice paralysis after a few weeks.

Ersatz TV (For Radio?)

I had previously considered running radio stations on my home network as an alternative to making playlists of shuffled songs with similar genres, where I could quickly dip in and out without much thought. But although I read up about applications like AzureCast, they weren’t really what I was after - such applications were designed to be actual radio stations streaming outwards to audiences. Also, a station would be running 24/7 and I felt that would be a waste to resources, especially if I was running multiple stations. So, I abandoned the idea.

Earlier this week though, I saw this thread on the /r/selfhosted subreddit, with the original poster talking about setting up a local IPTV for their home using Ersatz TV, with themed “TV stations” created by streaming content from their video collection. They showed examples of a mixed British comedies channel, a dedicated Simpsons channel, a personalised MTV channel showcasing their favourite music videos, and so on. What’s even better is that this software doesn’t run 24/7, and only activates when someone starts streaming from a channel, and this can be emulated to stick to a strict schedule, where if you tune into an episode that started at 5pm at 5:10pm, you’ll come into the stream with the episode already ten minutes in. Or, it can operate on a simple shuffle, which can be modified to start at the start of the content, or come in at a random time to really simulate the experience of just turning on a channel and just seeing what happens to be on.

All this alone is extremely neat, and I was impressed not just with the software, but also how dedicated the original poster had been at setting everything up, curating those 750 music videos, creating TV channel icons, and even implementing commercials! Unfortunately for me, I will not be able to recreate such a fantastic setup with my current limited low-end hardware as my server is unable to transcode video and I don’t believe HLS Direct/Direct Play is an option, based on various posts I’ve seen across the internet. However, you know what needs minimal transcoding? Songs!

Yes, alongside assigned libraries for TV Shows, Movies, Music and Other Videos, there is also an option for Songs, where instead of playing a curated selection of TV shows, Ersatz TV can play your selected music with a small aspect of transcoding where it generates an image on screen showing the names of the artist, album and song, cover art, and a blurred background based on the cover art. This, combined with how the stream only starts when you open it, not running 24/7, made me think I had found what I was looking for, overcoming my kind of choice paralysis: create themed “radio” stations based on what I’ve downloaded from YouTube, and listen to them like this rather than from AudioBookShelf, because I’m not picky to the exact file I wish to play, I just know the sort of sound/genre I want. But not only that, I could also make radio stations of genres of music I listen to casually, as I wanted when looking into AzureCast, such as the LoFi, FutureFunk and Vaporware music I downloaded from BandCamp.

Setting Up

I found setting up the stations a tad complicated, so I’ll explain here how I did it not just to share, but to remind me if I wish to add more radio stations in the future!

For this example, I’ll walkthrough the creation of my LoFi radio channel, using local audio files saved on the same disk (though integrations with JellyFin, Plex and Emby also exist). But before we begin, we need to understand how Ersatz TV identifies and tags files, here is what the official documentation says:

Songs Metadata

Songs will have basic metadata pulled from embedded tags (artist, album, title).

Songs Fallback Metadata

Songs will have a tag added to their metadata for every containing folder, including the top-level folder. As an example, consider adding a songs folder with the following files:

  • Rock\Awesome Band\Awesome Album\01 Track 1.flac
  • Rock\Awesome Band\Better Album\05 Track 5.flac

Your songs library will then have two media items with the following metadata:

  1. title: 01 Track 1, tags: Rock, Awesome Band, Awesome Album
  2. title: 05 Track 5, tags: Rock, Awesome Band, Better Album

As a result, simply pointing Ersatz TV to either my BandCamp collection or to the downloaded YouTube content won’t be very helpful later on when selecting which files play on which channel. Either I would have to manually organise track-by-track in Ersatz TV, or I can make my life easier from the start by creating a new directory solely for the purposes of these radio stations. Choosing the latter, creating a new folder titled “IPTV”, I organise my files into folders by genre and then either by artist or just having the files placed loose in the folder. For example:

/IPTV/Music/LoFi/Sleepy Fish/ or /IPTV/Music/Nature Sounds/

By doing this, I can later run a search for tag_full:"LoFi" or tag_full:"Nature Sounds"and all the files in that folder will appear, making it easy to add everything in that folder to where I want it to be.

So,your first step is to organise your files into genres if you’re doing something like I am! After that, I installed Ersatz TV and then began properly:

  1. Go to Media Sources and then Local. Press the pencil icon next to Songs. Add the path to the audio files. Mine was /IPTV/Music

  2. Go to Media and then Libraries. Find the Songs library and press the “refresh” symbol next to the magnifying glass. Let it fully scan your files.

  3. Go to Media and then Songs to verify this worked. Your files should be there with metadata and cover art.

  4. Go to FFmpeg Profiles, and press on Add Profile.

  5. Although this is for audio, due to the generation of a screen showing the artist, album and track titles, as well as cover art, there are some video settings that are relevant here. To save on transcoding resources, I have mine set as followed, but if you have a more powerful machine, you may be able to increase these options, and you may also be able to offset transcoding to a graphics card by fiddling around the Hardware Acceleration setting.

    • Name: Audio

    • Thread Count: 0

    • Preferred Resolution: 640x480

    • Scaling Behaviour: Scale and Pad

    • Video Format: h264

    • Video Profile: high

    • Video B-Frames [unticked]

    • Video Bit Depth: 8-bit

    • Video Bitrate: 500

    • Video Buffer Size: 4000

    • Video Hardware Acceleration: None

    • Video Tinemap Algorithm: Linear

    • Video Normalize Frame Rate [unticked]

    • Video Auto Deinterlace Video [ticked]

    • Audio Format: aac

    • Audio Bitrate: 320

    • Audio Buffer Size: 384

    • Audio Channels: 2

    • Audio Sample Rate: 48

    • Audio Noramlize Loudness: Off

      Press Add Channel.

  6. Go to Channels and press on Add Channel. Give your channel a number and a name. You can also add other features like adding it to a group, and giving it a logo and watermark. I then changed the following settings:

    • Progress Mode: Always
    • Streaming Mode: HLS Segmenter
    • FFmpeg Profile: Audio

    Press Add Channel.

  7. Go to Lists and then Collections. Press on Add Collection, give it a name, and then on Add Collection.

  8. You’ll then be back at the Collections page. At the top of the screen, you will see a search bar. As I am making my LoFi collection and I already put all my LoFi music into a folder titled LoFi, I then typed this into the search bar: tag_full:"LoFi" and all my music I placed in that folder appeared.

Please note: This is case sensitive, you need to be exact - “Lofi” or “lofi” doesn’t work for me as my folder is “LoFi”!

When you see your files, and they’re correct, press on the button top-right “+ Add All”. A pop-up will appear, press on (New Collection) and I selected my LoFi collection. I then pressed Add To Collection. You can verify if this worked by going back to Collections and pressing the pencil next to your collection, and all the files should load.

  1. Go to Scheduling and then on Schedules. Press on Add Schedule. I then had the following settings:
  • Name: LoFi
  • Keep Multi-Part Episodes Together [unticked]
  • Treat Collections As Shows* [unticked]
  • Shuffle Schedule Items [ticked]
  • Random Start Point [ticked]
  • Fixed Start Time Behaviour: Flexible

If you wish for the tracks to start at their start, untick Random Start Point.

When you are done, press on Add Schedule.

  1. You’ll then be at a new screen, press on Add Schedule Item. A lot of settings appear here, but I only needed to adjust one option. Where it says “Type to search…” under Collection, type in your collection name and select it when it appears. Then press on Save Changes.

  2. Go to Schedules and then Playouts. Press on Add Playout, select the channel you created back in step 2, and then the schedule you named in step 5. For me, both of these were called LoFi.

  3. And you are pretty much done!! Go back to Channels and you should see a little play button lit up next to your channel. When you press on it, a pop-up should appear and then after a little wait (depending on the power of your resources), the screen should change to show a graphic of the track playing, and you should be able to hear your audio! For more stations, just keep repeating these steps, adjusting the names throughout for as many stations as you desire, and of course, if you do have better hardware than I do, feel free to experiment with the FFmpeg settings to improve the stream’s quality.

Clients

However, that play button is a preview, not designed for actually playing the radio stations. On that Channel page, there are two buttons at the top: M3U and XMLTV, here you can grab files and URLs to then import into clients of choice to play the audio. I’ve found the simplest one to be VLC, where it immediately begins to play channel 1, though pressing the Playlist button gives you the option to change to other stations - as such, I’d recommend making sure channel 1 is a relatively “chill” station if you removed the default Ersatz TV channel on channel 1 so you aren’t blasted with loud music straight away! You can always change the channel number, as well as later add watermarks (need to be setup first elsewhere though) and channel logos, by pressing the pencil icon next to the channel on that Channels page.

VLC is not perfect though. While fine on my computer, it does not like the screen being turned off on my Android devices, because although the generated graphic is great, I may not need it on all the time and would like the choice to save battery by having the screen off. This led to a bigger dilemma as this isn’t actually a radio station, and VLC treats it as a video channel. I initially tried IPTV Player from the IzzyOnDroid repository, and although it has a lovely simple interface, playback nonetheless stopped when I turned my screen off. Digging around the Google Play Store, I came across IPTV by Alexander Sofronov, an app free with adverts, or paid to remove them. It again lays out the channels nicely after easily giving it my .m3u URL, and has a range of features including that to allow play in background, which continues playback when the screen is off!

Otherwise, there is also the option to integrate the channels into JellyFin, Plex and Emby, and you can use their various clients to access your Ersatz TV channels, which may be a more preferable option depending on your existing setup. It’s not something that interests me at this time, but I thought it was worth mentioning.

Future

One major downside to all this is that I cannot utilise my new music setup, where music is streamed via UPnP on a Raspberry Pi through a DAC to improve audio quality, so I have to play the music via Bluetooth, but even if I could use my DAC, Ersatz TV is compressing everything into .aac and a bitrate of 320. This isn’t a major issue for the content from YouTube as they’re already compressed, but I do feel it is a shame for the high quality .FLAC files downloaded from BandCamp.

However, at the end of the day, although I would either love audio to be streamed in its original high quality in Ersatz TV or for there to be a new sort of dedicated radio version of Ersatz TV focused on audio delivery, I think the bigger point is that I am now actually listening to my BandCamp music more, and that’s better than not listening to it at all, as what was happening before.

Looking forward into what is actually possible, rather than my wish of better audio quality, there are great possibilities with this powerful software that I haven’t even begun to tap into yet! Not only could I upgrade my hardware for a higher quality performance, but I could look into creating custom logos for each of my channels, and even go into creating audio clips to insert as audio idents - small audio clips that play between tracks on more traditional radio channels, usually announcing the name of the channel, telling the listener the channel’s frequency, or delivering a tag line. Heck, you could even add in radio commercials, real or ficational! And although there is ErsatzTV Filler to supply great filler connect visually, such as news and weather reports, I am unsure if it’s something I want to integrate into my audio based streams, I’ll need to think it over more. For now, I’m satisfied with my endless streams of ambient music, ASMR and nature sounds, and the bonus addition of selected genres of my BandCamp music also now more accessible!

Room: Basement
Tags: Music Setup

WebMentions

What is a WebMention? - Send a WebMention
Β© Jessica 2020 – 2025