Kozai::Rotator::Tracker
Follows a satellite with a rotator, in real time.
Two things stop this from being a loop that forwards every computed position straight to the motors:
- Rate limiting. A rotator takes seconds to move a few degrees and answers each command over a serial link. Commanding it ten times a second achieves nothing but a backlog, and on some controllers a command received mid-move restarts the move.
- A deadband. Antenna beamwidths are measured in degrees. Chasing tenths of a degree wears the motors out for pointing accuracy that no antenna can use.
Constants
How much azimuth travel switching to the flipped pointing must save before it is worth the switch.
Constructors
Instance methods
Decides where to point for angles, without talking to the rotator.
Returns nil if the satellite is below the rotator's elevation range,
which is the signal to leave the antenna where it is.
Separated from #follow so that the decision — the part with all the
awkward cases in it — can be tested without a socket.
Points the rotator at angles, subject to the rate limit and deadband.
Returns the target commanded, or nil if nothing was sent.
A connection failure is logged and swallowed rather than raised: losing the rotator should not stop the daemon predicting passes or serving the API, and the next call will try to reconnect.