Skip to content

Commit 4257ef9

Browse files
committed
ESP32 I2S PDM
1 parent 1d2ee2b commit 4257ef9

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/AudioTools/CoreAudio/AudioI2S/I2SESP32V1.h

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -351,12 +351,12 @@ class I2SDriverESP32V1 {
351351

352352
protected:
353353
i2s_pdm_tx_slot_config_t getTxSlotConfig(I2SConfigESP32V1 &cfg) {
354-
#ifdef ARDUINO
355-
return I2S_PDM_TX_SLOT_DEFAULT_CONFIG(
354+
#ifdef SOC_I2S_HW_VERSION_2
355+
return I2S_PDM_TX_SLOT_DAC_DEFAULT_CONFIG(
356356
(i2s_data_bit_width_t)cfg.bits_per_sample,
357357
(i2s_slot_mode_t)cfg.channels);
358358
#else
359-
return I2S_PDM_TX_SLOT_DAC_DEFAULT_CONFIG(
359+
return I2S_PDM_TX_SLOT_DEFAULT_CONFIG(
360360
(i2s_data_bit_width_t)cfg.bits_per_sample,
361361
(i2s_slot_mode_t)cfg.channels);
362362
#endif

0 commit comments

Comments
 (0)