I am programming an Arduino with an A9 which has the ability to take AT commands directly. I'm using the following script, which allows me to enter commands:
void setup()
{
Serial.begin(115200);
Serial1.begin(115200);
pinMode(4, OUTPUT);
pinMode(5, OUTPUT);
pinMode(8,OUTPUT);
digitalWrite(5, HIGH);
digitalWrite(4, LOW);
digitalWrite(8, HIGH);
delay(3000);
digitalWrite(8, LOW);
Serial.println("A7 Power ON!");
}
void loop()
{
char dat;
if(Serial1.available()){
dat = Serial1.read();
Serial.print(dat);
}
if(Serial.available()){
dat = Serial.read();
Serial1.print(dat);
}
}
I can see that it's registered:
AT+CREG?
+CREG: 2,3,"A5FA","5CB4",0
and that it is in plaintext SMS mode:
AT+CMGF=?
+CMGF:(0,1)
OK
AT+CMGF=1
OK
but attempts to send and receive messages get a CMS ERROR 500 and 300 respectively:
AT+CMGS="0584413829"
test sms
+CMS ERROR: 500AT+CMGL="ALL"
+CMS ERROR: 300
Anyone have any ideas? I'm at my wits' end.