X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=hardware%2Flascar-el-usb%2Fapi.c;h=16349fddb3e4f895e3a1efd517d2270bd30990a0;hb=1987b8d63e748f0813dc6a4630e99686e4fe1728;hp=e987570579838a318ad3b3b507e7a7147c6bdd1a;hpb=9a5693a5acf677c47285307235b9d47bcc3b932e;p=libsigrok.git diff --git a/hardware/lascar-el-usb/api.c b/hardware/lascar-el-usb/api.c index e9875705..16349fdd 100644 --- a/hardware/lascar-el-usb/api.c +++ b/hardware/lascar-el-usb/api.c @@ -89,7 +89,7 @@ static GSList *hw_scan(GSList *options) struct dev_context *devc; struct sr_dev_inst *sdi; struct sr_usb_dev_inst *usb; - struct sr_hwopt *opt; + struct sr_config *src; GSList *usb_devices, *devices, *l; const char *conn; @@ -105,10 +105,10 @@ static GSList *hw_scan(GSList *options) conn = NULL; for (l = options; l; l = l->next) { - opt = l->data; - switch (opt->hwopt) { + src = l->data; + switch (src->key) { case SR_HWOPT_CONN: - conn = opt->value; + conn = src->value; break; } } @@ -335,7 +335,6 @@ static int hw_dev_acquisition_start(const struct sr_dev_inst *sdi, { struct sr_datafeed_packet packet; struct sr_datafeed_header header; - struct sr_datafeed_meta_analog meta; struct dev_context *devc; struct drv_context *drvc = di->priv; struct libusb_transfer *xfer_in, *xfer_out; @@ -429,12 +428,6 @@ static int hw_dev_acquisition_start(const struct sr_dev_inst *sdi, devc->log_size = xfer_in->buffer[1] + (xfer_in->buffer[2] << 8); libusb_free_transfer(xfer_out); - /* Send metadata about the SR_DF_ANALOG packets to come. */ - packet.type = SR_DF_META_ANALOG; - packet.payload = &meta; - meta.num_probes = 1; - sr_session_send(devc->cb_data, &packet); - pfd = libusb_get_pollfds(drvc->sr_ctx->libusb_ctx); for (i = 0; pfd[i]; i++) { /* Handle USB events every 100ms, for decent latency. */