From: v1ne Date: Tue, 31 Mar 2020 22:05:37 +0000 (+0200) Subject: ols: Make external clock setting queriable X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=50b15953feef442760719fa8c56e0d1337a1df97;p=libsigrok.git ols: Make external clock setting queriable ... and thus selectable in PulseView. --- diff --git a/src/hardware/openbench-logic-sniffer/api.c b/src/hardware/openbench-logic-sniffer/api.c index 2815a50a..23f68c57 100644 --- a/src/hardware/openbench-logic-sniffer/api.c +++ b/src/hardware/openbench-logic-sniffer/api.c @@ -36,7 +36,7 @@ static const uint32_t devopts[] = { SR_CONF_SAMPLERATE | SR_CONF_GET | SR_CONF_SET | SR_CONF_LIST, SR_CONF_TRIGGER_MATCH | SR_CONF_LIST, SR_CONF_CAPTURE_RATIO | SR_CONF_GET | SR_CONF_SET, - SR_CONF_EXTERNAL_CLOCK | SR_CONF_SET, + SR_CONF_EXTERNAL_CLOCK | SR_CONF_GET | SR_CONF_SET, SR_CONF_CLOCK_EDGE | SR_CONF_GET | SR_CONF_SET | SR_CONF_LIST, SR_CONF_PATTERN_MODE | SR_CONF_GET | SR_CONF_SET | SR_CONF_LIST, SR_CONF_SWAP | SR_CONF_SET, @@ -229,6 +229,10 @@ static int config_get(uint32_t key, GVariant **data, case SR_CONF_RLE: *data = g_variant_new_boolean(devc->capture_flags & CAPTURE_FLAG_RLE ? TRUE : FALSE); break; + case SR_CONF_EXTERNAL_CLOCK: + *data = g_variant_new_boolean( + devc->capture_flags & CAPTURE_FLAG_CLOCK_EXTERNAL ? TRUE : FALSE); + break; case SR_CONF_CLOCK_EDGE: *data = g_variant_new_string(external_clock_edges[ devc->capture_flags & CAPTURE_FLAG_INVERT_EXT_CLOCK ? 1 : 0]);