int trig=7;
int echo=6;
int timeinMicro;
int distanceinCm;
void setup() {
  Serial.begin(9600);
  pinMode(7, OUTPUT);
  pinMode(6, INPUT);
}

void loop() {
  digitalWrite(trig, LOW);
  delayMicroseconds(2);

  digitalWrite(trig, HIGH);
  delayMicroseconds(10);

  digitalWrite(trig, LOW);

  timeinMicro=pulseIn(echo, HIGH);
  distanceinCm=timeinMicro /29 /2;
  Serial.println(distanceinCm);
  delay(100);
}