Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[vdr] Re: [ANNOUNCE] bitstreamout plugin 0.61 (sound loop through sound card)



On Sat, Jun 05, 2004 at 03:20:36PM +0200, Norbert Schmidt wrote:
> I did this in the bitstreamout subdir. Now I have no freezing
> at the first switch anymore, but still after some zapping, which
> goes very slow now (1-2 sec.)
> 
> Additionally I have a delay of more than one second on PCM-
> channels, which seems to me is excactly the delay before the
> tone comes in after a channel switch. On DD-channels I got a
> just randomly.
> 
> BTW: I use an AMD Athlon 64 3400+. I don't know if this chip is
> called HAMMER ?!?

The old code name for x86_64 aka AMD Athlon 64 was AFAIK Hammer.

> 
> Below the new messages log. Notice: After INSTREAM: ... VDR still
> shows the last channel, but no tone, no zapping possible.

Some strange happens here.  The method I use to stop a bitstream
forwarding thread as fast as possible is:

        int n = 500;                            // 500 ms

        clear_flag(ACTIVE);                     // Set only above
        do {
            bounce->flush();
            bounce->signal();			// Here the thread will be waken up
            usleep(1000);
            if (!Active())			// Now it should be finished
                break;
        } while (test_flag(RUNNING) && (n-- > 0));
        Cancel(0);

        if (test_flag(RUNNING) || Active()) {
            esyslog("INSTREAM: Forwarding bitstream thread was broken");
            usleep(1000);
            if (stream) {                       // thread broken
                spdifDev->Close();
                clear_flag(BOUNDARY);
                stream->Reset();
                bounce->leaveio();
            }
            clear_flag(RUNNING);                // Should not happen
        }

        ResetScan(true);
        clear_setup(LIVE);
        stream = NULL;

You may change the `Cancel(0);' in replay.c (one place) and channel.c
(two places) into `Cancel(1);' ... nevertheless something is broken.

You may also try to call VDR with

     LD_ASSUME_KERNEL=2.4.21 vdr

to be sure that we do not see a NPTL brokne behaviour of vdr or
glibc.

> 
> >Btw: are you able to use VDR during recordings but without
> >bitstreamout plugin ... this because the  `Bufferoverlow'
> >messages look strange.
> >
> > 
> >
> This works just fine. No bufferoverflow at all.
> 
> Anything else I could/should do?
> 
> Jun  5 15:09:40 amd64 vdr[6963]: bso(instream): Forwarding bitstream 
> thread started (pid=6963, tid=114696)
> Jun  5 15:09:41 amd64 vdr[6958]: CAM: Irdeto SE       , 01, 06FF, 06FF
> Jun  5 15:09:43 amd64 vdr[6952]: assuming manual start of VDR
> Jun  5 15:09:51 amd64 vdr[6952]: switching to channel 5
> Jun  5 15:09:51 amd64 vdr[6962]: receiver on device 1 thread ended 
> (pid=6962, tid=98311)
> Jun  5 15:09:56 amd64 vdr[6952]: INSTREAM: Forwarding bitstream thread 
> was broken

This should not happen.

> Jun  5 15:07:18 amd64 vdr[6844]: bso(instream): Forwarding bitstream 
> thread started (pid=6844, tid=114696)
> Jun  5 15:07:19 amd64 vdr[6839]: CAM: Irdeto SE       , 01, 06FF, 06FF
> Jun  5 15:07:21 amd64 vdr[6833]: assuming manual start of VDR
> Jun  5 15:08:02 amd64 vdr[6843]: Bufferoverlow
> Jun  5 15:08:02 amd64 vdr[6843]: Bufferoverlow
> Jun  5 15:08:02 amd64 vdr[6843]: Bufferoverlow
> Jun  5 15:08:02 amd64 vdr[6843]: Bufferoverlow
> Jun  5 15:08:03 amd64 vdr[6843]: Bufferoverlow

[...]

> Jun  5 15:08:07 amd64 vdr[6843]: Bufferoverlow
> Jun  5 15:08:07 amd64 vdr[6843]: Bufferoverlow
> Jun  5 15:08:07 amd64 vdr[6843]: Bufferoverlow
> Jun  5 15:08:07 amd64 vdr[6843]: Bufferoverlow
> Jun  5 15:08:07 amd64 vdr[6833]: caught signal 2
> Jun  5 15:08:07 amd64 vdr[6833]: saved setup to /etc/vdr/dev/setup.conf
> Jun  5 15:08:07 amd64 vdr[6836]: tuner on device 1 thread ended 
> (pid=6836, tid=16386)
> Jun  5 15:08:07 amd64 vdr[6843]: receiver on device 1 thread ended 
> (pid=6843, tid=98311)
> Jun  5 15:08:07 amd64 vdr[6837]: Section handler thread ended (pid=6837, 
> tid=32771)
> Jun  5 15:08:07 amd64 vdr[6839]: tuner on device 2 thread ended 
> (pid=6839, tid=49156)
> Jun  5 15:08:08 amd64 vdr[6840]: Section handler thread ended (pid=6840, 
> tid=65541)
> Jun  5 15:08:08 amd64 vdr[6833]: stopping plugin: bitstreamout
> Jun  5 15:08:13 amd64 vdr[6833]: INSTREAM: Forwarding bitstream thread 
> was broken

IMHO something goes wrong within the thread handling of
the VDR ringbuffer and/or thread handling on a 64bit architecture
or caused by NPTL.



         Werner

-- 
AC3 loop through sound card http://bitstreamout.sourceforge.net/
Howto http://www.vdr-portal.de/board/thread.php?threadid=1958
------------------------------------------------------------------
 "Having a smoking section in a restaurant is like having
         a  peeing section in a swimming pool." -- Edward Burr




Home | Main Index | Thread Index