Commit Graph

20 Commits

Author SHA1 Message Date
Uwe Hermann 54ab1dcdc4 Add missing entries to sr_config_info_data[].
Newly added keys:

 - SR_CONF_SAMPLE_INTERVAL
 - SR_CONF_NUM_TIMEBASE
 - SR_CONF_NUM_VDIV
 - SR_CONF_CENTER_FREQUENCY
 - SR_CONF_DEVICE_MODE
 - SR_CONF_SCAN_OPTIONS
 - SR_CONF_DEVICE_OPTIONS
 - SR_CONF_DEVICE_MODE
 - SR_CONF_TEST_MODE

Also, keep the same ordering and grouping as in libsigrok.h.
2014-11-22 17:02:57 +01:00
Uwe Hermann 91219afc75 Use g_malloc0() consistently, simplify error handling.
Use g_malloc0() for small allocations and assume they always
succeed. Simplify error handling in a few places accordingly.

Don't always sanity-check parameters for non-public (SR_PRIV)
functions, we require the developers to invoke them correctly.
This allows further error handling simplifications.
2014-11-22 17:02:57 +01:00
Aurelien Jacobs 8a58419d37 Finish fixing broken sr_config_list() logic. 2014-11-19 17:34:19 +01:00
Bert Vermeulen db6fa867a4 Add debug spew to all sr_config_(get|set|list) calls. 2014-11-18 15:46:59 +01:00
Bert Vermeulen cf3db38193 Fix broken sr_config_list() logic. 2014-11-18 15:46:24 +01:00
Bert Vermeulen c6dde8125a Check driver capabilities before sr_config_get/set/list. 2014-11-17 13:20:32 +01:00
Bert Vermeulen adfba7368a Refactor scan options check. 2014-11-14 20:25:12 +01:00
Bert Vermeulen 071151b578 sr_driver_scan: Enforce options passed in by client. 2014-11-14 12:22:54 +01:00
Bert Vermeulen 6fad08e6ab Change SR_CONF_FILTER key to a boolean type.
This was an ill-defined string before, now it's simply something
you turn on or off on a channel.
2014-10-27 17:09:57 +01:00
Bert Vermeulen a700a3a4bf More robust searching for config keys. 2014-10-27 17:09:27 +01:00
Bert Vermeulen 51b1b95edb Add config info for device type and limit config keys. 2014-10-27 17:09:07 +01:00
Bert Vermeulen 61b0292217 Accept subtype of expected GVariant values. 2014-10-22 22:18:52 +02:00
Janne Huttunen a42a39ac37 Export LCR meter 'auto' bits as config keys instead of mqflags.
The automatic selections of the measured quantity and equivalent circuit
model are more part of the configuration of the meter than attributes
of the measurement result. To reflect this, model them as config keys
instead of mqflags. This allows a driver that supports remote control to
implement 'set' method for them and has the additional benefit of saveing
two flag bits.
2014-10-21 12:23:20 +02:00
Bert Vermeulen ae431bc8d6 Fix short names for SR_CONF_OUTPUT_VOLTAGE_TARGET/_CURRENT_LIMIT. 2014-10-16 13:22:51 +02:00
Bert Vermeulen ca95e90fb3 Use SR_CONF_OUTPUT_VOLTAGE_TARGET and _CURRENT_LIMIT.
These describe them better; the two are fundamentally different
things to set.
2014-10-15 12:03:00 +02:00
Bert Vermeulen 584560f142 Change type of SR_CONF keys to uint32_t. 2014-09-16 21:22:41 +02:00
Martin Ling 13fef1ed24 hwdriver: Validate types of GVariants passed by user. 2014-09-14 04:47:12 +01:00
Bert Vermeulen a1eaa9e066 Revamp PPS-related config keys. 2014-09-08 12:45:21 +02:00
Bert Vermeulen cff7d8d60d Add config key for amplitude.
This is intended for setting (or getting) the amplitude of a source
which doesn't really have an MQ associated with it, such as the demo
driver's analog channels.
2014-07-28 15:40:19 +02:00
Bert Vermeulen 155b680da4 Reorganize project tree. 2014-07-22 18:19:29 +02:00
Renamed from hwdriver.c (Browse further)