2022-12-12 15:23:51 -05:00
|
|
|
subroutine decode0(dd,ss,savg)
|
2022-12-04 10:17:02 -05:00
|
|
|
|
|
|
|
use timer_module, only: timer
|
|
|
|
parameter (NSMAX=60*96000)
|
|
|
|
|
2022-12-12 18:52:45 -05:00
|
|
|
real*4 dd(2,NSMAX),ss(322,NFFT),savg(NFFT)
|
2022-12-04 10:17:02 -05:00
|
|
|
real*8 fcenter
|
|
|
|
integer hist(0:32768)
|
|
|
|
character mycall*12,hiscall*12,mygrid*6,hisgrid*6,datetime*20
|
|
|
|
character mycall0*12,hiscall0*12,hisgrid0*6
|
2022-12-10 10:52:58 -05:00
|
|
|
character*60 result
|
2022-12-14 16:52:06 -05:00
|
|
|
common/decodes/ndecodes,ncand,nQDecoderDone,nWDecoderBusy, &
|
|
|
|
nWTransmitting,result(50)
|
2023-01-16 17:45:14 -05:00
|
|
|
common/npar/fcenter,nutc,fselected,mousedf,mousefqso,nagain, &
|
2022-12-04 10:17:02 -05:00
|
|
|
ndepth,ndiskdat,neme,newdat,nfa,nfb,nfcal,nfshift, &
|
|
|
|
mcall3,nkeep,ntol,nxant,nrxlog,nfsample,nxpol,nmode, &
|
|
|
|
ndop00,nsave,max_drift,nhsym,mycall,mygrid,hiscall,hisgrid,datetime
|
2022-12-12 13:44:41 -05:00
|
|
|
data neme0/-99/
|
2022-12-04 10:17:02 -05:00
|
|
|
save
|
|
|
|
|
2022-12-14 16:52:06 -05:00
|
|
|
nQDecoderDone=0
|
2022-12-04 10:17:02 -05:00
|
|
|
if(newdat.ne.0) then
|
|
|
|
nz=96000*nhsym/5.3833
|
|
|
|
hist=0
|
|
|
|
do i=1,nz
|
|
|
|
j1=min(abs(dd(1,i)),32768.0)
|
|
|
|
hist(j1)=hist(j1)+1
|
|
|
|
j2=min(abs(dd(2,i)),32768.0)
|
|
|
|
hist(j2)=hist(j2)+1
|
|
|
|
enddo
|
|
|
|
m=0
|
|
|
|
do i=0,32768
|
|
|
|
m=m+hist(i)
|
|
|
|
if(m.ge.2*nz) go to 10
|
|
|
|
enddo
|
|
|
|
10 rmsdd=1.5*i
|
|
|
|
endif
|
|
|
|
|
|
|
|
mycall0=mycall
|
|
|
|
hiscall0=hiscall
|
|
|
|
hisgrid0=hisgrid
|
|
|
|
neme0=neme
|
|
|
|
|
2023-01-25 08:51:51 -05:00
|
|
|
call timer('qmapa ',0)
|
|
|
|
call qmapa(dd,ss,savg,newdat,nutc,fcenter,ntol,nfa,nfb, &
|
2022-12-22 10:06:29 -05:00
|
|
|
mousedf,mousefqso,nagain,nfshift,max_drift, &
|
2022-12-21 13:29:32 -05:00
|
|
|
nfcal,mycall,hiscall,hisgrid,nfsample,nmode,ndepth, &
|
2023-01-16 17:45:14 -05:00
|
|
|
datetime,ndop00,fselected)
|
2023-01-25 08:51:51 -05:00
|
|
|
call timer('qmapa ',1)
|
2022-12-04 10:17:02 -05:00
|
|
|
|
|
|
|
return
|
|
|
|
end subroutine decode0
|