+#include "libsigrok.h"
+#include "libsigrok-internal.h"
+#include <glib.h>
+#include <libusb.h>
+#include <stdlib.h>
+#include <string.h>
+
+static const int32_t hwopts[] = {
+ SR_CONF_CONN,
+};
+
+static const int32_t hwcaps[] = {
+ SR_CONF_LOGIC_ANALYZER,
+ SR_CONF_SAMPLERATE,
+ SR_CONF_EXTERNAL_CLOCK,
+ SR_CONF_CLOCK_EDGE,
+ SR_CONF_TRIGGER_MATCH,
+ SR_CONF_TRIGGER_SOURCE,
+ SR_CONF_TRIGGER_SLOPE,
+ SR_CONF_LIMIT_MSEC,
+ SR_CONF_LIMIT_SAMPLES,
+};
+
+static const int32_t trigger_matches[] = {
+ SR_TRIGGER_ZERO,
+ SR_TRIGGER_ONE,
+ SR_TRIGGER_RISING,
+ SR_TRIGGER_FALLING,
+};
+
+/* The hardware supports more samplerates than these, but these are the
+ * options hardcoded into the vendor's Windows GUI.
+ */
+static const uint64_t samplerates[] = {
+ SR_MHZ(125), SR_MHZ(100),
+ SR_MHZ(50), SR_MHZ(20), SR_MHZ(10),
+ SR_MHZ(5), SR_MHZ(2), SR_MHZ(1),
+ SR_KHZ(500), SR_KHZ(200), SR_KHZ(100),
+ SR_KHZ(50), SR_KHZ(20), SR_KHZ(10),
+ SR_KHZ(5), SR_KHZ(2), SR_KHZ(1),
+ SR_HZ(500), SR_HZ(200), SR_HZ(100),
+};
+
+/* Names assigned to available trigger sources. Indices must match
+ * trigger_source enum values.
+ */
+static const char *const trigger_source_names[] = { "CH", "TRG" };
+
+/* Names assigned to available trigger slope choices. Indices must
+ * match the signal_edge enum values.
+ */
+static const char *const signal_edge_names[] = { "r", "f" };