Montreal Doppler I Doppler DF unit
Front panel view of the Montreal
Doppler I with the alternate firmware. Note that the
center LED was not installed, as the blinking of the cardinal
points allows visual orientation in the dark. Click on image for a larger version.
Important information - please read:
This is not an official page of the late Jacques
Feel free to ask me (via the link at the bottom
of this page) if you have any questions.
The "Alternate Firmware" for the Doppler I is still
available - go
here for more information on pre-programmed
Included on this page are some modifications
that are recommended to all users of the Doppler I - even if
you plan to continue using the original
firmware. If you plan to build this unit, but cannot
locate IC2, a MAX293 or MAX294, don't worry - it works quite
well without it. See
below for comments on operating without IC2.
Adding 3 or 4 buttons to an already-built Doppler 1 unit
is quite simple: The
With this firmware it is possible to add a serial port
to feed bearing data to a computer. At this time, that
information is not
The late Jacques Brodeur, VE2EMM, designed a microprocessor-based
"Doppler" type DF unit described on theVE2EMM's
Montreal Doppler I pagethat drives the antenna
switching circuit, updates the display, and does signal processing
to determine the bearing. This unit works along the same
principles that the so-called "Roanoake" DF units do - but the
addition of a microprocessor (to do the generation of switching
signals and determining the phase of the recovered audio signal)
adds additional flexibility.
In examining the schematic and source code for the original
Doppler I, one can see that it is a more-or-less straightforward
implementation of the original "Roanoke" hardware in code:
Signals are amplified and lowpass filtered by IC2.
Signals are further amplified and filtered by IC3A.
IC4 is a classic "Roanoake-type" switched-capacitor
commutating filter, providing stable, narrowband filtering.
IC3B and IC3C restore a "sine wave" shape to the "stairstep"
output of IC4.
IC3D is a slicer that converts the sinewave output of IC3C
into a square wave for input to IC1 (the processor) for
IC1 also provides timing for the the IC4 filter and switching
of the antennas.
IC1's software measures the "delay" of the square wave output
from IC3D with respect to the antenna switching to determine the
phase (and thus bearing) of the received signal, and displays
the determined bearing, along with an offset value (supplied by
the user) for directional calibration..
In the later Montreal Doppler II/III Jacques added more
sophisticated "DSP" (Digital Signal Processing) techniques to the
inputted signal. In using DSP, one may simply throw the
filtered audio signal into the microprocessor, eliminating the need
for the restored square wave provided by IC3C and IC3D. Not
only does this simplify the circuitry and improve temperature
stability (by removing a potential source of drift) it allows the
processor to determine some aspect of the "quality" of the signal
Even though the original Doppler I firmware didn't employ DSP
techniques, it is possible to improve the
functionality/performance of it by replacing the microcontroller
with one containing new code and performing simple hardware
Three ways to use the firmware:
There are three ways that one can use the
firmware, depending on the amount of modification that you wish to
The "Simple" modification.
minimal modification to the unit, namely the
bypassing of IC3C and IC3D as well as the
modification of the "Audio Level" detector. Both of
these modifications are detailed below. With this
modification, one uses the original LEDs, calibration
potentiometer, "Radio 1/Radio2" switch, and "Fast/Slow" switch
and low/high audio levels are indicated by slow/fast blinking of
the display. By plugging in the new firmware and doing
these modifications, you get much-improved response to
weak/noisy signals, and superior rejection of bad
bearings. In addition to this, one can select the amount
of desired averaging by grounding the appropriate processor pin
through a resistor while powering up the unit. It is
not necessary to add additional switches unless one wishes to
change the amount of average often. See below for more information on operating
using this mode.
Using single-color LEDs.
be gained by installing/replacing dual-color LEDs to get Red,
Green, and Yellow colors to denote signal quality, it is still
possible to obtain most of the benefits of the full
features of the firmware (e.g. adjustable parameters such as
averaging, thresholds, serial data, etc.) even if one has
single-color LEDs. Of course, the ability to represent
more types of information on the display is limited as one
cannot simultaneously denote "bad," "integrated" and
"averaged" bearings with just a single color. But it is
possible to configure the unit to represent the "averaged"
bearings as well as the menu items using just a single
color. This mode requires the modifications described for
the "simple" mode plus the installation of at least three
pushbutton switches - or a fourth pushbuttons switch and some
simple circuitry if one wants to be able to send serial data as
The "full color" modifications
the modifications mentioned above, plus the installation of 32
two-color LEDs instead of (or to replace) the single-color
LEDs. Read more about this below!
"What's so great about a 'sliding average?'"
One of the more important design aspects of this type of
direction-finding system is that of a good filter to detect
the "switching tone" caused by the electronic rotation of
the antennas: It is this switching tone that carries
the phase (that is, direction) information as well as
information that can potentially indicate something about
its quality. The narrower the filter, the more readily
the bearing may be dug out of weak-signal noise or
There is a penalty, however: The narrower the filter,
the slower that it will be to respond to changes in a
This Doppler unit, as originally designed, already had one
very tight bandpass filter - the 8-capacitor "Roanoake-type"
bandpass filter consisting of capacitors C21-C28 and
IC4. By adding a "damping" control to replace SW4, R17
and R18, one can vary the response time from very quick to
The "sliding average" is, in a very real way, a software
simulation of this same type of filter. Just like the
8-capacitor filter, it averages, over time, the directional
information comprising the signal. Because it is
software-controlled, it can be made to function very much
like the 8-capacitor filter - but it can also be configured
to automatically "reset" when the signal goes away, allowing
the new signal to be analyzed quickly without being affected
by previous signal's bearing.
In this way, one can get some of the benefits of having
"slow" filtering by increasing the number of averages taken
- but still be able to respond to short-duration signals.
Features of the new firmware:
RS-232 serial output to a computer (an optional
modification): With the addition of a 4th
switch and some simple circuitry (a couple of transistors and
resistors) a serial output of the bearing (in "Agrelo" (tm)
format) is possible at 2400, 4800, 9600, or 19200 baud.
There are two modes of operation: Single-shot mode where
one bearing is sent when the button is pressed, or the
"Continuous Bearing" mode which sends a constant string of
bearings. This feature may be useful where the primary
purpose of the DF unit is remote monitoring and a "fancy"
display is not needed. Note that the display will
briefly go blank when a bearing is being sent.
Adaptive filtering: In the form of an
adjustable sliding average, much of the functionality of the
"Roanoake-type" filter is simulated. An average of the
past 2, 4, 8, 16 or 32 readings can be presented as a "sliding"
average. Unlike integration, this does not reduce the
update rate. The averaged bearings (displayed in a
yellow/orange color) consist only of "good"
readings. This averaging also includes an "Average Clear"
function - that is, it can automatically purge the remnants of
the previous signal from the averaging buffer and then
"re-build" the average when the next signal comes along:
This feature allows the new transmission (even if it is very
brief) to be recorded, without having been affected by the
previous signal's bearing still present, allowing very rapid
response even with the filtering set to the "slow" mode (e.g. a
larger number of averages.)
Multi-color display: The use of bi-color
LEDs is supported to provide the simultaneous display of three
colors: Red shows "bad" bearings, green
shows the "current" bearing, while yellow shows the
Improved signal processing: The use of
DSP techniques to process the incoming signal. Usable
bearings are possible with more than a 20 dB range of input
signal. The DSP allows removal of the slicer circuit and
the audio filter consisting of IC3C and removes a major
contributor of bearing drift due to changes in
temperature. Also, by placing the audio level detector on
the input of the switched-capacitor filter (one of
the easy modifications mentioned below) it is possible to
get usable bearings from signals of far worse quality
than before as well as more-quickly detect conditions when
bearing quality is bad.
Signal quality calculation: The "quality"
of the signal is calculated, allowing one to reject bearings of
poorer quality and are below the desired "threshold."
Improved "Freezing" of the last bearing when the signal
goes away: A very simple modification allows much
faster response to the "squelching" of the receiver, allowing
the bearing of the previous transmission to be "frozen"
accurately when it disappears. Additionally, the
"averaged" bearing is less-affected by short bursts of noise, so
it is still likely to point in the correct direction even if
there is a burst of "squelch noise" when the signal drops.
Adjustable integration: Each reading can
consist of 1, 2, 4, 8, 16 or 32 "samples." (There are 20
samples/sec.) More integration slows the display, but can
help smooth out noise. "Good" readings are displayed in
green and "bad" readings are displayed in red. Note
that normally, one would set the "integration" to a setting of
1 or 2 and allow the averaging to do its work.
Displayable "Audio Level Meter": The
current audio level may be displayed at the touch of a button to
allow easier adjustment of the receiver's volume.
Displayable "Signal Quality Meter": The
quality of the signal being received may be displayed at any
Adjustable "audio level" threshold: Audio
levels below the threshold will cause the display to "freeze" -
very useful when you want to preserve the last reading after the
Adjustable "quality" threshold: The
current signal quality may be displayed at the touch of a
button, and the threshold above which readings will be
calculated may be adjusted.
The addition of an "Auto Calibrate" feature:
this feature, the current bearing can be made to represent the
"North" bearing - something very useful when in a car. The
bearing may also be manually adjusted in either
11 degree steps (approx. 1 LED at a time) or in 1 degree steps.
Display "Mirroring": The display may be
"mirrored" - that is, increasing degrees may be represented in a
counter-clockwise direction instead of the usual "clockwise"
direction. This allows the display to be observed as a
reflection in the windshield of a vehicle, for example. (This
mode reverses the display, but not the bearings sent on the
Upside-down display: If, for some reason,
you constructed the unit such that LED1 was south instead of
north, or if it is more practical to mount the unit upside-down,
the display can be configured such that the bearings are
displayed 180 degrees off to accommodate.
Selectable Antenna Drive polarity: Antenna
drive polarity may be selected as positive or negative, letting
you use practically any existing antenna switcher that you might
Selectable antenna rotation: Antenna
rotation may be selected as Clockwise or
Counter-Clockwise. This can quickly allow the user to
reconfigure the antenna array switch without re-labeling or
reconnecting the antennas. (This reverses the display
and the bearings sent on the serial port.)
Blinking cardinal points: The LEDs at the
cardinal points blink in different colors (North = Green,
South = Yellow, East and West are Red) allow orientation
of the display even in the dark.
A "Stop Rotation" button: When the antenna
rotation is active, the switching tone (which carries the
bearing information) may cover up background noise or low-level
modulation - not to mention having the effect of degrading weak
signals somewhat. Being able to start/stop the rotation
allows one to quickly check the signal.
Four-radio memory: The antenna
configuration and direction calibration may be "remembered" for
up to 4 radios.
Dim/Bright selection: When using in a dark
location or at night, it may be nice to reduce the brightness of
Interior view showing the main board
with the processor and audio filtering. Click on image for a larger view.
The first modification below (involving R9) is extremely
simple and is strongly recommended as it greatly
improves performance in the presence of weak/noisy signals.
Also, the third modification (the "damping" control) is
recommended as one can greatly improve the unit's response to even
very brief transmissions. The first three
modifications are recommended even if you are NOT
intending to use this firmware!
Speeding up the response to audio level - Moving the "input" of R9 from the output of U3B (pin
7) to U3B pin 1 and changing C8 from 0.47 uF to 0.047 uF.
This will allow a much faster response to the
"squelching" of the input signal and will "freeze" the display
as soon as the input signal disappears. This
involves lifting one end of a resistor and adding a jumper.
"Knee" frequency adjustment of the lowpass filter, IC2
- This modification improves temperature stability
of the unit and is described in detail below. If you cannot
locate a MAX293 or MAX294 for IC2, don't worry - you can use the
unit without it with only minor
The addition of a "damping" control.
Replacing the "Fast/Slow" switch and the two 1 megohm fixed
resistors with a 1 meg pot, a series 47k resistor and a
compensation capacitor) allows a full range of adjustment of the
unit's response. (It also provides something to fill
the hole when you get rid of the "Calibration" pot.)
The remainder of these modifications only apply to
units running the "Alternate" firmware. The first
modification listed below (bypassing IC3C and D) is required
to use the new firmware.
Bypassing of IC3C and D -As
mentioned before, the functions of IC3 sections C and D will no
longer be needed. This modification removes one
stage of (now) unnecessary filtering - a source of bearing drift
as well as the comparator. This is done using one
of two ways:
Jumper IC3 pins 7 and 14 together and bend pin 14 of IC3 so
that it is not in the socketOR
Cut the trace at near pin 14 of IC3 and run a jumper so that
pin 7 of IC3 is connected directly to pin 7 of IC1, the main
The addition of some selector buttons: The
addition of a few pushbutton switches and series resistors (470
ohms to 1k ohm) allow the easy configuration of various settings
as mentioned below. At this point, a total of 3
buttons will be used with a optional 4th button if a serial
port output is desired: The existing button (SW2) will
not be needed and may be rewired as one of the added
buttons. See the section "adding buttons" for
details on how the buttons are to be connected.
The replacement of the LEDs with a dual-color
version: A strongly recommended
modification would be the replacement of all 32 compass rose
LEDs with dual-color (red/green) LEDs. This will allow
color-coded indication of the type of bearing being received as
well as provide a visual indicator of the cardinal points
(North/South/East/West) in the dark. Note: The
firmware will still permit the use of the original
single-color LEDs if so-desired, but simultaneous display of
"integrated" and "averaged" bearings will not be
possible. The LEDs recommended for the compass are
DigiKey P/N: 160-1038-ND which are Liteon P/N:
The removal of the "calibration" potentiometer. The
remove the need for the "calibration" potentiometer as
calibration may be done "automatically" by using the current
averaged bearing. The "hole" that you may have in your
enclosure from this potentiometer (if you already built it...)
could be used for an adjustable "damping" control, eliminating
the need for the "Fast/Slow" switch and providing enhanced
The (optional) addition of hardware for a serial port.
button and adding some simple circuitry (two transistors and
several resistors) it is possible to add a serial output of the
bearing. This allows the unit to automatically transmit
received bearings to a computer or in response to a buttonpress
by the user.
A recommended modification for all
users of the Montreal Doppler I "Knee frequency
This modification is applicable to all users of the
Doppler I, no matter which firmware is being used.
The original instructions recommend that the C1/C2
combination on pin 1 of IC2 be adjusted for a value of
approximately 680 pF to "ADJ for 500 Hz knee at pin 5."
I would not recommend this procedure for
one main reason: At the "knee" (that is, the
frequency at which the attenuation of the lowpass filter
starts to increase dramatically) the
phase-versus-frequency changes most dramatically. In
looking at the datasheet for the MAX293/294, one can see
that as one moves from 500 Hz to just 560 Hz (assuming
that the "knee" is set precisely at 500 Hz - a clock
frequency of 50 KHz) that the phase changes by about 180
degrees! Assuming that one adjusts the clock
frequency precisely at the knee, if the center frequency
drifted 3% over temperature (this assumes zero capacitor
drift and only that drift intrinsic to the oscillator in
the chip) one could expect as much as 90 degrees of phase
shift. This phase shift does, of course, translate directly
into bearing calibration drift!
A better solution is to purposely tune the oscillator a
bit high to move the "knee" away from the 500 Hz - say,
around 700 Hz (which would use a 470 pF capacitor.)
At this frequency, the "phase-versus-frequency" curve is
much shallower - representing only 20-30 degrees for a 3%
frequency variation. It should go without saying
that one should use ONLY NPO ceramic or
polystyrene capacitors for the C1/C2 combination for best
temperature stability. If you are really
after best stability, one could simply supply an external
crystal-referenced clock (in the range of 50 to 75 KHz) to
If you have concern about the higher "knee" frequency
degrading performance on the unit - don't worry about
it: IC1A's bandpass filter will take care of it -
not to mention the highly effective filtering action of
the 8-capacitor "Roanoake-type" bandpass filter consisting
of IC4 and C21-C28 - it's this second filter that does
almost all of the filtering, anyway.
It is worth mentioning that a unit with the above
modification - and the bypassing of IC3C and IC3D (mentioned
below) displayed only about 15-20 degrees of bearing
drift over a 20 degree C (nearly 40 degree F) temperature
range. Additional comment concerning the removal of
IC2, the low-pass switched-capacitor filter:
These comments are applicable to
all users of the Doppler I, no matter which firmware
is being used.
Upon construction, IC2 may be completely
eliminated without any significant affect on performance
as the 8-capacitor filter (consisting of IC4 and C21-C38)
does the majority of the filtering, anyway.
Elimination of IC2 does, however, require a much higher
audio input to the unit, so if you have already added an
attenuator to reduce the level, you will likely have to
remove or readjust it. This modification consists of
Remove IC2. (Hopefully you used a socket...)
Jumper out R10, the 51k resistor.
Jumper pins 3 and 4 of IC2.
Jumper pins 5 and 8 of IC2.
Elimination of IC2 reduces one potential source of
temperature-related drift and eliminates one of the more expensive,
There is one caveat, however: Presuming that you have done the
modification to "speed up" the audio detector (e.g. moving the
"input" of R9 - see below) the detector becomes somewhat
less-sensitive to the presence of multipath owing to the fact that
it is a bit less-able to detect the decrease in the amplitude of the
switching tone's fundamental frequency. As for its main
purpose - quickly detecting the loss of audio when the squelch
closes to allow "freezing" of the display - it works very well.
With the above modification, only a modest volume level was required
to drive the unit - somewhere between 1/4 to 1/2 volume on the
radios that I have tried and, in all cases, well below a volume
level that could cause distortion of the received audio. In
the original circuit, enough gain was present so that one either had
to have the volume control set very low or put an
attenuator in front of the input to the main board so that the
radio's volume control wasn't set at a "microscopically low" setting
where the adjustment of the volume control was very touchy.
Preliminary operating instructions
for the "Simple" mode:
The "Simple" mode can only be entered by executing
an "EEPROM Clear" - This is done by grounding RB5 (pin 26)
through a 220-1000 ohm resistor while power is applied.
For this mode, only the bypassing
of IC3 sections C and D is required, along with the "speeding
up the response to audio level"
modifications listed above are required. This mode operates
very much like the original software:
Low audio levels cause the display to blink slowly (about once
Excessively high audio levels cause the display to blink
quickly (about 3 times per second.)
The direction calibration is set using the "calibrate"
Antenna rotation is always Clockwise, as per the original
Antenna switching polarity is always negative - that is, an
antenna is selected when the respective pin is grounded by the
processor, as per the original firmware.
There are a few important differences, though:
Where the original firmware simply timed pulses from IC3D,
this firmware does DSP analysis of the incoming signal to
determine the bearing and the quality of the
signal. By analyzing the signal in this manner, usable
bearings may be obtained from signals of worse quality than with
the original firmware.
Originally, the displayed bearing was the result of the
summation of two successive bearings averaged together.
This firmware actually does vector-based averaging of the
signals that it receives and displays the true vector sum of
those signals being averaged, taking into account not only the
bearing, but the quality of those signals. In cases of
severe multipath, heavy noise and/or modulation, this can help
to provide a more consistent indication of bearing with the
result might otherwise be a seemingly random display of
The "quality" of the signals is calculated: Only
averaged signals with a net quality of "3" or greater are
displayed. This can go a long way to reduce extraneous
readings cause by reflection and modulation.
Adjusting the calibration is made easier: When the unit
is powered up, the calibration pot is read and its setting is
translated to a "calibration" bearing. As the
potentiometer is adjusted, the display is updated to show the
new calibration settings and 2 seconds after the user stops
adjusting the potentiometer, normal operation begins, using that
By default, the displayed bearing consists of the past four
readings (there 20 readings taken per second) trigonometrically
averaged together, but this may be set at 2, 4, 8, 16 or 32 by
grounding the appropriate pin (through a 220-1k resistor) as the
unit is powered up. Because the average is a "sliding"
average, the display is still updated 20 times-per-second no
matter what the setting, but the currently displayed bearing
also includes information of the past averaged bearings.
Adaptive filtering is enabled. 1/2 second after the
signal goes away, the "average" is erased. What this means
is that even if you have the averaging set to 16 or 32 - which
means that the display contains an average of about 1 second's
worth of signal - it will still respond very quickly when a new
signal appears, as the average consists of only those bearings
that have been accumulated up to that point - even if the signal
is brief enough that only, say, 4 bearings have been acquired.
The number of averages may be selected when the unit is being
constructed. By default, the unit displays the result of
bearings averaged together. By grounding the appropriate
pin of the microprocessor through a resistor (220 to 1000 ohms)
while power is applied, a different number of averages may be
selected. When this is done, the LED number corresponding
to the number of averages selected will be displayed for 2
seconds before the calibration setting is shown. (This
will happen only when the pin is grounded. "North"
is LED #1.) The selections are as follows:
Pin 21 (RB0) - 2 averages. When selected, LED #2
is illuminated for 2 seconds before the calibration setting
Pin 22 (RB1) - 4 averages - the default setting. When
LED #4 is illuminated for 2 seconds before the calibration
setting is shown.
Pin 23 (RB2) - 8 averages. When selected, LED #8
is illuminated for 2 seconds before the calibration setting
Pin 24 (RB3) - 16 averages. When selected, LED #16
is illuminated for 2 seconds before the calibration setting
Pin 25 (RB4) - 32 averages. When selected, LED #32
is illuminated for 2 seconds before the calibration setting
The unit may be constructed with either 3 or 4 pushbuttons,
with the 4th pushbutton being required only if serial data
functions are desired.
If the unit is in "Simple" mode (due to an EEPROM clear or
because of new firmware or a hardware upgrade) the "Simple"
mode is exited by holding down buttons 1, 2 and 3 while
applying power, which will cause the unit to enter the
"Configuration" mode. Once "Simple" mode is exited, it
can be re-entered only by doing an "EEPROM Clear."
The original Doppler I firmware offered no provisions for
pushbuttons. Being that a 28 pin microcontroller is used,
there are not a lot of extra pins available for added function -
unless you wish to multiplex them onto existing pins. In
this firmware, this is exactly what was done: When a button
is pressed, it grounds that pin through a 1k resistor. While
the mincrocontroller is scanning to update the LEDs, it will
occasionally turn off all of the LEDs and check to see if a button
had been pressed, effectively "grounding" the respective pin.
Because the pin that is "lightly grounded" through the pushbutton
is also used to power an LED, pushing the button will also cause
some LEDs that were not selected to be illuminated to glow
dimly while the button(s) is/are being pressed. This is an
unavoidable consequence of the multiplexing of the LEDs with the
Similarly, to provide an RS-232 output, the LED display must be
blanked briefly while the data is being sent because the serial
output of the microcontroller is also shared with one of the LED's
common leads to avoid. To avoid I/O conflicts and data
corruption, all LEDs (except the one in the center) are
turned off for the duration of the data packet.
The buttons may be operated in one of two ways:
A "Shortpress": This is a brief (less than 1.5
seconds) press of the button(s.) The desired function is
activated the instant that the button is released.
A "Longpress": This is a longer-duration (approx.
2 seconds or longer) press of the button(s.) The desired
function is activated as soon as the button has been held down
for the minimum amount of time.
Additionally, there are two distinct modes that the unit may be in:
Configuration mode: This allows the configuration
of various hardware and timer-related settings. While in
this mode, a 3-LED "triangular" pattern will blink.
Operate mode: This allows the display and/or
changing of various parameters, as well causing certain actions
to occur while the unit is in operation.
If an EEPROM reset is done, the unit will come up in "Simple
Mode" (see above) by default. The "full-featured"
mode is enabled by doing a reset buttons 1, 2 and 3 held down
for several seconds and entering Configuration
mode. Once the "Full Featured" mode is enabled, it is
only possible to re-enter "Simple Mode" by doing an EE RESET.
If you had been using the original firmware, make
certain that the antenna polarity and rotation
direction are set to negative switching polarity and clockwise
rotation to allow for compatibility with your exising antenna
array: There is no guarantee that the
default settings will be correct when an "EEPROM Clear" is done.
Note: When in configuration mode
"idle" display, three LEDs will blink in a triangular
pattern and no other LEDs will be lit. After setting a
configuration, the new configuration will be displayed for a
couple of seconds and then the display will revert back to the
"triangular blink pattern" at which time more changes may be
Button 1 (Shortpress): Toggle
enable/disable of the display of "bad" bearings (displayed
in RED.) When the red "bad" bearings are to be displayed,
the SOUTH LED will flicker red. When the display of "bad"
bearings is to be disabled, a green and yellow LED will flicker
on either side of the the SOUTH LED. This may be done to
if the red "bad" LED causes too much visual "clutter."
Button 1 (Longpress): Flip display (e.g.
"mirror" mode.) The display "spins" in the direction of
increasing degrees, that is, it spins Clockwise for a "normal"
display and CounterClockwise for a "flipped" display. Note
that "flip" mode does not affect the way any of the
configuration menus are displayed.
Buttons 2 or 3 (shortpress): Toggle
Button 2 (Shortpress): Antenna rotation
direction. Two LEDs (red and green) chase each other in antenna
rotation direction. Note that antenna rotation is stored
separately with each of the 4 possible radio presets.
Buttons 1 or 3 (Shortpress): Toggle
Button 2 (Longpress): Select antenna
drive polarity. Green/Red on East/West cardinal points with duty
cycle indicating drive polarity. Note that antenna
drive polarity is stored separately with each of the 4
possible radio presets.
Positive drive: A quick "on" flash indicates that an
antenna is turned on when voltage is present on the antenna
Negative drive: A quick quick "off" flash indicates
that an antenna is turned off when there is zero voltage
present on the antenna drive pin.
Buttons 1 or 2 (shortpress): Toggle
Buttons 1 and 2 (Longpress): Toggles
enabling of the display blinking according to the audio
level. When enabled, the display will blink slowly
(once-per-second) when the audio is too low and it will blink
quickly (three times per second) if the audio level is too
high. Cardinal point blinking is independent of this
function. This function is most useful when using
the "Single Color" mode (just one color of LEDs
installed) to indicate whether the audio is too high or, too
Button 3 (Shortpress): Select test
antenna: When this command is executed, or when rotation is
stopped (see the "stop rotation" command below) 1,
2, 3 or 4 green LEDs (on cardinal points) depicts whether
antenna 1, 2, 3 or 4 turned on at that time. A selection of
"none" is indicated by a flashing red LED on the North
point. This function is useful for testing an antenna
array and its switcher.
Button 3 (Longpress): Configure the
"average clear" time. "Off" is indicated by a flashing red LED
on the South point, a yellow indicates a time of "0" seconds,
and the selected time increments going CW from south in 1/4ths
of a second per LED, with the available times being 1/4, 1/2,
3/4, 1, 2.5 and 5 seconds. The "average clear"
function resets the contents of the "running average" after the
signal disappears. If set to "0" (the yellow LED) it
clears it the instant that the signal goes away, while the timed
settings wait for that period of time to pass before the signal
Button 1 (shortpress): Decrements time
Button 2 (shortpress): Increments time
Buttons 2 and 3 (Longpress): Toggles
enables/disables the cardinal point blinking. When the
cardinal point blinking is enabled, the 4 cardinal points will
display as blinking. If the cardinal points are disabled,
they will be turned on continuously (non-blinking.)
Button 4 (Shortpress): This configures
the baud rate of the data to be sent via the serial port.
The baud rate indicated by number of LEDs illuminated: 2
= 2400, 4 = 4800, 9 = 9600, and 19 = 19200 baud.
Note that when the setting hits maximum or minimum and "rolls
over" back to the beginning, the LEDs will change color.
If the LEDs are YELLOW (or a red/green combination) if AVERAGED
bearing is sent. If the LEDs are GREEN, the current
(integrated) bearing is sent.
Button 4 (Longpress): The serial data can
be sent manually and/or automatically. When sent
automatically, the interval between transmissions is indicated
in RED in 1/4ths of seconds, CCW from "North" point. Settings
are 1/4 second (1 LED,) 1/2 second (2 LEDs,) 3/4 second (3
LEDs,) 1 second (4 LEDs,) 2.5 seconds (10 LEDs) and 5 seconds
Button 1 (shortpress): Decreases
Button 2 (shortpress): Increases
Buttons 1, 2 and 3 (Longpress): From this
"configuration mode idle display" this "reboots" the unit,
allowing exit of the configuration mode. Release
the buttons as soon as the display changes!
Comments on the configuration mode:
Configuration mode may also be entered by holding down
buttons 1, 2 and 3 while turning the power on.
Settings are saved to nonvolatile memory as soon as they
When exiting using the buttons 1, 2 and 3 to exit the
configuration mode, release the buttons as soon as the
Additional configuration options:
There are two more configuration options possible. These are
activated by grounding the appropriate pin, through a resistor with
a value of 220 to 1k ohms, while the power is applied:
RB7 (Pin 28): Rotate the display 180
degrees. This option simply turns the display
upside-down. This is useful if, for whatever reason, the
display has been mounted inverted.
RB6 (Pin 27): Toggles "One-Color" mode. If
you have already built a Doppler I, performed the above
modifications, but have not replaced the LEDs
with the dual-color devices, you can use this function to cause
all parameters to be displayed as one color.
If this setting is activated, you will also want to disable the
"bad" bearings (done by a "shortpress" of buttons 1 in the
Configuration mode) and the "current" bearings (done
by a "longpress" of buttons 2 and 3 in the "Operate" mode)
as well as activating the "Audio Level Blink" mode (done by
a "longpress" of buttons 1 and 2 in the Configuration mode)
to avoid confusion caused by displaying several different types
of data with the same color.
RB5 (Pin 26): EEPROM RESET and enter
SIMPLE mode. This also restores default
settings and calibrate the audio detector. If this
function is performed, remove all audio from the input to
allow proper audio level meter calibration!
This will cause all configuration to be set to the defaults.
This function also initiates a re-calibration of the audio
detector. This function looks at the audio level
detector input and calibrates the current audio level reading
as "zero" so it is important that audio not be
present on the input. If audio is detected on the input,
all LEDs will briefly display RED and a "canned" default value
will be used instead. This "audio calibrate" function is
used to accommodate different voltage drops across the audio
To exit SIMPLE mode, press and hold buttons 1, 2 and 3 for
several seconds: This will enter "Config" mode. Once
mode is exited, it is not possible to return to
SIMPLE mode without doing an EEPROM RESET.
Important note for users of the original Doppler I
firmware: When an EEPROM RESET is done,
users of the original Doppler I firmware need to be aware that
two parameters need to be changed in order for it to work
properly with their original antenna switching unit:
Antenna rotation needs to be switched to Clockwise (CW)
mode. This is done with a shortpress of button 2 in
the configuration menu (see above.)
Antenna switching polarity needs to be changed to Negative
mode (that is, the LEDS blink off
briefly.) This is done with a longpress of button 2 in
the configuration menu (see above.)
"Operate" mode is the normal mode where the display
shows the bearings.
LEDs on the four cardinal points (North, South, East
and West) will blink briefly once every 3/4 of a
second or so. This allows visual orientation of
the unit in the dark.
Button 1 (Shortpress): Display quality. Green
LEDs, displayed CCW from "North" with the number of LEDs
Flashing red and with a single green LED indicates quality
of zero. Automatically times out if no button pressed,
but may be extended by pressing and/or holding of button 1
(once it is displaying the quality) before it times out and
returns to normal operation. This mode does not stop
A single red LED at approximately the "East" position
indicate an audio overload condition.
Button 1 (Longpress): Calibrate direction.
Green indicates current calibration setting while yellow shows
the corrected direction. Note that calibration
direction is stored separately with each of the 4 possible
Button 2 (shortpress) decrements by 11 degrees (1 LED)
Button 3 (shortpress) increments by 11 degrees (1 LED.)
"Fine" calibrate mode: Button 1 (short) will switch to
"fine" calibration mode with green showing current calibration
and yellow showing corrected direction:
Button 2 (shortpress) decrements by 1 degree
Button 3 (shortpress) increments by 1 degree.
Button 1 (shortpress) exits.
Either mode is exited after a short period with no
Buttons 1 and 3 (Longpress):Toggle
mode. When this is done, the East/West LEDs will blink
green/yellow respectively at the new brightness setting.
NOTE: Cardinal point blinking does not
Buttons 1 and 2 (Longpress):
Auto-calibrate. The "north" direction is automatically set
to that of the present averaged direction. This
mode does not stop antenna rotation.
Button 2 (Shortpress): Display audio
level using 1-8 LEDs. Yellow LEDs, displayed CCW from "North"
with the number of LEDs indicating quality.
Flashing red and yellow LEDs at the "north" position
indicate quality of zero. Automatically times out if no button
pressed, but may be extended by pressing and/or holding of
button 1 before it times out. This mode does not
stop antenna rotation.
A single red LED at approximately the "East" position
indicates an audio overload condition.
Button 2 (Longpress): Adjust averaging.
Averaging indicated by number of green LEDs illuminated from 2
to 32. This mode stops antenna rotation!
Button 1 (shortpress) decreases averaging
Button 3 (shortpress) increases averaging.
Integration adjust mode: Another press of Button
2 (shortpress) switches to integrate adjust mode with the
number of integrations indicated by the number of red LEDs,
from 1 to 32.
Button 1 (shortpress) decreases integration.
Button 3 (shortpress) increases integration.
Button 2 (shortpress) exits to normal operation.
Either mode is exited after a short period with no
Button 2 (Shortpress): Toggle stop/start
rotation. Stopping rotation is useful for wanting to listen to
signal without the switching tone - particularly useful when the
signal is very weak or if you are trying to hear something on
modulated onto the signal. When rotation is
stopped, the display is frozen and the cardinal points will
blink quickly - even if the blinking of cardinal points has
Button 2 (Longpress): Adjust quality threshold.
Quality level is display in green with a quality of zero
indicated by flashing red LED. The LED (green or yellow)
increasing quality displayed CCW from "North." If displayed in
green, ONLY current bearing is used for gating, if displayed in
yellow, BOTH the current and averaged bearing are gated. This
mode stops antenna rotation.
Button 3 (shortpress) changes to "Audio threshold adjust"
Audio level threshold adjust mode: Another press of
Button 3 (shortpress) switches to Audio threshold adjust with
a threshold of zero (disabled) indicated by a flashing red LED
with a yellow LED, with increasing level displayed "CCW" from
"North" in yellow.
Button 1 (shortpress) decrements threshold level
Button 2 (shortpress) increases audio threshold.
Button 3 (shortpress) exits.
Either mode is exited after a short period with no
Buttons 2 and 3 (Longpress): Turn
on/off the display of the "Current" (green) bearing. When
the "current" bearing is turned off, the "North" point will be
flanked by a yellow and red blinking LED. When the
"current" bearing is turns on, the "North" point will be a
blinking green LED, indicating that "current" (green-colored)
bearings are to be displayed. One might turn off the
display of the "current" bearing for two reasons:
De-clutter the display. If the signal has a lot of
multipath, the constantly-moving green LED may make the
display a bit more difficult to read. Turning it off
leaves only the "average" bearing on the display.
Increase brightness. When the "current" bearing is
turned off, the brightness of the green LED that would be
displayed is combined with the yellow LED. This causes
the color to shift a bit toward the green, but it also makes
the LED noticeably brighter. Note that this setting has
no effect on whether or not "current" bearings may be sent via
the serial port.
Button 4 (Shortpress): A buttonpress causes the
bearing to be sent once. The baud rate and whether or not
the "averaged" or "current" bearing is to be sent depends on the
settings in configuration. Note: Whenever a
bearing is sent, the display will blank momentarily.
Button 4 (Longpress): This causes bearings to
be sent automatically. The interval at which the bearings
are to be sent, as well as the baud rate and whether or not the
"averaged" or the "current" bearing is to be sent is set in
configuration. Note: This mode setting is
saved in nonvolatile memory! This means that
even if power-cycled, it will return to the "timed sending"
mode. Note: Whenever a bearing is sent, the
display will blank momentarily.
Buttons 3 and 4 (Shortpress or Longpress):
the "automatic timed-sending" of the bearings via the serial
port. Note that the disabling of this mode is saved in
nonvolatile memory, so it will not resume sending next time the
unit is power-cycled.
Buttons 1, 2 and 3 (Longpress):
Restart the software and enter config mode. Note:
Release the buttons as soon as the display changes!
Comments on normal operation:
If the audio level or quality factor is too low, bearings
displayed in RED (if "bad" bearings are enabled)
will appear and neither the "current" bearing (displayed in
green) or the "averaged" bearing (displayed in yellow)
will be updated.
Selecting 1 of 4 radio presets:
Configurations for up to 4 different radios may be stored,
allowing multiple radios and/or antenna switching systems to be
used without need to recalibrate. The radio configuration to
use is selected by pressing and holding buttons 1, 2, 3, or 4
while turning on the power, selecting radio #1, 2, 3 or 4
respectively, and storing this selection in nonvolatile memory.
When the unit powers up, the display will show, by the number of
LEDs, which radio configuration is being used. Note that
the LEDs depicting the radio selection is shown both at the top
and the bottom of the display - that is there will be 2 LEDs on
the top, and 2 on the bottom to indicate the selection of radio
#2. Of course, if the 4th button was not
installed, you will, not be able to select configuration #4.
The configuration data saved includes:
Direction calibration - that is, which way is "North."
With a fixed station, this would probably be True North but in a
vehicular installation, this usually refers to a "Straight
Antenna rotation direction - CW or CCW. Depending on
one's labeling and the order that antenna cables are connected,
one may need to select antenna rotation direction.
Antenna polarity - positive or negative drive. If you
have different antenna switching units, you may need to have
different settings to use them.
As mentioned above, there is a "single-color"
mode where green, yellow and red are represented identically
by the firmware: This mode is intended to be used when
only a single color (or, more accurately,
"single-polarity" LEDs) are used. Were this mode
not present, certain representations (such some of the menu
settings, blinking cardinal points, etc.) would not cause
single-color LEDs to illuminate.
It should be remembered that it is, in fact, color that is
used to represent different types of data when it is
displayed and that with the use of single-color LEDs, being
able to differentiate different types of information becomes
impossible - or, at the very least, rather confusing and
this is one of the reasons why each configuration/menu item
displays its data in a unique pattern or format, as far as
possible. A notable exception to this is in the display
of the adjustment of the amount of averaging and
integration as well as the threshold for the quality and
audio level: These can be confusing to adjust with
just one color present - but not impossible.
When in single-color mode, it will probably be necessary to
disable display of the "Bad" bearing (those that would
be displayed in red) as
well as the "integrated" bearing (those that would be displayed
in green) as they would otherwise just show up
identically, confusing the readings. When using single-color
LEDs, it would also be advantageous to turn on "audio level
blinking" so that the display blinks on/off according to the amount
of audio present (e.g. "fast" blinking if the audio level is too
high, "slow" blinking if the audio level is too low.)
Setting the proper audio level:
the firmware is capable of handling a wide range of audio
levels, it is best to set it properly. Because the
audio level also affects the calculated quality, being able
to best reject "bad" bearings (as well as to avoid
unnecessary filtering of rather poor quality, but
potentially useful ones) it is best if the "normal" audio
level be set as follows:
Tune in a "clean" signal, free of multipath and
full-quieting. This is the sort of signal that you would
also use to calibrate the direction. If possible, this
signal should also be unmodulated, but it is possible, with
practice, to adjust the audio level using, say, a repeater,
mentally taking into account the natural pauses in speech.
In "Simple" mode:
Increase the audio level just to the point where the
display starts to blink quickly, indicating an overload
level - and then back it off slightly. It is OK for
there to be an occasional "overload" blink. Normally,
one would set the squelch to close reliably when no signals
In "Complex" mode:
Display the quality by pressing and releasing button
#1. To make the quality display continuously, press
and hold button #1 again - while the quality is being
displayed. (That is, press, release,
and then press button #1 again to make it display the
quality until after you released button #1.)
Note that a quality reading is displayed on the upper and
lower portion of the display, with the upper
display indicating the quality of the "integrated" bearing
and the lower reading indicating the quality
of the averaged bearing. Always
adjust using the upper reading - the quality of
the "integrated" bearing.
Increase the audio level until the 8th
quality indicator (LED #8) just
illuminates. It is normal for the quality reading to
decrease slightly during modulation (such as speech.)
It is also normal for the the 9th LED (the "overload"
indicator - displayed in red) to flash on occasionally.
If button #2 is pressed and released, the "audio level"
will also be displayed. Note that this is calculated
differently from the quality and will vary more with noise
and modulation. A quality level of "8" usually
corresponds with an audio level of somewhere between 4 and
Normally, one would set the squelch such that it closed
reliably when there was no signal present: This allows
the "average clear" function to work properly, allowing the
unit to respond instantly to new signals when they appear.
Important note: If the "damping"
control is adjusted, it may be necessary to re-check the audio
level versus quality level. As the damping is increased
(slowing down the response to bearings but increasing the
noise immunity) the audio level into the processor is reduced
somewhat, lowering the calculated quality reading by 1 or 2
It is better to run an audio level that is slightly low
rather than one that is too "hot!"
Overdriving the audio significantly will cause the bearings
shift by 10-20 degrees, depending on the amount of
overload. If one is just using the the display as a
rough indicator of direction, 10-20 degrees may not be too
significant, but if you are feeding bearings to a computer or
external display, it is best to minimize potential errors!
Because the processor used has only 28 pins - and pretty much all of
them are used for driving the LEDs and antenna - we have to "re-use"
some of the pins in order to add buttons. Fortunately, this is
pretty easy since we have complete control of our hardware and this
allows us to use a pin that's also used for driving the LEDs to also
"read" the status of the buttons. This is done by occasionally
blanking the LEDs, but it's done so quickly that the user doesn't
Depending on your preference, you can use either 3 or 4 buttons, the
4th button only being used to store or select the 4th radio's stored
preset, or to trigger the sending of data on the serial port - but
if you don't wish to add the serial port or require a 4th preset
position for radios, there's no real need to add that 4th button!
When pressed, the button grounds the appropriate pin of the
processor via a 470 ohm resistor. Using this resistor permits
one to press the button, but not affect the display or draw too much
current from the pin, but when the processor switches to the "read
button" mode, this resistance will firmly pull that pin to ground
while pull-up resistors built into the processor pull the pin's
voltage up if the button isn't being pressed.
These buttons are mapped to processor pins as follows:
Button 1 - Connects to RB0, processor pin 21 through a
470 ohm resistor. This is the same as pin "D1" on the
Button 2 - Connects to RB1, processor pin 22 through a
470 ohm resistor. This is the same as pin "D2" on the
Button 3 - Connects to RB2, processor pin 23 through a
470 ohm resistor. This is the same as pin "D3" on the
Button 4 - This optional button connects to RB3,
processor pin 24 through a 470 ohm resistor. This is
the same as pin "D4" on the processor/LED
As implied, "Normally-Open" pushbutton switches were used with one
end of the switch grounded. It is recommended that the 470 ohm
resistor in series with the switch be placed nearer the
processor pin than the switch to minimize lead length of a "raw"
processor signal. For the connection, it's probably easiest to
solder these resistors on the bottom side of the board where the
wire to the LED board is connected, slipping a small piece of
insulating tubing over the resistor and the solder joint connecting
the wire that runs to the switch. Alternatively - depending on
where your switches are located - one may locate the resistors on
the compass rose display board.
In the interest of minimizing possible RFI (e.g. interference
emanating from the DF unit) it's best to keep the lead lengths as
short as practical. The 470 ohm resistors placed near the
processor rather than the switch will help to attenuate RFI that
might be radiated from the wire since this slows the transitions
of the digital signals.
If you need more information as to how these buttons are
connected, please feel free to ask using the email link at the
bottom of this page.
Adding a serial port:
As noted below, for multiplexing processor pin 2
(RA0) is used to allow sending of the serial data.
If the unit is to ever be used in "simple" mode (e.g. maximum
compatibility with the original firmware, serial port sending
is not possible and the modification below should NOT
be made and the reason for this is that in "simple"
mode, this pin is used as an input from the calibration
If you have added the 4th button, it is possible to add a bit more
circuitry to connect a transmit-only serial port -
that is, we send bearing data in the "Agrelo" format, but we cannot
receive anything. As with the buttons, the serial data lines
are shared with other functions so it is necessary to multiplex
their use and when serial data is sent, the compass rose LED display
will momentarily blink: The higher the baud rate, the shorter
the duration of the "off" period of the blink.
On the original firmware - and with this
firmware when used in "Simple" mode - processor pin RA0 (pin 2) is
connected to two potentiometers selected by a switch, each one used
to set the calibration of the unit with one potentiometer for each
radio. Since this firmware (when not in "simple" mode)
does the calibration differently, that pin may be used as an
"enable" line for the serial data that is transmitted from RC6, pin
17: When pin 2 is at a high logic level, there is valid serial
data at pin 17 but when pin 2 is low, it is required that the serial
line revert to the "idle" state.
This multiplexing may be accomplished using a single logic chip
(such as a 4011 quad NAND gate) or it may also be done with simple
transistor logic: I have yet to add details of how I did this
(using simple transistor logic) to this web page, but if you
need more information, feel free to ask using the email link at the
bottom of this web page.
As noted above, the "Agrelo" format is used to send the bearing data
- and the signal quality - and in this format:
%bbb/q <cr> <lf>
% - The percent sign is used as a prefix for the bearing
bbb - Three digits are ALWAYS used for sending the bearing
/ - A slash separates the bearing from the quality data
q - The quality of the data from 0 through 8 where 0 is very bad
and 8 is the best possible quality,
<cr> <lf> - A carriage-return and line-feed are used
to terminate the string
Again, do not do the above
modification if you plan to use the processor in "simple" mode as
pin 2 must be used as an input to read the calibration
Tips for operation:
Typical operation is one where the signals are of fair to good
quality. Under these conditions, one would typically set the
"damping" control to minimum to provide the fastest possible
response time, the number of averages would be set to 32, the number
of integrations would be set to 1, and the "Average Clear" setting
would be at 1/2 second. In this mode, the unit will respond to
any transmission of about 1/10th second or longer, with better
accuracy occurring with longer transmissions and stronger signals.
"Weak signal" conditions:
Occasionally, one will have to locate a signal that is extremely
weak and/or "multipathy." One can usually discern a trend in
terms of bearings that one gets with above settings - but in these
situations, it may be necessary to improve the filtering.
Note, however, that adding additional filtering has the necessary
result of slowing down the response to signals.
The first technique to locating such poor quality signals is to
increase the amount of damping (that is, setting the "fast/slow"
switch to "slow" on the original version.) This will provide
additional filtering of the received signal while slowing the
response. An additional technique is to increase the amount of
integration - although a setting of higher than 8 or so is usually
not going to provide much additional improvement.
When signals are extremely poor, to not expect a high-quality,
consistent bearing but, rather, look for a general trend such as
left, right, front or back. If you are able to determine the
bearing within 90 degrees, you will always be able to move closer to
the source and hopefully improve the signal quality as you do
so. Remember: As with any direction-finding
system, multipath will always cause inconsistent bearings. For
this reason, one should always pay attention to the long term
trend rather than short-term peaks.
The very best way to learn what is a real signal and what is a
reflection is to gain as much experience as possible through
practice! Some suggestions on gaining proficiency
Participate in local DF activities. If there are
none in your area, start your own!
Generate your own "Fox" signal. Although hiding a
transmitter yourself is somewhat like hiding your own easter
eggs, knowing exactly where your transmitter is
and observing what multipath does to the bearing can help you
get a "feel" as to how to recognize potential multipath
conditions when you see them. If you do generate your
own signal, make sure that you don't QRM other users of the
spectrum and that you ID legally!
"DF" someone else. Chances are that there are a
few people in your area that are on the air a lot: If you
don't already know where they live, you can find out by DFing
State of progress for the new
At the time of this writing, the code is fully
operational. If you are interested in this code, please
let me know at the email address below. For information
about the availability of this firmware, please go here.
The code for the alternate firmware was originally based on
that of the original Montreal Doppler II DF unit by the late
Jacques Brodeur, VE2EMM, and full credit is given to him for
this fine work. Because the additional modifications are
my own and were not done with his involvement!
Although good faith efforts have been made to make certain
that the operation of the hardware/firmware is as described, it
is possible that "undocumented features" (bugs) may be
present: It is through testing, use, and feedback from the
users that projects such as this may be improved, and the user
is asked to be understanding of this fact. This firmware
is strictly intended only for non-commercial amateur-radio use
and any other use is in violation of applicable laws.
This code is available in the form of pre-programmed
Do you have any questions on this or other DF-related
topics? Go here.