I'm trying to translate the help file for logic analyzer.
And I'm not sure what "base time step" does.
It's mapped to variable "m_timeStep", which is used to calcuate a count "lastime". ( In LAnalyzer::dump() )
And lasttime is used to control the samples retrieved from the channel's buffer.
What I'm not sure here is that, if the buffer's sample rate is not equal to m_timeStep ("base time step") , is the data retrieve count is correctly calculated?
And I'm not sure what "base time step" does.
It's mapped to variable "m_timeStep", which is used to calcuate a count "lastime". ( In LAnalyzer::dump() )
- Code:
uint64_t lastTime = (endTime-startTime)/m_timeStep;
And lasttime is used to control the samples retrieved from the channel's buffer.
- Code:
for( int i=0; i<m_bufferSize; ++i )
{
index++;
double val = m_channel[ch]->m_buffer[index];
uint64_t time = m_channel[ch]->m_time[index];
......
time = (time-startTime)/m_timeStep;
......
samples.insert( time, { val, ch } );
if( time == lastTime ) break; // All samples before endTime already registered
}
What I'm not sure here is that, if the buffer's sample rate is not equal to m_timeStep ("base time step") , is the data retrieve count is correctly calculated?