azonenberg changed the topic of #scopehal to: libscopehal, libscopeprotocols, and glscopeclient development and testing | https://github.com/glscopeclient/scopehal-apps | Logs: https://libera.irclog.whitequark.org/scopehal
<azonenberg> Next item I'm working on: ability for filters to hide parameters from the GUI
<azonenberg> the intended use case is when you create a new filter deriving from an existing one
<azonenberg> and it mostly provides a frontend for calculating parameters for the other one
<azonenberg> e.g. the future resolution enhancement filter will just be a shim around the low pass FIR filter
<azonenberg> this will also include the ability for parameters to be marked as read only
<azonenberg> so you can display e.g. the calculated cutoff frequency of the resolution enhancement filter
<azonenberg> without letting the user modify it because that makes no sense
<azonenberg> also the channel emulation and de-embed filters share code but some of the parameters for one make no sense in the context of the other
Degi_ has joined #scopehal
Degi has quit [Ping timeout: 244 seconds]
Degi_ is now known as Degi
<_whitenotifier-e> [scopehal] azonenberg pushed 2 commits to master [+2/-0/±6] https://github.com/glscopeclient/scopehal/compare/3d3a31f673cc...246d593ecc6c
<_whitenotifier-e> [scopehal] azonenberg 3e81e9c - Initial support for read-only and hidden parameter
<_whitenotifier-e> [scopehal] azonenberg 246d593 - Added EnhancedResolutionFilter. Fixes #600.
<_whitenotifier-e> [scopehal] azonenberg closed issue #600: Resolution enhancement filter - https://github.com/glscopeclient/scopehal/issues/600
<_whitenotifier-e> [scopehal-docs] azonenberg pushed 1 commit to master [+0/-0/±1] https://github.com/glscopeclient/scopehal-docs/compare/0274c35be913...f3d68bc5341e
<_whitenotifier-e> [scopehal-docs] azonenberg f3d68bc - Documented enhanced resolution filter
<_whitenotifier-e> [scopehal-apps] azonenberg pushed 2 commits to master [+0/-0/±6] https://github.com/glscopeclient/scopehal-apps/compare/fde47b09ac06...36201e94086d
<_whitenotifier-e> [scopehal-apps] azonenberg 3e5bfc9 - Initial support for read-only and hidden parameters
<_whitenotifier-e> [scopehal-apps] azonenberg 36201e9 - FilterDialog: added support for read only parameters changing when other parameters change. Avoid infinite recursion and crash if a read-only parameter updates during a refresh of the filter.
<azonenberg> And one more feature down
nelgau_ has joined #scopehal
nelgau has quit [Ping timeout: 248 seconds]
bvernoux has joined #scopehal
<azonenberg> So i have a call in an hour and a half with a manufacturer of probes (not saying which at this point in the game)
<azonenberg> Going to try and negotiate a deal to get a couple of pre-terminated pieces of that special lossy coax for 10M ohm 10x passive probe R&D, with the intention of eventually having them build cable + BNC compensation box assemblies for a production run
<azonenberg> while i supply the solder-in probe head
<azonenberg> Anyone have questions or things i should ask them? No promises
<azonenberg> But this looks to be the only option. Nobody makes or has sources for the cable except probe vendors
<azonenberg> So if you want to get the cable you gotta make friends with a probe OEM :p
<azonenberg> (since it's not sold on the open market)
<josuah> azonenberg: that sounds very cool! :D
<josuah> azonenberg: how come that such cables are not to be sold to the public?
<josuah> ah, you mean they do not sell the cable, except as part of probes?
bvernoux has quit [Quit: Leaving]
<azonenberg> Yeah
<azonenberg> i mean, it makes sense
<azonenberg> the cable has no use except as part of a probe
<azonenberg> and people DIYing probes is not really a common thing
<azonenberg> so every probe vendor designs and makes the cable for their own use
<azonenberg> theres no demand for just the cable
<d1b2> <louis> I'm not entirely sure what I've changed, but I've got our Tek stably capturing 125Mpt waveforms at about 0.6Hz without locking up knocks on wood
<d1b2> <louis> w/o the chunking buisiness
<d1b2> <louis> Part of it is handling malformed WFMO? responses, since it sometimes decides to omit fields for fun
<d1b2> <louis> and part of it is retrying instead of bailing out (and screwing up the scope's outgoing SCPI buffer state) in certain cases
<azonenberg> Awesome
<azonenberg> well, send the PR whenever you're ready
<azonenberg> also i would really like a HzClock somewhere for WFM/s. we do not currently have this globally
<d1b2> <louis> What are your thoughts on gotos for this kind of error handling? There's some code in various places that looks like c++ ... int retries = 0; do_retry: if (retries++ > 3) return false; //actually fail ... ... if (erroneous_condition) goto do_retry; ... ...
<azonenberg> it might be in some of your drivers but i think it would be good to add to OscilloscopeWindow or something for global trigger rate
<azonenberg> I'm not a huge fan of that, but i also recognize that it might be the best option in some narrow cases. There has been some discussion of using C++ exceptions more widely
<azonenberg> wrt error handling in general
<d1b2> <louis> which can of course become c++ for (int retry = 0; retry < 3; retry ++) { ... ... if (erroneous_condition) continue; ... ... break; } but I'm not sure that's actually any clearer
<d1b2> <louis> (follow with c++ if (retry == 3) return false; //actually fail )
<azonenberg> I'm going to say that if you can avoid a goto without making the code a lot uglier, you should
<azonenberg> that loop pattern is fairly understandable IMO
<azonenberg> in particular, goto can cause some issues wrt local variable stack frame unwinding
<azonenberg> i think it doesnt always call destructors etc?
<azonenberg> would have to check the spec
<d1b2> <louis> OK, I will do that then 👍
<d1b2> <louis> The question in practice of course is, what is 'a lot uglier' 😛
<azonenberg> Lol yeah
Bird|otherbox has quit [Remote host closed the connection]
Bird|otherbox has joined #scopehal
Bird|otherbox has quit [Remote host closed the connection]
Bird|otherbox has joined #scopehal
<Bird|otherbox> azonenberg: destructors seem to get called, but it's an error to try to goto over a *constructor* call
<azonenberg> ah, ok
<azonenberg> yeah the same is true of switch statements
<azonenberg> which are glorified gotos :p
<josuah> gotos with a scope and only one place where it is allowed to jump
<josuah> and a wonderful hammer for crafting state machines
<azonenberg> lol yes
<josuah> for+break/while+break feels a bit in-between gotos and Djkstra's algopurity
* josuah wonders what else there is for state machines
<josuah> ah, arrays!
<josuah> one position per state, and the content for that position setting the next one
<azonenberg> ah yes. basically microcode
<azonenberg> i do that in RTL sometimes
<josuah> attempt report: not much luck with compiling scopehal on OpenBSD, due to lack of OpenCL here
<azonenberg> OpenCL is entirely optional
<azonenberg> If not having it breaks the build, that's a bug we need to address
<josuah> ah! which means: round 2!
<azonenberg> cmake should detect the presence of opencl
<josuah> I might just have glossed over some documentation
<azonenberg> and set a global HAVE_OPENCL flag
<josuah> I remember something like that
* josuah checks now
<azonenberg> and all opencl-dependent code in the project should be #ifdef guarded
<azonenberg> if any of it is not, that is a bug
<azonenberg> additionally, at run time it should check for any actual opencl devices meeting our requirements
<azonenberg> and if none are found, act as if there is no opencl support
<azonenberg> OpenMP, on the other hand, is a core requirement at compile time for threading
<josuah> ah, my bad it was OpenMP!
<josuah> or maybe just misdetecting it, or missing feature among OpenMP...
<azonenberg> Please look into it. I thought OMP was very well supported among ~all major compilers now
<azonenberg> at least the subset that i depend on which is not much
<josuah> azonenberg: I will now (1) go to sleep, (2) wake-up tomorrow, (3) then https://kolo.fr/day2295.webm
<josuah> thank you for the boost!