Pages: [1]   Go Down
Author Topic: Smoke Detector Triggers arduino and Arduino makes phone call using DTMF Tones  (Read 1867 times)
0 Members and 1 Guest are viewing this topic.
HK
Offline Offline
Jr. Member
**
Karma: 0
Posts: 69
Micro
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello ,

Please help I am making a system that makes phone call when Smoke detector triggers arduino and plays a recorded sound in SD card by using DTMF tones saved in that Sd card , I have tried following things partly .

playing a wav tones from SD card .

Generating WAV files for DTMF tones for Specific Phone numbers by using this website. http://www.dialabc.com/sound/generate/

I have a telephone Instrument that can take DTMF tones and calls to a number .

Please help me for pointing out the flow of code..


 
Logged

Peter.

Global Moderator
Netherlands
Offline Offline
Shannon Member
*****
Karma: 170
Posts: 12456
In theory there is no difference between theory and practice, however in practice there are many...
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

topdown it would be something like this.
Code:
void loop()
{
  bool b = detectSmoke();
  if (b == true)
  {
    playWave();
  }
  delay(1000);
}
Logged

Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)

HK
Offline Offline
Jr. Member
**
Karma: 0
Posts: 69
Micro
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks , How to create a State High or Low using Analogue PIR sensor ?

Means i am talking about following code , in that i need only two states its high or low how to achieve this ?

Code:
#include <SD.h>                      // need to include the SD library
#include <TMRpcm.h>           //  also need to include this
#define SD_ChipSelectPin 10  //using digital pin 10 as chipselect on arduino UNO


     TMRpcm tmrpcm;   // create an object for use in this sketch
     char mychar;
     int pirSensor = 0;
     int THRESHOLD = 149;
     byte val = 0;
 
 void setup(){
     
     tmrpcm.speakerPin = 9; //11 on Mega, 9 on Uno, Nano, etc
     Serial.begin(9600);
     if (!SD.begin(SD_ChipSelectPin))
     {       
     Serial.println("SD fail");
     return;
     }
        tmrpcm.play("1.wav");     //plays a file everytime uno resets
     }
 void loop(){
 
     if(Serial.available()){ 
     mychar = Serial.read();
   
     val = analogRead(pirSensor);
     if (val >= THRESHOLD)
     {
     tmrpcm.play("1.wav");
     }
    }
  }


pls help me.
Logged

Peter.

Global Moderator
Netherlands
Offline Offline
Shannon Member
*****
Karma: 170
Posts: 12456
In theory there is no difference between theory and practice, however in practice there are many...
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset


you should make a RC low pass filter with a resistor and a capacitor and then connect to a analogPin

- https://www.circuitlab.com/circuit/d8tbvn/pwm-output-into-a-low-pass-filter/ -


A more in depth backgrounder - http://www.proaxis.com/~wagnerj/PWMfil/PWM%20Filters.pdf -
Logged

Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)

HK
Offline Offline
Jr. Member
**
Karma: 0
Posts: 69
Micro
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks for solution i'll check it.
Logged

Peter.

HK
Offline Offline
Jr. Member
**
Karma: 0
Posts: 69
Micro
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

As I am not good in electronics can you please suggesta circuit example for me please?
Logged

Peter.

Global Moderator
Netherlands
Offline Offline
Shannon Member
*****
Karma: 170
Posts: 12456
In theory there is no difference between theory and practice, however in practice there are many...
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

try this - http://en.wikipedia.org/wiki/File:RC_Divider.svg -
Logged

Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)

HK
Offline Offline
Jr. Member
**
Karma: 0
Posts: 69
Micro
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

What values of resistance and cap is needed pls tell.
Logged

Peter.

Global Moderator
Netherlands
Offline Offline
Shannon Member
*****
Karma: 170
Posts: 12456
In theory there is no difference between theory and practice, however in practice there are many...
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

a indepth story might help  - http://provideyourown.com/2011/analogwrite-convert-pwm-to-voltage/ -
Logged

Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)

HK
Offline Offline
Jr. Member
**
Karma: 0
Posts: 69
Micro
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Sorry to say but i didn't understand can you give me straight circuit for that ?
my need  is I have a analog PIR sensor that has 3 pins 1 for supply 5v one for signal out and rest is ground so i need that signal to convert to Digital to state ON or OFF pls help me and sorry if I missed something to say .
Logged

Peter.

Offline Offline
Newbie
*
Karma: 0
Posts: 14
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

hello good day...
can you please help me about my thesis project?

my project is when smoke sensor detect  a smoke, the smoke sensor will trigger's the arduino uno to send a message using GSM module....

I'm not really familiar with this stuff...
can you help me about the codes.. thanks
Logged

Pages: [1]   Go Up
Jump to: