Scope: updated documentation and fixed live rate setting when a decimation takes place

pull/263/head
f4exb 2018-10-20 10:41:49 +02:00
rodzic 8836b98542
commit fac0e652c4
7 zmienionych plików z 28 dodań i 6 usunięć

Plik binarny nie jest wyświetlany.

Przed

Szerokość:  |  Wysokość:  |  Rozmiar: 14 KiB

Po

Szerokość:  |  Wysokość:  |  Rozmiar: 16 KiB

Plik binarny nie jest wyświetlany.

Wyświetl plik

@ -462,7 +462,7 @@ void ChannelAnalyzerGUI::setNewFinalRate()
QString s = QString::number(m_rate/1000.0, 'f', 1);
ui->spanText->setText(tr("%1 kS/s").arg(s));
m_scopeVis->setLiveRate(m_rate);
m_scopeVis->setLiveRate(getRequestedChannelSampleRate());
}
void ChannelAnalyzerGUI::setFiltersUIBoundaries()
@ -547,6 +547,8 @@ void ChannelAnalyzerGUI::applySettings(bool force)
ChannelAnalyzer::MsgConfigureChannelAnalyzer* message =
ChannelAnalyzer::MsgConfigureChannelAnalyzer::create( m_settings, force);
m_channelAnalyzer->getInputMessageQueue()->push(message);
m_scopeVis->setLiveRateLog2Decim(m_settings.m_spanLog2);
}
}

Wyświetl plik

@ -321,12 +321,22 @@ By default the trace display is enabled and this checkbox is checked. You can op
This area shows the current trace color. When clicking on it a color chooser dialog appears that lets you change the color of the current trace
<h3>11. Memory select</h3>
<h3>11. Save traces in memory</h3>
The last 15 traces are stored in memory and this button lets you browse through traces in memory. The memory index appears on the left of the button. Traces in memory are sorted from latest (1) to oldest (15). The memory index 0 is the current live trace. When indexes > 0 are selected the live trace is suspended.
While in memory mode (see E.13 next) use this button to save the bank of traces in memory (50 last traces) to file. A file dialog will open to let you choose the file name and locaion. By default the file extension is `.trcm`.
<h3>12. Load traces into memory</h3>
While in memory mode (see E.13 next) use this button to load traces previously saved to file using the (E.11) button into the traces memory bank (50 traces). A file dialog will open to let you select the file. It will look for files with `.trcm` extension by default.
<h3>13. Memory select</h3>
The last 50 traces are stored in memory and this button lets you browse through traces in memory. The memory index appears on the left of the button. Traces in memory are sorted from latest (1) to oldest (50). The memory index 0 is the current live trace. When indexes > 0 are selected the live trace is suspended.
It is the complex signal that is memorized actually so when a trace in memory is selected you can still use the global and trace controls to change the display. In particular the projection mode and the number of traces can be changed. Only the full trace length cannot be modified. When in memory mode the triggers are disabled since they only apply to a live trace.
While in memory trace the save (E.11) and load (E.12) traces to file buttons can be used.
<h2>F. Trigger control line</h2>
![Channel Analyzer NG plugin scope1 controls](../../../doc/img/ChAnalyzerNG_plugin_scope3.png)

Wyświetl plik

@ -55,6 +55,7 @@ ScopeVis::ScopeVis(GLScope* glScope) :
m_traceStart(true),
m_sampleRate(0),
m_liveSampleRate(0),
m_liveLog2Decim(0),
m_traceDiscreteMemory(m_nbTraceMemories),
m_freeRun(true),
m_maxTraceDelay(0),
@ -82,12 +83,19 @@ void ScopeVis::setLiveRate(int sampleRate)
m_liveSampleRate = sampleRate;
if (m_currentTraceMemoryIndex == 0) { // update only in live mode
setSampleRate(m_liveSampleRate);
setSampleRate(m_liveSampleRate/(1<<m_liveLog2Decim));
}
}
void ScopeVis::setLiveRateLog2Decim(int log2Decim)
{
m_liveLog2Decim = log2Decim;
setLiveRate(m_liveSampleRate);
}
void ScopeVis::setSampleRate(int sampleRate)
{
qDebug("ScopeVis::setSampleRate: %d S/s", sampleRate);
m_sampleRate = sampleRate;
if (m_glScope) {
@ -861,7 +869,7 @@ bool ScopeVis::handleMessage(const Message& message)
// transition to live mode
if (m_currentTraceMemoryIndex == 0)
{
setSampleRate(m_liveSampleRate); // reset to live rate
setLiveRate(m_liveSampleRate); // reset to live rate
setTraceSize(m_liveTraceSize, true); // reset to live trace size
setPreTriggerDelay(m_livePreTriggerDelay, true); // reset to live pre-trigger delay
}

Wyświetl plik

@ -153,6 +153,7 @@ public:
virtual ~ScopeVis();
void setLiveRate(int sampleRate);
void setLiveRateLog2Decim(int log2Decim);
void configure(uint32_t traceSize, uint32_t timeBase, uint32_t timeOfsProMill, uint32_t triggerPre, bool freeRun);
void addTrace(const TraceData& traceData);
void changeTrace(const TraceData& traceData, uint32_t traceIndex);
@ -1106,6 +1107,7 @@ private:
SampleVector::const_iterator m_triggerPoint; //!< Trigger start location in the samples vector
int m_sampleRate; //!< Actual sample rate being used
int m_liveSampleRate; //!< Sample rate in live mode
int m_liveLog2Decim; //!< Sample rate decimation log2 in live mode
TraceBackDiscreteMemory m_traceDiscreteMemory; //!< Complex trace memory for triggered states TODO: vectorize when more than on input is allowed
bool m_freeRun; //!< True if free running (trigger globally disabled)
int m_maxTraceDelay; //!< Maximum trace delay

Wyświetl plik

@ -284,7 +284,7 @@ This controls the decay rate of the stroke when phosphor display is engaged (4.C
<h4>4.8. Phosphor display stroke decay divisor</h4>
When phosphor display is engaged (4.C) and stroke decay is 1 (4.7) this divides the unit decay by this value by diminishing histogram pixel value by one each time a decay divisor of FFTs have been produced. So actual decay rate is 1 over this value.
When phosphor display is engaged (4.C) and stroke decay is 1 (4.7) this divides the unit decay by this value by diminishing histogram pixel value by one each time a number of FFTs equal to this number have been produced. Thus the actual decay rate is 1 over this value. This allow setting a slower decay rate than one unit for each new FFT.
<h4>4.9. Phosphor display stroke strength</h4>