I think it is only for arduino UNO, but I want to use it on arduino MEGA; since it hoes not hav pins, I want to connect only the pins required.
I have moved the jumpers to serial software position, and connect pin gnd and use external power source. I have also connected pins 7,8 of shield to pin 7 of arduino MEGA, but still it is not working.
Connect D7 & D8 on the shield to Serial1 (or Serial2, or Serial3) on the MEGA?
The product documentation for the MEGA claims it supports Software Serial on any digital pin, but the Software Serial library tells a different story:
Not all pins on the Mega and Mega 2560 support change interrupts, so only the following can be used for RX: 10, 11, 12, 13, 14, 15, 50, 51, 52, 53, A8 (62), A9 (63), A10 (64), A11 (65), A12 (66), A13 (67), A14 (68), A15 (69).
But in any case there is often no need for Software Serial with so many hardware ports.
I have connected D7, D8 of shield to D10, D11 of MEGA, and also connected the gnd of MEGA to that of shield, I have run the example MakeVoiceCall, but still no result. The only thing appearing on serial monitor is "Make Voice Call".
I think the code is stuck at line <<if (gsmAccess.begin(PINNUMBER) == GSM_READY) {>>
also, since there is no PIN lock on the SIM card, I have not specified it in the code.
Are you using the GSM library that comes with the IDE? The one intended for use with the Quectel M10 chipset? If so then search for the SIM900 GSM library instead.
And personally, to test it, I would jumper D7 & D8 to D18 & D19, load a SerialRelay library and just try some basic AT commands to test the device. I think it's ATD +447791123456; to dial a number... ATH to hang up.
void loop()
{
if (SIM900.available()) // if date is comming from softwareserial port ==> data is comming from gprs shield
Serial.write(SIM900.read());
if (Serial.available()) // if data is available on hardwareserial port ==> data is comming from PC or notebook
SIM900.write(Serial.read());
}
when i type AT, it replies OK.... so it is working
But I have another problem, now when i type ATD+230******* (I live in mauritius), on the serial monitor, it says no carrier.... I dont know what the problem is. on the other hand; When i call the shield, "RING" is displayed on the serial monitor, then i can use ATH or ATA.
What is the cause of the problem "no carrier"?????
Hello everyone! with regards to the problem, is it possible or is it okay if I would directly connect the RX,TX to D7,D8? or is it really necessary to use other pins?
thanks!
baron989:
I connected D7,D8 of shield to D10,D11 of arduino.
I loaded the code:
#include <SoftwareSerial.h>
SoftwareSerial SIM900(10, 11); // (RX, TX). please zoom image above to see exactly what is going where.