GPRS SIM900A Not Connecting to Blynk Server

Hello all :heart_eyes:, I have the blynk application, the arduino uno and a SIM900A GSM/GPRS Module. Using the user_defined_connection sketch, I managed to modify the code to

char auth[] = "MyTokenHere";
SoftwareSerial mySerial(10, 11); // configure software serial port
bool connected = false;

size_t BlynkStreamRead(void* buf, size_t len) // This function is used to receive data
{
  return Serial.readBytes((byte*)buf, len);
}

size_t BlynkStreamWrite(const void* buf, size_t len) // This function is used to send data
{
  return Serial.write((byte*)buf, len);
}



void setup()
{
  Serial.begin(9600);
  mySerial.begin(9600);

  // Setup your connection here.

  mySerial.println("AT");  
  delay(100); 
  mySerial.println("AT+CIPMUX=0");
  delay(200); 
  mySerial.println("AT+CGATT?"); 
  delay(100);
  mySerial.println("AT+CSTT=\"airtelgprs.com\",\"\",\"\"");
  delay(200);
  mySerial.println("AT+CIICR");  
  delay(1500);
  mySerial.println("AT+CIFSR");
  delay(2000);
  mySerial.println("AT+CIPSTART=\"TCP\" , \"cloud.blynk.cc\", \"8442\"");
  delay(5000);
  
  //Hopefully this modem connected to the network

  
 
  Blynk.begin(auth); 

  do {
    connected = Blynk.connect();
  } while (!connected);

 
}

 void loop()
{
    if (connected) {
      bool hasIncomingData = (Serial.available() > 0);
    if (!Blynk.run(hasIncomingData)) {
  
    }
  }
}

Still, my modem cannot connect to the blynk server. Please help as I have to submit this by next monday!
Thanks and Cheers :smile:

@vshymanskyy please advice.

1 Like

Sorry, I don’t have the module and can’t run/check your code.
We don’t support GSM connections yet (but will do in near future)…

darthwebber, if You manage to run it somehow, please post a solution here, as I gonna try to do the same. For now I have not any idea what to send to SIM900 and what to read back. My idea will be to compare with another serial-based solutions (for example by analyzing the serial-usb-TCP communication from direct USB connection) but have no time for now.

Hi, @marvin7 :slight_smile: . As @vshymanskyy pointed out that they don’t support GSM connections now, I switched to an ethernet sheild. But I will not give up. I will try my best to find a solution and get it to work. Till then, patience is a virtue! :wink:

1 Like