]> sigrok.org Git - libsigrok.git/blobdiff - hardware/agilent-dmm/api.c
Rename SR_HWOPT_* and SR_HWCAP_* to SR_CONF_*
[libsigrok.git] / hardware / agilent-dmm / api.c
index 9bcca5887e29e9208ffcd25ebc143a91d6adf691..9d401c7e51734f9a8c10bf659dffe7fb32f08704 100644 (file)
 #include "agilent-dmm.h"
 
 static const int hwopts[] = {
-       SR_HWOPT_CONN,
-       SR_HWOPT_SERIALCOMM,
+       SR_CONF_CONN,
+       SR_CONF_SERIALCOMM,
        0,
 };
 
 static const int hwcaps[] = {
-       SR_HWCAP_MULTIMETER,
-       SR_HWCAP_LIMIT_SAMPLES,
-       SR_HWCAP_LIMIT_MSEC,
-       SR_HWCAP_CONTINUOUS,
+       SR_CONF_MULTIMETER,
+       SR_CONF_LIMIT_SAMPLES,
+       SR_CONF_LIMIT_MSEC,
+       SR_CONF_CONTINUOUS,
        0,
 };
 
@@ -125,10 +125,10 @@ static GSList *hw_scan(GSList *options)
        for (l = options; l; l = l->next) {
                src = l->data;
                switch (src->key) {
-               case SR_HWOPT_CONN:
+               case SR_CONF_CONN:
                        conn = src->value;
                        break;
-               case SR_HWOPT_SERIALCOMM:
+               case SR_CONF_SERIALCOMM:
                        serialcomm = src->value;
                        break;
                }
@@ -280,7 +280,7 @@ static int hw_dev_config_set(const struct sr_dev_inst *sdi, int hwcap,
        }
 
        switch (hwcap) {
-       case SR_HWCAP_LIMIT_MSEC:
+       case SR_CONF_LIMIT_MSEC:
                /* TODO: not yet implemented */
                if (*(const uint64_t *)value == 0) {
                        sr_err("LIMIT_MSEC can't be 0.");
@@ -290,7 +290,7 @@ static int hw_dev_config_set(const struct sr_dev_inst *sdi, int hwcap,
                sr_dbg("Setting time limit to %" PRIu64 "ms.",
                       devc->limit_msec);
                break;
-       case SR_HWCAP_LIMIT_SAMPLES:
+       case SR_CONF_LIMIT_SAMPLES:
                devc->limit_samples = *(const uint64_t *)value;
                sr_dbg("Setting sample limit to %" PRIu64 ".",
                       devc->limit_samples);