atomic14 / esp32-i2s-mic-test

The Simplest Test Code for an I2S Microphone on the ESP32 I can Imagine
112 stars 17 forks source link

All Samples are -1 #1

Closed Saschko2000 closed 3 years ago

Saschko2000 commented 3 years ago

When I run the Code, all I see an the Serial Port are lots of -1 :-(

The Code Works with the INMP441-Breakoutboard, but not with the ICS-43434.

Have you any idea, on how to test the mic step by step?

Thank you very much

Sascha

cgreening commented 3 years ago

Make sure you are connecting the L/R pin to GND to ensure the microphone is on the left chanel.

Saschko2000 commented 3 years ago

My be a problem with the board an the soldering, but i double-checked everything. I mesured the pcb and soldered a second board with the same result :-(. I hope this is a software problem, an not a hardware one. To check this, I just ordered one of your board, But now I have to wait for delivery ;-)

Have you any idea, I could test meanwile?

Thanks a lot Sascha

cgreening commented 3 years ago

Good news and bad news I guess - good news that it's not one of my boards! Bad news that your boards are not working. I just put your order in the post so you should receive it in 3-5 days (though with Covid and Brexit, delivery times are wildly optimistic).

If the INMP is working then it's probably not a software problem. Can you share the boards you are using and the wiring you have used?

Saschko2000 commented 3 years ago

ESP32 WLED Schematic.pdf ESP32 WLED Board

Saschko2000 commented 3 years ago

And thanks a lot for fast replay and sending. :-)

cgreening commented 3 years ago

Looking at the schematic - the pins are wired up as:

WS - IO15 SCK - IO14 SD - IO32

Probably a silly question, but have you change the code to match?

#define I2S_MIC_SERIAL_CLOCK GPIO_NUM_14
#define I2S_MIC_LEFT_RIGHT_CLOCK GPIO_NUM_15
#define I2S_MIC_SERIAL_DATA GPIO_NUM_32
cgreening commented 3 years ago

Just having a look at the PCB layout. I might be missing it, but I think the GND of the ICS-43434 is not connected to anything? And I can't find C4 anywhere.

Screenshot 2021-06-22 at 15 12 00

Saschko2000 commented 3 years ago

Yes, this just looks like, but is only for better visualisation. In real, the top and the bottom layer have a ground-plane.

Probably a silly question, but have you change the code to match?

Yes and No. I did change the code, but I made a fucking mistake. Despite double-checking everything. I hate this. You are my Hero for today. Now I get values :-)

Thank you :-)

cgreening commented 3 years ago

That's great news! Looks like an interesting project. Good luck with it.

Aishwarya876 commented 2 years ago

When I run the Code, all I see an the Serial Port are lots of -1 :-(

The Code Works with the INMP441-Breakoutboard, but not with the ICS-43434.

Have you any idea, on how to test the mic step by step?

Thank you very much

Sascha Even im getting same error i would be very greatful if anyone could help me (on serial monitor its just -1)

Saschko2000 commented 2 years ago

Please let us know your code, and how you connected the mic. In my case it was an error in my code.

Aishwarya19966 commented 2 years ago

connections:

VDD | 3v3 | GND | GND | GND L/R | GND | Left channel or right channel WS | 22 | Left right clock SCK | 26 | Serial clock SD | 21 | Serial data

Here is the code link WhatsApp Image 2022-01-23 at 12 07 01 Screenshot 2022-01-23 at 12 13 40 PM

I would be very greatful for any help

Saschko2000 commented 2 years ago

But you changed the pin configuration from

#define I2S_MIC_SERIAL_CLOCK GPIO_NUM_32
#define I2S_MIC_LEFT_RIGHT_CLOCK GPIO_NUM_25
#define I2S_MIC_SERIAL_DATA GPIO_NUM_33

to

#define I2S_MIC_SERIAL_CLOCK GPIO_NUM_26
#define I2S_MIC_LEFT_RIGHT_CLOCK GPIO_NUM_22
#define I2S_MIC_SERIAL_DATA GPIO_NUM_21

right?

Aishwarya19966 commented 2 years ago

Yes I Did change pins in code as well

Aishwarya19966 commented 2 years ago

Hey can you please help me with your email ID i have been trying on this. since too long its not working i really need help