On Mon, Oct 13, 2014 at 09:35:46AM +0300, Janne Huttunen wrote:
> On Sat, Oct 11, 2014 at 3:47 PM, Janne Huttunen <[email protected]> wrote:
> > Add flags for indicating that the meter has selected the measured
> > quantitiy and/or the used measurement model automatically. These
> > are similar to the existing auto-range flag.
> 
> Actually, this got me into thinking; would it make more sense
> to model these as (read/list only) config keys with enumerated
> values?
> 
> My LCR meter apparently doesn't support remote control, but it
> would be a perfect candidate for it. It has only two input
> terminals and no physical switches - only momentary pushbuttons.
> It would thus be possible to control all aspects of the meter
> remotely, except maybe turn it on or enable the PC link.
> 
> So, if the meter would be such a good candidate for remote
> control, I'm sure some LCR meters out there do actually support
> it. In that case the measured quantity and equivalent model
> selection should be configurable anyways, so why not export them
> as such already? This would also save two precious flags.

Sounds like a good idea.
I have a BK Precision 879B LCR Meter that I will want to write a driver
for, some day... This one is fully remotely controlable, so preparing
the API to support such a feature is definitely a good idea.

> Looking at the existing code, the precedent seems to be to export
> enumerated config values as strings, right? This would mean that
> I would define something like these:
> 
> SR_CONF_MEASURED_QUANTITY (SR_T_STRING)
> 
>   "AUTO"
>   "INDUCTANCE"
>   "CAPACITANCE"
>   "RESISTANCE"

The BK 879B does not have AUTO mode, and it also add an IMPEDANCE mode.
Using a string here allows those different use cases, so it seems good,
as long as the application can list the supported strings.

> SR_CONF_EQUIV_CIRCUIT_MODEL (SR_T_STRING)
> 
>   "AUTO"
>   "PARALLEL"
>   "SERIES"

The BK 879B is equivalent but missing the AUTO, once again.

Also the BK 879B can set (and read) a secondary mesured quantity among
DISSIPATION_FACTOR, QUALITY_FACTOR, THETA and ESR. This would fit well
in your model, by just adding another conf key. (and this can easily be
added later on, when actually needed)

And obviously, you can also set/get the used frequency among a list of
supported ones.

> Any LCR meter driver that supports remote control could then
> define also _set() method for these.

Sounds like a good plan to me.
This would work perfectly with at least one remotely controlable LCR
meter.

Aurel

------------------------------------------------------------------------------
Comprehensive Server Monitoring with Site24x7.
Monitor 10 servers for $9/Month.
Get alerted through email, SMS, voice calls or mobile push notifications.
Take corrective actions from your mobile device.
http://p.sf.net/sfu/Zoho
_______________________________________________
sigrok-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/sigrok-devel

Reply via email to