From: djk Date: Fri, 22 Oct 1999 14:51:46 +0000 (+0000) Subject: fixed console scrolling? finally? X-Git-Tag: R_1_32~4 X-Git-Url: http://dxcluster.net/gitweb/gitweb.cgi?a=commitdiff_plain;h=bfa8589d67aebae38f9ed41b4539577ad45b8f94;p=spider.git fixed console scrolling? finally? swopped b1 and b2 in DXBearing calcs to see it this is any better --- diff --git a/cmd/Commands_en.hlp b/cmd/Commands_en.hlp index f11b6b2a..015bc790 100644 --- a/cmd/Commands_en.hlp +++ b/cmd/Commands_en.hlp @@ -469,10 +469,24 @@ string to see a selection of files in a filearea eg:- See also TYPE - to see the contents of a file. === 0^SHOW/MUF []^Show the likely propagation to a prefix -This command allow you to estimate the likelyhood of you contacting +This command allow you to estimate the likelihood of you contacting a station with the prefix you have specified. The output assumes a modest power of 20dBW and receiver sensitivity of -123dBm (about 0.15muV/10dB SINAD) +The result predicts the most likely operating frequencies and signal +levels for high frequency (shortwave) radio propagation paths on +specified days of the year and hours of the day. It is most useful for +paths between 250 km and 6000 km, but can be used with reduced accuracy +for paths shorter or longer than this. + +The command uses a routine MINIMUF 3.5 developed by the U.S. Navy and +used to predict the MUF given the predicted flux, day of the year, +hour of the day and geographic coordinates of the transmitter and +receiver. This routine is reasonably accurate for the purposes here, +with a claimed RMS error of 3.8 MHz, but much smaller and less complex +than the programs used by major shortwave broadcasting organizations, +such as the Voice of America. + The command will display some header information detailing its assumptions, together with the locations, latitude and longitudes and bearings. It will then show UTC (UT), local time at the other end diff --git a/cmd/show/muf.pl b/cmd/show/muf.pl index 5c9f92b6..c216b6dd 100644 --- a/cmd/show/muf.pl +++ b/cmd/show/muf.pl @@ -31,8 +31,8 @@ if (!$lon1 && !$lat1) { } $lat2 = $a->{lat}; $lon2 = $a->{long}; -($b2, $d) = DXBearing::bdist($lat1, $lon1, $lat2, $lon2); -($b1, undef) = DXBearing::bdist($lat2, $lon2, $lat1, $lon1); +($b1, $d) = DXBearing::bdist($lat1, $lon1, $lat2, $lon2); +($b2, undef) = DXBearing::bdist($lat2, $lon2, $lat1, $lon1); # convert stuff into radians $lat1 *= $d2r; diff --git a/perl/console.pl b/perl/console.pl index 75632aa8..97c0864c 100755 --- a/perl/console.pl +++ b/perl/console.pl @@ -139,7 +139,7 @@ sub show_screen if ($spos == @shistory - 1) { # if we really are scrolling thru at the end of the history - my $line = $shistory[-1]; + my $line = $shistory[$spos]; $top->addstr("\n") if $spos > 0; setattr($line); $top->addstr($line); @@ -151,7 +151,7 @@ sub show_screen # anywhere else my ($i, $l); my $p = $spos-1; - for ($i = 0; $i <= $pagel && $p >= 0; ) { + for ($i = 0; $i < $pagel && $p >= 0; ) { $l = measure($shistory[$p]); $i += $l; $p-- if $i < $pagel; @@ -161,19 +161,24 @@ sub show_screen $top->move(0, 0); $top->attrset(COLOR_PAIR(0)) if $has_colors; $top->clrtobot(); - for ($i = 0; $i <= $pagel && $p < @shistory; $p++) { + for ($i = 0; $i < $pagel && $p < @shistory; $p++) { my $line = $shistory[$p]; my $lines = measure($line); last if $i + $lines > $pagel; - $top->move($i, 0); setattr($line); - $top->addstr($line); + $top->addstr($i, 0, $line); $top->attrset(COLOR_PAIR(0)) if $has_colors; $i += $lines; } $spos = $p; + $spos = @shistory if $spos > @shistory; } - $top->refresh(); + my $shl = @shistory; + my $add = "$call-$spos-$shl"; + $scr->addstr(LINES()-4, 0, '-' x (COLS() - length $add)); + $scr->addstr($add); + $scr->refresh(); +# $top->refresh(); } # add a line to the end of the top screen @@ -246,6 +251,10 @@ sub rec_stdin } # add it to the monitor window + unless ($spos == @shistory) { + $spos = @shistory; + show_screen(); + }; addtotop($inbuf) if $inbuf; # send it to the cluster @@ -290,7 +299,7 @@ sub rec_stdin $i += $l; $spos++ if $i <= $pagel; } - $spos = @shistory if $spos > @shistory; + $spos = @shistory if $spos >= @shistory - 1; show_screen(); } else { beep(); @@ -336,7 +345,7 @@ sub rec_stdin } } elsif ($r ge ' ' && $r le '~') { # move the top screen back to the bottom if you type something - if ($spos < @shistory - 1) { + if ($spos < @shistory) { $spos = @shistory; show_screen(); }