From: Russ Dill Date: Mon, 30 Dec 2013 15:04:42 +0000 (-0800) Subject: zeroplus: Add getters for memory configuration X-Git-Tag: libsigrok-0.3.0~342 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=a864a05b25d150214978f51e21b724d912648129;p=libsigrok.git zeroplus: Add getters for memory configuration This is needed at capture readback time to determine how many samples to read in. Signed-off-by: Russ Dill --- diff --git a/hardware/zeroplus-logic-cube/analyzer.c b/hardware/zeroplus-logic-cube/analyzer.c index 1bf1f65b..63116fc1 100644 --- a/hardware/zeroplus-logic-cube/analyzer.c +++ b/hardware/zeroplus-logic-cube/analyzer.c @@ -564,11 +564,21 @@ SR_PRIV void analyzer_set_ramsize_trigger_address(unsigned int address) g_ramsize_triggerbar_addr = address; } +SR_PRIV unsigned int analyzer_get_ramsize_trigger_address(void) +{ + return g_ramsize_triggerbar_addr; +} + SR_PRIV void analyzer_set_triggerbar_address(unsigned int address) { g_triggerbar_addr = address; } +SR_PRIV unsigned int analyzer_get_triggerbar_address(void) +{ + return g_triggerbar_addr; +} + SR_PRIV unsigned int analyzer_read_status(libusb_device_handle *devh) { return gl_reg_read(devh, DEV_STATUS); diff --git a/hardware/zeroplus-logic-cube/analyzer.h b/hardware/zeroplus-logic-cube/analyzer.h index f6e95875..94d1cc1a 100644 --- a/hardware/zeroplus-logic-cube/analyzer.h +++ b/hardware/zeroplus-logic-cube/analyzer.h @@ -85,6 +85,8 @@ enum { SR_PRIV void analyzer_set_freq(int freq, int scale); SR_PRIV void analyzer_set_ramsize_trigger_address(unsigned int address); SR_PRIV void analyzer_set_triggerbar_address(unsigned int address); +SR_PRIV unsigned int analyzer_get_ramsize_trigger_address(void ); +SR_PRIV unsigned int analyzer_get_triggerbar_address(void); SR_PRIV void analyzer_set_compression(unsigned int type); SR_PRIV void analyzer_set_memory_size(unsigned int size); SR_PRIV void analyzer_add_trigger(int channel, int type);