Upload
others
View
4
Download
0
Embed Size (px)
Citation preview
Industrial Electrical Engineering and Automation
Lund University, Sweden
Position sensors
and
dimmer introduction
2019-10-16
Gunnar Lindstedt & Fran Márquez
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
Measurement of Rot. Angle
• Potentiometer (no endstop)
• Resolver
• Digital absolute encoder
(Gray code)
• Incremental encoder
(optional index pulse)
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
Measurement of Rot. Angle
• Resolver
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
Measurement of Rot. Angle• Resolver
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
Measurement of Rot. Angle
• Digital absolute encoder (Gray code)
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
Incremental Encoder Waveform
Z optional
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
How to Keep Track of the Position?
(A,B)
S0
S2 S3
S1
10
00
01
01
11
10
11
00
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
Encoder algoritm by
René Sommer
AB BA Next AB
00 00 01 01
01 10 11 01
11 11 10 01
10 01 00 01
00 00 10 10
10 01 11 10
11 11 01 10
01 10 00 10
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
Alternative implementation(most common in this course)
switch (ABnew){
case 0 : if (AB==2)n++; else /* AB==1 */ n--; break;
case 1 : if (AB==0)n++; else /* AB==3 */ n--; break;
…
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
Implementation
• Count the passing of one transition
section in the graph
• Current state gives quad-resolution
• Consider the frequency of the
changes and select polling or interrupt
Industrial Electrical Engineering and Automation
Lund University, Sweden
Dimmer
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
AVR
board
Incremental
encoder board
Power amp Load
A B
PWM
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
In
Vcc
GND
+12V
Load
BC557
BD179
1002k2
100
100n
1N4004
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
Applied Mechatronics
Industr
ial E
lectr
ical E
ngin
eering a
nd A
uto
mation
With filters…
Applied Mechatronics