diff --git a/lib/msk40decodeframe.f90 b/lib/msk40decodeframe.f90 index 2bc549489..ae75ddf95 100644 --- a/lib/msk40decodeframe.f90 +++ b/lib/msk40decodeframe.f90 @@ -134,14 +134,14 @@ subroutine msk40decodeframe(c,mycall,hiscall,xsnr,bswl,nhasharray, & nrxrpt=iand(imsg,15) nrxhash=(imsg-nrxrpt)/16 - if(nhammd.le.4 .and. cord .lt. 0.65 .and. nrxhash.eq.ihash) then + if(nhammd.le.4 .and. cord .lt. 0.65 .and. & + nrxhash.eq.ihash .and. nrxrpt.ge.7) then !write(*,*) 'decodeframe 1',nbadsync,nhammd,cord,nrxhash,nrxrpt,ihash,xsnr,sigma nsuccess=1 write(msgreceived,'(a1,a,1x,a,a1,1x,a4)') "<",trim(mycall), & trim(hiscall),">",rpt(nrxrpt) return -! elseif(bswl .and. nhammd.le.2 .and. cord.lt.0.40 .and. xsnr .gt. -3.0) then - elseif(bswl .and. nhammd.le.4 .and. cord.lt.0.65 ) then + elseif(bswl .and. nhammd.le.4 .and. cord.lt.0.65 .and. nrxrpt.ge.7 ) then do i=1,nrecent do j=i+1,nrecent if( nrxhash .eq. nhasharray(i,j) ) then @@ -157,7 +157,6 @@ subroutine msk40decodeframe(c,mycall,hiscall,xsnr,bswl,nhasharray, & endif enddo enddo -! if(nsuccess.eq.0 .and. nhammd.le.2 .and. cord.lt.0.40 .and. xsnr.gt. -3.0 ) then if(nsuccess.eq.0) then nsuccess=3 !write(*,*) 'decodeframe 4',bswl,nbadsync,nhammd,cord,nrxhash,nrxrpt,ihash,xsnr,sigma,nsuccess diff --git a/lib/msk40spd.f90 b/lib/msk40spd.f90 index 1831e0235..c8af1a49e 100644 --- a/lib/msk40spd.f90 +++ b/lib/msk40spd.f90 @@ -69,12 +69,12 @@ subroutine msk40spd(cbig,n,ntol,mycall,hiscall,bswl,nhasharray,recent_calls, & detfer=-999.99 nfhi=2*(fc+500) nflo=2*(fc-500) - ihlo=(nfhi-2*ntol)/df+1 - ihhi=(nfhi+2*ntol)/df+1 - illo=(nflo-2*ntol)/df+1 - ilhi=(nflo+2*ntol)/df+1 - i2000=nflo/df+1 - i4000=nfhi/df+1 + ihlo=nint((nfhi-2*ntol)/df)+1 + ihhi=nint((nfhi+2*ntol)/df)+1 + illo=nint((nflo-2*ntol)/df)+1 + ilhi=nint((nflo+2*ntol)/df)+1 + i2000=nint(nflo/df)+1 + i4000=nint(nfhi/df)+1 do istp=1,nstep ns=1+60*(istp-1) ne=ns+NSPM-1