Tune that dial - Index of
Tune that dial - Index of
Tune that dial - Index of
Create successful ePaper yourself
Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.
contains a complete superheterodyne<br />
receiver. Here again the reference frequency,<br />
in this case the local oscillator<br />
frequency, is provided by a PLL oscillator.<br />
As the PLL multiplication factor is 32<br />
and the IF is 10.7 MHz, the crystal frequency<br />
must be 13.2256 MHz (see [1]).<br />
A remarkable feature <strong>of</strong> this IC is the<br />
integrated image rejection mixer,<br />
which effectively means <strong>that</strong> the mixer<br />
stage also provides adequate image<br />
frequency suppression, so there is no<br />
need for a preselection filter at the<br />
input. As a result, the required number<br />
<strong>of</strong> external components can be<br />
reduced to around 20.<br />
The receiver does not have to be tuned,<br />
and it boasts a sensitivity <strong>of</strong> better than<br />
approximately 1 µV. The receiver IC also<br />
has an audio filter <strong>that</strong> is intended to<br />
reduce noise and interference. A ‘data<br />
slicer’ after the filter provides automatic<br />
operating point adjustment to provide<br />
data <strong>that</strong> is as reliable as possible even<br />
under weak signal conditions.<br />
The receiver unit is also fitted with an<br />
ATtiny15L microcontroller. The data<br />
slicer output <strong>of</strong> the receiver IC is connected<br />
to an input <strong>of</strong> the microcontroller,<br />
which decodes the burst signals<br />
from the transmitter. If the decoded<br />
data contains the correct key, it activates<br />
two outputs. Here OUT1 provides<br />
a 1-second pulse if the correct<br />
key is received. It is intended to be<br />
used to drive a mechanical latch<br />
opener, which is usually fitted with a<br />
solenoid. The second output (OUT2) is<br />
an alternate-action switch. OUT2<br />
L1:<br />
8mm<br />
L2: 5mm 7mm<br />
4mm<br />
switches to +5 V when the key is<br />
received once and then toggles to 0 V<br />
the next time it is received. It can thus<br />
be used to switch something on or <strong>of</strong>f,<br />
such the control unit <strong>of</strong> an alarm system<br />
or an anti-start device in a car.<br />
S<strong>of</strong>tware<br />
The s<strong>of</strong>tware consists <strong>of</strong> two separate<br />
programs – one for the transmitter and<br />
one for the receiver. At somewhat more<br />
than 400 lines each, these programs<br />
are fairly modest in size.<br />
At the transmitter end, after starting<br />
up the s<strong>of</strong>tware looks for a particular<br />
value (a ‘signature’) in the EEPROM <strong>of</strong><br />
IN<br />
FL1<br />
C7<br />
10n<br />
C3<br />
1n<br />
IN<br />
C1<br />
10n<br />
X1<br />
GND<br />
10,7MHz<br />
OUT<br />
C8<br />
1n<br />
2 7 14<br />
AVDD AVDD DVDD<br />
27<br />
11<br />
1<br />
PWRDN<br />
IRSEL<br />
XTAL1<br />
VDD5<br />
AGCDIS<br />
XTALSEL<br />
24<br />
15<br />
16<br />
28<br />
3<br />
12<br />
XTAL2<br />
LNAIN<br />
MIXOUT<br />
IC1<br />
LNAOUT<br />
MIXIN1<br />
PDOUT<br />
DATAOUT<br />
6<br />
8<br />
26<br />
25<br />
18<br />
IFIN2<br />
17<br />
IFIN1<br />
9<br />
MIXIN2<br />
L2<br />
4<br />
LNASRC<br />
22nH<br />
the microcontroller to see whether a<br />
valid key has already been generated.<br />
If it hasn’t, the s<strong>of</strong>tware immediately<br />
generates a 24-bit code and stores it in<br />
the EEPROM memory along with the<br />
signature so it will not have to generate<br />
a new key the next time.<br />
A random number generator <strong>that</strong> provides<br />
an arbitrary 24-bit value is<br />
needed to generate the key. This is<br />
implemented using a capacitor connected<br />
to pin 2 <strong>of</strong> the microcontroller.<br />
The algorithm used for this purpose is<br />
based on timing. Pin 2 is first configured<br />
as an output and held low for a<br />
certain length <strong>of</strong> time to discharge the<br />
capacitor. After <strong>that</strong> the pin is config-<br />
IC2<br />
1<br />
RESET PB0<br />
5<br />
7<br />
PB2 PB4<br />
2<br />
3<br />
PB3 PB1<br />
6<br />
ATTiny15L<br />
12/2006 - elektor electronics 39<br />
C1<br />
10n<br />
IC1<br />
5<br />
PB0 RESET<br />
1<br />
2<br />
PB4 PB2<br />
7<br />
6<br />
PB1 PB3<br />
3<br />
ATTiny15L<br />
C2<br />
100n<br />
MAX1473<br />
DSP<br />
DFFB<br />
DSN<br />
DFO<br />
OPP<br />
AGND AGND DGND<br />
5<br />
10<br />
13<br />
23<br />
22<br />
20<br />
19<br />
21<br />
C4<br />
1n<br />
C9<br />
100p<br />
C2<br />
10n<br />
C11<br />
100n<br />
L1<br />
Ø 15mm<br />
C5<br />
2p7<br />
R3<br />
220k<br />
C10<br />
47n<br />
C6<br />
220p<br />
1M<br />
10k<br />
R1<br />
R2<br />
DATA<br />
JP1<br />
LEARN<br />
Figure 2. The receiver is somewhat larger, primarily due to the extensive circuitry around the MAX1473.<br />
8<br />
4<br />
L1<br />
*<br />
3p3<br />
4cm 4cm<br />
*<br />
VDD<br />
GND PAGND<br />
C4<br />
10n<br />
5<br />
EN XTAL1<br />
1<br />
IC2<br />
X1<br />
6<br />
DATA<br />
MAX1472<br />
4<br />
PAOUT XTAL2<br />
8<br />
13.560MHz<br />
C3<br />
*<br />
7<br />
2 3<br />
+5V<br />
8<br />
4<br />
S1<br />
050364 - 11<br />
C12<br />
100n<br />
BT1<br />
CR2032 3V<br />
see text *<br />
Figure 1. The transmitter consists <strong>of</strong> only two ICs and can be built in a very compact form.<br />
820 Ω<br />
R4<br />
D1<br />
LOW<br />
CUR<br />
820 Ω<br />
050364 - 12<br />
R5<br />
D2<br />
OUT1<br />
OUT2