return TRUE;
}
-static int hw_dev_acquisition_start(int dev_index, void *cb_data)
+static int hw_dev_acquisition_start(const struct sr_dev_inst *sdi,
+ void *cb_data)
{
struct sr_datafeed_packet *packet;
struct sr_datafeed_header *header;
struct sr_datafeed_meta_logic meta;
- struct sr_dev_inst *sdi;
struct context *ctx;
uint32_t trigger_config[4];
uint32_t data;
int num_channels;
int i;
- if (!(sdi = sr_dev_inst_get(odi->instances, dev_index)))
- return SR_ERR;
-
ctx = sdi->priv;
if (sdi->status != SR_ST_ACTIVE)
}
/* TODO: This stops acquisition on ALL devices, ignoring dev_index. */
-static int hw_dev_acquisition_stop(int dev_index, void *cb_data)
+static int hw_dev_acquisition_stop(const struct sr_dev_inst *sdi,
+ void *cb_data)
{
struct sr_datafeed_packet packet;
/* Avoid compiler warnings. */
- (void)dev_index;
+ (void)sdi;
packet.type = SR_DF_END;
sr_session_send(cb_data, &packet);