Panasonic EVWAE/EVWAD position sensor

Hi all, I've been working on a project that required to use this encoder. Any idea is there any Arduino library for this encoder? Can't seem to find it online.

Brand: Panasonic
Type: EVWAE/EVWAD
datasheet

It's just a potentiometer:

You just read it as an analogue input.

You don't need a library.
Connect pin1 to arduino ground.
Connect pin3 to arduino 5V
Conncet pin2 to arduino A0
use analogRead(A0) to read the position.
The value will range from 0 to 1023, 512 is in the middle

0 is 0 degrees, 512 is 171.5 degrees, 1023 is 343 degrees

You can use map to get degrees
deg = map(analog_ read_value, 0, 1023, 0, 343)

1 Like

Can you provide me with a simple code to test if my potentiometer is working correctly? Now, the value I got is fluctuating. Thank you

Show how you have it connected to the Arduino

Hi, @b4bygirl
Welcome to the forum.

Can you please tell us your electronics, programming, arduino, hardware experience?

Is this a school/college/university project?

What is the application of your project?

Thanks.. Tom.. :smiley: :+1: :coffee: :australia:

// the setup routine runs once when you press reset:
void setup() {
  // initialize serial communication at 9600 bits per second:
  Serial.begin(9600);
}

// the loop routine runs over and over again forever:
void loop() {
  // read the input on analog pin 0:
  int sensorValue = analogRead(A0);
  // print out the value you read:
  Serial.println(sensorValue);
  delay(200);        // delay in between reads for stability
}
1 Like

This topic was automatically closed 180 days after the last reply. New replies are no longer allowed.