Skip to content

Commit

Permalink
Lots of tooltip improvements to BERT UI
Browse files Browse the repository at this point in the history
  • Loading branch information
azonenberg committed Aug 30, 2023
1 parent 69dec0e commit 453aab1
Show file tree
Hide file tree
Showing 4 changed files with 30 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib
12 changes: 11 additions & 1 deletion src/ngscopeclient/BERTDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,10 @@ bool BERTDialog::DoRender()
}

HelpMarker(to_string(m_bert->GetCustomPatternLength()) +
" -bit pattern sent by all channels in custom-pattern mode");
" -bit pattern sent by all channels in custom-pattern mode.\n"
"\n"
"Note that this includes the reference clock output on the ML4039, if\n"
"configured in SERDES mode.");
}
}

Expand All @@ -137,10 +140,17 @@ bool BERTDialog::DoRender()
m_txPattern = m_bert->GetGlobalCustomPattern();
m_txPatternText = to_string_hex(m_txPattern);
}
HelpMarker("Select which clock to output from the reference clock output port");

ImGui::SetNextItemWidth(width);
if(Dialog::Combo("Data Rate", m_dataRateNames, m_dataRateIndex))
{
m_bert->SetDataRate(m_dataRates[m_dataRateIndex]);

//Reload refclk mux setting names
m_refclkNames = m_bert->GetRefclkOutMuxNames();
}
HelpMarker("PHY signaling rate for all transmit and receive ports");
}

return true;
Expand Down
8 changes: 8 additions & 0 deletions src/ngscopeclient/BERTInputChannelDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,7 @@ bool BERTInputChannelDialog::DoRender()
ImGui::SetNextItemWidth(width);
if(ImGui::Checkbox("Invert", &m_invert))
m_channel->SetInvert(m_invert);
HelpMarker("Inverts the polarity of the input");
}

if(ImGui::CollapsingHeader("CDR", defaultOpenFlags))
Expand All @@ -151,13 +152,18 @@ bool BERTInputChannelDialog::DoRender()
auto lock = m_channel->GetCdrLockState();
ImGui::Checkbox("Lock", &lock);
ImGui::EndDisabled();
HelpMarker(
"Indicates whether the clock recovery loop and PRBS checker are locked to incoming data.\n"
"If not locked, no measurements can be made.");
}

if(ImGui::CollapsingHeader("Pattern Checker", defaultOpenFlags))
{
ImGui::SetNextItemWidth(width);
if(Dialog::Combo("Pattern", m_patternNames, m_patternIndex))
m_channel->SetPattern(m_patternValues[m_patternIndex]);

HelpMarker("Expected PRBS pattern");
}

if(ImGui::CollapsingHeader("Measurements", defaultOpenFlags))
Expand All @@ -172,6 +178,7 @@ bool BERTInputChannelDialog::DoRender()
auto state = m_parent->GetSession().GetBERTState(m_channel->GetBERT());
state->m_horzBathtubScanPending[m_channel->GetIndex()] = true;
}
HelpMarker("Acquire a single horizontal bathtub measurement");

if(ImGui::Button("Eye"))
{
Expand All @@ -182,6 +189,7 @@ bool BERTInputChannelDialog::DoRender()
auto state = m_parent->GetSession().GetBERTState(m_channel->GetBERT());
state->m_eyeScanPending[m_channel->GetIndex()] = true;
}
HelpMarker("Acquire a single eye pattern measurement");
}

return true;
Expand Down
10 changes: 10 additions & 0 deletions src/ngscopeclient/BERTOutputChannelDialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -158,27 +158,37 @@ bool BERTOutputChannelDialog::DoRender()
ImGui::SetNextItemWidth(width);
if(Dialog::Combo("Pattern", m_patternNames, m_patternIndex))
m_channel->SetPattern(m_patternValues[m_patternIndex]);

if(!m_channel->GetBERT()->IsCustomPatternPerChannel())
HelpMarker("Pattern to drive out this port.\nNote that all ports in \"custom\" mode share a single pattern generator");
else
HelpMarker("Pattern to drive out this port.");
}

if(ImGui::CollapsingHeader("PHY Control", defaultOpenFlags))
{
ImGui::SetNextItemWidth(width);
if(ImGui::Checkbox("Enable", &m_enable))
m_channel->Enable(m_enable);
HelpMarker("Enable the output driver");

ImGui::SetNextItemWidth(width);
if(ImGui::Checkbox("Invert", &m_invert))
m_channel->SetInvert(m_invert);
HelpMarker("Invert polarity of the output");

ImGui::SetNextItemWidth(width);
if(Dialog::Combo("Swing", m_driveNames, m_driveIndex))
m_channel->SetDriveStrength(m_driveValues[m_driveIndex]);
HelpMarker("Peak-to-peak swing of the output (with no emphasis)");

if(ImGui::SliderFloat("Pre-cursor", &m_precursor, 0.0, 1.0, "%.2f", ImGuiSliderFlags_AlwaysClamp))
m_channel->SetPreCursor(m_precursor);
HelpMarker("Pre-cursor FFE tap value");

if(ImGui::SliderFloat("Post-cursor", &m_postcursor, 0.0, 1.0, "%.2f", ImGuiSliderFlags_AlwaysClamp))
m_channel->SetPostCursor(m_postcursor);
HelpMarker("Post-cursor FFE tap value");

}

Expand Down

0 comments on commit 453aab1

Please sign in to comment.