1
0
mirror of https://github.com/f4exb/sdrangel.git synced 2024-12-17 23:28:50 -05:00

Changed scope trigger level scale and display

This commit is contained in:
f4exb 2015-07-26 10:35:57 +02:00
parent c36104708a
commit f06c8e1e58
3 changed files with 21 additions and 14 deletions

View File

@ -106,7 +106,7 @@ Done since the fork
- Make the low cutoff frequency of the SSB filter variable so it can be used for CW also.
- NFM demodulation without using atan and smooth squelch with AGC suppressing most clicks on low level signals and hiss on carrier tails. Only useful modulation comes through.
- Added working WFM demodulation. Optimized for no atan2.
- OsmoSDR and GNURAdio plugins removed from the build as they have too many bugs that are too difficult to correct
- OsmoSDR and GNURadio plugins removed from the build as they have too many bugs that are too difficult to correct
- New plugin for BladeRF interfacing libbladeRF directly
- Corrected the nasty audio band resampling bug preventing use of sample rates that are not power of 2 multiples of 48kHz. This was because the resampling ratio was calculated with an integer division instead of a float division.
- As a consequence of the above added more interesting values for the available sampling rates of the BladeRF plugin
@ -137,4 +137,5 @@ To Do
- Tx channels for Rx/Tx boards like BladeRF
- Enhance WFM (stereo, RDS?)
- Even more demods ...
- ASRP4 support

View File

@ -201,14 +201,14 @@ void GLScopeGUI::applyTriggerSettings()
quint32 preTriggerSamples = (m_glScope->getTraceSize() * m_triggerPre) / 100;
if (m_triggerChannel == ScopeVis::TriggerMagDb) {
triggerLevel = m_triggerLevel - 100.0;
triggerLevel = m_triggerLevel/10.0 - 100.0;
}
else {
triggerLevel = m_triggerLevel / 100.0;
triggerLevel = m_triggerLevel / 1000.0;
}
m_glScope->setTriggerChannel((ScopeVis::TriggerChannel) m_triggerChannel);
m_glScope->setTriggerLevel(m_triggerLevel / 100.0);
m_glScope->setTriggerLevel(m_triggerLevel / 1000.0);
m_scopeVis->configure(m_messageQueue,
(ScopeVis::TriggerChannel) m_triggerChannel,
@ -223,13 +223,20 @@ void GLScopeGUI::applyTriggerSettings()
void GLScopeGUI::setTrigLevelDisplay()
{
if (m_triggerChannel == ScopeVis::TriggerMagDb) {
ui->trigText->setText(tr("%1dB").arg(m_triggerLevel - 100.0, 0, 'f', 0));
ui->trigText->setText(tr("%1\ndB").arg(m_triggerLevel/10.0 - 100.0, 0, 'f', 1));
}
else if (m_triggerChannel == ScopeVis::TriggerPhase) {
ui->trigText->setText(tr("%1π").arg(m_triggerLevel / 100.0, 0, 'f', 2));
}
else {
ui->trigText->setText(tr("%1").arg(m_triggerLevel / 100.0, 0, 'f', 2));
else
{
qreal a = m_triggerLevel / 1000.0;
if(fabs(a) < 0.000001)
ui->trigText->setText(tr("%1\nn").arg(a * 1000000000.0));
else if(fabs(a) < 0.001)
ui->trigText->setText(tr("%1\nµ").arg(a * 1000000.0));
else if(fabs(a) < 1.0)
ui->trigText->setText(tr("%1\nm").arg(a * 1000.0));
else
ui->trigText->setText(tr("%1").arg(a * 1.0));
}
}
@ -239,7 +246,6 @@ void GLScopeGUI::setAmpScaleDisplay()
ui->ampText->setText(tr("%1\ndB").arg(amps[m_amplification]*500.0, 0, 'f', 1));
} else {
qreal a = amps[m_amplification]*10.0;
//ui->ampText->setText(tr("%1").arg(amps[m_amplification]*10.0, 0, 'f', 3));
if(a < 0.000001)
ui->ampText->setText(tr("%1\nn").arg(a * 1000000000.0));

View File

@ -6,7 +6,7 @@
<rect>
<x>0</x>
<y>0</y>
<width>807</width>
<width>809</width>
<height>69</height>
</rect>
</property>
@ -722,10 +722,10 @@
<string>Trigger level</string>
</property>
<property name="minimum">
<number>-100</number>
<number>-1000</number>
</property>
<property name="maximum">
<number>100</number>
<number>1000</number>
</property>
<property name="pageStep">
<number>1</number>