From: Kate J. Temkin Date: Thu, 22 Aug 2019 01:12:33 +0000 (-0600) Subject: fx2lafw: allow for sampling at 48MHz, matching a fw change X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=1656cd4a4a967cd007675bdae3b780f58fe38619;p=libsigrok.git fx2lafw: allow for sampling at 48MHz, matching a fw change --- diff --git a/src/hardware/fx2lafw/api.c b/src/hardware/fx2lafw/api.c index d1071916..04efcf3f 100644 --- a/src/hardware/fx2lafw/api.c +++ b/src/hardware/fx2lafw/api.c @@ -157,6 +157,7 @@ static const uint64_t samplerates[] = { SR_MHZ(12), SR_MHZ(16), SR_MHZ(24), + SR_MHZ(48), }; static gboolean is_plausible(const struct libusb_device_descriptor *des) diff --git a/src/hardware/fx2lafw/protocol.c b/src/hardware/fx2lafw/protocol.c index ec2b5c01..83315808 100644 --- a/src/hardware/fx2lafw/protocol.c +++ b/src/hardware/fx2lafw/protocol.c @@ -112,7 +112,7 @@ static int command_start_acquisition(const struct sr_dev_inst *sdi) sr_dbg("GPIF delay = %d, clocksource = %sMHz.", delay, (cmd.flags & CMD_START_FLAGS_CLK_48MHZ) ? "48" : "30"); - if (delay <= 0 || delay > MAX_SAMPLE_DELAY) { + if (delay < 0 || delay > MAX_SAMPLE_DELAY) { sr_err("Unable to sample at %" PRIu64 "Hz.", samplerate); return SR_ERR; }