mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-15 08:31:57 -05:00
Options for introducing frequency drift and frequency steps (e.g. 10 Hz) in Q65 simulator.
This commit is contained in:
parent
a02cbabb99
commit
6074e4e3af
@ -19,10 +19,10 @@ program q65sim
|
||||
character msgsent*37
|
||||
|
||||
nargs=iargc()
|
||||
if(nargs.ne.9) then
|
||||
print*,'Usage: q65sim "msg" A-E freq fDop DT f1 TRp Nfile SNR'
|
||||
print*,'Example: q65sim "K1ABC W9XYZ EN37" A 1500 0.0 0.0 0.0 60 1 -26'
|
||||
print*,' fDop is Doppler spread; f1 is drift rate (Hz/min)'
|
||||
if(nargs.ne.10) then
|
||||
print*,'Usage: q65sim "msg" A-E freq fDop DT f1 Stp TRp Nfile SNR'
|
||||
print*,'Example: q65sim "K1ABC W9XYZ EN37" A 1500 0.0 0.0 0.0 1 60 1 -26'
|
||||
print*,' fDop: Doppler spread; f1: drift rate (Hz/min); Stp: step size (Hz)'
|
||||
go to 999
|
||||
endif
|
||||
call getarg(1,msg)
|
||||
@ -37,10 +37,12 @@ program q65sim
|
||||
call getarg(6,arg)
|
||||
read(arg,*) f1
|
||||
call getarg(7,arg)
|
||||
read(arg,*) ntrperiod
|
||||
read(arg,*) nstp
|
||||
call getarg(8,arg)
|
||||
read(arg,*) nfiles
|
||||
read(arg,*) ntrperiod
|
||||
call getarg(9,arg)
|
||||
read(arg,*) nfiles
|
||||
call getarg(10,arg)
|
||||
read(arg,*) snrdb
|
||||
|
||||
if(ntrperiod.eq.15) then
|
||||
@ -89,7 +91,7 @@ program q65sim
|
||||
h=default_header(12000,npts)
|
||||
|
||||
write(*,1004)
|
||||
1004 format('File TR Freq Mode S/N Dop DT f1 Message'/66('-'))
|
||||
1004 format('File TR Freq Mode S/N Dop DT f1 Stp Message'/70('-'))
|
||||
|
||||
do ifile=1,nfiles !Loop over requested number of files
|
||||
if(ntrperiod.lt.60) then
|
||||
@ -112,8 +114,8 @@ program q65sim
|
||||
bandwidth_ratio=2500.0/6000.0
|
||||
sig=sqrt(2*bandwidth_ratio)*10.0**(0.05*snrdb)
|
||||
if(snrdb.gt.90.0) sig=1.0
|
||||
write(*,1020) ifile,ntrperiod,f0,csubmode,snrdb,fspread,xdt,f1,trim(msgsent)
|
||||
1020 format(i4,i6,f7.1,2x,a1,2x,f5.1,f6.2,2f6.1,2x,a)
|
||||
write(*,1020) ifile,ntrperiod,f0,csubmode,snrdb,fspread,xdt,f1,nstp,trim(msgsent)
|
||||
1020 format(i4,i6,f7.1,2x,a1,2x,f5.1,f6.2,2f6.1,i4,2x,a)
|
||||
phi=0.d0
|
||||
dphi=0.d0
|
||||
k=(xdt+0.5)*12000 !Start audio at t=xdt+0.5 s (TR=15 and 30 s)
|
||||
@ -123,8 +125,8 @@ program q65sim
|
||||
isym=i/nsps + 1
|
||||
if(isym.gt.nsym) exit
|
||||
if(isym.ne.isym0) then
|
||||
! Drift term
|
||||
freq = f0 + itone(isym)*baud*mode65 + f1*i*dt/60.0
|
||||
if(nstp.ne.0) freq=nstp*nint(freq/nstp)
|
||||
dphi=twopi*freq*dt
|
||||
isym0=isym
|
||||
endif
|
||||
|
@ -1,6 +1,6 @@
|
||||
program test_q65
|
||||
|
||||
character*75 cmd1,cmd2,line
|
||||
character*82 cmd1,cmd2,line
|
||||
character*22 msg
|
||||
character*8 arg
|
||||
character*1 csubmode
|
||||
@ -8,9 +8,9 @@ program test_q65
|
||||
logical decok
|
||||
|
||||
nargs=iargc()
|
||||
if(nargs.ne.10) then
|
||||
print*,'Usage: test_q65 "msg" A-D depth freq DT fDop TRp Q nfiles SNR'
|
||||
print*,'Example: test_q65 "K1ABC W9XYZ EN37" A 3 1500 0.0 5.0 60 3 100 -20'
|
||||
if(nargs.ne.12) then
|
||||
print*,'Usage: test_q65 "msg" A-D depth freq DT fDop f1 Stp TRp Q nfiles SNR'
|
||||
print*,'Example: test_q65 "K1ABC W9XYZ EN37" A 3 1500 0.0 5.0 0.0 1 60 3 100 -20'
|
||||
print*,'Use SNR = 0 to loop over all relevant SNRs'
|
||||
print*,'Use MyCall=K1ABC, HisCall=W9XYZ, HisGrid="EN37" for AP decodes'
|
||||
print*,'Option Q sets QSOprogress (0-5) for AP decoding.'
|
||||
@ -28,12 +28,16 @@ program test_q65
|
||||
call getarg(6,arg)
|
||||
read(arg,*) fDop
|
||||
call getarg(7,arg)
|
||||
read(arg,*) ntrperiod
|
||||
read(arg,*) f1
|
||||
call getarg(8,arg)
|
||||
read(arg,*) nQSOprogress
|
||||
read(arg,*) nstp
|
||||
call getarg(9,arg)
|
||||
read(arg,*) nfiles
|
||||
read(arg,*) ntrperiod
|
||||
call getarg(10,arg)
|
||||
read(arg,*) nQSOprogress
|
||||
call getarg(11,arg)
|
||||
read(arg,*) nfiles
|
||||
call getarg(12,arg)
|
||||
read(arg,*) snr
|
||||
|
||||
if(ntrperiod.eq.15) then
|
||||
@ -68,7 +72,7 @@ program test_q65
|
||||
|
||||
! 1 2 3 4 5 6 7
|
||||
! 123456789012345678901234567890123456789012345678901234567890123456789012345'
|
||||
cmd1='q65sim "K1ABC W9XYZ EN37 " A 1500 5.0 0.0 60 100 -10.0 > junk0'
|
||||
cmd1='q65sim "K1ABC W9XYZ EN37 " A 1500 5.0 0.0 0.0 1 60 100 -10.0 > junk0'
|
||||
cmd2='jt9 -3 -p 15 -L 300 -H 3000 -d 3 -b A -Q 3 -f 1500 *.wav > junk'
|
||||
|
||||
write(cmd1(10:33),'(a)') '"'//msg//'"'
|
||||
@ -76,15 +80,17 @@ program test_q65
|
||||
write(cmd1(37:40),'(i4)') nf0
|
||||
write(cmd1(41:45),'(f5.0)') fDop
|
||||
write(cmd1(46:50),'(f5.2)') dt
|
||||
write(cmd1(51:54),'(i4)') ntrperiod
|
||||
write(cmd1(55:59),'(i5)') nfiles
|
||||
write(cmd1(51:54),'(f4.0)') f1
|
||||
write(cmd1(55:57),'(i3)') nstp
|
||||
write(cmd1(58:61),'(i4)') ntrperiod
|
||||
write(cmd1(62:66),'(i5)') nfiles
|
||||
|
||||
write(cmd2(11:13),'(i3)') ntrperiod
|
||||
write(cmd2(33:34),'(i2)') ndepth
|
||||
write(cmd2(44:44),'(i1)') nQSOprogress
|
||||
write(cmd2(49:52),'(i4)') nf0
|
||||
cmd2(39:39)=csubmode
|
||||
|
||||
|
||||
call system('rm -f *.wav')
|
||||
|
||||
! call qra_params(ndepth,maxaptype,idf0max,idt0max,ibwmin,ibwmax,maxdist)
|
||||
@ -110,7 +116,7 @@ program test_q65
|
||||
nfalse=0
|
||||
naptype=0
|
||||
ndecn=0
|
||||
write(cmd1(63:67),'(f5.1)') snr1
|
||||
write(cmd1(70:74),'(f5.1)') snr1
|
||||
call system(cmd1)
|
||||
call sec0(0,tdec)
|
||||
call system(cmd2)
|
||||
|
Loading…
Reference in New Issue
Block a user