On Fri, 24 Apr 2009, Sudeept Prusti wrote: > Hi all, > > As i am working on alsa for minimal PCM playback (8khz,mono,16 bit pcm > file). > > When i tried to allocate 1k buffer and send through snd_pcm_writei() > call it doesn't play perfect and skips are there in between. If we keep > on increasing in allocating the buffer for 31 kb then it could play the > buffers randomly. Sure. Your file read logic is broken. You have to check number of bytes read and do not assume that 'k' bytes were read all time. Also, using seek is not necessary for sequential reads. Jaroslav ----- Jaroslav Kysela <perex@xxxxxxxx> Linux Kernel Sound Maintainer ALSA Project, Red Hat, Inc. _______________________________________________ Alsa-devel mailing list Alsa-devel@xxxxxxxxxxxxxxxx http://mailman.alsa-project.org/mailman/listinfo/alsa-devel