mirror of
				https://github.com/saitohirga/WSJT-X.git
				synced 2025-10-31 13:10:19 -04:00 
			
		
		
		
	Tweaking msk32 decoder.
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@6875 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
		
							parent
							
								
									d987f8c507
								
							
						
					
					
						commit
						73c5fef39b
					
				| @ -108,7 +108,7 @@ subroutine detectmsk32(cbig,n,lines,nmessages,nutc) | |||||||
|     likelymessages(irpt)=ig |     likelymessages(irpt)=ig | ||||||
| !    write(*,*) hashmsg,ig,ig24(ig) | !    write(*,*) hashmsg,ig,ig24(ig) | ||||||
|   enddo   |   enddo   | ||||||
|   qsocontext=.true. |   qsocontext=.false. | ||||||
| 
 | 
 | ||||||
|   ! fill the detmet, detferr arrays |   ! fill the detmet, detferr arrays | ||||||
|   nstepsize=48  ! 4ms steps |   nstepsize=48  ! 4ms steps | ||||||
| @ -225,7 +225,7 @@ subroutine detectmsk32(cbig,n,lines,nmessages,nutc) | |||||||
|     ddr=abs(ccr1)*abs(ccr2) |     ddr=abs(ccr1)*abs(ccr2) | ||||||
|     crmax=maxval(abs(ccr)) |     crmax=maxval(abs(ccr)) | ||||||
| 
 | 
 | ||||||
| ! Find 3 largest peaks | ! Find 6 largest peaks | ||||||
|     do ipk=1,6 |     do ipk=1,6 | ||||||
|       iloc=maxloc(abs(ccr)) |       iloc=maxloc(abs(ccr)) | ||||||
|       ic1=iloc(1) |       ic1=iloc(1) | ||||||
| @ -235,7 +235,7 @@ subroutine detectmsk32(cbig,n,lines,nmessages,nutc) | |||||||
|       ccr(max(1,ic1-7):min(NPTS-32*6-41,ic1+7))=0.0 |       ccr(max(1,ic1-7):min(NPTS-32*6-41,ic1+7))=0.0 | ||||||
|     enddo |     enddo | ||||||
| 
 | 
 | ||||||
|     do ipk=1,6 |     do ipk=1,2 | ||||||
| 
 | 
 | ||||||
| ! we want ic to be the index of the first sample of the frame | ! we want ic to be the index of the first sample of the frame | ||||||
|       ic0=ipeaks(ipk) |       ic0=ipeaks(ipk) | ||||||
| @ -279,7 +279,7 @@ subroutine detectmsk32(cbig,n,lines,nmessages,nutc) | |||||||
| ! Final estimate of the carrier frequency - returned to the calling program | ! Final estimate of the carrier frequency - returned to the calling program | ||||||
|         fest=1500+ferr+ferr2  |         fest=1500+ferr+ferr2  | ||||||
| 
 | 
 | ||||||
|         do idf=0,10   ! frequency jitter |         do idf=0,6                         ! frequency jitter | ||||||
|           if( idf .eq. 0 ) then |           if( idf .eq. 0 ) then | ||||||
|             deltaf=0.0 |             deltaf=0.0 | ||||||
|           elseif( mod(idf,2) .eq. 0 ) then |           elseif( mod(idf,2) .eq. 0 ) then | ||||||
| @ -294,7 +294,7 @@ subroutine detectmsk32(cbig,n,lines,nmessages,nutc) | |||||||
| ! place the beginning of frame at index NSPM+1 | ! place the beginning of frame at index NSPM+1 | ||||||
|           cdat2=cshift(cdat2,ic-(NSPM+1)) |           cdat2=cshift(cdat2,ic-(NSPM+1)) | ||||||
| 
 | 
 | ||||||
|           do iav=1,8 ! Hopefully we can eliminate some of these after looking at more examples  |           do iav=1,8 ! Frame averaging patterns  | ||||||
|             if( iav .eq. 1 ) then |             if( iav .eq. 1 ) then | ||||||
|               c=cdat2(NSPM+1:2*NSPM)   |               c=cdat2(NSPM+1:2*NSPM)   | ||||||
|             elseif( iav .eq. 2 ) then |             elseif( iav .eq. 2 ) then | ||||||
| @ -397,7 +397,8 @@ subroutine detectmsk32(cbig,n,lines,nmessages,nutc) | |||||||
|             iloc=minloc(cd) |             iloc=minloc(cd) | ||||||
|             imsg2=iloc(1)-1 |             imsg2=iloc(1)-1 | ||||||
|             cdrat=cdm2/(cdm+0.001) |             cdrat=cdm2/(cdm+0.001) | ||||||
|             if( cdrat .gt. cdratbest ) then | !            if( cdrat .gt. cdratbest ) then | ||||||
|  |             if( cdm .lt. cdbest ) then | ||||||
|               cdratbest = cdrat |               cdratbest = cdrat | ||||||
|               cdbest = cdm |               cdbest = cdm | ||||||
|               imsgbest = imsg |               imsgbest = imsg | ||||||
| @ -407,7 +408,7 @@ subroutine detectmsk32(cbig,n,lines,nmessages,nutc) | |||||||
|               idfbest = idf |               idfbest = idf | ||||||
|               idbest = id |               idbest = id | ||||||
|               nbadsyncbest = nbadsync |               nbadsyncbest = nbadsync | ||||||
|               if( ( ihammd(imsgbest)+nbadsyncbest  .le. 5 )  .and. ( (cdratbest .gt. 1000.0) .or. (cdbest .eq. 0.0) ) ) goto 999 |               if( ( ihammd(imsgbest)+nbadsyncbest  .le. 4 )  .and. ( (cdratbest .gt. 100.0) .and. (cdbest .le. 0.05) ) ) goto 999 | ||||||
|             endif |             endif | ||||||
| 
 | 
 | ||||||
|           enddo ! frame averaging loop |           enddo ! frame averaging loop | ||||||
| @ -423,7 +424,7 @@ subroutine detectmsk32(cbig,n,lines,nmessages,nutc) | |||||||
|   enddo |   enddo | ||||||
| 999 continue | 999 continue | ||||||
|   if( imsgbest .ge. 0 ) then |   if( imsgbest .ge. 0 ) then | ||||||
|     if(ihammd(imsgbest)+nbadsyncbest .le. 5) then |     if( ( ihammd(imsgbest)+nbadsyncbest  .le. 4 )  .and. ( (cdratbest .gt. 50.0) .and. (cdbest .le. 0.05) ) ) then | ||||||
|       if( qsocontext ) then |       if( qsocontext ) then | ||||||
|         nrxrpt=iand(likelymessages(imsgbest),31) |         nrxrpt=iand(likelymessages(imsgbest),31) | ||||||
|         nrxhash=(likelymessages(imsgbest)-nrxrpt)/32 |         nrxhash=(likelymessages(imsgbest)-nrxrpt)/32 | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user