Say where the station being worked is
N1MM writes a line under its entry window with the beam heading, the heading the long way round, the distance and the sun times at the other end. This writes the same line. SunTimes is the published sunrise equation, with the usual -0.833 degrees for the sun's radius and refraction at the horizon, and it returns nothing on the days inside the polar circles when the sun does not rise or set. It agrees with published times for London at both solstices, Sydney in June and the equator at the equinox, to within three minutes. StationPath picks the position: the grid square when the contest exchanges one and it has been copied, then the call history file, then the country file, which puts the station in the middle of its country. That is close enough to point a beam with. Our own end comes from the station grid square, or from the country file for our own call. One thing to know when reading the times: they are that station's own sunrise and sunset in UTC, so for Japan the sun rises late the evening before. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -409,6 +409,8 @@ public sealed partial class EntryWindow : Window
|
||||
RunBorder.Background = Logging.IsRunning ? Verdicts.Worth : new SolidColorBrush(Color.FromArgb(0x22, 0x80, 0x80, 0x80));
|
||||
ContestText.Text = ContestLine();
|
||||
|
||||
PathText.Text = PathLine();
|
||||
|
||||
Verdict? verdict = Logging.Verdict();
|
||||
VerdictBorder.Background = Verdicts.Colour(verdict);
|
||||
VerdictText.Text = VerdictLine(verdict);
|
||||
@@ -434,6 +436,21 @@ public sealed partial class EntryWindow : Window
|
||||
$"{Logging.Log.Tally.Points} pts · {mults} · {Logging.Log.TotalScore:N0}{radio}";
|
||||
}
|
||||
|
||||
/// Where the station being worked is: the beam heading, the heading the
|
||||
/// long way round, the distance, and the sun there. N1MM writes the same
|
||||
/// line under its entry window.
|
||||
private string PathLine()
|
||||
{
|
||||
if (Logging is null || StationPath.For(Logging, DateTime.UtcNow) is not { } path)
|
||||
{
|
||||
return "";
|
||||
}
|
||||
string sun = path.Sunrise is { } rise && path.Sunset is { } set
|
||||
? $" · SR {rise:HH:mm}Z SS {set:HH:mm}Z"
|
||||
: " · no sunrise or sunset today";
|
||||
return $"Hdg {path.Heading:0}° · LP {path.LongPath:0}° · {path.DistanceKm:N0} km{sun}";
|
||||
}
|
||||
|
||||
private string VerdictLine(Verdict? verdict)
|
||||
{
|
||||
if (Logging is null || Logging.Entry.Call.Trim().Length == 0)
|
||||
|
||||
Reference in New Issue
Block a user