mirror of
				https://github.com/saitohirga/WSJT-X.git
				synced 2025-10-31 04:50:34 -04:00 
			
		
		
		
	It's basically working with multicast data now ...
git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/map65@396 ab8295b8-cf94-4d9e-aec4-7959e3be5d79
This commit is contained in:
		
							parent
							
								
									d9e8ad5d65
								
							
						
					
					
						commit
						2d27f21d31
					
				| @ -3,8 +3,8 @@ subroutine audio_init(ndin,ndout) | ||||
| 
 | ||||
| #ifdef Win32 | ||||
|   use dfmt | ||||
|   integer Thread1,Thread2 | ||||
|   external a2d,decode1 | ||||
|   integer Thread1,Thread2,Thread3 | ||||
|   external a2d,decode1,recvpkt | ||||
| #endif | ||||
| 
 | ||||
|   include 'gcom1.f90' | ||||
| @ -44,8 +44,10 @@ subroutine audio_init(ndin,ndout) | ||||
| !     THREAD_PRIORITY_TIME_CRITICAL     15 | ||||
|      | ||||
|   m0=SetPriorityClass(GetCurrentProcess(),NORMAL_PRIORITY_CLASS) | ||||
| !  m0=SetPriorityClass(GetCurrentProcess(),HIGH_PRIORITY_CLASS) | ||||
| 
 | ||||
| ! Start a thread for doing A/D and D/A with sound card. | ||||
| !  (actually, only D/A is used in MAP65) | ||||
|   Thread1=CreateThread(0,0,a2d,0,CREATE_SUSPENDED,id1) | ||||
|   m1=SetThreadPriority(Thread1,THREAD_PRIORITY_ABOVE_NORMAL) | ||||
|   m2=ResumeThread(Thread1) | ||||
| @ -54,6 +56,12 @@ subroutine audio_init(ndin,ndout) | ||||
|   Thread2=CreateThread(0,0,decode1,0,CREATE_SUSPENDED,id2) | ||||
|   m3=SetThreadPriority(Thread2,THREAD_PRIORITY_BELOW_NORMAL) | ||||
|   m4=ResumeThread(Thread2) | ||||
| 
 | ||||
| ! Start a thread to receive packets from Linrad | ||||
|   Thread3=CreateThread(0,0,recvpkt,0,CREATE_SUSPENDED,id3) | ||||
|   m5=SetThreadPriority(Thread3,THREAD_PRIORITY_ABOVE_NORMAL) | ||||
|   m6=ResumeThread(Thread3) | ||||
| 
 | ||||
| #else | ||||
| !  print*,'Audio INIT called.' | ||||
|   ierr=start_threads(ndevin,ndevout,y1,y2,nmax,iwrite,iwave,nwave,    & | ||||
|  | ||||
| @ -9,10 +9,8 @@ subroutine decode1(iarg) | ||||
| 
 | ||||
|   character sending0*28,mode0*6,cshort*11 | ||||
|   integer sendingsh0 | ||||
|   character*80 fname80 | ||||
|   parameter (NSMAX=60*96000)          !Samples per 60 s file | ||||
|   integer*2 id(4,NSMAX)               !46 MB: raw data from Linrad timf2 | ||||
|   common/datcom/nutc,newdat2,id,fname80,nlen | ||||
| 
 | ||||
|   include 'datcom.f90' | ||||
|   include 'gcom1.f90' | ||||
|   include 'gcom2.f90' | ||||
|   include 'gcom3.f90' | ||||
|  | ||||
| @ -1,10 +1,8 @@ | ||||
| !----------------------------------------------------- getfile | ||||
| subroutine getfile(fname,len) | ||||
|   character*(*) fname | ||||
|   character*80 fname80 | ||||
|   parameter (NSMAX=60*96000)          !Samples per 60 s file | ||||
|   integer*2 id(4,NSMAX)               !46 MB: raw data from Linrad timf2 | ||||
|   common/datcom/nutc,newdat2,id,fname80,nlen | ||||
| 
 | ||||
|   include 'datcom.f90' | ||||
|   include 'gcom2.f90' | ||||
| 
 | ||||
|   fname80=fname | ||||
|  | ||||
| @ -7,9 +7,8 @@ subroutine getfile2(fname,len) | ||||
|   parameter (NDMAX=661500)  ! =60*11025 | ||||
|   character*(*) fname | ||||
|   character infile*15 | ||||
|   parameter (NSMAX=60*96000)          !Samples per 60 s file | ||||
|   integer*2 id(4,NSMAX)               !46 MB: raw data from Linrad timf2 | ||||
|   common/datcom/nutc,newdat2,id | ||||
| 
 | ||||
|   include 'datcom.f90' | ||||
|   include 'gcom1.f90' | ||||
|   include 'gcom2.f90' | ||||
|   include 'gcom4.f90' | ||||
|  | ||||
							
								
								
									
										18
									
								
								map65a.f90
									
									
									
									
									
								
							
							
						
						
									
										18
									
								
								map65a.f90
									
									
									
									
									
								
							| @ -16,16 +16,16 @@ subroutine map65a | ||||
|   integer indx(MAXMSG),nsiz(MAXMSG) | ||||
|   logical done(MAXMSG) | ||||
|   character decoded*22,blank*22 | ||||
|   parameter (NSMAX=60*96000)          !Samples per 60 s file | ||||
|   integer*2 id(4,NSMAX)               !46 MB: raw data from Linrad timf2 | ||||
|   common/datcom/nutc,newdat2,id | ||||
|   include 'datcom.f90' | ||||
|   common/spcom/ip0,ss(4,322,NFFT),ss5(322,NFFT) | ||||
|   data blank/'                      '/ | ||||
|   data shmsg0/'ATT','RO ','RRR','73 '/ | ||||
|   data nfile/0/,nutc0/-999/,nid/0/ | ||||
|   include 'gcom2.f90' | ||||
|   save | ||||
| 
 | ||||
|   include 'gcom2.f90' | ||||
| !  print*,'A',newdat2,nutc,nfile | ||||
|   if(newdat2.eq.0) newdat2=1                      !### | ||||
| 
 | ||||
|   if(newdat2.gt.0) nid=1 | ||||
|   if(nid.eq.0) go to 999 | ||||
| @ -70,8 +70,15 @@ subroutine map65a | ||||
|      nfilt=2                      !nfilt=2 is faster for selected freq | ||||
|      freq=fselect | ||||
|      dt=2.314240                  !Not needed? | ||||
| !     print*,'B',newdat2,nfilt,freq,nflip,ip0 | ||||
| 
 | ||||
|       write(*,3001) newdat2,nfilt,nflip,ip0,freq,               & | ||||
|            (id(1,i),id(2,i),id(3,i),id(4,i),i=1,2) | ||||
|  3001 format(4i5,f10.3,8i5) | ||||
| 
 | ||||
|      call decode1a(id,newdat2,nfilt,freq,nflip,ip0,sync2,        & | ||||
|           a,dt,pol,nkv,nhist,qual,decoded) | ||||
| !     print*,'C',nkv,qual,decoded | ||||
|      nsync1=0 | ||||
|      nsync2=nint(10.0*log10(sync2)) - 40 !### empirical ### | ||||
|      ndf=nint(a(1)) | ||||
| @ -291,5 +298,6 @@ subroutine map65a | ||||
|   call display | ||||
|   ndecdone=2 | ||||
|      | ||||
| 999 return | ||||
| 999 newdat2=0 | ||||
|   return | ||||
| end subroutine map65a | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user