 //---- gsm end
 
 void pickedUpHandler(telephone::ButtonState buttonState) {
-  isGettingPhoneNumber = buttonState == PRESSED;
-  if (isGettingPhoneNumber) {
+  isHeadsetUp = buttonState == PRESSED;
+  if (isHeadsetUp) {
     Serial.println("Headset up");
     phoneNumber = "";
   } else {

Button buttonAsterisk(0, 1023);
Button buttonNumberSign(0, 1023);
Button buttonPlus(0, 1023);

boolean isGettingPhoneNumber;
boolean isGettingDigit;
boolean isTalking;


const int ASTERISK_PIN = A3;
const int NUMBER_SIGN_PIN = A4;
const int PLUS_PIN = A5;
const int AUTO_START_GSM_PIN = 8;

Button buttonHandset(0, 1023);
