Hi, someone has informations how to use the ESP32s3 sense integrated microphone with micropython? I can use the microphone with C++ and circuitpython samples, but it’s not working with micropython. The only difference I see is that micropython have an additional ws pin that C++ and circuit don’t have. In the esp32s3 schematic the microphone ws pin is grounded and therefore not available.
Mi basic code is following
mic_sck_pin = Pin(42)
mic_ws_pin = Pin(1)
mic_sd_pin = Pin(41)
audio_in = I2S(
0,
sck=mic_sck_pin,
ws=mic_ws_pin,
sd=mic_sd_pin,
mode=I2S.RX,
bits=16,
format=I2S.MONO,
rate=16000,
ibuf=8192,
)
samples = bytearray(2048)
while True:
read_bytes = audio_in.readinto(samples)
# amplify the signal to make it more audible
I2S.shift(buf=samples, bits=16, shift=4)
# send bytes to socket
s.send(samples[:read_bytes])
Thank you to anyone can help me
bye