On Fri, Nov 08, 2013 at 10:38:52PM +0100, Mathias Grimmberger wrote:
> 
> > I think the next thing to try is to merge in the additional changes from
> > your standalone version into the unified version. Would you like to
> > attempt that?
> 
> Yes.

Great, that'd be really helpful.

> Oh, another thing. I think I already mentioned that the Rigol DS4000
> and DS6000 series seem to be using the exact same protocol as the
> DS2000, probably common firmware parts.
> 
> So it may be useful to in general distinguish between the protocol used
> by the DS1xx2 and the one used by the newer devices (seems to me to
> conform to IEEE 488.2) and only use the series number to work around
> specific quirks if needed.
> 
> So in case a DS4000 owner suddenly appears we'd not need to amend much
> code. And I'm willing to bet that the new DS1000Z series uses the new
> protocol too... (no programming manual available yet).

That makes sense. We can replace the 'series' struct member with
whatever else suits, perhaps something like 'protocol_version' - or even
just 'data_format' if it's only the waveform readout format that varies.

Similarly, some functions can be named more appropriately. If we think
the protocol is the same for DS2000/4000/6000, then e.g. functions like
rigol_ds2xx2_read_header should just be rigol_ds_read_header. Use names
like rigol_ds1xx2_read_waveform only when there is known model/series
specific behaviour.

Remember, by the way, that a lot of what you've done may work just as
well on the DS1000 series too, I have haven't tested it there yet.


Martin

------------------------------------------------------------------------------
November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
techniques for threading, error checking, porting, and tuning. Get the most 
from the latest Intel processors and coprocessors. See abstracts and register
http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk
_______________________________________________
sigrok-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sigrok-devel

Reply via email to