const int potPin = 36;
// Potentiometer value
int potValue = 0;
float result = 0;
void setup() {
Serial.begin(115200);
delay(1000);
pinMode(potPin,INPUT_PULLUP);
}
void loop() {
// Measures the value of the potentiometer
potValue = analogRead(potPin);
result = (float)potValue / 4095 * 5;
String str = " бар";
Serial.println(result + str);
delay(250);
}