I'm trying to hook up my GSM/GPS/BLE Shield called "Quectel MC60". I found some example Code for an quite similar MC60 Module here:
This is the code:
#include <SoftwareSerial.h>
SoftwareSerial gsm(0, 1);
void setup()
{
Serial.begin(9600);
gsm.begin(9600);
}
void loop()
{
if (Serial.available() > 0)
{
String data = Serial.readString();
Serial.println(data);
gsm.println(data);
}
if (gsm.available() > 0)
{
String data = gsm.readString();
Serial.println(data);
}
}
I just adapted the pins from "2,3" Because the shield goes on top of the Adruino Uno and matches with the 0 (RX), 1 (TX) Pins.
The thing is that it connects correctly but if I call "AT", it loops through the whole time and shows me this:
AT
OK
SMS Ready
AT
OK
SMS Ready
AT
AT
OK
SMS Ready
OK
OK
ERROR
AT
AT
OK
SMS Ready
OK
OK
ERROR
AT
OK
SMS Ready
AT
AT
OK
SMS Ready
OK
OK
ERROR
OK
ERROR
AT
OK
SMS Ready
AT
AT
OK
SMS Ready
OK
OK
ERROR
OK
H⸮H⸮j⸮H⸮
ERROR
AT
AT
OK
SMS Ready
OK
OK
ERROR
AT
OK
SMS Ready
AT
AT
AT
OK
SMS Ready
AT
AT
OK
SMS Ready
OK
OK
ERROR
OK
H⸮H⸮j⸮H⸮
ERROR
OK
ERROR
AT
OK
SMS Ready
AT
AT
OK
SMS Ready
OK
OK
ERROR
OK
H
AT
AT
Ma⸮
As far as I understand ist that the "gsm.available();" should not be the whole time over 0 so that it doesnt loop throught. Can anyone help me out with that to understand whats going on? Im quite new to Arduino development.
This is unfortunately the only thing whats out there to the Module:
Ok, it confused me a second that on the pcb pin0 is in the manual actually pin1.
So far so good. I get a response back but it loops constantly and respnonds the same:
AT
AT
OK
+CPIN: READY
AT
OK
+CPIN: READY
OK
ERROR
AT
OK
+CPIN: READY
OK
ERROR
OK
ERROR
Call Ready
AT
OK
+CPIN: READY
OK
ERROR
OK
ERROR
Call Ready
OK
ERROR
SMS Ready
AT
OK
+CPIN: READY
OK
ERROR
OK
ERROR
Call Ready
OK
ERROR
SMS Ready
OK
ERROR
AT
OK
+CPIN: READY
OK
ERROR
OK
ERROR
Call Ready
OK
ERROR
SMS Ready
OK
ERROR
OK
ERROR
AT
OK
+CPIN: READY
OK
ERROR
OK
ERROR
Call Ready
OK
ERROR
SMS Ready
OK
ERROR
OK
ERROR
OK
ERROR
I guess something in the code above is not correct. But when i look up some other examples, they are similar. "+CPIN: READY" means that the pin code works (in my case there is none).