Skip to content

Commit

Permalink
AR pin config: SCK == 1 --> PDM microphone
Browse files Browse the repository at this point in the history
  • Loading branch information
softhack007 committed May 4, 2024
1 parent 5ab1b14 commit cd5494f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions usermods/audioreactive/audio_reactive.h
Original file line number Diff line number Diff line change
Expand Up @@ -1121,6 +1121,11 @@ class AudioReactive : public Usermod {
delay(100); // Give that poor microphone some time to setup.

useBandPassFilter = false;

#if !defined(CONFIG_IDF_TARGET_ESP32S2) && !defined(CONFIG_IDF_TARGET_ESP32C3)
if ((i2sckPin == I2S_PIN_NO_CHANGE) && (i2ssdPin >= 0) && (i2swsPin >= 0) && ((dmType == 1) || (dmType == 4)) ) dmType = 5; // dummy user support: SCK == -1 --means--> PDM microphone
#endif

switch (dmType) {
#if defined(CONFIG_IDF_TARGET_ESP32S2) || defined(CONFIG_IDF_TARGET_ESP32C3) || defined(CONFIG_IDF_TARGET_ESP32S3)
// stub cases for not-yet-supported I2S modes on other ESP32 chips
Expand Down

0 comments on commit cd5494f

Please sign in to comment.