[บัดกรีขาแล้วพร้อมใช้] INMP441 โมดูลไมโครโฟนรอบทิศทาง Omnidirectional Microphone Module I2S Interface MEMS
INMP441 Feature:
1. The microphone module has a 24‑bit digital I2S interface with high‑ data, and the output performance is stable.
2. With flat broadband frequency response and high signal‑to‑noise ratio, it can produce high‑definition natural sound.
3. INMP441 is a high-performance, low-power, digital output omnidirectional MEMS microphone with a bottom port.
4. With MEMS sensor, signal conditioning, analog‑to‑digital converter, anti‑aliasing filter, power management and I2S interface.
5. The microphone outputs the signal on the left channel when the level is low, and outputs the signal on the right channel when the level is high.
INMP441 Omnidirectional Microphone Specification:
- Item Type: Microphone Module
- Interface Definition:
- SCK: Serial data clock of I2S interface
- WS: Select serial data for I2S interface
- L/R: Left/right channel selection
- When set to low level, the microphone outputs signals on the left channel
- When set to high level, the microphone outputs the signal on the right channel
- SD: Serial data output from I2S interface
- VCC: Input power, 1.8V-3.3V
- GND: Power supply
With flat broadband frequency response and high signal‑to‑noise ratio, it can produce high‑definition natural sound.
INMP441 is a high-performance, low-power, digital output omnidirectional MEMS microphone with a bottom port.
The microphone module has a 24‑bit digital I2S interface with high‑ data, and the output performance is stable
ตัวอย่างโค้ต INMP441
Connect to ESP32: INMP441 ESP32
SCK >> GPIO14
SD >> GPIO32
WS >> GPIO15
L/R >> GND
GND >> GND
VDD >> VDD3.3
6
#define I2S_PORT I2S_NUM_0
10
Serial.println("Setup I2S ...");
21
int bytes = i2s_pop_sample(I2S_PORT, (char*)&sample, portMAX_DELAY);
23
Serial.println(sample);
28
const i2s_config_t i2s_config = {
29
.mode = i2s_mode_t(I2S_MODE_MASTER | I2S_MODE_RX),
31
.bits_per_sample = i2s_bits_per_sample_t(16),
32
.channel_format = I2S_CHANNEL_FMT_ONLY_LEFT,
33
.communication_format = i2s_comm_format_t(I2S_COMM_FORMAT_I2S | I2S_COMM_FORMAT_I2S_MSB),
34
.intr_alloc_flags = 0, // default interrupt priority
40
i2s_driver_install(I2S_PORT, &i2s_config, 0, NULL);
44
const i2s_pin_config_t pin_config = {
45
.bck_io_num = I2S_SCK,
51
i2s_set_pin(I2S_PORT, &pin_config);