-
Notifications
You must be signed in to change notification settings - Fork 121
WIP: Rigol oscilloscope refactor #1017
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
diggit
wants to merge
37
commits into
ngscopeclient:master
Choose a base branch
from
diggit:rigol_oscilloscope_refactor
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Differentiate between scope families and then group their common behavior in switch statements. This is more flexible approach and allow more fine tuned, per family behavior than immediately grouping them by protocol. - use smart pointers where it makes sense - use vector/array rather than C arrays DS1000Z - implemented memory/samplerate configuration - improved download speed - improved trigger poll performance/robustness Other families should have same handling as before.
to make sure all scope families are handled everywhere
When trigger offset was beyond memory range, at least DS1000Z never received trigger.
This is necessary, because samplerate changes timebase. While TB changes, Rigol oscilloscopes keep the trigger position constant relative to the capture mid point. Because scopehal reference point is at start, the trigger has to be updated to keep it constant from scopehal's POV.
As interleaving done automatically by scope is not considered to be an interleaving feature, see ngscopeclient#1014
This is happening with the pico-bridge, too, so probably a bug of ngscopeclient itself and not specific to any make or model of 'scopes. |
Initial tests with 1 channel and 1 MB chunks worked fine. Later tests with 2 channels failed, but 500 kB chunk size worked fine, but failed for 3 or 4 channels. It looks like the chunk size (maxpoints), also depends on the amount of enabled channels. There may be still some margin, but it's not worth chaseing it.
Proper resource locking was missing at multiple places. It may not be 100% complete yet.
- change verbose logs to trace - add more trace logs - print detected options - remove purely development logs
There are DHO4000 series scopes, which support 250 MHZ BW limit.
- all the series/model -> limiters logic is now in `GetChannelBandwidthLimiters` - `SetChannelBandwidthLimit` uses values from `GetChannelBandwidthLimiters` and uses nearest higher limit
it is more complicated than expected, no obvious rules
- deduce whole trigger state from data preamble rather than status - resilient against fast triggers skipping transitions - properly handles busy(wait)/armed(run) states
…ies::MSODS1000Z as there are also MSO scopes
MSODS1000Z was the only exception and it works there.
- recognize MSO1000Z as MSODS1000Z (tested) - recognize DHO800/DHO900/DHO1000/DHO4000 (untested)
only `double` for now, but templating allows easy addition of more
…nnel configuration - it may touch channels and it caused bugs when adding LA support
most of necessary includes are already included indirectly
- developed with MSO1000Z series - MSO5000/DHO900 implemented, but not tested
…o `std::optional`
Author
|
@jwise I guess you have access to DHO4000 series scope. Could you give a shot to this PR? If you do please enable trace log for transport and RigolOscilloscope driver. |
…hannel - ATM only affects MSODS1000Z as there are collisions between digital banks and some analog channels
…lDivisor` because ATM this divisor behavior seems to be specific to MSODS1000Z only
…Depth` - we have to ensure, the trigger status does not change after we query it so we can restore correct value in the end
…g input - all supported except MSO5000
scopehal does not support it now, so it will not be listed in available trigger inputs
…dd MSO5000 as affected
…sableChannel` is called number of enabled channels may affect current samplerate, especially near the maximum rates
- it is dependent on how many analog channels are enabled
to not report `TRIGGER_MODE_TRIGGERED` when scope state == `TD`, because then the `ngscopeclient` immediately calls `AcquireData`, but data are available once the scope reaches `STOP` state, not `TD`.
…erate info in preamble
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This is a Rigol Oscilloscope driver refactor.
Related issues #943
I need testers for most scope families (see below).
Refactor
Supported devices and new features
Known issues (TBD):
Fixes
Triggers
Not yet supported devices