mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2024-11-25 13:48:42 -05:00
Implement AP for all contest modes and also for Hound mode. AP is always active for Hounds. AP is automatically disabled if MyCall or DxCall are extended callsigns.
This commit is contained in:
parent
0b3b050221
commit
4b54873c81
@ -23,7 +23,8 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, &
|
||||
real dd0(15*12000)
|
||||
integer*1 message77(77),apmask(174),cw(174)
|
||||
integer apsym(58)
|
||||
integer mcq(29),mcqru(29),mcqfd(29),mrrr(19),m73(19),mrr73(19)
|
||||
integer mcq(29),mcqru(29),mcqfd(29),mcqtest(29),mcqhund(29)
|
||||
integer mrrr(19),m73(19),mrr73(19)
|
||||
integer itone(NN)
|
||||
integer icos7(0:6),ip(1)
|
||||
integer nappasses(0:5) !Number of decoding passes to use for each QSO state
|
||||
@ -38,12 +39,14 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, &
|
||||
complex cs(0:7,NN)
|
||||
logical first,newdat,lsubtract,lapon,lapcqonly,nagain,unpk77_success
|
||||
data icos7/3,1,4,0,6,5,2/ ! Flipped w.r.t. original FT8 sync array
|
||||
data mcq/0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0/
|
||||
data mcqru/0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,1,1,0,0,1,1,0,0/
|
||||
data mcqfd/0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,1,0,0,1,0,0,0,1,0/
|
||||
data mrrr/0,1,1,1,1,1,1,0,1,0,0,1,0,0,1,0,0,0,1/
|
||||
data m73/0,1,1,1,1,1,1,0,1,0,0,1,0,1,0,0,0,0,1/
|
||||
data mrr73/0,1,1,1,1,1,1,0,0,1,1,1,0,1,0,1,0,0,1/
|
||||
data mcq/0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0/
|
||||
data mcqru/0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,1,1,1,1,0,0,1,1,0,0/
|
||||
data mcqfd/0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,1,0,0,1,0,0,1,0,0,0,1,0/
|
||||
data mcqtest/0,0,0,0,0,0,0,0,0,1,1,0,0,0,0,1,0,1,0,1,1,1,1,1,1,0,0,1,0/
|
||||
data mcqhund/0,0,0,0,0,0,0,0,0,0,1,0,1,0,1,0,1,0,0,0,0,1,0,0,1,1,1,0,0/
|
||||
data mrrr/0,1,1,1,1,1,1,0,1,0,0,1,0,0,1,0,0,0,1/
|
||||
data m73/0,1,1,1,1,1,1,0,1,0,0,1,0,1,0,0,0,0,1/
|
||||
data mrr73/0,1,1,1,1,1,1,0,0,1,1,1,0,1,0,1,0,0,1/
|
||||
data first/.true./
|
||||
data graymap/0,1,3,2,5,6,4,7/
|
||||
save nappasses,naptypes,ncontest0,one,hiscall12_0
|
||||
@ -51,7 +54,10 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, &
|
||||
|
||||
if(first.or.(ncontest.ne.ncontest0)) then
|
||||
mcq=2*mcq-1
|
||||
mcqfd=2*mcqfd-1
|
||||
mcqru=2*mcqru-1
|
||||
mcqtest=2*mcqtest-1
|
||||
mcqhund=2*mcqhund-1
|
||||
mrrr=2*mrrr-1
|
||||
m73=2*m73-1
|
||||
mrr73=2*mrr73-1
|
||||
@ -243,7 +249,7 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, &
|
||||
! 6 ap pass 3
|
||||
! 7 ap pass 4
|
||||
|
||||
if(lapon) then
|
||||
if(lapon.or.ncontest.eq.6) then !Hounds always use AP
|
||||
if(.not.lapcqonly) then
|
||||
npasses=3+nappasses(nQSOProgress)
|
||||
else
|
||||
@ -269,10 +275,6 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, &
|
||||
else
|
||||
iaptype=1
|
||||
endif
|
||||
if(iaptype.ge.2 .and. apsym(1).gt.1) cycle ! no mycall was entered
|
||||
if(iaptype.ge.3 .and. apsym(30).gt.1) cycle ! no, or nonstandard dxcall
|
||||
if(iaptype.ge.3 .and. (abs(f1-nfqso).gt.napwid .and. abs(f1-nftx).gt.napwid) ) cycle
|
||||
apsym=2*apsym-1
|
||||
|
||||
! ncontest=0 : NONE
|
||||
! 1 : NA_VHF
|
||||
@ -281,17 +283,24 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, &
|
||||
! 4 : RTTY
|
||||
! 5 : FOX
|
||||
! 6 : HOUND
|
||||
!
|
||||
! Conditions that cause us to bail out of AP decoding
|
||||
if(ncontest.le.4 .and. iaptype.ge.3 .and. (abs(f1-nfqso).gt.napwid .and. abs(f1-nftx).gt.napwid) ) cycle
|
||||
if(ncontest.eq.5) cycle ! No AP for Foxes
|
||||
if(ncontest.eq.6.and.f1.gt.950.0) cycle ! Hounds use AP only for signals below 950 Hz
|
||||
if(iaptype.ge.2 .and. apsym(1).gt.1) cycle ! No, or nonstandard, mycall
|
||||
if(iaptype.ge.3 .and. apsym(30).gt.1) cycle ! No, or nonstandard, dxcall
|
||||
apsym=2*apsym-1 ! Change from [0,1] to antipodal
|
||||
|
||||
if(iaptype.eq.1.and.ncontest.eq.5) cycle
|
||||
|
||||
if(iaptype.eq.1) then ! CQ,???,??? or CQ RU,???,???
|
||||
if(iaptype.eq.1) then ! CQ or CQ RU or CQ TEST or CQ FD
|
||||
apmask=0
|
||||
apmask(1:29)=1
|
||||
if( ncontest.eq.0.or.ncontest.eq.1 &
|
||||
.or.ncontest.eq.2.or.ncontest.eq.6 ) &
|
||||
llrd(1:29)=apmag*mcq(1:29)
|
||||
if( ncontest.eq.3) llrd(1:29)=apmag*mcqfd(1:29)
|
||||
if( ncontest.eq.4) llrd(1:29)=apmag*mcqru(1:29)
|
||||
if(ncontest.eq.0) llrd(1:29)=apmag*mcq(1:29)
|
||||
if(ncontest.eq.1) llrd(1:29)=apmag*mcqtest(1:29)
|
||||
if(ncontest.eq.2) llrd(1:29)=apmag*mcqtest(1:29)
|
||||
if(ncontest.eq.3) llrd(1:29)=apmag*mcqfd(1:29)
|
||||
if(ncontest.eq.4) llrd(1:29)=apmag*mcqru(1:29)
|
||||
if(ncontest.eq.6) llrd(1:29)=apmag*mcqhund(1:29)
|
||||
apmask(75:77)=1
|
||||
llrd(75:76)=apmag*(-1)
|
||||
llrd(77)=apmag*(+1)
|
||||
@ -299,15 +308,24 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, &
|
||||
|
||||
if(iaptype.eq.2) then ! MyCall,???,???
|
||||
apmask=0
|
||||
if(ncontest.ge.0.and.ncontest.le.2.or.ncontest.ge.5) then
|
||||
if(ncontest.eq.0.or.ncontest.eq.1) then
|
||||
apmask(1:29)=1
|
||||
llrd(1:29)=apmag*apsym(1:29)
|
||||
apmask(75:77)=1
|
||||
llrd(75:76)=apmag*(-1)
|
||||
llrd(77)=apmag*(+1)
|
||||
else if(ncontest.eq.2) then
|
||||
apmask(1:28)=1
|
||||
llrd(1:28)=apmag*apsym(1:28)
|
||||
apmask(72:74)=1
|
||||
llrd(72)=apmag*(-1)
|
||||
llrd(73)=apmag*(+1)
|
||||
llrd(74)=apmag*(-1)
|
||||
apmask(75:77)=1
|
||||
llrd(75:77)=apmag*(-1)
|
||||
else if(ncontest.eq.3) then
|
||||
apmask(1:28)=1
|
||||
llrd(1:28)=apmag*apsym(2:29)
|
||||
llrd(1:28)=apmag*apsym(1:28)
|
||||
apmask(75:77)=1
|
||||
llrd(75:77)=apmag*(-1)
|
||||
else if(ncontest.eq.4) then
|
||||
@ -316,12 +334,19 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, &
|
||||
apmask(75:77)=1
|
||||
llrd(75)=apmag*(-1)
|
||||
llrd(76:77)=apmag*(+1)
|
||||
else if(ncontest.eq.6) then ! ??? RR73; MyCall <???> ???
|
||||
apmask(29:56)=1
|
||||
llrd(29:56)=apmag*apsym(1:28)
|
||||
apmask(72:77)=1
|
||||
llrd(72:73)=apmag*(-1)
|
||||
llrd(74)=apmag*(+1)
|
||||
llrd(75:77)=apmag*(-1)
|
||||
endif
|
||||
endif
|
||||
|
||||
if(iaptype.eq.3) then ! MyCall,DxCall,???
|
||||
apmask=0
|
||||
if(ncontest.eq.0.or.ncontest.eq.1.or.ncontest.eq.2) then
|
||||
if(ncontest.eq.0.or.ncontest.eq.1.or.ncontest.eq.2.or.ncontest.eq.6) then
|
||||
apmask(1:58)=1
|
||||
llrd(1:58)=apmag*apsym
|
||||
apmask(75:77)=1
|
||||
@ -331,6 +356,7 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, &
|
||||
apmask(1:56)=1
|
||||
llrd(1:28)=apmag*apsym(1:28)
|
||||
llrd(29:56)=apmag*apsym(30:57)
|
||||
apmask(72:74)=1
|
||||
apmask(75:77)=1
|
||||
llrd(75:77)=apmag*(-1)
|
||||
else if(ncontest.eq.4) then ! RTTY RU
|
||||
@ -342,24 +368,22 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, &
|
||||
llrd(76:77)=apmag*(+1)
|
||||
endif
|
||||
endif
|
||||
|
||||
if(iaptype.ge.4.and.ncontest.eq.5) cycle !Fox doesn't care
|
||||
if(iaptype.ge.5.and.ncontest.eq.6) cycle !Hound
|
||||
|
||||
if(iaptype.eq.5.and.ncontest.eq.6) cycle !Hound
|
||||
if(iaptype.eq.4 .or. iaptype.eq.5 .or. iaptype.eq.6) then
|
||||
apmask=0
|
||||
if(ncontest.le.4) then
|
||||
if(ncontest.le.4 .or. (ncontest.eq.6.and.iaptype.eq.6)) then
|
||||
apmask(1:77)=1 ! mycall, hiscall, RRR|73|RR73
|
||||
llrd(1:58)=apmag*apsym
|
||||
if(iaptype.eq.4) llrd(59:77)=apmag*mrrr
|
||||
if(iaptype.eq.5) llrd(59:77)=apmag*m73
|
||||
if(iaptype.eq.6) llrd(59:77)=apmag*mrr73
|
||||
else if(ncontest.eq.6) then ! Hound listens for MyCall RR73;...
|
||||
else if(ncontest.eq.6.and.iaptype.eq.4) then ! Hound listens for MyCall RR73;...
|
||||
apmask(1:28)=1
|
||||
llrd(1:28)=apmag*apsym(1:28)
|
||||
apmask(72:77)=1
|
||||
llrd(72)=apmag*(-1)
|
||||
llrd(73:74)=apmag*(1)
|
||||
llrd(72:73)=apmag*(-1)
|
||||
llrd(74)=apmag*(1)
|
||||
llrd(75:77)=apmag*(-1)
|
||||
endif
|
||||
endif
|
||||
@ -417,7 +441,6 @@ subroutine ft8b_2(dd0,newdat,nQSOProgress,nfqso,nftx,ndepth,lapon,lapcqonly, &
|
||||
if(arg.gt.0.1) xsnr2=arg
|
||||
xsnr=10.0*log10(xsnr)-27.0
|
||||
xsnr2=10.0*log10(xsnr2)-27.0
|
||||
!write(87,'(f10.1,2x,f10.1)') xsnr,xsnr2
|
||||
if(.not.nagain) then
|
||||
xsnr=xsnr2
|
||||
endif
|
||||
|
@ -131,9 +131,6 @@ contains
|
||||
hd=nharderrors+dmin
|
||||
call timer('ft8b ',1)
|
||||
if(nbadcrc.eq.0) then
|
||||
! call jtmsg(message,iflag)
|
||||
! This probably needs to be re-visited for the new message type
|
||||
! if(iand(iflag,31).ne.0) message(22:22)='?'
|
||||
ldupe=.false.
|
||||
do id=1,ndecodes
|
||||
if(msg37.eq.allmessages(id).and.nsnr.le.allsnrs(id)) ldupe=.true.
|
||||
|
Loading…
Reference in New Issue
Block a user