K1TTT Home | What's New | Weather | Webcams | Tech Reference | WebCluster | BIG!



THIS PROGRAM ONLY WORKS ON CT VERSION 7 LOGS, 9TO8 AND 8TO7 ARE INCLUDED
TO CONVERT THE LOGS.
										  BUST MANUAL


COMMAND LINE: BUST FILENAME
 
This program takes a contest log and tries to find bad calls.
 
There is a set of rules in the file CALLSIGN.PAT.  The following describes 
how to make up new rules and understand how to change what I have come up 
with.  The original rules I started with were from an article by K3ZO in 'The 
DX Magazine' for Feb, 1990.  I have added lots of common sense rules to his 
list.  I am working on rules for Russian calls with NT2X and K1KI.  Please
send me any new ones you come up with.

                            ****WARNING**** 
Do not assume that just because this program flags a call as 'bad' that it 
has to be removed from the log.  Some of these rules are already outdated due 
to countries changing callsign sequences or issuing special contest calls.

What does the program do??  The Bust program takes a file full of bad
callsign rules that have been encoded in a special pattern matching notation
and stores them away in memory for quick access.  Then it reads in a contest
log file and compares every call to each pattern to try to find a 'match' to
a pattern in memory.  If a match is found then the callsign is flagged as
bad and is printed out along with an explanation of the rule for the operator
to decide about leaving it in the log or taking it out.

A rule 'pattern' descibes a bad callsign character by character.  You can
look at it as if the program is stepping through the pattern and the
call one letter at a time.   As long as the call matches the pattern the
procedure continues.  If the pattern runs out before the end of the callsign
then the rest is assumed to match.  If the callsign runs out of characters
first then it doesn't match and the call is passes as good.

 
RULE FORMATTING:
 
THINGS THAT GO INTO RULE DEFINITION:
The components that make up a 'rule' are:

Single characters:
	 A = match the letter 'A'
	 1 = match the number '1'
	 etc....

Repetition flags:
	 : = match one
	 + = match one or more
	 * = match zero or more
	 - = optional match
These must be followed by a character type specifier:
    N = match any character (A-Z, 0-9)
    A = match any letter(A-Z)
    D = match any digit (0-9)
To make up phrases like:
	 :D = match one of any digit
	 +A = match one or more letters
	 *N = match zero or more letters or digits
	 -D = optionally match one digit

Groups of characters to match:
	 [] = match
	 !  = match any characters not in list
	 -  = match a range of characters
Which can make up phrases like:
	 [ABCFXZ] = match a,b,c,f,x, or z
	 [!ABC] = match anything other than a,b, or c
	 [!A-R] = match anything other than letters a to r


  The following are some simple examples of patterns and what they match or
don't match.

PATTERN       MATCHES                   DOESN'T MATCH
:A:D          A1, Z0, Q8                AA, 19, 1A
+A:D          A1, AA1, ABC1             AA, 19, 1A
*A:D          1, 19, A1, AA1, ABC1      AA, 1A          
F:D           F1, F2, F9                A1, Z0, 1A
[ABC]B:D      AB1, CB1, BB9             AC1, DB9, CZ0
[!ABC]B:D     ZB1, DB9, QB0             AC1, AB1, CB1, BB9, CZ0

 
WHAT ARE WE TRYING TO 'MATCH':
First, what do we do with a match??  Well, if a callsign matches one of the 
patterns it gets flagged as a 'bad' call.  Therefore we make up rules that 
specify what a 'bad' call is, like:

    1. Calls that start with 3 letters
    2. Call with first letter B with prefix other than BT,BV,BY,BZ
	 3. French calls with a 1 or 6 that don't have 3 letter suffix
	 4. East German calls that don't end in A to O

Then we try to make a pattern that will match only calls fitting that rule.

Unfortunately some countries have made the job a bit harder by restricting
certain types of calls to certain bands and modes.  I.E. the HJ prefix is only
used on CW or 40m and 80m SSB.  So we need some way to specify rules for those
calls.  So what I do is append the band and mode information to the end of
the callsign before it goes through the pattern matcher.  What it looks like
then is this: "BY1AA=4S"  where the '=' is added at the end of the call,
followed by the band number (1=160m, 2=80m, ... 6=10m) and the mode (S=SSB,
C=CW).  Now we can make rules that apply to specific bands and not have
another mechanism to remember.  This also helps us by marking the end of the
call with the '=' sign, so now we can sort out calls that have to have
specific lengths. 
 
This means the following combinations can be made to specify bands and modes:
	 =3C      = match a '3' (40meters) followed by "C" for CW, call would be
					bad on 40m CW.
	 =4       = match just a '4' for 20m either mode, call would be bad on
					20m any mode.
	 =:DS     = match any band, but only for SSB, call would be bad on SSB
					on any band.

Which for our rule that is valid only on CW or 40/80 SSB means that it is 
bad on any other band or on ssb so we could do:
    =[1456]S  = which means the call is bad on 160, 20, 15, or 10m SSB
 
Also, before a call is sent through the pattern matcher any portable part of 
the call is removed.  This way a /QRP, /A, /MM, /CT3  etc. does not affect the 
checking of the basic callsign.  Using the "Check Prefixes" option of the 
program will check the portable parts of calls to be sure they are valid 
in the *.CTY file for that contest.  This is the same type of check that MM 
and CT do when reloading a log to create the *.BAD file.
 
 
Now, back to some of the cases I mentioned earlier and how to make up rules 
for them.
 
    1. Calls that start with 3 letters
       This is fairly easy, all we need is a rule that will 'match' if the 
       first 3 characters are letters.  Since the :A phrase says to match any 
       one letter we can use that to get the rule:
       :A:A:A
       Notice, that since we are only worried about the first 3 characters of
       the call we don't have to go past that in the rule.  This makes use of 
       the property that says if the rule runs out before the callsign does
       the rest is assumed to match.
    2. Call with first letter B with prefix other than BT,BV,BY,BZ
       This is a bit harder, but at least we only have to deal with the first 
       2 characters of the call.  First, we only want this to apply to calls 
       that start with a 'B'.  Then if the second character is not one of the 
       group 'TVYZ' we want it to 'match'.  So we get the rule: 
       B[!TVYZ]
       This is the same as above, if we match the 'B', and then the next 
       character is not one of the set "TVYZ" we don't care what the rest of 
       the call might be.
 
    3. French calls with a 1 or 6 that don't have 3 character suffix
       Now this is a real test of the capability of the rules and how well 
       you understand them.  First we need calls that start with 'F', 
       followed by a '1' or '6'.  Then we need to match one or two character 
       suffixes to reject suffixes that are too short.  For this we will use 
       one of the 'optional' matches for the second letter of the suffix to 
       get:
       F[16]:A-A=
       Note how we have the ":A-A" which will match one letter, then 
       optionally another letter.  We can not use "+A" in this case because 
       that would also match 3 letters.  Then the '=' will anchor the end of 
       the rule so that if there was a third letter in suffix it would not 
       match the '=' and the call would pass as good.
       Unfortunately the French also use other preffixes like FB, FD, FE, FF 
       that follow the same rule.  But this can not be combined be cause of 
       other calls that also start with F and don't necessarily have 3 letter 
       suffixes.  Calls like FR, FS, FJ, FC, FT may not fit the 3 letter 
       rule. This means we need a second rule to finish this problem to 
       specify the other French prefixes we want to check for 3 letter 
       suffixes.  To cover this we get the rule:
       F[BDEF][16]:A-A=
       Which will match French 2 letter prefixes followed by a '1' or '6' 
       with only 1 or 2 letter suffixes.
    4. East German calls that don't end in A to O
       Now here is the killer.  Fortunately I think these calls are all being 
       replaced, but it is still a good example and will probably be very 
       similar to some of the Russian rules for suffixes.
       First we want to match calls that start with 'Y', followed by a digit 
       from 2 to 9, followed by another digit from 0 to 9, then there could 
       be one, two, or in rare cases three letter suffix that must end with a 
       letter in the range of 'A' to 'O'.  With all this in mind we get the 
       rules:
       Y[2-9]:D[!A-O]=           for single letter suffix
       Y[2-9]:D:A[!A-O]=         for 2 letter suffix
       Y[2-9]:D:A:A[!A-O]=       for rare 3 letter suffix
       Again we ended up with multiple rules, in this case because if we had 
       used a '+A' or '*A' it would have also matched the last letter that we 
       wanted to check specifically.
 
Now if you look in the file CALLSIGN.PAT you will see all the rules that I 
have come up with.  Each rule also has a line giving the explanation for it.
This way when the program is run against a log it gives a plain English
explanation for why each call is busted.  You will note that some of them are
not hard rules, only that the call is rarely used.
 
Now you should all be experts at making rules for bad callsigns.  If you come 
up with a good rule that you can't put into the file I will try to help you.  
I would also like to collect any rules that you find that I don't have in the 
file or ones that are obsolete so we can try to keep this tool up to date.
 
When you come up with a new pattern you can test it by using the program 
option for 'test callsign.pat'.  This lets you put in callsigns by hand to 
see if they get busted or not.  If they are busted the explanation and rule
number are printed out.  If the call is ok nothing is displayed.
 
It is possible to come up with rules that you can't get to in the file.  For
instance a call like "HI500ABC" would always be rejected by the "CALL TOO LONG"
rule near the top of the file, so if you tried to come up with a specific rule
saying that HI500 calls only have 2 letter suffixes you would not get to it
unless you put it before the rule for maximum callsign length.

Some of the 'Generic' rules will reject calls that may be good.  The special
calls using extra long numbers, like the "HI500ABC" above may very well be a 
legal call.  But since these should be relatively few, especially during a 
contest, I feel it is better to have them flagged as bad and let the operator
determine if they are correct than to try to come up with rules that may only
be used once.
 
At present the rule file is limited to 200 rules.  I have about 100 rules
written so far.  If we really find a lot more I will extend the capabilities
later.



David Robbins, K1TTT K1TTT@arrl.net