* struct sr_context *sr_ctx;
*
* if ((ret = sr_init(&sr_ctx)) != SR_OK) {
- * printf("Error initializing libsigrok (%s): %s.",
+ * printf("Error initializing libsigrok (%s): %s.\n",
* sr_strerror_name(ret), sr_strerror(ret));
* return 1;
* }
* // Use libsigrok functions here...
*
* if ((ret = sr_exit(sr_ctx)) != SR_OK) {
- * printf("Error shutting down libsigrok (%s): %s.",
+ * printf("Error shutting down libsigrok (%s): %s.\n",
* sr_strerror_name(ret), sr_strerror(ret));
* return 1;
* }
}
#endif
+/** @private */
SR_PRIV struct sr_usbtmc_dev_inst *sr_usbtmc_dev_inst_new(const char *device)
{
struct sr_usbtmc_dev_inst *usbtmc;
return usbtmc;
}
+/** @private */
SR_PRIV void sr_usbtmc_dev_inst_free(struct sr_usbtmc_dev_inst *usbtmc)
{
g_free(usbtmc->device);
SR_MQFLAG_AVG = 0x40000,
};
-/** sigrok context (opaque). @see sr_init(), sr_exit(). */
+/**
+ * @struct sr_context
+ * Opaque structure representing a libsigrok context.
+ *
+ * None of the fields of this structure are meant to be accessed directly.
+ *
+ * @see sr_init(), sr_exit().
+ */
struct sr_context;
/** Packet in a sigrok data feed. */
};
/**
+ * @struct sr_session
+ *
* Opaque data structure representing a libsigrok session. None of the fields
* of this structure are meant to be accessed directly.
*/
*/
/**
+ * @private
+ *
* Convert a string representation of a numeric value to a long integer. The
* conversion is strict and will fail if the complete string does not represent
* a valid long integer. The function sets errno according to the details of the
}
/**
+ * @private
+ *
* Convert a string representation of a numeric value to an integer. The
* conversion is strict and will fail if the complete string does not represent
* a valid integer. The function sets errno according to the details of the
}
/**
+ * @private
+ *
* Convert a string representation of a numeric value to a double. The
* conversion is strict and will fail if the complete string does not represent
* a valid double. The function sets errno according to the details of the
}
/**
+ * @private
+ *
* Convert a string representation of a numeric value to a float. The
* conversion is strict and will fail if the complete string does not represent
* a valid float. The function sets errno according to the details of the