#include <Servo.h>
Servo myproject;
int  pot=A4;
int value=0;
void setup() {
  // put your setup code here, to run once:
myproject.attach(9);
pinMode(pot, INPUT);
pinMode(10, OUTPUT);
Serial. begin(115200);
}

void loop() {
  // put your main code here, to run repeatedly:
 value=analogRead(A4);
Serial. println(value);
int fin_val=map(value, 0,1023,0,180);
myproject.write(fin_val) ;
Serial. println(fin_val) ;
delay(20);
tone(10,5000);
delay(30);
tone(10,4000);
delay(60);
}