An electro-mechanical device for detecting angular position and/or motion.
0
votes
1answer
30 views
Why is my code only reading the change of the encoder's pin A?
I am writing code for reading in a quadrature encoder. I used attachInterrupt on pin 2 and 3, but by using the same ISR.
int encAPin= 2;
int encBPin= 3;
volatile int encAValue= 0;
...
1
vote
3answers
43 views
Absolute encoder vs Accelerometer for calculating angles
I've been toying with this idea for a while and after some thorough research I'm more than happy that the project is realistic. However I'm in need of some direction in terms of the sensors I should ...
1
vote
2answers
64 views
Problem to convert rotary encoder output to angle
I'm using this incremental rotary encoder with a rotating disc.
Here is my system:
I will explain the system briefly and above is the illustration for that:
The rotary encoder(blue) is attached/...
1
vote
2answers
109 views
How to detect the direction of a rotary encoder?
I'm trying to detect the direction of rotation for an incremental rotary encoder. I'm supposed to get +1 for clockwise and -1 for counter-clockwise. However, I receive random values. Any help ...
1
vote
0answers
46 views
Encoder + Bounce2 Library
I am working towards debouncing my keyes rotary encoder using the Bounce2 library found here ( https://github.com/thomasfredericks/Bounce2 ).
I believe the problem lies in my code as there isn't much ...
0
votes
1answer
47 views
Arduino leonardo. Encoder mouse movement
I want to connect my sensonrs to an arduino leonardo.
The principal idea is use it like a scratch (like dj hero or beatmania??), if I move the scratsh up, the mouse will go up ( y Axis ), and if it ...
1
vote
0answers
50 views
Rotary Encoder on LoLin NodeMcu increases value when rotating right/left
I have a test program running on my LoLin NodeMcu board, with a Rotary Encoder connected.
I use Task.h and RotaryEncoderTask.h from this library: https://github.com/Makuna/Task (though my issue is ...
1
vote
1answer
61 views
Read/write data from 2 Arduinos simultaneously with Python
So for my project I have one Arduino Mega hooked up with a quadrature rotary encoder which is connected to the computer. An Arduino Uno is connected to a circuit I built, which in turn is connected to ...
0
votes
1answer
93 views
How to read differential TTL signal from encoder using Arduino?
I am using Arduino UNO/ MEGA to read the incremental encoder pulses (Baumer encoder EIL580). Currently, I am using it in single-ended mode (reading A,B and Z outputs) as I am not sure how to read the ...
4
votes
2answers
138 views
How to control cold to hot (blue to red gradient) RBG LED strip/bulb with a rotary encoder
Im doing a project for university and am struggling to code and setup a rotary encoder that can control the hot-cold variations. Much like the idea of communicating temperature selected by turning a ...
0
votes
1answer
182 views
How to configure 2nd Quadrature Decoder IO pins in Arduino IDE
I am working to read two quadrature encoders using a single Arduino DUE, as part of my summer vacations project. According to the following link
http://atmel.force.com/support/servlet/fileField?id=...
0
votes
1answer
295 views
Reading Two Quadrature Encoder using a single Arduino Due
I am working on an autonomous robot in my summer vacations. I am currently working on running the motors of my robot in a closed loop. In order to do so, I have to interface two Quadrature encoders of ...
1
vote
1answer
80 views
Quadrature Encoder:Interrupts: Reset Count
I'm working on a quadrature encoder(with a 500ppr codewheel) with a Channel A, B and an Index pulse output. Using an Arduino Mega I'm counting the number of pulses on Channel A on the rising edge. ...
1
vote
1answer
130 views
Interfacing pc mouse (serial port DB-9)
So I`ve got that mouse with serial connector. It is named serial so it should be easier to connect than even a ps2 mouse, right?
I can`t find any instruction on it. Or should I see instruction on ps2 ...
1
vote
0answers
33 views
Program does not seem to be passing from setup to loop, or printing to sd card
I am trying to write code to test servo motors using an encoder. I create a file in the setup part, and then set 1500 microseconds to 0 for the encoder. However, if I try to print something to the SD ...
-1
votes
3answers
88 views
Communication between IC and microcontroller (Teensy 3.2)
I am trying to use a rotary encoder with an integrated circuit to measure the position of a rotating shaft. I am then taking this data and writing to an SD card. The IC seems to be working correctly ...
8
votes
1answer
440 views
How to design and debug a custom I2C master-slave system?
How to proceed, when in need of a custom I2C master-slave system?
What are the design criteria to apply?
What are the debugging tools one can use to troubleshoot problems?
0
votes
1answer
432 views
Rotary Encoder problem with LCD Display
Program reads rotary encoder correctly without bouncing in this code:
int val = 0;
byte clkPin = 3;
byte dtPin = 2;
bool lastClk;
bool lastDt;
void setup() {
pinMode(clkPin,INPUT);
pinMode(dtPin,...
1
vote
1answer
103 views
Shaft Encoder Accuracy
So, first of all I just want to point out this code is from: Reading Rotary Encoders and is not mine.
I have a magnetic shaft encoder mounted on a regular DC motor, my problem is that I cannot ...
0
votes
0answers
98 views
Arduino AEAT - 601B - F06 coding. how to start?
i would like to write a program, and i have limited basics on Arduino.
What i wanted to code is for an Encoder AEAT - 601B - F06
the signal pulse is in the picture below
http://postimg.org/image/...
1
vote
2answers
4k views
Reading from a KY-040 rotary encoder with Digispark
I have a rotary encoder KY-040 connected to a Digispark like this:
CLK go to p0 and and DT go to p2, SW is disconnected for now (it's just a button).
I did everything like the instructions here: ...
2
votes
1answer
90 views
Sampling rate issue
I have an Arduino code which runs decently.
// Read in 10-bits Magnetic Encoder AEAT-6010-A06 into Arduino Uno
// Sampling
// Declarate
const int CSn = 4; // Chip select
const int CLK = 7; // ...
0
votes
3answers
475 views
counting pulses from encoder on interrupt 0 pin every 50 ms
I want to calculate the number of pulses coming from motor1 encoder pin2 (Int0) as input , and motor 2 encoder pin3 (Int1), I am working now for the first motor (just for the first motor ) so I set ...
-1
votes
1answer
229 views
Incremental encoder code
can somebody tell me what`s wrong with my code, i am using it to calculate rpm using incremental encoder
long counter=0;
long rpm = 0, z =0;
long ini_time = 0;
long end_time=0;
void setup(){
...
1
vote
2answers
543 views
Reading quadrature encoder
I am using an encoder motor for one of my projects and i was reading encoder values manually through Arduino. It was working fine when i turned it slowly, but whenever i would rotate it at some higher ...
0
votes
0answers
20 views
How to read data from a rotary encoder with ATmega328 [duplicate]
I'm using a home made "bare bones" Arduino, made with the ATmega328, and I need to read angle data from a geared DC drill motor, turning at speeds between 0 and 450 RPM. This is so I can use it as ...
0
votes
4answers
3k views
How to read data from a rotary encoder with ATmega328
I'm using a home made "bare bones" Arduino, made with the ATmega328, and I need to read angle data from a geared DC drill motor, turning at speeds between 0 and 450 RPM. This is so I can use it as ...
1
vote
1answer
835 views
Is it possible to use two encoders with Arduino Uno?
I would like to control 2 motors with the Arduino Uno board, which provides only two interrupt pins on digital 2 and 3.
I've set one encoder using these pins, and it works. What do you think about ...
3
votes
4answers
812 views
Rotary encoder on Uno and interrupts issue
This question is regarding a project using an Arduino Uno.
I have one of these quadrature rotary encoders.
I'm using a slightly modified version of the code from the article, Quadrature Encoder too ...
1
vote
1answer
1k views
bitRead() gives wrong answer Arduino UNO R3
I am trying to read from a quadrature rotary encoder using an Arduino UNO R3. This is done by connecting the encoder's channel A pin to the Arduino interrupt 0 pin (digital IO pin 2). Inside the ...
1
vote
2answers
149 views
If statement behaves erratically
I connected the output from an encoder motor to int0. this is used to increment a counter at every pulse. in the loop(), I check this counter and stops the motor if it is above certain value. But this ...
1
vote
2answers
1k views
Turning a DC motor a set number of Rotations using an encoder
I'm using an arduino UNO, and i want to turn a motor a set number of revolutions, i'm trying to read the clicks of the encoder which has a resolution of 360 clicks/ revolution, my logic is that i ...
12
votes
2answers
9k views
How precise can I get Arduino using rotary encoders?
Stepper motors are often pricey for a large motor. However, with a powerful, standard DC motor and a rotary encoder, you can "simulate" a stepper motor. How accurate are rotary encoders with Arduino ...