From 17beaf71de8fd136c90d4be997ae66d5d410dd67 Mon Sep 17 00:00:00 2001 From: Joe Taylor Date: Wed, 29 Aug 2018 09:21:08 -0400 Subject: [PATCH] Cleaning up the handling of goofy calls. --- Configuration.ui | 2 +- decodedtext.cpp | 5 +++-- decodedtext.h | 1 + lib/77bit/messages.txt | 23 ++++++++++++++++------- lib/77bit/packjt77.f90 | 4 ++-- 5 files changed, 23 insertions(+), 12 deletions(-) diff --git a/Configuration.ui b/Configuration.ui index b508e5cc2..efebaf801 100644 --- a/Configuration.ui +++ b/Configuration.ui @@ -2833,7 +2833,7 @@ Right click for insert and delete options. - Special operating activity: FT8 and MSK144 + Special operating activity (FT8 and MSK144 only) diff --git a/decodedtext.cpp b/decodedtext.cpp index f76ec73a8..8e419f145 100644 --- a/decodedtext.cpp +++ b/decodedtext.cpp @@ -22,7 +22,8 @@ DecodedText::DecodedText (QString const& the_string) { if (message_.length() >= 1) { - message_ = message_.left (36).remove (QRegularExpression {"[<>]"}); + message0_ = message_.left(36); + message_ = message_.left(36).remove (QRegularExpression {"[<>]"}); int i1 = message_.indexOf ('\r'); if (i1 > 0) { @@ -41,7 +42,7 @@ DecodedText::DecodedText (QString const& the_string) } // stdmsg is a Fortran routine that packs the text, unpacks it // and compares the result - auto message_c_string = message_.toLocal8Bit (); + auto message_c_string = message0_.toLocal8Bit (); message_c_string += QByteArray {37 - message_c_string.size (), ' '}; is_standard_ = stdmsg_(message_c_string.constData(),37); } diff --git a/decodedtext.h b/decodedtext.h index 5120909d1..88062231e 100644 --- a/decodedtext.h +++ b/decodedtext.h @@ -79,6 +79,7 @@ private: int padding_; bool contest_mode_; QString message_; + QString message0_; bool is_standard_; }; diff --git a/lib/77bit/messages.txt b/lib/77bit/messages.txt index 5399dcc92..4370fe411 100644 --- a/lib/77bit/messages.txt +++ b/lib/77bit/messages.txt @@ -55,15 +55,24 @@ PA9XYZ 590003 IO91NP G4ABC/P R 570007 JO22DB PA9XYZ G4ABC/P RR73 -8. Compound or goofy calls +8. Compound or nonstandard callsign calls CQ ----------------------------------------------------------- CQ PJ4/K1ABC - W9XYZ -W9XYZ K1ABC -11 - K1ABC W9XYZ R-09 -W9XYZ RRR - W9XYZ 73 -9. Other stuff + PJ4/K1ABC +W9XYZ -11 + W9XYZ R-09 + PJ4/K1ABC RRR + PJ4/K1ABC 73 + +9. Compound or nonstandard callsign answers a CQ +----------------------------------------------------------- +CQ W9XYZ EN37 + YW18FIFA + W9XYZ -11 + W9XYZ R-09 +YW18FIFA RRR + YW18FIFA 73 +10. Other stuff ----------------------------------------------------------- TNX BOB 73 GL CQ YW18FIFA diff --git a/lib/77bit/packjt77.f90 b/lib/77bit/packjt77.f90 index 0f2305601..6220afdf6 100644 --- a/lib/77bit/packjt77.f90 +++ b/lib/77bit/packjt77.f90 @@ -116,7 +116,6 @@ subroutine save_hash_call(c13,n10,n12,n22) 900 return end subroutine save_hash_call - subroutine pack77(msg0,i3,n3,c77) use packjt @@ -834,7 +833,6 @@ subroutine pack77_03(nwords,w,i3,n3,c77) return end subroutine pack77_03 - subroutine pack77_1(nwords,w,i3,n3,c77) ! Check Type 1 (Standard 77-bit message) and Type 2 (ditto, with a "/P" call) @@ -860,6 +858,8 @@ subroutine pack77_1(nwords,w,i3,n3,c77) if(w(1)(1:1).eq.'<' .and. index(w(1),'>').ge.5) ok1=.true. if(w(2)(1:1).eq.'<' .and. index(w(2),'>').ge.5) ok2=.true. if(.not.ok1 .or. .not.ok2) return + if(w(1)(1:1).eq.'<' .and. index(w(2),'/').gt.0) return + if(w(2)(1:1).eq.'<' .and. index(w(1),'/').gt.0) return if(nwords.eq.2 .and. (.not.ok2 .or. index(w(2),'/').ge.2)) return if(nwords.eq.2) go to 10