How to use linear encoders with Arduino. hardware, code, and demo.
How to salvage linear encoders form a broken (or out of ink) printer and use them with an Arduino to make precise motions measurements. Hardware, theory, software walkthrough, and demo. I also discuss some of the pitfalls of interrupt code. The code: // Interrupt information // 0 on pin 2 // 1 on pin 3 #define encoderI 2 #define encoderQ 4 // Only use one interrupt in this example volatile int count; void setup() { Serial.begin(115200); count=0; pinMode(encoderI, INPUT); pinMode(encoderQ, INPUT); attachInterrupt(0, handleEncoder, CHANGE); } void loop() { Serial.println(count); delay(10); } void handleEncoder() { if(digitalRead(encoderI) == digitalRead(encoderQ)) { count++; } else { count--; } }

How to use rotary encoders

Arduino DRO Linear Scale Interface

Accuracy of a print head sensor in a DIY linear drive

How to Use Arduino Interrupts The Easy Way

How to linear encoders works

What is an ENCODER - Linear and Rotary encoder - Incremental and Absolute encoder

#19 How to use a Rotary Encoder with an Interrupt routine on your Arduino

Using Rotary Encoders with Arduino

PRINTER ENCODER ON ARDUINO

How to Make Anything Remote Controlled with the RX480E Circuit!

Encoded Motor With Arduino

Unbelievable Smart Worker & Hilarious Fails | Construction Compilation #8 #adamrose #smartworkers

Schematics and sketch to use inkjet printer linear encoder

CNC v3.2.1 - electronics using DC motors and rotary encoders

Stop Buying Arduino Boards! Build Them for $3 Instead

Adventures in Science: How to Use Rotary Encoders

How to Use a Joystick with Arduino: Wiring and Basic Controls

Digital Readout DRO with digital caliper gauge (german)

JCS-900 DRO with Arduino and LCD

