ATSC 3.0

Lost Dog
Junior
Posts: 36
Joined: Sat Feb 08, 2014 4:18 pm
United States of America

Re: ATSC 3.0

Post by Lost Dog »

kmdewaal wrote:
Sun Apr 04, 2021 7:21 am
And now also the patch.....
Log attached!

I'll let you know when I hear back from someone at SiliconDust.
Attachments
mythtv-setup.20210404153634.23224.log.zip
(54.92 KiB) Downloaded 475 times
Lost Dog
Junior
Posts: 36
Joined: Sat Feb 08, 2014 4:18 pm
United States of America

Re: ATSC 3.0

Post by Lost Dog »

For AC-4 support I tried manually editing the MythTV FFMPEG directory with the patches here:

https://github.com/FFmpeg/FFmpeg/compar ... ff=unified

It keep throwing an error during compile:

Code: Select all

libavformat/mpegts.c: In function ‘ff_old_parse_mpeg2_descriptor’:
libavformat/mpegts.c:2077:25: error: ‘AVStreamInternal’ {aka ‘struct AVStreamInternal’} has no member named ‘request_probe’
 2077 |             st->internal->request_probe = 0;
      |                         ^~
make[2]: *** [ffbuild/common.mak:59: libavformat/mpegts.o] Error 1
make[2]: *** Waiting for unfinished jobs....
I know zero about coding but I've been trying to copy the ac-3 formats seen in mpegts.c but so far no luck... No idea why "request_probe" throws an error.
User avatar
kmdewaal
Developer
Posts: 640
Joined: Wed Dec 07, 2016 8:01 pm
Netherlands

Re: ATSC 3.0

Post by kmdewaal »

For this error you can try

Code: Select all

st->request_probe = 0
The AC-4 patch must be from a different version of ffmpeg than what is in mythtv. But it just might work....
Lost Dog
Junior
Posts: 36
Joined: Sat Feb 08, 2014 4:18 pm
United States of America

Re: ATSC 3.0

Post by Lost Dog »

kmdewaal wrote:
Mon Apr 05, 2021 8:55 am
For this error you can try

Code: Select all

st->request_probe = 0
The AC-4 patch must be from a different version of ffmpeg than what is in mythtv. But it just might work....
That seemed to work and it compiled cleanly but I was not able to get any audio playback. At this point I think it's a bit beyond my pay grade...
User avatar
kmdewaal
Developer
Posts: 640
Joined: Wed Dec 07, 2016 8:01 pm
Netherlands

Re: ATSC 3.0

Post by kmdewaal »

The way forward is to make a development branch of mythtv and then update ffmpeg to the development version that supports AC-4. Since that is also beyond my pay grade we have to ask this friendly and then it just might happen, but we have to have ATSC-3.0/AC-4 recordings first to make that useful.
User avatar
gigem
Developer
Posts: 5
Joined: Fri Feb 07, 2014 8:19 pm
United States of America

Re: ATSC 3.0

Post by gigem »

The current, internal, HDHR recorder in MythTV is incompatible with the HDHR5-4K except when only ATSC 1.0 channels are used. The reason is due to a limitation in the HDHR API. There is no way to specify which modulation is needed when allocating a tuner. This limitation is very unlikely to be fixed as Silicon Dust considers that old, API to be obsolete.

The only current way to record mixed ATSC 1.0 and 3.0 programs with the HDHR5-4K is to use the external, mythhdhrrecorder (https://github.com/garybuhrmaster/mythhdhrrecorder). That recorder works because it uses the new, HTTP API preferred by Silicon Dust.

In addition, MythTV must be configured to use the HDHR5-4K with two videosources. One videosource must only contain the ATSC 1.0 channels and have up to 2 tuners assigned to it. The other videosource must only contain the ATSC 3.0 channels and have up to 2 tuners assigned to it. As I understand it, that is the only way to force the use of either ATSC 1.0-only or ATSC 1.0/3.0 tuners. Without that control, there will be cases where recordings fail because the correct type of tuner is not available when needed.
Lost Dog
Junior
Posts: 36
Joined: Sat Feb 08, 2014 4:18 pm
United States of America

Re: ATSC 3.0

Post by Lost Dog »

Here's the reply from someone on the SiliconDust forum:
libhdhomerun is a waste of your time for this since the way MythTV uses it is designed around broadcasts being transport streams. ATSC 3 doesn't use transport streams, so there's really no point in trying to cram that square peg into the round hole. You're better off using ExternalRecorder and mythhdhrrecorder. When tuning by virtual channel as mythhdhrrecorder does, the HDHomeRun converts the stream to a TS in realtime, so it more or less just works with existing solutions as long as you support HEVC and AC-4. I assume MythTV already has HEVC support implemented for European countries that are using it. AC-4 support exists in an ffmpeg fork that you can find linked elsewhere on this forum.
User avatar
kmdewaal
Developer
Posts: 640
Joined: Wed Dec 07, 2016 8:01 pm
Netherlands

Re: ATSC 3.0

Post by kmdewaal »

OK, those are both good answers. The way forward is to use the mythhdhrecorder and the externalrecorder. Once you have that all running it would be very good to put the whole procedure somewhere on the MythTV WIki to help everybody who is struggling with this. And once there are recordings we can have a go at the AC-4 audio.
ulmus-scott
Junior
Posts: 41
Joined: Sat Jun 05, 2021 12:50 am
United States of America

Re: ATSC 3.0

Post by ulmus-scott »

Regarding codec support in ffmpeg, see:
#5514 (Interlaced HEVC Steam not Decoded Properly) maybe also https://trac.ffmpeg.org/ticket/4141
#8349 (Dolby AC-4 Support)
I couldn't find anything about MPEG-H 3D audio.
On the first two tuners it can detect the ATSC 3.0 channels but they have the same virtual number as the ATSC 1.0. This causes problems (SiliconDust's solution for the hdhomerun_config_gui app is to [prepend] a 1 to the start of the virtual number to separate the ATSC 3.0 from 1.0).
This is a reasonable solution to be able to uniquely identify each channel. N.B. the channels must carry equivalent programming to use the same channel number.

From ATSC A/65 §6.3.1 Terrestrial Virtual Channel Table and Annex B, major_channel_number shall be between 1 and 99 and minor_channel_number shall be between 1 and 999 (0 is reserved for analog).

From ATSC A/331 §6.3 Service List Table (SLT) (also refernces A/63 Annex B), I’m not sure if the range of major channel number is [1, 99] as above or [1, 999]. Regardless, adding 100 will generate unique ids.
User avatar
jfabernathy
Senior
Posts: 577
Joined: Wed Feb 18, 2015 2:37 pm
Location: Raleigh, NC
United States of America

Re: ATSC 3.0

Post by jfabernathy »

I'm curious where this topic stands now? I've been curious about what ATSC 3.0 means to me and I could do some testing if it moves the project forward.

I have a test system built on the 11th Gen Intel 1165G7. It is using mythtv v32-pre built from master or sometimes a devel branch. I currently use only the HDHR Quatro, but I've been thinking about getting one of the 4K capable tuners to play with. I've been using mythtv long enough to remember when HDHR tuners transitioned from using UDP to the TCP and HTTP formats first with mythhdhrrecorder and now integrated in the main stream.

I live in an area, near Raleigh, NC, USA where all 4 major networks plus PBS have some level of ATSC 3.0 being transmitted. I'm about 10 miles from the main TV tower farms, so I should be able to receive something. I've just been looking for a reason to buy one of the new HDHR tuners.

I also have several FireTV 4K, including MAX alone with a Shield TV which seem to have newer playback formats.

I have time to play with this as I'm retired and semi-locked down due to Covid-19 so I'm looking for an interesting project this winter.
User avatar
paulh
Developer
Posts: 909
Joined: Thu Feb 06, 2014 6:09 pm
Great Britain

Re: ATSC 3.0

Post by paulh »

I live in the UK so ATSC 3.0 is of no interest to me so I've not been following developments but from what I can recall the big problem is with the audio codec used and lack of support in ffmpeg.

https://trac.ffmpeg.org/ticket/8349
Last edited by paulh on Fri Dec 31, 2021 1:22 pm, edited 1 time in total.
Reason: Add ffmpeg ticket
Qmann
Newcomer
Posts: 10
Joined: Fri Dec 16, 2022 10:55 pm
Location: Behind enemy lines
United States of America

Re: ATSC 3.0

Post by Qmann »

@jfabernathy did you ever do any testing?
User avatar
jfabernathy
Senior
Posts: 577
Joined: Wed Feb 18, 2015 2:37 pm
Location: Raleigh, NC
United States of America

Re: ATSC 3.0

Post by jfabernathy »

Qmann wrote:
Fri Dec 16, 2022 10:59 pm
@jfabernathy did you ever do any testing?
No, I don't have a HDHR 4K yet. I did buy a new TV with an ATSC 3.0 tuner, but they aren't broadcasting in 4K yet, so what's the point.
bobmyth
Newcomer
Posts: 6
Joined: Fri Jul 03, 2020 12:17 am
United States of America

Re: ATSC 3.0

Post by bobmyth »

I have an HDHR 4k. There are no 4k broadcasts in my area. However, using the Superbowl as an example, my ATSC-1.0 recording at 14GB while the ATSC-3.0 broadcast recording was 4.3GB. Is there something I can do to help?
User avatar
paulh
Developer
Posts: 909
Joined: Thu Feb 06, 2014 6:09 pm
Great Britain

Re: ATSC 3.0

Post by paulh »

The problem is there is no open source decoder available for the AC4 audio that ATSC3.0 uses. There are some work in progress patches (see the ffmpeg ticket above) that adds some initial support to ffmpeg but they are incomplete and haven't been accepted by the ffmpeg devs.

If you compile your own source you could try to patch our copy of ffmpeg with the WIP patches and see if they work for you. I guess we could apply the patches ourselves but that could create a problem with later re-syncs to upstream ffmpeg so we would prefer to wait for ffmpeg to adds official support for AC4.
Post Reply