mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2025-05-29 12:52:28 -04:00
Linux makefile additions for plrr, plrs.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/map65@454 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
parent
eba299aeff
commit
f15ca0266d
16
Makefile.in
16
Makefile.in
@ -36,9 +36,9 @@ RM ?= @RM@
|
|||||||
F2PY = @F2PY@
|
F2PY = @F2PY@
|
||||||
|
|
||||||
###
|
###
|
||||||
all: Audio.so
|
all: Audio.so plrs plrr
|
||||||
|
|
||||||
OBJS2C = init_rs.o encode_rs.o decode_rs.o plrr_subs.o loc.o
|
OBJS2C = init_rs.o encode_rs.o decode_rs.o plrr_subs.o loc.o deep65.o
|
||||||
|
|
||||||
F2PYONLY = ftn_init ftn_quit audio_init getfile azdist0 astro0 \
|
F2PYONLY = ftn_init ftn_quit audio_init getfile azdist0 astro0 \
|
||||||
spec map65a0
|
spec map65a0
|
||||||
@ -54,7 +54,7 @@ SRCS2F77 = indexx.f gen65.f chkmsg.f \
|
|||||||
gentone.f gencwid.f set.f db.f pctile.f sort.f ssort.f \
|
gentone.f gencwid.f set.f db.f pctile.f sort.f ssort.f \
|
||||||
avemsg65.f demod64a.f encode65.f extract.f four2a.f getpfx1.f \
|
avemsg65.f demod64a.f encode65.f extract.f four2a.f getpfx1.f \
|
||||||
getpfx2.f graycode.f grid2k.f interleave63.f k2grid.f \
|
getpfx2.f graycode.f grid2k.f interleave63.f k2grid.f \
|
||||||
deep65.f morse.f nchar.f packcall.f packgrid.f \
|
morse.f nchar.f packcall.f packgrid.f \
|
||||||
packmsg.f packtext.f setup65.f unpackcall.f unpackgrid.f \
|
packmsg.f packtext.f setup65.f unpackcall.f unpackgrid.f \
|
||||||
unpackmsg.f unpacktext.f astro.f azdist.f coord.f dcoord.f \
|
unpackmsg.f unpacktext.f astro.f azdist.f coord.f dcoord.f \
|
||||||
deg2grid.f dot.f ftsky.f geocentric.f GeoDist.f grid2deg.f \
|
deg2grid.f dot.f ftsky.f geocentric.f GeoDist.f grid2deg.f \
|
||||||
@ -71,7 +71,7 @@ SRCS3C = ptt_unix.c igray.c wrapkarn.c cutil.c
|
|||||||
OBJS3C = ${SRCS3C:.c=.o}
|
OBJS3C = ${SRCS3C:.c=.o}
|
||||||
AUDIOSRCS = a2d.f90 jtaudio.c resample.c start_portaudio.c
|
AUDIOSRCS = a2d.f90 jtaudio.c resample.c start_portaudio.c
|
||||||
|
|
||||||
#Audio.so: $(OBJS2C) $(SRCS2F90) $(SRCS2F77) $(SRCS2C)
|
#Audio.so: $(OBJS2C) $(SRCS2F90) $(SRCS2F77) $(SRCS2C)
|
||||||
# python f2py.py -c \
|
# python f2py.py -c \
|
||||||
# --quiet --"fcompiler=compaqv" \
|
# --quiet --"fcompiler=compaqv" \
|
||||||
# --opt="/nologo /traceback /warn:errors /fast /fpp /define:Win32 \
|
# --opt="/nologo /traceback /warn:errors /fast /fpp /define:Win32 \
|
||||||
@ -107,10 +107,16 @@ encode_rs_int.o: encode_rs.c
|
|||||||
decode_rs_int.o: decode_rs.c
|
decode_rs_int.o: decode_rs.c
|
||||||
$(CC) $(CFLAGS) -c -DBIGSYM=1 -o decode_rs_int.o decode_rs.c
|
$(CC) $(CFLAGS) -c -DBIGSYM=1 -o decode_rs_int.o decode_rs.c
|
||||||
|
|
||||||
|
plrr: plrr.f90 sec_midn.F90 plrr_subs.c cutil.c
|
||||||
|
$(FC) -o plrr plrr.f90 sec_midn.F90 plrr_subs.c cutil.c
|
||||||
|
|
||||||
|
plrs: plrs.f90 sec_midn.F90 plrs_subs.c cutil.c
|
||||||
|
$(FC) -o plrs plrs.f90 sec_midn.F90 plrs_subs.c cutil.c
|
||||||
|
|
||||||
.PHONY : clean
|
.PHONY : clean
|
||||||
clean:
|
clean:
|
||||||
${RM} -f *.o *.pyc *.so *~ map65
|
${RM} -f *.o *.pyc *.so *~ map65
|
||||||
(cd portaudio-v19;${MAKE} clean)
|
# (cd portaudio-v19;${MAKE} clean)
|
||||||
distclean: clean
|
distclean: clean
|
||||||
${RM} -f config.log config.status Makefile
|
${RM} -f config.log config.status Makefile
|
||||||
(cd portaudio-v19;${MAKE} distclean)
|
(cd portaudio-v19;${MAKE} distclean)
|
||||||
|
4
cutil.c
4
cutil.c
@ -81,7 +81,7 @@ time_t time_(void)
|
|||||||
double hrtime_(void)
|
double hrtime_(void)
|
||||||
{
|
{
|
||||||
struct timeval tv;
|
struct timeval tv;
|
||||||
struct timezone tz;
|
|
||||||
gettimeofday(&tv,&tz);
|
gettimeofday(&tv,NULL);
|
||||||
return(tv.tv_sec+1.e-6*tv.tv_usec);
|
return(tv.tv_sec+1.e-6*tv.tv_usec);
|
||||||
}
|
}
|
||||||
|
6
map65rc
6
map65rc
@ -1,6 +1,6 @@
|
|||||||
*font: Arial 8
|
*font: Arial 10
|
||||||
*Label*font: Arial 8
|
*Label*font: Arial 10
|
||||||
*Text*font: "Courier New" 9
|
*Text*font: "Courier New" 12
|
||||||
*Canvas*font: "Lucida Console" 16
|
*Canvas*font: "Lucida Console" 16
|
||||||
*background: gray85
|
*background: gray85
|
||||||
*Text*background: white
|
*Text*background: white
|
||||||
|
11
plrr.f90
11
plrr.f90
@ -6,16 +6,15 @@ program plrr
|
|||||||
integer*2 nblock
|
integer*2 nblock
|
||||||
real*8 center_freq,buf8
|
real*8 center_freq,buf8
|
||||||
common/plrscom/center_freq,msec,fselect,iptr,nblock,userx_no,iusb,buf8(174)
|
common/plrscom/center_freq,msec,fselect,iptr,nblock,userx_no,iusb,buf8(174)
|
||||||
! 8 4 4 4 2 1 1 1392
|
|
||||||
|
|
||||||
call setup_rsocket
|
call setup_rsocket
|
||||||
|
ns0=-99
|
||||||
npkt=0
|
|
||||||
|
|
||||||
10 call recv_pkt(center_freq)
|
10 call recv_pkt(center_freq)
|
||||||
npkt=npkt+1
|
ns=mod(msec/1000,60)
|
||||||
if(mod(npkt,1000).eq.0) write(*,1010) npkt,center_freq,0.001*msec,fselect
|
if(ns.ne.ns0) write(*,1010) ns,center_freq,0.001*msec,sec_midn()
|
||||||
1010 format('npkt:',i10,' f0:',f8.3,' t:',f10.3,' fselect:',f10.3)
|
1010 format('ns:',i3,' f0:',f10.3,' t1:',f10.3,' t2:',f10.3)
|
||||||
|
ns0=ns
|
||||||
go to 10
|
go to 10
|
||||||
|
|
||||||
end program plrr
|
end program plrr
|
||||||
|
24
plrs.f90
24
plrs.f90
@ -19,13 +19,12 @@ program plrs
|
|||||||
logical fast,pause
|
logical fast,pause
|
||||||
real*8 center_freq,dmsec,dtmspacket,tmsec
|
real*8 center_freq,dmsec,dtmspacket,tmsec
|
||||||
common/plrscom/center_freq,msec2,fsample,iptr,nblock,userx_no,iusb,buf8(174)
|
common/plrscom/center_freq,msec2,fsample,iptr,nblock,userx_no,iusb,buf8(174)
|
||||||
! 8 4 4 4 2 1 1 1392
|
|
||||||
data nm/45,46,48,50,52,54,55,56,57,58,59/
|
data nm/45,46,48,50,52,54,55,56,57,58,59/
|
||||||
data nblock/0/,fast/.false./,pause/.false./
|
data nblock/0/,fast/.false./,pause/.false./
|
||||||
|
|
||||||
nargs=iargc()
|
nargs=iargc()
|
||||||
if(nargs.ne.3) then
|
if(nargs.ne.4) then
|
||||||
print*,'Usage: plrs <fast|pause|slow> <minutes> <iters>'
|
print*,'Usage: plrs <fast|pause|slow> <minutes> <iters> <iwait>'
|
||||||
go to 999
|
go to 999
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@ -36,8 +35,16 @@ program plrs
|
|||||||
read(arg,*) nfiles
|
read(arg,*) nfiles
|
||||||
call getarg(3,arg)
|
call getarg(3,arg)
|
||||||
read(arg,*) iters
|
read(arg,*) iters
|
||||||
|
call getarg(4,arg)
|
||||||
|
read(arg,*) iwait
|
||||||
|
|
||||||
fname="all.tf2"//char(0)
|
if(iwait.ne.0) then
|
||||||
|
1 if(mod(int(sec_midn()),60).eq.0) go to 2
|
||||||
|
call sleep_msec(100)
|
||||||
|
go to 1
|
||||||
|
endif
|
||||||
|
|
||||||
|
2 fname="all.tf2"//char(0)
|
||||||
userx_no=0
|
userx_no=0
|
||||||
iusb=1
|
iusb=1
|
||||||
center_freq=144.125d0
|
center_freq=144.125d0
|
||||||
@ -50,10 +57,9 @@ program plrs
|
|||||||
do iter=1,iters
|
do iter=1,iters
|
||||||
fd=open(fname,RMODE) !Open file for reading
|
fd=open(fname,RMODE) !Open file for reading
|
||||||
dmsec=-dtmspacket
|
dmsec=-dtmspacket
|
||||||
nsec0=time()
|
nsec0=sec_midn()
|
||||||
|
|
||||||
do ifile=1,nfiles
|
do ifile=1,nfiles
|
||||||
print*,'Reading file',ifile
|
|
||||||
ns0=0
|
ns0=0
|
||||||
tmsec=1000*(3600*7 + 60*nm(ifile))-dtmspacket
|
tmsec=1000*(3600*7 + 60*nm(ifile))-dtmspacket
|
||||||
nr=read(fd,d,NBYTES)
|
nr=read(fd,d,NBYTES)
|
||||||
@ -77,14 +83,14 @@ program plrs
|
|||||||
npkt=npkt+1
|
npkt=npkt+1
|
||||||
|
|
||||||
if(mod(npkt,100).eq.0) then
|
if(mod(npkt,100).eq.0) then
|
||||||
nsec=time()-nsec0
|
nsec=int(sec_midn())-nsec0
|
||||||
nwait=msec-1000*nsec
|
nwait=msec-1000*nsec
|
||||||
! Pace the data at close to its real-time rate
|
! Pace the data at close to its real-time rate
|
||||||
if(nwait.gt.0 .and. .not.fast) call usleep(nwait*1000)
|
if(nwait.gt.0 .and. .not.fast) call usleep(nwait*1000)
|
||||||
endif
|
endif
|
||||||
ns=mod(msec2/1000,60)
|
ns=mod(msec2/1000,60)
|
||||||
if(ns.ne.ns0) write(*,1010) npkt,ns,0.001*msec2,nwait
|
if(ns.ne.ns0) write(*,1010) ns,center_freq,0.001*msec2,sec_midn()
|
||||||
1010 format('npkt:',i10,' ns:',i6,' t:',f10.3,' nwait:',i8)
|
1010 format('ns:',i3,' f0:',f10.3,' t1:',f10.3,' t2:',f10.3)
|
||||||
ns0=ns
|
ns0=ns
|
||||||
enddo
|
enddo
|
||||||
if(pause) then
|
if(pause) then
|
||||||
|
Loading…
x
Reference in New Issue
Block a user