sdi->vendor = g_strdup(manufacturer);
sdi->model = g_strdup(product);
sdi->version = g_strdup(hwrev);
- sdi->driver = di;
sdi->priv = devc;
for (i = 0; i < ARRAY_SIZE(channel_names); i++) {
chtype = (i == 0) ? SR_CHANNEL_ANALOG : SR_CHANNEL_LOGIC;
sr_channel_new(sdi, i, chtype, TRUE, channel_names[i]);
}
-
- //Add the driver
- struct drv_context *drvc = di->context;
- drvc->instances = g_slist_append(drvc->instances, sdi);
- devices = g_slist_append(devices, sdi);
}
- return devices;
+ return std_scan_complete(di, devices);
}
static int dev_open(struct sr_dev_inst *sdi)
/* Reset trigger state. */
devc->trigger_state = 0x00;
- std_session_send_df_header(sdi, LOG_PREFIX);
+ std_session_send_df_header(sdi);
/* Our first channel is analog, the other 8 are of type 'logic'. */
/* TODO. */