title: How to receive caller number from Arduino SIM800C GSM shield?
body: <p>I'm trying to code a GSM caller number receiver. When I (as the phone answerer) answer the phone it should print out the caller number.</p>
  
  <p>I have trouble finding the right AT command for receiving the caller number. I tried <code>AT+CLIP=1\r</code> and on the loop <code>+CLIP</code>, but with no success. </p>
  
  <p>Here is my code:</p>
  
  <pre class="lang-cpp prettyprint-override"><code>#include &lt;GSMSim.h&gt;
  #include &lt;SoftwareSerial.h&gt;
  
  #define RX 7
  #define TX 8
  #define RESET 2
  #define BAUD 9600
  
  GSMSim gsm;
  SoftwareSerial mySerial =  SoftwareSerial(RX, TX);
  /*
   * Also you can this types:
   * GSMSim gsm(RX, TX);
   * GSMSim gsm(RX, TX, RESET);
   * GSMSim gsm(RX, TX, RESET, LED_PIN, LED_FLAG);
   */
  
  void setup() {
    Serial.begin(9600);
    Serial.println("GSMSim Library - Call Example");
    Serial.println("");
    delay(1000);
  
    gsm.start(); // baud default 9600
    mySerial.read();
    mySerial.print("AT+CLIP=1\r");
  }
  
  void loop() {
    Serial.println(gsm.callStatus());
    gsm.callAnswer();
    Serial.println("Number:");
    Serial.println(mySerial.print("+CLIP"));
    delay(1000);
  }
  </code></pre>