X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=src%2Fhardware%2Fappa-55ii%2Fprotocol.h;h=171ac63670cb959391e8cfc640144042f8846c37;hb=49a468ed8bbd4d8f70cedc8fea205fba45e2e552;hp=fa3c247694a4c2b9b680b18e84c2fbc4c250fdca;hpb=155b680da482cea2381becb73c51cfb838bff31e;p=libsigrok.git diff --git a/src/hardware/appa-55ii/protocol.h b/src/hardware/appa-55ii/protocol.h index fa3c2476..171ac636 100644 --- a/src/hardware/appa-55ii/protocol.h +++ b/src/hardware/appa-55ii/protocol.h @@ -22,33 +22,24 @@ #include #include -#include "libsigrok.h" +#include #include "libsigrok-internal.h" #define LOG_PREFIX "appa-55ii" -#define APPA_55II_NUM_CHANNELS 2 -#define APPA_55II_BUF_SIZE (4 + 32 + 1) -#define DEFAULT_DATA_SOURCE DATA_SOURCE_LIVE +#define APPA_55II_NUM_CHANNELS 2 +#define APPA_55II_BUF_SIZE (4 + 32 + 1) +#define DEFAULT_DATA_SOURCE DATA_SOURCE_LIVE enum { DATA_SOURCE_LIVE, DATA_SOURCE_MEMORY, }; -/** Private, per-device-instance driver context. */ struct dev_context { - /* Acquisition settings */ - uint64_t limit_samples; /**< The sampling limit (in number of samples). */ - uint64_t limit_msec; /**< The time limit (in milliseconds). */ - gboolean data_source; /**< Whether to read live samples or memory */ - void *session_cb_data; /**< Opaque pointer passed in by the frontend. */ + struct sr_sw_limits limits; + gboolean data_source; /**< Whether to read live samples or memory */ - /* Operational state */ - uint64_t num_samples; /**< The number of already received samples. */ - int64_t start_time; /**< The time at which sampling started. */ - - /* Temporary state across callbacks */ uint8_t buf[APPA_55II_BUF_SIZE]; unsigned int buf_len; uint8_t log_buf[64];