]> sigrok.org Git - libsigrok.git/blobdiff - src/hardware/manson-hcs-3xxx/api.c
Removal of sdi->index, step 4: fix trivial sr_dev_inst_new() calls
[libsigrok.git] / src / hardware / manson-hcs-3xxx / api.c
index ce6b6f32e8fa1b565aeb6ca82d820dd165fe5d97..b0dc27338371870c1f3ea0a16c6e375ce7062d76 100644 (file)
@@ -35,15 +35,15 @@ static const uint32_t devopts[] = {
        /* Device class */
        SR_CONF_POWER_SUPPLY,
        /* Aquisition modes. */
-       SR_CONF_LIMIT_SAMPLES,
-       SR_CONF_LIMIT_MSEC,
        SR_CONF_CONTINUOUS,
+       SR_CONF_LIMIT_SAMPLES | SR_CONF_GET | SR_CONF_SET,
+       SR_CONF_LIMIT_MSEC | SR_CONF_GET | SR_CONF_SET,
        /* Device configuration */
-       SR_CONF_OUTPUT_CURRENT,
-       SR_CONF_OUTPUT_CURRENT_MAX,
-       SR_CONF_OUTPUT_ENABLED,
-       SR_CONF_OUTPUT_VOLTAGE,
-       SR_CONF_OUTPUT_VOLTAGE_MAX,
+       SR_CONF_OUTPUT_CURRENT | SR_CONF_GET,
+       SR_CONF_OUTPUT_CURRENT_MAX | SR_CONF_GET | SR_CONF_SET | SR_CONF_LIST,
+       SR_CONF_OUTPUT_ENABLED | SR_CONF_GET | SR_CONF_SET,
+       SR_CONF_OUTPUT_VOLTAGE | SR_CONF_GET,
+       SR_CONF_OUTPUT_VOLTAGE_MAX | SR_CONF_GET | SR_CONF_SET | SR_CONF_LIST,
 };
 
 /* Note: All models have one power supply output only. */
@@ -150,7 +150,7 @@ static GSList *scan(GSList *options)
        }
 
        /* Init device instance, etc. */
-       if (!(sdi = sr_dev_inst_new(0, SR_ST_INACTIVE, "Manson",
+       if (!(sdi = sr_dev_inst_new(SR_ST_INACTIVE, "Manson",
                                    models[model_id].name, NULL))) {
                sr_err("Failed to create device instance.");
                return NULL;