[alsa-devel] Is snd_pcm_hw_params_set_period_time_near the same as sampling period?

Clemens Ladisch clemens at ladisch.de
Fri Jul 24 10:50:48 CEST 2009

Guilherme Longo wrote:
> I am trying to understand a piece of a code  I am  studing .
> What does exactly the functions snd_pcm_hw_params_set_period_time_near  
> sets?

The period time.

> In my understand period time should be the time between 2 consecutive 
> samples,

In ALSA, a period is the interval between consecutive interrupts from
the sound card; this is the same as a fragment in OSS.

When the application tries to write/read more than than would be
available, ALSA waits until the next period boundary before checking


More information about the Alsa-devel mailing list