Skip to product information
1 of 1

uOttawa Makerstore

Rotary Encoder Brick Sensor Module (KY‑040)

Rotary Encoder Brick Sensor Module (KY‑040)

Regular price $4.25 CAD
Regular price Sale price $4.25 CAD
Sale Sold out

This small module is an incremental rotary encoder designed as an easy‑to‑use input device for microcontrollers such as Arduino, ESP32, or Raspberry Pi. Instead of a limited‑angle potentiometer, it spins freely in 360° and outputs digital pulses you can count to track how much and in which direction the knob has turned.

How it works

  • The encoder converts angular displacement into a series of digital pulses; typical “one‑round” pulse count is about 20 pulses per revolution (PPR).
  • It outputs two square‑wave signals (A and B, or CLK and DT) with a 90° phase difference; comparing the timing of these pulses lets your code detect rotation direction and steps.
  • The built‑in push‑button on the shaft can reset the count or act as a separate “select/confirm” input, starting counting from 0 when pressed.

Electrical specs and connections

  • Operating voltage: 3.3–5 V DC, typically powered from the board’s 5 V rail.
  • Pins (standard KY‑040 module):
    • GND – ground
    • (VCC) – 3.3–5 V power
    • CLK (A) – quadrature output channel A
    • DT (B) – quadrature output channel B
    • SW – push‑button output (normally open, pulled to GND when pressed)

Typical uses

  • Volume or menu control knobs on DIY audio or display interfaces.
  • User input for motor‑control, CNC‑style jogs, or parameter tuning on embedded projects.

Note: Exact dimensions and pulse count may vary slightly by vendor, but “one round = 20 pulses” is the common spec.
Disclaimer: The images shown are for illustration purposes only and may not be an exact match.

View full details