mirror of
				https://github.com/f4exb/sdrangel.git
				synced 2025-11-03 13:11:20 -05:00 
			
		
		
		
	SDRdaemon plugin: use a fixed time bound raw buffer of 8 seconds
This commit is contained in:
		
							parent
							
								
									17d58ba2a5
								
							
						
					
					
						commit
						d5f65a7e39
					
				@ -25,7 +25,7 @@
 | 
			
		||||
const int SDRdaemonBuffer::m_udpPayloadSize = 512;
 | 
			
		||||
const int SDRdaemonBuffer::m_sampleSize = 2;
 | 
			
		||||
const int SDRdaemonBuffer::m_iqSampleSize = 2 * m_sampleSize;
 | 
			
		||||
const int SDRdaemonBuffer::m_rawBufferLengthSeconds = 4; // should be even
 | 
			
		||||
const int SDRdaemonBuffer::m_rawBufferLengthSeconds = 8; // should be even
 | 
			
		||||
 | 
			
		||||
SDRdaemonBuffer::SDRdaemonBuffer(uint32_t throttlems) :
 | 
			
		||||
	m_throttlemsNominal(throttlems),
 | 
			
		||||
@ -88,10 +88,6 @@ void SDRdaemonBuffer::updateBufferSize(uint32_t sampleRate)
 | 
			
		||||
{
 | 
			
		||||
	uint32_t rawSize = sampleRate * m_iqSampleSize * m_rawBufferLengthSeconds; // store worth of this seconds of samples at this sample rate
 | 
			
		||||
 | 
			
		||||
	if (rawSize < (1<<24)) {
 | 
			
		||||
		rawSize = (1<<24);
 | 
			
		||||
	}
 | 
			
		||||
 | 
			
		||||
	if (rawSize != m_rawSize)
 | 
			
		||||
	{
 | 
			
		||||
		m_rawSize = rawSize;
 | 
			
		||||
 | 
			
		||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user