X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=src%2Fhardware%2Fbaylibre-acme%2Fprotocol.h;h=2425c992648f72ebdce4e0525bb8f79ac36d2147;hb=92cd85149a2497e6eecd8f35e43893b905dc2faa;hp=13c00fe684679b9ec3aaeae9935909f11240447e;hpb=7c91c22a31a5017117116fa1fe6c2addbac813f1;p=libsigrok.git diff --git a/src/hardware/baylibre-acme/protocol.h b/src/hardware/baylibre-acme/protocol.h index 13c00fe6..2425c992 100644 --- a/src/hardware/baylibre-acme/protocol.h +++ b/src/hardware/baylibre-acme/protocol.h @@ -23,7 +23,7 @@ #include #include #include -#include "libsigrok.h" +#include #include "libsigrok-internal.h" #define LOG_PREFIX "baylibre-acme" @@ -49,25 +49,13 @@ enum probe_type { PROBE_TEMP, }; -enum channel_type { - ENRG_PWR = 1, - ENRG_CURR, - ENRG_VOL, - TEMP_IN, - TEMP_OUT, -}; - -/** Private, per-device-instance driver context. */ struct dev_context { uint64_t samplerate; - uint64_t limit_samples; - uint64_t limit_msec; + struct sr_sw_limits limits; uint32_t num_channels; - uint64_t samples_read; - int64_t start_time; - int64_t last_sample_fin; - int pipe_fds[2]; + uint64_t samples_missed; + int timer_fd; GIOChannel *channel; }; @@ -98,4 +86,7 @@ SR_PRIV int bl_acme_set_power_off(const struct sr_channel_group *cg, SR_PRIV int bl_acme_receive_data(int fd, int revents, void *cb_data); +SR_PRIV int bl_acme_open_channel(struct sr_channel *ch); + +SR_PRIV void bl_acme_close_channel(struct sr_channel *ch); #endif