'How to be sure that the communication between the Arduino M0 and the SIM900a is done
I wrote this few lines to make the test of communication between Arduino M0 and Sim900a but in the serial Monitor there is no result afferming that the communication is done. Any Help?? and thank you.
char c = ' ';
void setup()
{
Serial.begin(19200);
Serial1.begin(9600);
}
void loop()
{
// Keep reading from Arduino Serial Monitor and send to SIM900A
if (Serial.available())
{ c = Serial.read();
Serial.println(c);
Serial1.write(c);
}
// Keep reading from SIM900 and send to Arduino Serial Monitor
if (Serial1.available())
{ c = Serial1.read();
Serial.write(c);
Serial.println(c);
}
}
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
Solution | Source |
---|