Skip to contentSkip to conversation

snd_pcm_status_get_trigger_tstamp

DISCUSSION Men Muheim 1 participant 2 messages Nov 13, 2002

lore
Share & tools
lore

Men Muheim

author
#0 lore raw

Hello,

I am having a problem using the function snd_pcm_status_get_trigger_tstamp(). I expect the function to return the sample time of the latest trigger, which corresponds to the time of the first sample in the actual channel area.

Instead the function returns zero in my case. Am I misunderstanding the means of the function or is the function not supported in alsa-0.9.0beta10?

I appreciate any comments on this...

Regards, Men

PS: I am using SND_PCM_ACCESS_MMAP_NONINTERLEAVED from
(http://www.alsa-project.org/alsa-doc/alsa-lib/_2test_2pcm_8c-example.ht
ml#example_test_pcm) and want to get the time of the first sample in the actual channel area by calling

void gettimestamp(snd_pcm_t *handle, snd_timestamp_t *timestamp)

{
        int err;
        snd_pcm_status_t *status;

        snd_pcm_status_alloca(&status);
        if ((err = snd_pcm_status(handle, status)) < 0) {
                printf("Stream status error: %s\n", snd_strerror(err));
                exit(0);
        }
        snd_pcm_status_get_trigger_tstamp(status, timestamp);
}

-------------------------------------------------------
This sf.net email is sponsored by: Are you worried about your web server security? Click here for a FREE Thawte Apache SSL Guide and answer your Apache SSL security
needs: http://www.gothawte.com/rd523.html

author
#1 lore raw

I have just installed alsa-0.9.0rc5, but this does not change anything...

Quoted 11 lines

-----Original Message-----
From: [email protected] [mailto:alsa-devel- [email protected]] On Behalf Of Men Muheim
Sent: Mittwoch, 13. November 2002 11:23
To: [email protected]
Subject: [Alsa-devel] snd_pcm_status_get_trigger_tstamp

Hello,

I am having a problem using the function snd_pcm_status_get_trigger_tstamp(). I expect the function to return

the

Quoted 1 line

sample time of the latest trigger, which corresponds to the time of

the

Quoted 3 lines

first sample in the actual channel area.

Instead the function returns zero in my case. Am I misunderstanding

the

Quoted 11 lines

means of the function or is the function not supported in alsa-0.9.0beta10?

I appreciate any comments on this...

Regards, Men

PS: I am using SND_PCM_ACCESS_MMAP_NONINTERLEAVED from

(http://www.alsa-project.org/alsa-doc/alsa-lib/_2test_2pcm_8c-example.ht

Quoted 1 line

ml#example_test_pcm) and want to get the time of the first sample in

the

Quoted 11 lines

actual channel area by calling

void gettimestamp(snd_pcm_t *handle, snd_timestamp_t *timestamp)

{
        int err;
        snd_pcm_status_t *status;

        snd_pcm_status_alloca(&status);
        if ((err = snd_pcm_status(handle, status)) < 0) {
                printf("Stream status error: %s\n",

snd_strerror(err));

Quoted 7 lines
                exit(0);
        }
        snd_pcm_status_get_trigger_tstamp(status, timestamp);
}
Quoted 9 lines

-------------------------------------------------------
This sf.net email is sponsored by: Are you worried about your web server security? Click here for a FREE Thawte Apache SSL Guide and answer your Apache SSL security
needs: http://www.gothawte.com/rd523.html
_______________________________________________
Alsa-devel mailing list [email protected]
https://lists.sourceforge.net/lists/listinfo/alsa-devel

-------------------------------------------------------
This sf.net email is sponsored by: Are you worried about your web server security? Click here for a FREE Thawte Apache SSL Guide and answer your Apache SSL security
needs: http://www.gothawte.com/rd523.html