mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-22 12:23:37 -05:00
Resurrect jt9sim, in case we need it.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@4305 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
parent
617b08175b
commit
60955db247
@ -28,7 +28,7 @@ CFLAGS = -I. -fbounds-check -mno-stack-arg-probe
|
|||||||
%.o: %.F90
|
%.o: %.F90
|
||||||
${FC} ${FFLAGS} -c $<
|
${FC} ${FFLAGS} -c $<
|
||||||
|
|
||||||
all: libjt9.a libastro.a jt9.exe jt9code.exe jt65code.exe
|
all: libjt9.a libastro.a jt9.exe jt9code.exe jt65code.exe jt9sim.exe
|
||||||
|
|
||||||
OBJS1 = pctile.o graycode.o sort.o ssort.o chkmsg.o \
|
OBJS1 = pctile.o graycode.o sort.o ssort.o chkmsg.o \
|
||||||
unpackmsg.o igray.o unpackcall.o unpackgrid.o \
|
unpackmsg.o igray.o unpackcall.o unpackgrid.o \
|
||||||
|
@ -19,8 +19,8 @@ program jt9sim
|
|||||||
|
|
||||||
nargs=iargc()
|
nargs=iargc()
|
||||||
if(nargs.ne.6) then
|
if(nargs.ne.6) then
|
||||||
print*,'Usage: jt9sim "message" fspan nsigs minutes SNR nfiles'
|
print*,'Usage: jt9sim "message" fspan nsigs minutes SNR nfiles'
|
||||||
print*,'Example: "CQ K1ABC FN42" 200 20 2 -28 1'
|
print*,'Example: jt9sim "CQ K1ABC FN42" 200 20 2 -28 1'
|
||||||
print*,' '
|
print*,' '
|
||||||
print*,'Enter message = "" to use entries in msgs.txt.'
|
print*,'Enter message = "" to use entries in msgs.txt.'
|
||||||
print*,'Enter SNR = 0 to generate a range of SNRs.'
|
print*,'Enter SNR = 0 to generate a range of SNRs.'
|
||||||
@ -54,7 +54,9 @@ program jt9sim
|
|||||||
if(minutes.eq.30) nsps=252000
|
if(minutes.eq.30) nsps=252000
|
||||||
if(nsps.eq.0) stop 'Bad value for minutes.'
|
if(nsps.eq.0) stop 'Bad value for minutes.'
|
||||||
|
|
||||||
f0=1400.d0 !Center frequency (Hz)
|
! f0=1400.d0 !Center frequency (Hz)
|
||||||
|
f0=3000.d0 !Center frequency (Hz)
|
||||||
|
|
||||||
! f0=1500.0
|
! f0=1500.0
|
||||||
! if(minutes.eq.5) f0=1100.
|
! if(minutes.eq.5) f0=1100.
|
||||||
! if(minutes.eq.10) f0=1050.
|
! if(minutes.eq.10) f0=1050.
|
||||||
@ -65,7 +67,7 @@ program jt9sim
|
|||||||
|
|
||||||
if(msg0(1:3).eq.'sin') read(msg0(4:),*) sinfreq
|
if(msg0(1:3).eq.'sin') read(msg0(4:),*) sinfreq
|
||||||
|
|
||||||
open(12,file='msgs.txt',status='old')
|
if(message.eq."") open(12,file='msgs.txt',status='old')
|
||||||
|
|
||||||
write(*,1000)
|
write(*,1000)
|
||||||
1000 format('File N freq S/N Message'/ &
|
1000 format('File N freq S/N Message'/ &
|
||||||
@ -88,7 +90,7 @@ program jt9sim
|
|||||||
endif
|
endif
|
||||||
|
|
||||||
if(msg0.ne.' ') then
|
if(msg0.ne.' ') then
|
||||||
call genjt9(message,msgsent,i4tone) !Encode message into tone #s
|
call genjt9(message,0,msgsent,i4tone,itext) !Encode message into tone #s
|
||||||
endif
|
endif
|
||||||
|
|
||||||
rewind 12
|
rewind 12
|
||||||
@ -154,8 +156,8 @@ program jt9sim
|
|||||||
i4=-10
|
i4=-10
|
||||||
if(i1Bits(i).eq.1) i4=10
|
if(i1Bits(i).eq.1) i4=10
|
||||||
i4=i4+128
|
i4=i4+128
|
||||||
if(i4.le.127) i1SoftSymbols(k)=i4
|
if(i4.le.127) i1SoftSymbols(i)=i4
|
||||||
if(i4.ge.128) i1SoftSymbols(k)=i4-256
|
if(i4.ge.128) i1SoftSymbols(i)=i4-256
|
||||||
enddo
|
enddo
|
||||||
limit=1000
|
limit=1000
|
||||||
call decode9(i1SoftSymbols,limit,nlim,msg)
|
call decode9(i1SoftSymbols,limit,nlim,msg)
|
||||||
|
32
lib/t1.f90
32
lib/t1.f90
@ -1,32 +0,0 @@
|
|||||||
program t1
|
|
||||||
|
|
||||||
character*22 msg
|
|
||||||
character*12 arg
|
|
||||||
complex c3(0:4096-1)
|
|
||||||
complex c5(0:4096-1)
|
|
||||||
|
|
||||||
call getarg(1,arg)
|
|
||||||
read(arg,*) nfile
|
|
||||||
|
|
||||||
do ifile=1,999
|
|
||||||
read(51,end=999) nutc,nsnr,xdt,nfreq,msg,c3,c5
|
|
||||||
write(*,1010) ifile,nutc,nsnr,xdt,nfreq,msg
|
|
||||||
1010 format(3i6,f7.1,i6,2x,a22)
|
|
||||||
|
|
||||||
if(ifile.eq.nfile) then
|
|
||||||
c3=c5
|
|
||||||
c3(1353:)=0
|
|
||||||
call four2a(c3,2048,1,-1,1)
|
|
||||||
|
|
||||||
df=12000.0/(128.0*2048.0)
|
|
||||||
do i=0,2048
|
|
||||||
freq=i*df
|
|
||||||
if(i.ge.1024) freq=(i-2048)*df
|
|
||||||
s=1.e-4*(real(c3(i))**2 + aimag(c3(i))**2)
|
|
||||||
write(13,3001) i,freq,s
|
|
||||||
3001 format(i6,2f10.3)
|
|
||||||
enddo
|
|
||||||
endif
|
|
||||||
enddo
|
|
||||||
|
|
||||||
999 end program t1
|
|
Loading…
Reference in New Issue
Block a user