}
sdi = g_malloc0(sizeof(struct sr_dev_inst));
- sdi->status = SR_ST_ACTIVE;
sdi->vendor = g_strdup(model->series->vendor->name);
sdi->model = g_strdup(model->name);
sdi->version = g_strdup(hw_info->firmware_version);
unsigned int i;
struct dev_context *devc = NULL;
- if (sdi)
- devc = sdi->priv;
-
if (key == SR_CONF_SCAN_OPTIONS) {
*data = g_variant_new_fixed_array(G_VARIANT_TYPE_UINT32,
scanopts, ARRAY_SIZE(scanopts), sizeof(uint32_t));
sr_scpi_source_add(sdi->session, scpi, G_IO_IN, 50,
rigol_ds_receive, (void *)sdi);
- /* Send header packet to the session bus. */
std_session_send_df_header(cb_data, LOG_PREFIX);
devc->channel_entry = devc->enabled_channels;
{
struct dev_context *devc;
struct sr_scpi_dev_inst *scpi;
- struct sr_datafeed_packet packet;
(void)cb_data;
return SR_ERR;
}
- /* End of last frame. */
- packet.type = SR_DF_END;
- sr_session_send(sdi, &packet);
+ std_session_send_df_end(sdi, LOG_PREFIX);
g_slist_free(devc->enabled_channels);
devc->enabled_channels = NULL;