From c7af9945d390a8be403802281a2dd2e4d78a1004 Mon Sep 17 00:00:00 2001 From: Joe Taylor Date: Wed, 28 Apr 2021 10:13:42 -0400 Subject: [PATCH] m65 noe mostly OK for single-pol mode. Needs more work for xpol. --- lib/map65_mmdec.f90 | 13 ++++----- lib/q65_decode.f90 | 4 +++ map65/libm65/q65b.f90 | 62 ++++++++++++++++--------------------------- 3 files changed, 34 insertions(+), 45 deletions(-) diff --git a/lib/map65_mmdec.f90 b/lib/map65_mmdec.f90 index c4e852206..5cabe623d 100644 --- a/lib/map65_mmdec.f90 +++ b/lib/map65_mmdec.f90 @@ -80,16 +80,17 @@ contains integer, intent(in) :: idec integer, intent(in) :: nused integer, intent(in) :: ntrperiod - character*3 cq if(nutc+snr1+nsnr+dt+freq+idec+nused+ntrperiod.eq.-999) stop if(decoded.eq.'-999') stop - cq='q ' - write(cq(2:2),'(i1)') idec - if(nused.ge.2) write(cq(3:3),'(i1)') nused - write(24,1010) nutc,nsnr,dt,nint(freq),decoded,cq -1010 format(i4.4,i4,f5.1,i5,4x,a37,1x,a3) + cq0='q ' + write(cq0(2:2),'(i1)') idec + if(nused.ge.2) write(cq0(3:3),'(i1)') nused + nsnr0=nsnr + xdt0=dt + nfreq0=nint(freq) + msg0=decoded select type(this) type is (counting_q65_decoder) diff --git a/lib/q65_decode.f90 b/lib/q65_decode.f90 index 07a15b81c..b1469c896 100644 --- a/lib/q65_decode.f90 +++ b/lib/q65_decode.f90 @@ -1,5 +1,9 @@ module q65_decode + integer nsnr0,nfreq0 + real xdt0 + character msg0*37,cq0*3 + type :: q65_decoder procedure(q65_decode_callback), pointer :: callback contains diff --git a/map65/libm65/q65b.f90 b/map65/libm65/q65b.f90 index 75c6ee5fa..9d6eb8b9a 100644 --- a/map65/libm65/q65b.f90 +++ b/map65/libm65/q65b.f90 @@ -1,7 +1,7 @@ subroutine q65b(nutc,fcenter,nfcal,nfsample,ikhz,mousedf,ntol,xpol, & mycall0,hiscall0,hisgrid,mode_q65) - use wavhdr + use q65_decode parameter (MAXFFT1=5376000) !56*96000 parameter (MAXFFT2=336000) !56*6000 (downsampled by 1/16) parameter (NMAX=60*12000) @@ -14,9 +14,9 @@ subroutine q65b(nutc,fcenter,nfcal,nfsample,ikhz,mousedf,ntol,xpol, & character*12 mycall,hiscall character*6 hisgrid character*4 grid4 - character*62 line - character*80 line2 - character*40 msg40 + character*80 line + character*37 msg1 + character*3 cq1 character*80 wsjtx_dir common/cacb/ca,cb save @@ -24,7 +24,6 @@ subroutine q65b(nutc,fcenter,nfcal,nfsample,ikhz,mousedf,ntol,xpol, & open(9,file='wsjtx_dir.txt',status='old') read(9,'(a)') wsjtx_dir close(9) - open(24,file='q65_decodes.txt',status='unknown') mycall='K1JT' hiscall='IV3NWV' @@ -67,6 +66,7 @@ subroutine q65b(nutc,fcenter,nfcal,nfsample,ikhz,mousedf,ntol,xpol, & ! 96000 5376000 0.017857143 336000 6000.000 ! 95238 5120000 0.018601172 322560 5999.994 + nsnr1=-99 npol=1 if(xpol) npol=4 do ipol=1,npol @@ -90,38 +90,23 @@ subroutine q65b(nutc,fcenter,nfcal,nfsample,ikhz,mousedf,ntol,xpol, & newdat=1 nagain=0 call map65_mmdec(nutc,iwave,nsubmode,nfa,nfb,nfqso,ntol,newdat,nagain, & - mycall,hiscall,hisgrid) - enddo - -! 1 2 3 4 5 6 -! 1234567890123456789012345678901234567890123456789012345678901234567 -! 0001 -22 2.9 1081 : EA2AGZ IK4WLV -16 q0 -! 110 101 2 1814 2.9 -11 # QRZ HB9Q JN47 1 0 30 H - nsnr0=-99 - line2=' ' - rewind 24 - - do i=1,8 - read(24,1002,end=100) line -1002 format(a62) - if(line(1:4).eq.'