Taiss/ 5Pcs KY-040 Rotary Encoder Module with 15×16.5 mm with Knobs Cap
Thumbnail 1Thumbnail 2Thumbnail 3Thumbnail 4Thumbnail 5Thumbnail 6Thumbnail 7

Taiss/ 5Pcs KY-040 Rotary Encoder Module with 15×16.5 mm with Knobs Cap

4.1/5
Product ID: 95765450
Secure Transaction
5V Power
🔄20 Pulses/Rotation
🔧Aluminium Knob

Description

🔧 Turn Your Ideas into Reality!

  • EASY RESET - One-click reset feature allows you to start counting from zero effortlessly.
  • VALUE PACK - Includes 5 rotary encoder modules and knobs, ensuring you have everything you need for your next project.
  • DURABLE DESIGN - Crafted with an aluminium alloy knob cap for longevity and a premium feel.
  • PRECISION CONTROL - Experience seamless rotation with 20 pulses per turn, perfect for fine-tuning your projects.
  • VERSATILE FUNCTIONALITY - Count pulses in both directions, giving you complete control over your applications.

The Taiss 5Pcs KY-040 Rotary Encoder Module is a versatile and durable component designed for precision control in various applications. Operating at 5V, it features a robust aluminium alloy knob cap and can count pulses in both directions, making it ideal for projects requiring accurate input. Each package includes five modules and knobs, providing excellent value for makers and engineers alike.

Large manufacture image 1
Small manufacture image 1Small manufacture image 2Small manufacture image 3Small manufacture image 4Small manufacture image 5Small manufacture image 6Small manufacture image 7Small manufacture image 8Small manufacture image 9Small manufacture image 10

Reviews

4.1

All from verified purchases

D**N

Works great, but super noisy.

They work great, ... as long as the noise is filtered out. I needed to run the signal on wire over 45 feet. This destroyed any ability to simply read DT -- it was just bouncing all over. I tried putting in a 0.1uF cap and tried pull up resistors. Neither was able to filter out the noise. So I wrote some code that seems to be working great. This should run on Arduino and similar devices. Keep in mind that this approach does NOT use interrupts, so it is possible that turns could possibly be missed if your MCU gets busy on other things (though unlikely, unless you're running very long processes).uint16_t debounceDuration = 100;uint8_t clkVal = 0;uint8_t dtVal = 0;uint8_t dtValPrev = 0;uint32_t dtValLows = 0;uint32_t dtValHighs = 0;uint32_t millisR = 0;bool activePeriod = false;bool dir = false;uint8_t clkPin = A0;uint8_t. dkPin = A1;uint32_t currentMillis = 0;void setup() {pinMode(clkPin, INPUT_PULLUP);pinMode(dkPin, INPUT_PULLUP);}void loop() {currentMillis = millis();clkVal = pinReadFast(clkPin);if (clkVal == LOW && !activePeriod && currentMillis - millisR > debounceDuration) { // happens one time once CLK goes low.millisR = currentMillis;activePeriod = true;dtValLows = 0;dtValHighs = 0;}if (activePeriod) {dtValPrev = dtVal;dtVal = pinReadFast(dkPin);if (currentMillis - millisR < 1) {if (dtVal == HIGH) dtValHighs++; else dtValLows++;}}if (currentMillis - millisR > debounceDuration && activePeriod) { // finished active period. fired oncedir = (dtValHighs > dtValLows);activePeriod = false;Serial.print("dir: ");Serial.println(dir);}}

B**N

Wish It Would Have Added Built-In Capacitors

This took me awhile to get working properly because my Arduino code was incorrect. It needs 0.1uF capacitors from the CLK and DT outputs to GND, and I wish these were built in. It's missing a resistor on the switch part, which I'm not using. The parts I ordered have 15 PPR.Here is my Arduino code if this is helpful for anyone...const int i_A = 3;const int i_B = 2;int encoderPos = 0;bool encAValPrev = LOW;void setup() {Serial.begin(9600);pinMode(i_A, INPUT);pinMode(i_B, INPUT);}void loop() {bool encAVal = digitalRead(i_A);if ((encAValPrev == HIGH) && (encAVal == LOW)) {if (digitalRead(i_B) == LOW) {encoderPos--;Serial.println(String(encoderPos) + " Counter-Clockwise");} else {encoderPos++;Serial.println(String(encoderPos) + " Clockwise");}}encAValPrev = encAVal;}

C**I

They work well and seem pretty sturdy

There is some position wiggle to them were position can jump back or not every single jump is recorded but every 2 jumps works fine and the wiggle can be adjusted in code. I'd probably buy these again

K**.

Switch bounce solved

I had a big problem with switch bounce when connecting clk, data, and switch to my Arduino Uno R4 Wifi, using the KY040 code from MediaFire. That program kept firing off a reset (switch depress) even when I was only rotating the dial. I also noticed that the switch was missing the 10KOhm pull-up resistor for the switch line, so I popped one off another switch and soldered that in. Bounce gone completely, and I can count up or down to my heart's content without a reset. Very nice, other than needing to buy a bunch of 10K 0805 chip resistors. Note that the program was supposed to provide pull-ups from the board, but that apparently did not happen properly. I note that two of the pins were analog optional pins, so perhaps that caused an issue. In any case, the switches appear to work well once modified.

=**=

Knobs don't fit, Missing resistor

The knobs don't fit on the D-shaft of the encoders. Also, while the pullup resistors for the CLK and DT pins were installed, the pullup on the pushbutton switch was missing. Other reviewers have had the same problems. Disappointing.

S**T

Very nice!

Very nice quality, machined aluminum caps and pleasing mechanical haptic feedback. (Makes nice clicky-clicks when you turn it, satisfying button press when you push on it.) Easy to solder, easy to find documentation.

D**F

Wrong knobs

The knobs do not fit the encoders. The knobs have a sharp spline shape but the encoder shafts are half circles.

Common Questions

Trustpilot

TrustScore 4.5 | 7,300+ reviews

Ayesha M.

The product exactly matches the description. Very satisfied with my purchase.

5 days ago

Ali H.

Fast shipping and excellent packaging. The Leatherman tool feels very premium and sturdy.

1 day ago

Shop Global, Save with Desertcart
Value for Money
Competitive prices on a vast range of products
Shop Globally
Serving over 300 million shoppers across more than 200 countries
Enhanced Protection
Trusted payment options loved by worldwide shoppers
Customer Assurance
Trusted payment options loved by worldwide shoppers.
Desertcart App
Shop on the go, anytime, anywhere.
6.36 OMR

Duties & taxes incl.

OMANstore
1
Free Returns

30 daysfor PRO membership users

15 dayswithout membership

Secure Transaction

Trustpilot

TrustScore 4.5 | 7,300+ reviews

Reema J.

Perfect platform for hard-to-find items. Delivery was prompt.

1 month ago

Neha S.

Excellent communication throughout the order process. Product is perfect.

2 weeks ago

Taiss 5pcs Ky 040 Rotary Encoder Module With 15 16 | Desertcart OMAN