Rotary Encoder Module Symbol

Rotary Encoder Module symbol
The Rotary Encoder Module symbol (IEC 60617 / ANSI Y32.2).

Definition: The Rotary Encoder Module symbol represents a mechanical incremental rotary encoder board (commonly the KY-040 module) that outputs two quadrature digital pulse trains (CLK and DT) indicating shaft rotation direction and position, plus a push-button output (SW) when the shaft is pressed, depicted as a rectangular module block with VCC, GND, SW, DT, and CLK pins for direct connection to microcontroller GPIO lines.

Also known as: KY-040 encoder, rotary encoder module, incremental encoder, quadrature encoder module, rotary knob encoder, volume encoder.

What the Rotary Encoder Module symbol means

The Rotary Encoder Module symbol denotes a PCB-mounted incremental rotary encoder that converts shaft rotation into digital pulse trains. As the knob turns clockwise or counter-clockwise, it generates two phase-shifted square-wave signals (CLK and DT / A and B channels) in quadrature (90° phase difference); comparing which signal leads the other determines the direction of rotation, while counting pulses measures the angle of rotation or incremental displacement.

In microcontroller and Arduino project schematics, this symbol marks the input device for menu navigation, volume control, motor speed setting, or position feedback. The SW pin provides a digital push-button output activated by pressing the shaft axially, adding a 'select' or 'confirm' function without requiring a separate switch symbol.

How to identify the Rotary Encoder Module symbol

The Rotary Encoder Module symbol is drawn as a rectangle representing the PCB module, labelled 'ROT ENC' or 'KY-040', with pins on the left side: VCC (power supply, typically 3.3–5 V), GND (ground), and SW (push-button output). Some block representations also show DT (Data / channel B) and CLK (Clock / channel A) pins on the same side or the right side. Physical module images show a knob protruding from a small PCB with a 5-pin header.

Function in a circuit

The rotary encoder module uses two mechanical contacts offset by half a detent step to produce quadrature output signals on its CLK and DT pins. When the shaft rotates one detent clockwise, CLK leads DT by 90°, producing a HIGH-LOW-LOW-HIGH sequence on CLK relative to DT. Counter-clockwise rotation reverses the sequence. A microcontroller firmware or interrupt service routine reads the pin states on each CLK edge to determine direction and accumulate a position count. Pressing the shaft activates the SW push-button, pulling SW LOW through an internal pull-up resistor.

Standards: IEC vs ANSI

IEC 60617IEC 60617 does not define a specific rotary encoder module symbol; the underlying incremental encoder principle is covered generically in IEC 61800 series (adjustable speed drives) and IEC 60034-25 (encoder interfaces for servo motors). Module-level schematics follow manufacturer datasheet pin conventions.
ANSI/IEEE 315IEEE 315-1975 / ANSI Y32.2 does not define a rotary encoder module block symbol. The module is represented as a rectangular functional block with labelled pins following the device manufacturer's (e.g., Bourns, Alps) datasheet. Arduino and hobbyist community schematics universally use this block-rectangle convention.
Key differenceNo significant IEC vs. ANSI glyph difference exists for this module; both standards use a labelled rectangular block. The KY-040 is a Chinese-market hobbyist module without a formal IEC or ANSI standard, and its symbol is manufacturer-defined.

Terminals / pins

PinName
vccVCC
gndGND
swSW

Typical values

Supply voltage (VCC): 3.3 V or 5 V DC. Encoder resolution: typically 20 pulses per revolution (PPR) for KY-040. Detents: 20 per revolution (one pulse per detent). Switch rating: typically 50 mA / 5 V DC. Output type: open-collector or digital (TTL/CMOS compatible). Operating temperature: −20 °C to +70 °C.

Where the Rotary Encoder Module symbol is used

Example

In an Arduino-based OLED menu system, the KY-040 module's VCC pin connects to the Arduino 5V rail, GND to ground, CLK to digital pin D2 (external interrupt 0), DT to D3 (external interrupt 1), and SW to D4 with an internal pull-up enabled. Firmware reads the CLK and DT pin states on each falling edge of CLK: CLK-LOW before DT-LOW means clockwise rotation (increment menu index); DT-LOW before CLK-LOW means counter-clockwise (decrement). Pressing the knob pulls SW low and confirms the selection.

Key facts

Frequently asked questions

What does the rotary encoder module symbol mean in a circuit diagram?

The rotary encoder module symbol represents a KY-040-type incremental encoder PCB that converts shaft rotation into two quadrature digital pulse trains (CLK and DT) and a push-button signal (SW). It is drawn as a rectangle with VCC, GND, SW, DT, and CLK pins for direct connection to microcontroller GPIO or interrupt lines.

What does a rotary encoder module look like in a schematic?

In a schematic the rotary encoder module appears as a labelled rectangle (KY-040 or ROT ENC) with 3–5 pins on the left: VCC, GND, SW (push-button), and optionally CLK and DT. It is the same rectangular block format used for other Arduino sensor modules in hobbyist schematic conventions.

How do the CLK and DT pins indicate rotation direction?

The CLK and DT outputs are 90° out of phase (quadrature). When the shaft turns clockwise, CLK transitions LOW before DT, so reading CLK-LOW with DT-HIGH indicates clockwise rotation. Counter-clockwise rotation reverses the sequence, with DT transitioning LOW before CLK. Firmware determines direction by sampling both pins on each CLK edge.

What is the SW pin on a rotary encoder module?

The SW pin is the output of an integrated push-button switch activated by pressing the rotary encoder shaft axially. When the shaft is pressed, SW is pulled LOW (active-low). When released, SW returns HIGH through an internal or external pull-up resistor. This allows a single module to provide both rotation and selection functions.

What is the difference between a rotary encoder and a potentiometer in a circuit diagram?

A potentiometer produces an analogue voltage proportional to shaft angle and requires an ADC input; it has a physical end-stop and is used for absolute angle measurement or volume control. A rotary encoder produces digital pulse trains indicating incremental rotation with no end-stop, interfaces directly to digital GPIO pins, and requires firmware to count pulses for relative position tracking.

What voltage does the rotary encoder module require?

The KY-040 rotary encoder module operates on 3.3 V or 5 V DC supplied to its VCC pin. The CLK, DT, and SW outputs are TTL/CMOS compatible at the supply voltage level, making the module directly compatible with both 5 V Arduino boards and 3.3 V ESP32 or Raspberry Pi GPIO pins.

Why does firmware need to debounce a rotary encoder?

Mechanical rotary encoders produce contact bounce — multiple rapid HIGH/LOW transitions — at each detent due to the physical spring-contact mechanism. Without debouncing, a single detent step may register as several pulses, causing erratic counting. Software debounce (minimum time between counted edges) or a hardware RC filter on CLK and DT eliminates false counts.

Place the Rotary Encoder Module symbol on a wiring diagram or schematic in the free online circuit diagram maker — no download required.