In aloop driver, Substream number influence the effect of playback and simultaneous recording

Viewed 19

app1 play pcm using hw:0,10p, and app2 record pcm using hw:0,10c, I met below problem:

(1)When the substream number of loopback_pcm_new is 2, in the loopback_pos_update function, the value of delta_play and delta_capt will update synchronously; and playback and capture are both normal. (2)When the number of streams of loopback_pcm_new is 1, only the value of delta_play is updated, however delta_capt is always 0, which cause the returned frames are same with calling loopback_pointer by several times (could see "abnormal.png"), then cause there's no available space to when write data from user, then cause the playback app must wait about 20ms until there's available space and spend more time to finish write every time.

(3)above (1) and (2) are all observed at the side of playback direction; and "normal.log" is for normal case, "abnormal.log" is for abnormal case.

(4)my understanding is: the number of subdivice could be 1 or 2, and this number shouldn't affect aloop playback and capture, but actually now it make the write process slow when using 1 substream.enter image description here

0 Answers
Related