diff --git a/CMakeLists.txt b/CMakeLists.txt index c8c6166bb..bcfdec5c0 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -375,18 +375,12 @@ set (wsjt_FSRCS lib/bpdecode40.f90 lib/bpdecode144.f90 lib/bpdecode128_90.f90 - lib/fsk4hf/bpdecode120.f90 - lib/fsk4hf/bpdecode168.f90 lib/ft8/bpdecode174.f90 lib/ft8/bpdecode174_91.f90 - lib/fsk4hf/bpdecode300.f90 - lib/fsk4hf/bpdecode204.f90 lib/baddata.f90 lib/calibrate.f90 lib/ccf2.f90 lib/ccf65.f90 - lib/fsk4hf/chkcrc10.f90 - lib/fsk4hf/chkcrc12.f90 lib/ft8/chkcrc12a.f90 lib/ft8/chkcrc13a.f90 lib/ft8/chkcrc14a.f90 @@ -396,8 +390,6 @@ set (wsjt_FSRCS lib/chkss2.f90 lib/ft8/compress.f90 lib/coord.f90 - lib/fsk4hf/cpolyfit.f90 - lib/fsk4hf/cpolyfitw.f90 lib/db.f90 lib/decode4.f90 lib/decode65a.f90 @@ -415,19 +407,14 @@ set (wsjt_FSRCS lib/encode_msk40.f90 lib/encode_msk144.f90 lib/encode_128_90.f90 - lib/fsk4hf/encode120.f90 - lib/fsk4hf/encode168.f90 lib/ft8/encode174.f90 lib/ft8/encode174_91.f90 - lib/fsk4hf/encode300.f90 - lib/fsk4hf/encode204.f90 lib/entail.f90 lib/ephem.f90 lib/extract.f90 lib/extract4.f90 lib/extractmessage144.f90 lib/extractmessage77.f90 - lib/fsk4hf/extractmessage168.f90 lib/ft8/extractmessage174.f90 lib/ft8/extractmessage174_91.f90 lib/fano232.f90 @@ -457,7 +444,6 @@ set (wsjt_FSRCS lib/ft8/foxgen_wrap.f90 lib/fqso_first.f90 lib/freqcal.f90 - lib/fsk4hf/fsk4hf.f90 lib/ft8/ft8apset.f90 lib/ft8/ft8apset_174_91.f90 lib/ft8/ft8b_1.f90 @@ -470,20 +456,10 @@ set (wsjt_FSRCS lib/gen65.f90 lib/gen9.f90 lib/geniscat.f90 - lib/fsk4hf/genfsk4hf.f90 lib/ft8/genft8.f90 lib/ft8/genft8_174_91.f90 lib/genmsk_128_90.f90 lib/genmsk40.f90 - lib/fsk4hf/genmskhf.f90 - lib/fsk4hf/genwsprlf.f90 - lib/fsk4hf/genwspr_fsk8.f90 - lib/fsk4hf/genwsprcpm.f90 - lib/fsk4hf/genwspr5.f90 - lib/fsk4hf/getfc1.f90 - lib/fsk4hf/getfc2.f90 - lib/fsk4hf/getfc1w.f90 - lib/fsk4hf/getfc2w.f90 lib/genqra64.f90 lib/ft8/genft8refsig.f90 lib/genwspr.f90 @@ -508,15 +484,6 @@ set (wsjt_FSRCS lib/jplsubs.f lib/jt9fano.f90 lib/jtmsg.f90 - lib/ldpcsim144.f90 - lib/ldpcsim128_90.f90 - lib/fsk4hf/ldpcsim120.f90 - lib/fsk4hf/ldpcsim168.f90 - lib/ft8/ldpcsim174.f90 - lib/ft8/ldpcsim174_91.f90 - lib/fsk4hf/ldpcsim300.f90 - lib/fsk4hf/ldpcsim204.f90 - lib/ldpcsim40.f90 lib/libration.f90 lib/lorentzian.f90 lib/lpf1.f90 @@ -538,22 +505,16 @@ set (wsjt_FSRCS lib/mskrtd.f90 lib/msk144signalquality.f90 lib/msk144sim.f90 - lib/fsk4hf/mskhfsim.f90 lib/mskrtd.f90 - lib/fsk4hf/msksoftsym.f90 - lib/fsk4hf/msksoftsymw.f90 lib/77bit/my_hash.f90 lib/ft8/osd174.f90 lib/ft8/osd174_91.f90 - lib/fsk4hf/osd300.f90 - lib/fsk4hf/osd204.f90 lib/77bit/parse77.f90 lib/pctile.f90 lib/peakdt9.f90 lib/peakup.f90 lib/plotsave.f90 lib/polyfit.f90 - lib/fsk4hf/polyfit4.f90 lib/prog_args.f90 lib/ps4.f90 lib/qra64a.f90 @@ -572,9 +533,7 @@ set (wsjt_FSRCS lib/softsym9f.f90 lib/softsym9w.f90 lib/shell.f90 - lib/fsk4hf/spec4.f90 lib/spec64.f90 - lib/fsk4hf/spec8.f90 lib/spec9f.f90 lib/stdmsg.f90 lib/subtract65.f90 @@ -607,15 +566,6 @@ set (wsjt_FSRCS lib/xcor4.f90 lib/wqdecode.f90 lib/wqencode.f90 - lib/fsk4hf/wspr_fsk8d.f90 - lib/fsk4hf/wspr_fsk8_sim.f90 - lib/fsk4hf/wspr_fsk8_wav.f90 - lib/fsk4hf/wspr_fsk8_downsample.f90 - lib/fsk4hf/wspr_wav.f90 - lib/fsk4hf/wsprlfsim.f90 - lib/fsk4hf/wsprcpm_wav.f90 - lib/fsk4hf/wspr5_wav.f90 - lib/fsk4hf/wspr5_downsample.f90 lib/wspr_downsample.f90 lib/zplot9.f90 ) @@ -1274,10 +1224,6 @@ add_executable (wsprcode lib/wsprcode/wsprcode.f90 lib/wsprcode/nhash.c wsjtx.rc) target_link_libraries (wsprcode wsjt_fort wsjt_cxx) -add_executable (wsprsimf lib/fsk4hf/wsprsimf.f90 lib/wsprcode/nhash.c - wsjtx.rc) -target_link_libraries (wsprsimf wsjt_fort wsjt_cxx) - add_executable (wsprsim ${wsprsim_CSRCS}) add_executable (jt4code lib/jt4code.f90 wsjtx.rc) @@ -1289,36 +1235,6 @@ target_link_libraries (msk144code wsjt_fort wsjt_cxx) add_executable (jt65 lib/jt65.f90 lib/jt65_test.f90 wsjtx.rc) target_link_libraries (jt65 wsjt_fort wsjt_cxx) -add_executable (ldpcsim40 lib/ldpcsim40.f90 wsjtx.rc) -target_link_libraries (ldpcsim40 wsjt_fort wsjt_cxx) - -add_executable (ldpcsim120 lib/fsk4hf/ldpcsim120.f90 wsjtx.rc) -target_link_libraries (ldpcsim120 wsjt_fort wsjt_cxx) - -add_executable (ldpcsim174 lib/ft8/ldpcsim174.f90 wsjtx.rc) -target_link_libraries (ldpcsim174 wsjt_fort wsjt_cxx) - -add_executable (ldpcsim174_91 lib/ft8/ldpcsim174_91.f90 wsjtx.rc) -target_link_libraries (ldpcsim174_91 wsjt_fort wsjt_cxx) - -add_executable (ldpcsim144 lib/ldpcsim144.f90 wsjtx.rc) -target_link_libraries (ldpcsim144 wsjt_fort wsjt_cxx) - -add_executable (ldpcsim128_90 lib/ldpcsim128_90.f90 wsjtx.rc) -target_link_libraries (ldpcsim128_90 wsjt_fort wsjt_cxx) - -add_executable (ldpcsim168 lib/fsk4hf/ldpcsim168.f90 wsjtx.rc) -target_link_libraries (ldpcsim168 wsjt_fort wsjt_cxx) - -add_executable (ldpcsim300 lib/fsk4hf/ldpcsim300.f90 wsjtx.rc) -target_link_libraries (ldpcsim300 wsjt_fort wsjt_cxx) - -add_executable (ldpcsim204 lib/fsk4hf/ldpcsim204.f90 wsjtx.rc) -target_link_libraries (ldpcsim204 wsjt_fort wsjt_cxx) - -add_executable (fsk4hf lib/fsk4hf/fsk4hf.f90 wsjtx.rc) -target_link_libraries (fsk4hf wsjt_fort wsjt_cxx) - add_executable (ft8code lib/ft8/ft8code.f90 wsjtx.rc) target_link_libraries (ft8code wsjt_fort wsjt_cxx) @@ -1328,33 +1244,6 @@ target_link_libraries (ft8sim wsjt_fort wsjt_cxx) add_executable (ft8sim2 lib/ft8/ft8sim2.f90 wsjtx.rc) target_link_libraries (ft8sim2 wsjt_fort wsjt_cxx) -add_executable (wsprlfsim lib/fsk4hf/wsprlfsim.f90 wsjtx.rc) -target_link_libraries (wsprlfsim wsjt_fort wsjt_cxx) - -add_executable (wspr_fsk8d lib/fsk4hf/wspr_fsk8d.f90 wsjtx.rc) -target_link_libraries (wspr_fsk8d wsjt_fort wsjt_cxx) - -add_executable (wspr_fsk8_sim lib/fsk4hf/wspr_fsk8_sim.f90 wsjtx.rc) -target_link_libraries (wspr_fsk8_sim wsjt_fort wsjt_cxx) - -add_executable (wsprcpmsim lib/fsk4hf/wsprcpmsim.f90 wsjtx.rc) -target_link_libraries (wsprcpmsim wsjt_fort wsjt_cxx) - -add_executable (wsprcpmd lib/fsk4hf/wsprcpmd.f90 wsjtx.rc) -target_link_libraries (wsprcpmd wsjt_fort wsjt_cxx) - -add_executable (wspr5d lib/fsk4hf/wspr5d.f90 wsjtx.rc) -target_link_libraries (wspr5d wsjt_fort wsjt_cxx) - -add_executable (wspr5d_exp lib/fsk4hf/wspr5d_exp.f90 wsjtx.rc) -target_link_libraries (wspr5d_exp wsjt_fort wsjt_cxx) - -add_executable (wspr5sim lib/fsk4hf/wspr5sim.f90 wsjtx.rc) -target_link_libraries (wspr5sim wsjt_fort wsjt_cxx) - -add_executable (mskhfsim lib/fsk4hf/mskhfsim.f90 wsjtx.rc) -target_link_libraries (mskhfsim wsjt_fort wsjt_cxx) - add_executable (msk144sd lib/msk144sd.f90 wsjtx.rc) target_link_libraries (msk144sd wsjt_fort wsjt_cxx) @@ -1501,7 +1390,7 @@ install (TARGETS jt9 wsprd fmtave fcal fmeasure if(WSJT_BUILD_UTILS) install (TARGETS ft8code jt65code qra64code qra64sim jt9code jt4code - msk144code wspr_fsk8d + msk144code RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT runtime BUNDLE DESTINATION ${CMAKE_INSTALL_BINDIR} COMPONENT runtime ) diff --git a/lib/77bit/packjt77.f90 b/lib/77bit/packjt77.f90 index 5735a33a3..553f1a01b 100644 --- a/lib/77bit/packjt77.f90 +++ b/lib/77bit/packjt77.f90 @@ -194,7 +194,7 @@ subroutine pack77(msg0,i3,n3,c77) 900 return end subroutine pack77 -subroutine unpack77(c77,msg) +subroutine unpack77(c77,msg,unpk77_success) parameter (NSEC=84) !Number of ARRL Sections parameter (NUSCAN=65) !Number of US states and Canadian provinces @@ -211,6 +211,7 @@ subroutine unpack77(c77,msg) character*4 grid4,cserial character*3 csec(NSEC) character*38 c + logical unpk77_success data c/' 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ/'/ data csec/ & @@ -232,10 +233,13 @@ subroutine unpack77(c77,msg) "NB ","NS ","QC ","ON ","MB ","SK ","AB ","BC ","NWT","NF ", & "LB ","NU ","VT ","PEI","DC "/ + unpk77_success=.true. + ! Check for bad data do i=1,77 if(c77(i:i).ne.'0' .and. c77(i:i).ne.'1') then - msg='QUIRK 2' + msg='failed unpack' + unpk77_success=.false. return endif enddo @@ -297,9 +301,10 @@ subroutine unpack77(c77,msg) else if(i3.eq.0 .and. (n3.eq.3 .or. n3.eq.4)) then ! 0.3 WA9XYZ KA1ABC R 16A EMA 28 28 1 4 3 7 71 ARRL Field Day - ! 0.4 WA9XYZ KA1ABC R 32A EMA 28 28 1 4 3 7 71 ARRL Field Day +! 0.4 WA9XYZ KA1ABC R 32A EMA 28 28 1 4 3 7 71 ARRL Field Day read(c77,1030) n28a,n28b,ir,intx,nclass,isec 1030 format(2b28,b1,b4,b3,b7) + if(isec.gt.NSEC .or. isec.lt.1) unpk77_success=.false. if(isec.gt.NSEC) isec=NSEC !### Check range for other params? ### if(isec.lt.1) isec=1 !### Flag these so they aren't printed? ### call unpack28(n28a,call_1) diff --git a/lib/ft8/ldpcsim174.f90 b/lib/fsk4hf/ldpcsim174.f90 similarity index 100% rename from lib/ft8/ldpcsim174.f90 rename to lib/fsk4hf/ldpcsim174.f90 diff --git a/lib/ft8/ldpcsim174_91.f90 b/lib/fsk4hf/ldpcsim174_91.f90 similarity index 97% rename from lib/ft8/ldpcsim174_91.f90 rename to lib/fsk4hf/ldpcsim174_91.f90 index ec948dfac..752adc2d8 100644 --- a/lib/ft8/ldpcsim174_91.f90 +++ b/lib/fsk4hf/ldpcsim174_91.f90 @@ -14,6 +14,7 @@ integer*1 msgbits(77) integer*1 message77(77) integer*1 apmask(N), cw(N) integer nerrtot(0:N),nerrdec(0:N) +logical unpk77_success real*8, allocatable :: rxdata(:) real, allocatable :: llr(:) @@ -51,7 +52,7 @@ allocate ( rxdata(N), llr(N) ) i3=0 n3=1 call pack77(msg,i3,n3,c77) !Pack into 12 6-bit bytes - call unpack77(c77,msgsent) !Unpack to get msgsent + call unpack77(c77,msgsent,unpk77_success) !Unpack to get msgsent write(*,*) "message sent ",msgsent read(c77,'(77i1)') msgbits(1:77) diff --git a/lib/ft8/ft8b_2.f90 b/lib/ft8/ft8b_2.f90 index d755f6914..5db727168 100644 --- a/lib/ft8/ft8b_2.f90 +++ b/lib/ft8/ft8b_2.f90 @@ -36,7 +36,7 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, & complex ctwk(32) complex csymb(32) complex cs(0:7,NN) - logical first,newdat,lsubtract,lapon,lapcqonly,nagain + logical first,newdat,lsubtract,lapon,lapcqonly,nagain,unpk77_success data icos7/3,1,4,0,6,5,2/ ! Flipped w.r.t. original FT8 sync array data mcq/0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0/ data mrrr/0,1,1,1,1,1,1,0,1,0,0,1,0,0,1,0,0,0,1/ @@ -321,8 +321,8 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, & if(i3.gt.4 .or. (i3.eq.0.and.n3.gt.5)) then cycle endif - call unpack77(c77,msg37) - if(index(msg37,'QU1RK').gt.0) then + call unpack77(c77,msg37,unpk77_success) + if(.not.unpk77_success) then cycle endif nbadcrc=0 ! If we get this far: valid codeword, valid (i3,n3), nonquirky message. diff --git a/lib/ft8/genft8_174_91.f90 b/lib/ft8/genft8_174_91.f90 index f7529f4b3..d56187d6c 100644 --- a/lib/ft8/genft8_174_91.f90 +++ b/lib/ft8/genft8_174_91.f90 @@ -10,11 +10,12 @@ subroutine genft8_174_91(msg,i3,n3,msgsent,msgbits,itone) integer itone(79) integer icos7(0:6) integer graymap(0:7) + logical unpk77_success data icos7/3,1,4,0,6,5,2/ !Costas 7x7 tone pattern data graymap/0,1,3,2,5,6,4,7/ call pack77(msg,i3,n3,c77) - call unpack77(c77,msgsent) + call unpack77(c77,msgsent,unpk77_success) read(c77,'(77i1)',err=1) msgbits go to 2 diff --git a/lib/genmsk_128_90.f90 b/lib/genmsk_128_90.f90 index a0979cc50..f1e82f683 100644 --- a/lib/genmsk_128_90.f90 +++ b/lib/genmsk_128_90.f90 @@ -32,7 +32,7 @@ subroutine genmsk_128_90(msg0,ichk,msgsent,i4tone,itype) real*8 xi(864),xq(864),pi,twopi data s8/0,1,1,1,0,0,1,0/ equivalence (ihash,i1hash) - logical first + logical first,unpk77_success data first/.true./ save @@ -73,7 +73,7 @@ subroutine genmsk_128_90(msg0,ichk,msgsent,i4tone,itype) endif call pack77(message,i3,n3,c77) - call unpack77(c77,msgsent) !Unpack to get msgsent + call unpack77(c77,msgsent,unpk77_success) !Unpack to get msgsent if(ichk.eq.1) go to 999 read(c77,"(77i1)") msgbits call encode_128_90(msgbits,codeword) diff --git a/lib/ldpcsim128_90.f90 b/lib/ldpcsim128_90.f90 index ebe759806..05b424b7e 100644 --- a/lib/ldpcsim128_90.f90 +++ b/lib/ldpcsim128_90.f90 @@ -14,6 +14,7 @@ program ldpcsim128_90 integer*1 msgbits(77) integer*4 i4Msg6BitWords(13) integer nerrtot(0:N),nerrdec(0:N) + logical unpk77_success real*8 rxdata(N), rxavgd(N) real llr(N) @@ -47,7 +48,7 @@ program ldpcsim128_90 i3=0 n3=1 call pack77(msg,i3,n3,c77) - call unpack77(c77,msgsent) + call unpack77(c77,msgsent,unpk77_success) read(c77,'(77i1)') msgbits write(*,*) "message sent ",msgsent @@ -107,7 +108,7 @@ program ldpcsim128_90 ! If the decoder finds a valid codeword, nharderrors will be .ge. 0. if( nharderrors .ge. 0 ) then write(c77,'(77i1)') message77 - call unpack77(c77,msgreceived) + call unpack77(c77,msgreceived,unpk77_success) nhw=count(cw.ne.codeword) if(nhw.eq.0) then ! this is a good decode ngood=ngood+1 diff --git a/lib/msk144decodeframe.f90 b/lib/msk144decodeframe.f90 index d6651e711..4fcb2cfe9 100644 --- a/lib/msk144decodeframe.f90 +++ b/lib/msk144decodeframe.f90 @@ -15,7 +15,7 @@ subroutine msk144decodeframe(c,softbits,msgreceived,nsuccess,recent_calls,nrecen real pp(12) real softbits(144) real llr(128) - logical first + logical first,unpk77_success data first/.true./ data s8/0,1,1,1,0,0,1,0/ save first,cb,fs,pi,twopi,dt,s8,pp @@ -101,7 +101,7 @@ subroutine msk144decodeframe(c,softbits,msgreceived,nsuccess,recent_calls,nrecen if( nharderror .ge. 0 .and. nharderror .lt. 18 ) then nsuccess=1 write(c77,'(77i1)') decoded77 - call unpack77(c77,msgreceived) + call unpack77(c77,msgreceived,unpk77_success) endif return diff --git a/mainwindow.cpp b/mainwindow.cpp index d95d4fe1f..632d7ef12 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -99,7 +99,7 @@ extern "C" { void genwspr_(char* msg, char* msgsent, int itone[], fortran_charlen_t, fortran_charlen_t); - void genwspr_fsk8_(char* msg, char* msgsent, int itone[], fortran_charlen_t, fortran_charlen_t); +// void genwspr_fsk8_(char* msg, char* msgsent, int itone[], fortran_charlen_t, fortran_charlen_t); void geniscat_(char* msg, char* msgsent, int itone[], fortran_charlen_t, fortran_charlen_t); @@ -1423,9 +1423,9 @@ void MainWindow::dataSink(qint64 frames) QDir::toNativeSeparators(m_config.writeable_data_dir ().absolutePath()) + "\" \"" + m_path + "\""; } else { if(m_mode=="WSPR-LF") { - cmnd='"' + m_appDir + '"' + "/wspr_fsk8d " + degrade + t2 +" -a \"" + - QDir::toNativeSeparators(m_config.writeable_data_dir ().absolutePath()) + "\" " + - '"' + m_fnameWE + ".wav\""; +// cmnd='"' + m_appDir + '"' + "/wspr_fsk8d " + degrade + t2 +" -a \"" + +// QDir::toNativeSeparators(m_config.writeable_data_dir ().absolutePath()) + "\" " + +// '"' + m_fnameWE + ".wav\""; } else { cmnd='"' + m_appDir + '"' + "/wsprd " + depth_string + " -a \"" + QDir::toNativeSeparators(m_config.writeable_data_dir ().absolutePath()) + "\" " + @@ -1436,7 +1436,7 @@ void MainWindow::dataSink(qint64 frames) int i1=cmnd.indexOf("/wsprd "); cmnd=t3.mid(0,i1+7) + t3.mid(i1+7); - if(m_mode=="WSPR-LF") cmnd=cmnd.replace("/wsprd ","/wspr_fsk8d "+degrade+t2); +// if(m_mode=="WSPR-LF") cmnd=cmnd.replace("/wsprd ","/wspr_fsk8d "+degrade+t2); if (ui) ui->DecodeButton->setChecked (true); m_cmndP1=QDir::toNativeSeparators(cmnd); p1Timer.start(1000); @@ -3514,8 +3514,8 @@ void MainWindow::guiUpdate() &m_currentMessageType, 22, 22); if(m_modeTx=="WSPR") genwspr_(message, msgsent, const_cast (itone), 22, 22); - if(m_modeTx=="WSPR-LF") genwspr_fsk8_(message, msgsent, const_cast (itone), - 22, 22); +// if(m_modeTx=="WSPR-LF") genwspr_fsk8_(message, msgsent, const_cast (itone), +// 22, 22); if(m_modeTx=="MSK144" or m_modeTx=="FT8") { char MyCall[6]; char MyGrid[6];