From cf6ee661ab10b21f5af5ab6e867eb6257da925bb Mon Sep 17 00:00:00 2001 From: Joe Taylor Date: Fri, 14 Feb 2020 10:15:37 -0500 Subject: [PATCH] Fix two bugs (thanks Steve!); add early-decode logic to jt9[.exe] from command line. --- lib/ft8_decode.f90 | 4 ++-- lib/jt9.f90 | 15 ++++++++++++++- 2 files changed, 16 insertions(+), 3 deletions(-) diff --git a/lib/ft8_decode.f90 b/lib/ft8_decode.f90 index 40b944bed..b2b8fe06b 100644 --- a/lib/ft8_decode.f90 +++ b/lib/ft8_decode.f90 @@ -75,7 +75,7 @@ contains else ndecodes=ndec_early endif - if(nhsym.eq.50 .and. ndec_early.ge.1) then + if(nzhsym.eq.50 .and. ndec_early.ge.1) then do i=1,ndec_early call subtractft8(dd,itone_save(1,i),f1_save(i),xdt_save(i)) enddo @@ -136,7 +136,7 @@ contains allmessages(ndecodes)=msg37 allsnrs(ndecodes)=nsnr f1_save(ndecodes)=f1 - xdt_save(ndecodes)=xdt + xdt_save(ndecodes)=xdt+0.5 itone_save(1:NN,ndecodes)=itone endif ! write(81,1004) nutc,ncand,icand,ipass,iaptype,iappass, & diff --git a/lib/jt9.f90 b/lib/jt9.f90 index 2e8dbd0f0..6eb732a82 100644 --- a/lib/jt9.f90 +++ b/lib/jt9.f90 @@ -13,6 +13,7 @@ program jt9 include 'jt9com.f90' + integer*2 id2a(180000) integer(C_INT) iret type(wav_header) wav real*4 s(NSMAX) @@ -301,7 +302,19 @@ program jt9 datetime="2013-Apr-16 15:13" !### Temp shared_data%params%datetime=transfer(datetime,shared_data%params%datetime) if(mode.eq.9 .and. fsplit.ne.2700) shared_data%params%nfa=fsplit - call multimode_decoder(shared_data%ss,shared_data%id2,shared_data%params,nfsample) + if(mode.eq.8) then +! "Early" decoding pass, FT8 only + nearly=35 + shared_data%params%nzhsym=nearly + id2a(1:nearly*3456)=shared_data%id2(1:nearly*3456) + id2a(nearly*3456+1:)=0 + call multimode_decoder(shared_data%ss,id2a, & + shared_data%params,nfsample) + shared_data%params%nzhsym=50 + endif +! Normal decoding pass + call multimode_decoder(shared_data%ss,shared_data%id2, & + shared_data%params,nfsample) enddo call timer('jt9 ',1)