From: "Men Muheim" <muheim@gmx.ch>
To: alsa-devel@lists.sourceforge.net
Subject: read time information
Date: Fri, 15 Nov 2002 11:28:53 +0100 [thread overview]
Message-ID: <001201c28c91$cc64f470$461d8481@profi> (raw)
In-Reply-To: <200201212159.QAA05738@renoir.op.net>
For synchronization purpose I need the current time of my sound card
(information on the sample that is currently played out might be
sufficient / ADAT-Synch timecode) I did anticipate that the functions
snd_pcm_status_alloca(&status);
snd_pcm_status_get_tstamp(status, timestamp);
do help me with this, but obviously they only call gettimeofday()
instead of returning a sound card time information (see
http://www.alsa-project.org/alsa-doc/alsa-lib/_2test_2latency_8c-example
.html#example_test_latency). From the API description I have found that
snd_pcm_hwsynch(...)
snd_pcm_delay(...)
must be used to get the current sample positions of the DAC/ADC. But
these functions do not seem to work on my system (alsa-0.9.0rc5 and an
RME9652 sound card). Besides that I want to read the ADAT-Synch timecode
instead of the buffer relative sample offset.
Therefore I was looking for another solution to get the time. I tried to
use the ALSA timer interface
(http://www.alsa-project.org/alsa-doc/alsa-lib/_2test_2timer_8c-example.
html#example_test_timer). But unfortunately I am getting a "timer time
out!", which means that
snd_timer_poll_descriptors(...)
did fail. Is the timer interface implemented for the By the RME9652? By
the way I do not understand how the sample number to the read time do
correlate with each other.
I would appreciate any help with this because if I cannot solve this
problem, I have to move to Windows ASIO (what a pitty!) ASIO provides
the functions
ASIOGetSamplePosition(...)
bufferSwitchTimeInfo(...)
which do exactly what I need.
Regards,
Men
-------------------------------------------------------
This sf.net email is sponsored by: To learn the basics of securing
your web site with SSL, click here to get a FREE TRIAL of a Thawte
Server Certificate: http://www.gothawte.com/rd524.html
next parent reply other threads:[~2002-11-15 10:28 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <200201212159.QAA05738@renoir.op.net>
2002-11-15 10:28 ` Men Muheim [this message]
2002-11-15 15:03 ` read time information Paul Davis
2002-11-18 9:55 ` Men Muheim
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='001201c28c91$cc64f470$461d8481@profi' \
--to=muheim@gmx.ch \
--cc=alsa-devel@lists.sourceforge.net \
--cc=men@ife.ee.ethz.ch \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox