tinyalsa 2.0.0:When I use tinyplay with -M (mmap), the wav file cannot be played normally
hhjon2018 opened this issue · comments
tinyalsa version is 2.0.0, i use command:
tinyplayv2 /data/test11.wav -D 0 -d 2 -M
Debugging found that it was blocked in the function pcm_mmap_transfer, and pcm->flags==PCM_NONBLOCK, lead to can not play
if (!avail) {
if (pcm->flags & PCM_NONBLOCK) {
errno = EAGAIN;
break;
}
/* wait for interrupt */
err = pcm_wait(pcm, -1);
if (err < 0) {
errno = -err;
break;
}
}
I want to know how to use tinyplay with mmap flag;