Project

General

Profile

Feature #5118

DAB radio from multistream

Added by saen acro over 6 years ago. Updated over 6 years ago.

Status:
New
Priority:
Normal
Assignee:
-
Category:
Demultiplex
Target version:
-
Start date:
2018-05-20
Due date:
% Done:

0%

Estimated time:

Description

Is it possible to be implemented as for other multistream services

Actually is possible im moment
with external software
https://github.com/piratfm/eti-tools
12303H 25546 7/8 QPSK/DVB-S 4.8 East

curl http://127.0.0.1:9981/stream/mux/beb...5e3d?pids=1061 | ./ts2na -p 1061 -s 12 | ./na2ni | ./ni2http --list
INFO: Using pid: 0x0425 (1061)
WARN: Forwarded error correction disabled (NOT COMPILED)
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0INFO: E1 Sync found at bit: 314, inverted: yes
DEBUG: seek: B:39, b:2
DEBUG: pre-readed output 14 frames (24 bytes left):
DEBUG: MULTIFRAME FILLING: 206
INFO: ETI Sync found at pos: 4
INFO: ETI Multiframe sync found at blockId: 10
100 249k 0 249k 0 0 178k 0 --:--:-- 0:00:01 --:--:-- 178kBBC National DAB (0xce15)
0 : BBC Radio 4Extra (0xc22c) Pri subch=12 start=774 CUs= 58 PL=uep 3 bitrate=80
1 : BBC Radio 1Xtra (0xc22a) Pri subch=10 start=582 CUs= 96 PL=uep 3 bitrate=128
2 : BBC AsianNetwork (0xc236) Pri subch= 7 start=486 CUs= 48 PL=uep 3 bitrate=64
3 : BBC WorldService (0xc238) Pri subch= 9 start=534 CUs= 48 PL=uep 3 bitrate=64
4 : BBC Radio 1 (0xc221) Pri subch= 1 start= 0 CUs= 96 PL=uep 3 bitrate=128
5 : BBC Radio 2 (0xc222) Pri subch= 2 start= 96 CUs= 96 PL=uep 3 bitrate=128
6 : BBC Radio 3 (0xc223) Pri subch= 3 start=192 CUs=140 PL=uep 3 bitrate=192
7 : BBC Radio 4 (0xc224) Pri subch= 4 start=332 CUs= 96 PL=uep 3 bitrate=128
8 : BBC Radio 5 Live (0xc225) Pri subch= 5 start=428 CUs= 58 PL=uep 3 bitrate=80
9 : BBC Radio 6Music (0xc22b) Pri subch=11 start=678 CUs= 96 PL=uep 3 bitrate=128

History

#1

Updated by da h4xX0rz1sT over 6 years ago

+1

I would love to have this feature on TVheadend, it's the one I'm missing the most. My usecase for TVh is bringing together all live media such as DVB-S/DVB-T/IPTV/Cameras and FM and record those per demand.

I've been fiddling around with the same tools and chain that you use, and also some others.

I currently just have Astra 1x 19,2°E satellite, that AFAIK unfortunately has no DAB/DAB+ to test with - if you know DAB/DAB+ streams on that sat please post it here, until I have my multifeed!

What you show is obviously an ETI (Ensemble Transport Interface) wrapped into a DVB transport stream, which makes stuff (relatively) easy.
You could feed ni2http into IceCast, and then use IceCast playlist and automatic IPTV network to feed it back into TVh, including metadata.
Another way is to extract a single station audio from the ETI via pipe, which seems to be the more direct way, but after audio extraction you have to feed it into ffmpeg and wrap it into MPEG TS, adding station name and other metadata back to it.

But currently these ways are rather complex, cumbersome and have a lot of drawbacks:
  • you can't automatically scan for ETIs, and stations inside the ETIs from TVheadend
  • you can't manage stations and logos from TVheadend
  • you need an additional service and a lot of external programs, making the whole software stack much more complex and error-prone
  • you may loose metadata, such as embedded text, images, EPG etc.
  • configuration is close to unmanageable, as you have to write a config section for each station you feed from ni2http, and AFAIK there currently is no tool to do that automatically

I'm receiving terrestrial DAB/DAB+ here in Germany, which makes the situation even more complex, since the ETIs are not wrapped inside DVB like on satellite.

If it is not wrapped inside DVB MPEG TS, that imposes even more issues:
  • you can't use standard DVB tools to scan and grab the streams (ETIs) from the tuner, but need to use the SDR way to access it (and a tuner that can act as SDR, of course)
  • you can't share a tuner between DAB/DAB+ and DVB-T/DVB-T2 terrestrial or cable reception, as either the external tools or TVh need exclusive access to the tuner

So the only way to do it in a proper and manageable way would be to implement DAB/DAB+ directly inside TVh.

Maybe the OpenDigitalRadio libraries can help, but I don't know how mature they are considering reception - OpenDigitalRadio was meant primarily for the other way around, to take streams, pack them into ETI and broadcast them.
Welle.io unfortunately seems to be unusable for that, too. rtl_dab_streamer only works on Windows and it obviously cannot support L-band as a source.

A quick-and-dirty solution could be
  • write a tool to scan for ETIs on DVB or SDR, list ETIs' stations, and output ETI and stations lists
  • write a tool to convert ETI and station lists to ni2http.conf and/or TVHeadend IPTV pipe

but as stated above this still wouldn't be a nice and proper solution.

And one more: proper FM radio is much the same issue, though a bit less complicated. Currently I use rtl_fm_streamer to grab some FM stations, push it through ffmpeg in an automatic IPTV network like this:

#EXTINF:-1 tvg-name="B5" group-title="Radio" radio="true" tvg-logo="",B5
pipe:///usr/bin/ffmpeg -loglevel fatal -i http://<rtl_fm_streamer_ip>:2346/102000000/1 -vn -acodec libmp3lame -ac 2 -ab 128k \
-metadata service_provider=FM -metadata service_name=B5 -f mpegts -mpegts_service_type digital_radio pipe:1

It has the same drawbacks shown above, no tuner sharing, station management sucks, but metadata is not such an issue, since there is (almost) none ;) (Yes, I know RDS and TMC) RDS can work if you use rtl_fm_streamer directly from Kodi, but I prefer to lose RDS but have central station management on TVh, even for the few stations I use.

Maybe anyone can help with other ideas how to integrate it into TVheadend. As always, thanks to the developers and anyone helping on that issue. If I can do anything help solve that problem, I'll participate for sure.

HTH,
/hxz

Also available in: Atom PDF