-20Jun00=======================================================================
-1. fixed decode_input so it accepts callsigns with 0 in them (!)
+20Jul00=======================================================================
+1. Finally managed to update my source with the sourceforge one
+2. added user->qra cleaning in various places
+3. added four digit locator strings to broadcast DX spots (for users).
+25Jun00=======================================================================
+1. added 0 to the regex that checks for valid data on the cluster.pl->client
+channel - this will allow G0VGS and G0RDI to connect....
+2. removed technically unnecessary /= 60 from the dup routines to see if
+Arnold's Sparcs don't then crash.
19Jun00=======================================================================
1. move ann_dup, spot_dup etc to dup_ann, dup_spots etc
2. made mode 3 the default line ending convention for all out going connects
$self->{dx} = $user->wantdx;
$self->{logininfo} = $user->wantlogininfo;
$self->{here} = 1;
-
+
+ # clean up qra locators
+ my $qra = $user->qra;
+ $qra = undef if ($qra && !DXBearing::is_qra($qra));
+ unless ($qra) {
+ my $lat = $user->lat;
+ my $long = $user->long;
+ $user->qra(DXBearing::lltoqra($lat, $long)) if (defined $lat && defined $long);
+ }
# add yourself to the database
my $node = DXNode->get($main::mycall) or die "$main::mycall not allocated in DXNode database";
}
# are any of the crucial fields invalid?
- if ($field[2] =~ /[a-z]/ || $field[6] =~ /[a-z]/ || $field[7] =~ /[a-z]/) {
- dbg('chan', "Spot contains lower case callsigns, rejected");
+ if ($field[2] =~ /(?:^\s*$|[a-z])/ || $field[6] =~ /(?:^\s*$|[a-z])/ || $field[7] =~ /(?:^\s*$|[a-z])/) {
+ dbg('chan', "Spot contains lower case callsigns or blanks, rejected");
return;
}
# you should be able to route on any of these
#
+ # fix up qra locators of known users
+ my $user = DXUser->get_current($spot[4]);
+ if ($user) {
+ my $qra = $user->qra;
+ if (!DXBearing::is_qra) {
+ my $lat = $user->lat;
+ my $long = $user->long;
+ if (defined $lat && defined $long) {
+ $user->qra(DXBearing::lltoqra($lat, $long));
+ $user->put;
+ }
+ }
+ }
+
# local processing
my $r;
eval {
my ($lat, $long) = DXBearing::stoll($field[3]);
$user->lat($lat);
$user->long($long);
+ my $qra = $user->qra || DXBearing::lltoqra($lat, $long);
+ $qra = DXBearing::lltoqra($lat, $long) unless DXBearing::is_qra($qra);
} elsif ($field[2] == 4) {
$user->homenode($field[3]);
}
# dump if too old
return 2 if $d < $main::systime - $dupage;
- $d /= 60; # to the nearest minute
# chomp $text;
# $text = substr($text, 0, $duplth) if length $text > $duplth;
my $dupkey = "$d|$sfi|$k|$a";
{
my @dx = @_;
my $t = ztime($dx[2]);
- return sprintf "DX de %-7.7s%11.1f %-12.12s %-30s %s", "$dx[4]:", $dx[0], $dx[1], $dx[3], $t ;
+ my $ref = DXUser->get_current($dx[4]);
+ my $loc = $ref->qra if $ref && $ref->qra;
+ $loc = substr($ref->qra, 0, 4) if $loc;
+ $loc = "" unless $loc;
+ return sprintf "DX de %-7.7s%11.1f %-12.12s %-30s %s $loc", "$dx[4]:", $dx[0], $dx[1], $dx[3], $t ;
}
# format a spot for user output in list mode
return 2 if $d < $main::systime - $dupage;
$freq = sprintf "%.1f", $freq; # normalise frequency
- $d /= 60; # to the nearest minute
chomp $text;
$text = substr($text, 0, $duplth) if length $text > $duplth;
+ unpad($text);
my $dupkey = "$freq|$call|$d|$text";
return 1 if exists $dup{$dupkey};
$dup{$dupkey} = $d * 60; # in seconds (to the nearest minute)
# dump if too old
return 2 if $d < $main::systime - $dupage;
- $d /= 60; # to the nearest minute
# chomp $text;
# $text = substr($text, 0, $duplth) if length $text > $duplth;
my $dupkey = "$d|$sfi|$k|$a|$r";
/*
* $Log$
- * Revision 1.3 2000-03-30 22:51:14 djk
+ * Revision 1.4 2000-07-20 14:16:00 minima
+ * can use Sourceforge now!
+ * added user->qra cleaning
+ * added 4 digit qra to user broadcast dxspots if available
+ *
+ * Revision 1.3 2000/03/30 22:51:14 djk
* fixed connect code in client.pl so it doesn't falsely recognise /spider
* /src/client as a 'client' directive.
* Tidied up the C client a bit
/*
*
* $Log$
- * Revision 1.1 2000-03-26 00:03:30 djk
+ * Revision 1.2 2000-07-20 14:16:00 minima
+ * can use Sourceforge now!
+ * added user->qra cleaning
+ * added 4 digit qra to user broadcast dxspots if available
+ *
+ * Revision 1.1 2000/03/26 00:03:30 djk
* first cut of client
*
* Revision 1.12 1998/05/05 14:01:27 djk
* $Header$
*
* $Log$
- * Revision 1.1 2000-03-26 00:03:30 djk
+ * Revision 1.2 2000-07-20 14:16:00 minima
+ * can use Sourceforge now!
+ * added user->qra cleaning
+ * added 4 digit qra to user broadcast dxspots if available
+ *
+ * Revision 1.1 2000/03/26 00:03:30 djk
* first cut of client
*
* Revision 1.7 1998/01/02 19:39:57 djk
/*
* $Log$
- * Revision 1.3 2000-03-30 22:51:14 djk
+ * Revision 1.4 2000-07-20 14:16:00 minima
+ * can use Sourceforge now!
+ * added user->qra cleaning
+ * added 4 digit qra to user broadcast dxspots if available
+ *
+ * Revision 1.3 2000/03/30 22:51:14 djk
* fixed connect code in client.pl so it doesn't falsely recognise /spider
* /src/client as a 'client' directive.
* Tidied up the C client a bit
* $Header$
*
* $Log$
- * Revision 1.2 2000-03-26 14:22:59 djk
+ * Revision 1.3 2000-07-20 14:16:00 minima
+ * can use Sourceforge now!
+ * added user->qra cleaning
+ * added 4 digit qra to user broadcast dxspots if available
+ *
+ * Revision 1.2 2000/03/26 14:22:59 djk
* removed some irrelevant log info
*
* Revision 1.1 2000/03/26 00:03:30 djk