|  | @@ -160,7 +160,7 @@ DWORD CSATDevices::WorkThread(LPVOID lpVoid)
 | 
	
		
			
				|  |  |  			else
 | 
	
		
			
				|  |  |  				it++;
 | 
	
		
			
				|  |  |  		}
 | 
	
		
			
				|  |  | -	} while (WaitForSingleObject(that->m_hEvent, 1000) == WAIT_TIMEOUT);
 | 
	
		
			
				|  |  | +	} while (WaitForSingleObject(that->m_hEvent, 2500) == WAIT_TIMEOUT);
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  	printf("end thread\n");
 | 
	
		
			
				|  |  |  	return 0;
 | 
	
	
		
			
				|  | @@ -192,6 +192,7 @@ void CSATDevices::AddReticleDevices(std::string ip)
 | 
	
		
			
				|  |  |  	stDevice.nType = Reticle;
 | 
	
		
			
				|  |  |  	stDevice.strName = ip;
 | 
	
		
			
				|  |  |  	stDevice.ulOfflineTime = 0;
 | 
	
		
			
				|  |  | +	stDevice.nStatus = 0;
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  	AutoThreadSection ats(&s_ThreadSection);
 | 
	
		
			
				|  |  |  	if (!IsDeviceExist(stDevice))
 | 
	
	
		
			
				|  | @@ -204,6 +205,7 @@ void CSATDevices::AddVirtualDevices(std::string name)
 | 
	
		
			
				|  |  |  	stDevice.nType = Virtual;
 | 
	
		
			
				|  |  |  	stDevice.strName = name;
 | 
	
		
			
				|  |  |  	stDevice.ulOfflineTime = 0;
 | 
	
		
			
				|  |  | +	stDevice.nStatus = 0;
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  	AutoThreadSection ats(&s_ThreadSection);
 | 
	
		
			
				|  |  |  	if (!IsDeviceExist(stDevice))
 | 
	
	
		
			
				|  | @@ -360,14 +362,16 @@ void CSATDevices::ReConnectAllDevices()
 | 
	
		
			
				|  |  |  	}
 | 
	
		
			
				|  |  |  }
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  | -int CSATDevices::AttachDeviceName2Buffer(char (&pbuff)[30][MAX_PATH])
 | 
	
		
			
				|  |  | +int CSATDevices::AttachDeviceName2Buffer(SATProtocol::Device (&pbuff)[30])
 | 
	
		
			
				|  |  |  {
 | 
	
		
			
				|  |  |  	int count = 0;
 | 
	
		
			
				|  |  |  	if ( pbuff ) {
 | 
	
		
			
				|  |  |  		std::string str;
 | 
	
		
			
				|  |  |  		std::vector<STDevice>::iterator it = s_vtDevices.begin();
 | 
	
		
			
				|  |  |  		for ( ;it != s_vtDevices.end(); it++ ) {
 | 
	
		
			
				|  |  | -			memcpy_s(pbuff[count++], MAX_PATH, it->strName.c_str(), it->strName.size());
 | 
	
		
			
				|  |  | +			pbuff[count].nType = it->nType;
 | 
	
		
			
				|  |  | +			pbuff[count].nStatus = it->nStatus;
 | 
	
		
			
				|  |  | +			memcpy_s(pbuff[count++].szName, MAX_PATH, it->strName.c_str(), it->strName.size());
 | 
	
		
			
				|  |  |  			// ³¬¹ý30Í˳ö;
 | 
	
		
			
				|  |  |  			if ( count == 30)
 | 
	
		
			
				|  |  |  				break;
 |