Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: ngscopeclient/scopehal
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: c3ae7f48e944
Choose a base ref
...
head repository: ngscopeclient/scopehal
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: add84fa0f03c
Choose a head ref
  • 1 commit
  • 1 file changed
  • 1 contributor

Commits on Dec 7, 2020

  1. Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    add84fa View commit details
Showing with 8 additions and 4 deletions.
  1. +8 −4 scopeprotocols/DDJMeasurement.cpp
12 changes: 8 additions & 4 deletions scopeprotocols/DDJMeasurement.cpp
Original file line number Diff line number Diff line change
@@ -151,8 +151,6 @@ void DDJMeasurement::Refresh()
int64_t tfirst = tie->m_offsets[0] * tie->m_timescale + tie->m_triggerPhase;
for(size_t idata=0; idata < samplen; idata ++)
{
uint8_t last_window = window;

//Sample the next bit in the thresholded waveform
window = (window >> 1);
if(samples.m_samples[idata])
@@ -180,9 +178,15 @@ void DDJMeasurement::Refresh()
if(itie >= tielen)
break;

//If the TIE sample is after this bit, don't do anything.
//We need edges within this UI.
int64_t tend = tstart + samples.m_durations[idata];
if(target > tend)
continue;

//Save the info in the DDJ table
num_table[last_window] ++;
sum_table[last_window] += tie->m_samples[itie];
num_table[window] ++;
sum_table[window] += tie->m_samples[itie];
}

//Calculate DDJ