Kozai::Radio::Tuner
Keeps a receiver on frequency across a pass.
Like Rotator::Tracker, this exists so that the corrections are rate
limited and quantised. A radio retuned every few hertz produces an audible
click on some models and a stream of serial traffic on all of them, for a
correction far below the width of the signal.
Constructors
Instance methods
Nominal downlink frequency in hertz.
NOTE: settable, through #retarget, and that is the point. A station
has one receiver and many satellites: work SO-50 on 436.795 and the next
pass is AO-73 on 145.935. The frequency is a property of what is being
tracked, not of the tuner โ what belongs to the tuner is the connection
and the rate limiting, which survive the change.
Whether frequency is far enough from the last command to be worth sending.
Retunes the radio for angles, subject to the step size and rate limit.
Returns the frequency commanded, or nil if nothing was sent. A
connection failure is logged rather than raised, for the same reason as
in Rotator::Tracker: the station keeps predicting even when the radio
is unplugged.
Points the receiver at a different transponder.
NOTE: clearing @last_frequency is not tidiness, it is the point.
#due? decides whether a retune is worth sending by comparing against
the last one, and it holds anything inside minimum_interval. Switching
from 436 MHz to 145 MHz would clear the step test on size alone, but
could still be held back a second by the rate limit โ a second of the
receiver sitting on the wrong band at the start of a pass, which is
exactly when there is least to spare. Forgetting the last command makes
the next #follow unconditional.
The mode is set here rather than on every retune: it does not change
across a pass, and rigctld writes it to the radio each time it is
asked.
Points the receiver at a different transponder.
NOTE: clearing @last_frequency is not tidiness, it is the point.
#due? decides whether a retune is worth sending by comparing against
the last one, and it holds anything inside minimum_interval. Switching
from 436 MHz to 145 MHz would clear the step test on size alone, but
could still be held back a second by the rate limit โ a second of the
receiver sitting on the wrong band at the start of a pass, which is
exactly when there is least to spare. Forgetting the last command makes
the next #follow unconditional.
The mode is set here rather than on every retune: it does not change
across a pass, and rigctld writes it to the radio each time it is
asked.
The frequency the radio should be on for angles.