if (!(sdi = sr_dev_inst_get(dev_insts, dev_index))) {
sr_err("sigma: %s: sdi was NULL", __func__);
if (!(sdi = sr_dev_inst_get(dev_insts, dev_index))) {
sr_err("sigma: %s: sdi was NULL", __func__);
}
if (!(ctx = sdi->priv)) {
sr_err("sigma: %s: sdi->priv was NULL", __func__);
}
if (!(ctx = sdi->priv)) {
sr_err("sigma: %s: sdi->priv was NULL", __func__);
*/
static int decode_chunk_ts(uint8_t *buf, uint16_t *lastts,
uint16_t *lastsample, int triggerpos,
*/
static int decode_chunk_ts(uint8_t *buf, uint16_t *lastts,
uint16_t *lastsample, int triggerpos,
struct context *ctx = sdi->priv;
struct sr_datafeed_packet packet;
const int chunks_per_read = 32;
struct context *ctx = sdi->priv;
struct sr_datafeed_packet packet;
const int chunks_per_read = 32;
gettimeofday(&ctx->start_tv, 0);
sigma_set_register(WRITE_MODE, 0x0d, ctx);
gettimeofday(&ctx->start_tv, 0);
sigma_set_register(WRITE_MODE, 0x0d, ctx);
gettimeofday(&header.starttime, NULL);
header.samplerate = ctx->cur_samplerate;
header.num_logic_probes = ctx->num_probes;
gettimeofday(&header.starttime, NULL);
header.samplerate = ctx->cur_samplerate;
header.num_logic_probes = ctx->num_probes;
/* Add capture source. */
sr_source_add(0, G_IO_IN, 10, receive_data, sdi);
/* Add capture source. */
sr_source_add(0, G_IO_IN, 10, receive_data, sdi);
if (!(sdi = sr_dev_inst_get(dev_insts, dev_index))) {
sr_err("sigma: %s: sdi was NULL", __func__);
if (!(sdi = sr_dev_inst_get(dev_insts, dev_index))) {
sr_err("sigma: %s: sdi was NULL", __func__);