Skip to content

Commit f1e6f01

Browse files
committed
Fix pointer issue with dma setup.
1 parent e30e234 commit f1e6f01

File tree

2 files changed

+2
-1
lines changed
  • ports/raspberrypi/common-hal/audiobusio
  • shared-bindings/audiobusio

2 files changed

+2
-1
lines changed

ports/raspberrypi/common-hal/audiobusio/I2SIn.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ void audiobusio_i2sin_reset_buffer(audiobusio_i2sin_obj_t *self,
270270

271271
audio_dma_result result = audio_dma_setup_record(
272272
&self->dma,
273-
&self,
273+
self,
274274
true,
275275
single_channel_output, // single channel
276276
channel, // audio channel

shared-bindings/audiobusio/I2SIn.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@
5757
static mp_obj_t audiobusio_i2sin_make_new(const mp_obj_type_t *type, size_t n_args, size_t n_kw, const mp_obj_t *all_args) {
5858
#if !CIRCUITPY_AUDIOBUSIO_I2SIN
5959
mp_raise_NotImplementedError_varg(MP_ERROR_TEXT("%q"), MP_QSTR_I2SIn);
60+
return NULL; // Not reachable.
6061
#else
6162
enum { ARG_bit_clock, ARG_word_select, ARG_data, ARG_buffer_size, ARG_channel_count, ARG_sample_rate, ARG_bits_per_sample, ARG_samples_signed };
6263
static const mp_arg_t allowed_args[] = {

0 commit comments

Comments
 (0)