]> sigrok.org Git - libsigrok.git/blobdiff - sigrok-proto.h
device: Change some functions to return int.
[libsigrok.git] / sigrok-proto.h
index 2d2b5fd063dd209ab47a4ea69da2a0c1f8879489..28dbc01fe6db87624781becbd89092bf2a1707a7 100644 (file)
@@ -39,23 +39,23 @@ int sr_datastore_put(struct sr_datastore *ds, void *data, unsigned int length,
 
 /*--- device.c --------------------------------------------------------------*/
 
-void sr_device_scan(void);
+int sr_device_scan(void);
 int sr_init_hwplugins(struct sr_device_plugin *plugin);
 GSList *sr_device_list(void);
 struct sr_device *sr_device_new(struct sr_device_plugin *plugin,
                                int plugin_index, int num_probes);
-void sr_device_clear(struct sr_device *device);
+int sr_device_clear(struct sr_device *device);
 void sr_device_destroy(struct sr_device *dev);
 
-void sr_device_probe_clear(struct sr_device *device, int probenum);
-void sr_device_probe_add(struct sr_device *device, const char *name);
+int sr_device_probe_clear(struct sr_device *device, int probenum);
+int sr_device_probe_add(struct sr_device *device, const char *name);
 struct sr_probe *sr_device_probe_find(struct sr_device *device, int probenum);
-void sr_device_probe_name(struct sr_device *device, int probenum,
-                         const char *name);
+int sr_device_probe_name(struct sr_device *device, int probenum,
+                        const char *name);
 
-void sr_device_trigger_clear(struct sr_device *device);
-void sr_device_trigger_set(struct sr_device *device, int probenum,
-                          const char *trigger);
+int sr_device_trigger_clear(struct sr_device *device);
+int sr_device_trigger_set(struct sr_device *device, int probenum,
+                         const char *trigger);
 gboolean sr_device_has_hwcap(struct sr_device *device, int hwcap);
 
 /*--- filter.c --------------------------------------------------------------*/