[mythtv-users] Audio Video Sync on v31 and Alsa Buffer Size

Stephen Worthington stephen_agent at jsw.gen.nz
Sun Jun 7 11:43:27 UTC 2020


On Sun, 7 Jun 2020 11:55:30 +0100, you wrote:

>On 07/06/2020 11:23, Stephen Worthington wrote:
>> On Thu, 04 Jun 2020 05:19:24 +1200, you wrote:
>> 
>(snip)
>> 
>> To further complicate things, if you change the audio device that
>> MythTV is using (say you plug in a TV with audio over HDMI and you
>> switch to using that, instead of the motherboard audio device(s)),
>> then the prealloc will need to be set for the new device.
>> 
>If this is true then it seems to me that the surest way of doing what is required would be with one 
>or more udev rules. That would apply the needed correction as root and at exactly the right times.

Unfortunately that does not work.  It was tried many years ago when
this problem first cropped up.  It seems (yet to be confirmed) that
when mythfrontend is using the audio device, not even root can change
the prealloc value.  Udev rules may be able to give mythfrontend the
ability to write to the prealloc setting, but mythfrontend also may
well not be able to write to the prealloc setting even then if it has
the audio device already open, which seems to be what is happening. So
if someone would like to try altering mythfrontend to close the audio
device and then try setting the prealloc value itself, before
reopening the audio device, that might work with the correct udev
permissions settings.  Or with mythfrontend running an external helper
file that has sudo permissions.

There would still be the problem of finding all the audio prealloc
settings devices and writing a udev rule for each one to allow mythtv
group to have access.  And, of course, these days there are plug-in
USB audio devices (eg DACs of many sorts) which can be plugged in at
any time.  There would also need to be a udev rule created for them if
they were used.  I am not sure if it would be possible to create a
generic udev rule that would allow access to any audio prealloc
settings device.


More information about the mythtv-users mailing list