X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=hardware%2Fagilent-dmm%2Fagilent-dmm.h;h=f3922a1fe9b314be86e46bfbf65cf08468daf2b4;hb=1e1bfcd0fef7c397b3d8fc6cd244263e6828a5da;hp=179d0013cfb4947102a1c0350484c843344c84d0;hpb=b186aa78b8302942c8853c9aed40e3e5eaba8e34;p=libsigrok.git diff --git a/hardware/agilent-dmm/agilent-dmm.h b/hardware/agilent-dmm/agilent-dmm.h index 179d0013..f3922a1f 100644 --- a/hardware/agilent-dmm/agilent-dmm.h +++ b/hardware/agilent-dmm/agilent-dmm.h @@ -21,6 +21,15 @@ #ifndef LIBSIGROK_AGILENT_DMM_H #define LIBSIGROK_AGILENT_DMM_H +/* Message logging helpers with driver-specific prefix string. */ +#define DRIVER_LOG_DOMAIN "agilent-dmm: " +#define sr_log(l, s, args...) sr_log(l, DRIVER_LOG_DOMAIN s, ## args) +#define sr_spew(s, args...) sr_spew(DRIVER_LOG_DOMAIN s, ## args) +#define sr_dbg(s, args...) sr_dbg(DRIVER_LOG_DOMAIN s, ## args) +#define sr_info(s, args...) sr_info(DRIVER_LOG_DOMAIN s, ## args) +#define sr_warn(s, args...) sr_warn(DRIVER_LOG_DOMAIN s, ## args) +#define sr_err(s, args...) sr_err(DRIVER_LOG_DOMAIN s, ## args) + #define AGDMM_BUFSIZE 256 /* Supported models */ @@ -37,22 +46,15 @@ enum { struct agdmm_profile { int model; const char *modelname; - int serial_speed; const struct agdmm_job *jobs; const struct agdmm_recv *recvs; }; -/* Private driver context. */ -struct drv_context { - GSList *instances; -}; - /* Private, per-device-instance driver context. */ struct dev_context { const struct agdmm_profile *profile; uint64_t limit_samples; uint64_t limit_msec; - struct sr_serial_dev_inst *serial; /* Opaque pointer passed in by the frontend. */ void *cb_data;