mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2025-05-29 12:52:28 -04:00
Fix defect in jt9 standalone mode causing randon file read
Made default values for decoding parameters better in standalone jt65 tool. git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6291 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
parent
d5bc774641
commit
ca5cfc1402
@ -11,7 +11,8 @@ program jt65
|
|||||||
real*4 dd(NZMAX)
|
real*4 dd(NZMAX)
|
||||||
character*80 infile
|
character*80 infile
|
||||||
character(len=500) optarg
|
character(len=500) optarg
|
||||||
character*6 mycall,hiscall,hisgrid
|
character*12 mycall,hiscall
|
||||||
|
character*6 hisgrid
|
||||||
common/tracer/limtrace,lu
|
common/tracer/limtrace,lu
|
||||||
equivalence (lenfile,ihdr(2))
|
equivalence (lenfile,ihdr(2))
|
||||||
type (option) :: long_options(9) = [ &
|
type (option) :: long_options(9) = [ &
|
||||||
@ -38,9 +39,10 @@ nhigh=4000
|
|||||||
n2pass=2
|
n2pass=2
|
||||||
nrobust=0
|
nrobust=0
|
||||||
nexp_decoded=0
|
nexp_decoded=0
|
||||||
|
naggressive=1
|
||||||
|
|
||||||
do
|
do
|
||||||
call getopt('f:hn:rc:x:g:X',long_options,c,optarg,narglen,nstat,noffset,nremain,.true.)
|
call getopt('f:hn:rc:x:g:X:s',long_options,c,optarg,narglen,nstat,noffset,nremain,.true.)
|
||||||
if( nstat .ne. 0 ) then
|
if( nstat .ne. 0 ) then
|
||||||
exit
|
exit
|
||||||
end if
|
end if
|
||||||
@ -90,6 +92,7 @@ nexp_decoded=0
|
|||||||
newdat=1
|
newdat=1
|
||||||
nfa=nlow
|
nfa=nlow
|
||||||
nfb=nhigh
|
nfb=nhigh
|
||||||
|
minsync=0
|
||||||
call get_command_argument(ifile,optarg,narglen)
|
call get_command_argument(ifile,optarg,narglen)
|
||||||
infile=optarg(:narglen)
|
infile=optarg(:narglen)
|
||||||
open(10,file=infile,access='stream',status='old',err=998)
|
open(10,file=infile,access='stream',status='old',err=998)
|
||||||
@ -109,7 +112,7 @@ nexp_decoded=0
|
|||||||
! write(56) ihdr(1:11)
|
! write(56) ihdr(1:11)
|
||||||
|
|
||||||
call jt65a(dd,npts,newdat,nutc,nfa,nfb,nfqso,ntol,nsubmode, &
|
call jt65a(dd,npts,newdat,nutc,nfa,nfb,nfqso,ntol,nsubmode, &
|
||||||
minsync,nagain,n2pass,nrobust,ntrials, naggressive,ndepth, &
|
minsync,nagain,n2pass,nrobust,ntrials,naggressive,ndepth, &
|
||||||
mycall,hiscall,hisgrid,nexp_decoded,ndecoded)
|
mycall,hiscall,hisgrid,nexp_decoded,ndecoded)
|
||||||
call timer('jt65a ',1)
|
call timer('jt65a ',1)
|
||||||
enddo
|
enddo
|
||||||
|
17
lib/jt9.f90
17
lib/jt9.f90
@ -13,12 +13,11 @@ program jt9
|
|||||||
integer(C_INT) iret
|
integer(C_INT) iret
|
||||||
integer*4 ihdr(11)
|
integer*4 ihdr(11)
|
||||||
real*4 s(NSMAX)
|
real*4 s(NSMAX)
|
||||||
integer*2 id2
|
|
||||||
character c
|
character c
|
||||||
character(len=500) optarg, infile
|
character(len=500) optarg, infile
|
||||||
character wisfile*80
|
character wisfile*80
|
||||||
integer :: arglen,stat,offset,remain,mode=0,flow=200,fsplit=2700, &
|
integer :: arglen,stat,offset,remain,mode=0,flow=200,fsplit=2700, &
|
||||||
fhigh=4000,nrxfreq=1500,ntrperiod0=1,ndepth=60001,nexp_decode=0
|
fhigh=4000,nrxfreq=1500,ntrperiod=1,ndepth=60001,nexp_decode=0
|
||||||
logical :: shmem = .false., read_files = .false., &
|
logical :: shmem = .false., read_files = .false., &
|
||||||
tx9 = .false., display_help = .false.
|
tx9 = .false., display_help = .false.
|
||||||
type (option) :: long_options(22) = [ &
|
type (option) :: long_options(22) = [ &
|
||||||
@ -90,7 +89,7 @@ program jt9
|
|||||||
read (optarg(:arglen), *) nthreads
|
read (optarg(:arglen), *) nthreads
|
||||||
case ('p')
|
case ('p')
|
||||||
read_files = .true.
|
read_files = .true.
|
||||||
read (optarg(:arglen), *) ntrperiod0
|
read (optarg(:arglen), *) ntrperiod
|
||||||
case ('d')
|
case ('d')
|
||||||
read_files = .true.
|
read_files = .true.
|
||||||
read (optarg(:arglen), *) ndepth
|
read (optarg(:arglen), *) ndepth
|
||||||
@ -200,19 +199,19 @@ program jt9
|
|||||||
go to 2
|
go to 2
|
||||||
1 nutc=0
|
1 nutc=0
|
||||||
2 nsps=0
|
2 nsps=0
|
||||||
if(ntrperiod0.eq.1) then
|
if(ntrperiod.eq.1) then
|
||||||
nsps=6912
|
nsps=6912
|
||||||
shared_data%params%nzhsym=181
|
shared_data%params%nzhsym=181
|
||||||
else if(ntrperiod0.eq.2) then
|
else if(ntrperiod.eq.2) then
|
||||||
nsps=15360
|
nsps=15360
|
||||||
shared_data%params%nzhsym=178
|
shared_data%params%nzhsym=178
|
||||||
else if(ntrperiod0.eq.5) then
|
else if(ntrperiod.eq.5) then
|
||||||
nsps=40960
|
nsps=40960
|
||||||
shared_data%params%nzhsym=172
|
shared_data%params%nzhsym=172
|
||||||
else if(ntrperiod0.eq.10) then
|
else if(ntrperiod.eq.10) then
|
||||||
nsps=82944
|
nsps=82944
|
||||||
shared_data%params%nzhsym=171
|
shared_data%params%nzhsym=171
|
||||||
else if(ntrperiod0.eq.30) then
|
else if(ntrperiod.eq.30) then
|
||||||
nsps=252000
|
nsps=252000
|
||||||
shared_data%params%nzhsym=167
|
shared_data%params%nzhsym=167
|
||||||
endif
|
endif
|
||||||
@ -227,7 +226,7 @@ program jt9
|
|||||||
call timer('jt9 ',0)
|
call timer('jt9 ',0)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
id2=0 !??? Why is this necessary ???
|
shared_data%id2=0 !??? Why is this necessary ???
|
||||||
|
|
||||||
do iblk=1,npts/kstep
|
do iblk=1,npts/kstep
|
||||||
k=iblk*kstep
|
k=iblk*kstep
|
||||||
|
Loading…
x
Reference in New Issue
Block a user