You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Perhaps just a personal issue, but I get wrong responses from setPin.
When I enter the correct pin it returns false and everything works fine. But when I enter the wrong pin it also returns false (and not true as you state in the description).
if ( (_readSerial(5000).indexOf("ER")) == -1)
{
return false;
}
else return true;
When I type the AT-Commands in by hand everything works fine. I hope that there is a solution. Thank you :-)
That's what I tried:
change RX,TX pins does not change anything.
It looks like that the _ readSerial functions only returns the command and did not contain the response from the module
Perhaps just a personal issue, but I get wrong responses from setPin.
When I enter the correct pin it returns false and everything works fine. But when I enter the wrong pin it also returns false (and not true as you state in the description).
if ( (_readSerial(5000).indexOf("ER")) == -1)
{
return false;
}
else return true;
When I type the AT-Commands in by hand everything works fine. I hope that there is a solution. Thank you :-)
Here my code:
#include <Sim800L.h>
#include <SoftwareSerial.h>
#define RX 5
#define TX 4
Sim800L GSM(RX, TX);
void setup(){
pinMode(11, OUTPUT);
digitalWrite(11,HIGH); //turns on the Sim800L module
Serial.begin(9600);
GSM.begin(4800);
String pin = "4311";
delay(5000);
if (GSM.setPIN(pin)) Serial.println("Pin set");
else Serial.println("Pin NOT set");
}
void loop(){
}
The text was updated successfully, but these errors were encountered: