Skip to content

Commit 873a300

Browse files
committed
i2s_fill_buffer: Need to fill with zeros when stopping
1 parent cfd8288 commit 873a300

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ports/esp32s2/i2s_common.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ static void i2s_fill_buffer(i2s_t *self) {
7575
int16_t signed_samples[STACK_BUFFER_SIZE / sizeof(int16_t)];
7676
mp_printf(&mp_plat_print, "playing=%d paused=%d stopping=%d sample@%p sample_data=%p..%p\n", self->playing, self->paused, self->stopping, self->sample, self->sample_data, self->sample_end);
7777

78-
if (!self->playing || self->paused || !self->sample) {
78+
if (!self->playing || self->paused || !self->sample || self->stopping) {
7979
memset(signed_samples, 0, sizeof(signed_samples));
8080

8181
size_t bytes_written = 0;

0 commit comments

Comments
 (0)