IDUINO ARD MIC MODUL4 Datasheet

IDUINO for Maker’s life
www.openplatform.cc
Large Microphone Module(ST1146)
1. Introduction
It’s a high sensitivity sound detection module, which has two output signal pin. one digital pin(D0), When it detect some sound up to certain threshold, it can output High or Low level. One analog pin(A0), it can real-time output voltage signal of the microphone.
Specification
Voltage:5V/3.3V Electret microphone(It’s different from module4) there is a mounting screw hole 3mm the use 5v DC power supply with analog output there are threshold level output flip high sensitive microphone and high sensitivity. a power indicator light the comparator output is light Weight: 4g Frequency Response range:50Hz20kHz Impedance2.2K ohm Sensitivity48~66dB polar patternUniversal Operating temperature: -40 to 85 degrees celsius Operating humidity: 30~90% Storage temperature : -5 to 30 degrees celsius Storage humidity : 20~75% product size: 44*15*10mm
IDUINO for Maker’s life
www.openplatform.cc
2. Pinout
Pin
Description
A0
Analog signal output pin
G
Ground
+
Power(5V/3.3V)
D0
Digital signal output pin
3. Example
We will use three example to show the different function of this module. Example 1 show you how to use the digital pin(D0), Example 2 show you how to use the digital pin(A0), In Example 3, we can try to combine this two function into one experiment.
3.1 Example 1
This example show you the digital pin function, connect Pin12(Arduino) to a LED light, and connect this module as below, and upload the code.
Then turn the variable resistor until the LED12 turns off. Now you can handclap or
make a sound, you will see the LED12 turns on.
Code for Example1
********Code begin********
int Led = 12 ;// define LED Interface int buttonpin = 7; // define D0 Sensor Interface int val = 0;// define numeric variables val
void setup ()
IDUINO for Maker’s life
www.openplatform.cc
{ pinMode (Led, OUTPUT) ;// define LED as output interface pinMode (buttonpin, INPUT) ;// output interface D0 is defined sensor }
void loop () { val = digitalRead(buttonpin);// if (val == HIGH) // { digitalWrite (Led, HIGH); } else { digitalWrite (Led, LOW); } }
********Code End********
3.2 Example 2
This example show you the Analog pin function, connect this module as below picture, and upload the code. Then open the Serial monitor, you can see some number between 0 to 1023. And now if you make some high or low voice, the number is changing.
IDUINO for Maker’s life
www.openplatform.cc
Code for Example2
********Code begin********
int sensorPin = A5; // select the input pin for the potentiometer void setup () { Serial.begin (9600); }
void loop () { sensorValue = analogRead (sensorPin);
delay (500); Serial.println (sensorValue, DEC); }
********Code End********
3.3 Example 3
In this example we try to combine digital pin and analog pin together to control two LED lights, connection and code as below.
Code for example 3
********Code begin********
int Led=13; int ledPin=12; int buttonpin=7;
IDUINO for Maker’s life
www.openplatform.cc
int sensorPin = A0; int sensorValue = 0; int val; void setup() { Serial.begin(9600); pinMode(Led,OUTPUT); pinMode(ledPin, OUTPUT); pinMode(buttonpin,INPUT); } void loop() { sensorValue = analogRead(sensorPin); digitalWrite(ledPin, HIGH); delay(sensorValue); digitalWrite(ledPin, LOW); delay(sensorValue); Serial.println(sensorValue, DEC); val=digitalRead(buttonpin); if(val==HIGH) { digitalWrite(Led,HIGH); } else { digitalWrite(Led,LOW); } }
********Code End********
Loading...