HI !
I am trying to use SIm 800 GSM Module with Arduino UNO.
ARDUINO DIGITAL PIN 9 is connected to TX of GSM Module
ARDUINO DIGITAL PIN 10 is connected to RX of GSM Module
ARDUINO is powered by PC USB
GSM MODULE is powered by 12v DC Adapter.
I have tried the following code for making outgoing call: -
#include <SoftwareSerial.h>
SoftwareSerial mySerial(9, 10); // RX, TX of Arduino Uno
void setup()
{
mySerial.begin(9600); // Setting the baud rate of GSM Module
Serial.begin(9600); // Setting the baud rate of Serial Monitor (Arduino)
delay(10000); //wait for 10 seconds
mySerial.println("ATD9464XXXXXX;" ); //dialing my mobile number
Serial.println("Calling"); // printing message on serial monitor
delay(10000); // wait for 10 seconds
mySerial.println("ATH" ); // hang up the call
Serial.println("END"); // printing message on serial monitor
}
void loop(){}
//code ends here
this code is not working.
But if I directly connect GSM Module TX, RX to RX, TX of ARDUINO and the use the following code, it makes outgoing call and hangs up simply : -
void setup()
{
Serial.begin(9600); //setting baud rate of serial communication with GSM Modem
delay(10000); //wait for 10 seconds
Serial.println("ATD9464XXXXXX;" ); // dialing mobile number
delay(10000); // wait for 10 seconds
Serial.println("ATH" ); // hang up the call
}
void loop() {}
//code ends here
Same issue is with sending / Receiving SMS also.
Can somebody guide me what is wrong with SoftwareSerial Library here in my code ?