]> sigrok.org Git - libsigrok.git/blobdiff - src/hardware/scpi-pps/api.c
scpi-pps: Add profile for Agilent N5763A 12.5V 120A supply
[libsigrok.git] / src / hardware / scpi-pps / api.c
index fb6a36e2baee4807f3872da0a56186ed8118eb20..a29744edefa0b79e6744906b414121511de0a37d 100644 (file)
@@ -91,7 +91,6 @@ static struct sr_dev_inst *probe_device(struct sr_scpi_dev_inst *scpi)
        }
 
        sdi = g_malloc0(sizeof(struct sr_dev_inst));
-       sdi->status = SR_ST_INACTIVE;
        sdi->vendor = g_strdup(vendor);
        sdi->model = g_strdup(hw_info->model);
        sdi->version = g_strdup(hw_info->firmware_version);
@@ -168,7 +167,6 @@ static struct sr_dev_inst *probe_device(struct sr_scpi_dev_inst *scpi)
        hw_info = NULL;
 
        scpi_cmd(sdi, devc->device->commands, SCPI_CMD_LOCAL);
-       sr_scpi_close(scpi);
 
        return sdi;
 }
@@ -402,7 +400,7 @@ static int config_set(uint32_t key, GVariant *data, const struct sr_dev_inst *sd
                select_channel(sdi, cg->channels->data);
 
        devc = sdi->priv;
-       ret = SR_OK;
+
        switch (key) {
        case SR_CONF_ENABLED:
                if (g_variant_get_boolean(data))