X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=src%2Fhardware%2Fyokogawa-dlm%2Fprotocol.h;h=0950267a3a0065a90df5cb7806bb829e066553a1;hb=db560903d196c39bceeaa543317fa602a02b51ac;hp=54b087cdccc8d7104a129cb25496084cd37d7ceb;hpb=8ab929d614262dc446ee2e948ca583d31110b14b;p=libsigrok.git diff --git a/src/hardware/yokogawa-dlm/protocol.h b/src/hardware/yokogawa-dlm/protocol.h index 54b087cd..0950267a 100644 --- a/src/hardware/yokogawa-dlm/protocol.h +++ b/src/hardware/yokogawa-dlm/protocol.h @@ -33,6 +33,8 @@ #define LOG_PREFIX "yokogawa-dlm" #define MAX_INSTRUMENT_VERSIONS 4 +#define RECEIVE_BUFFER_SIZE (4096) + /* See Communication Interface User's Manual on p. 268 (:WAVeform:ALL:SEND?). */ #define DLM_MAX_FRAME_LENGTH (12500) /* See Communication Interface User's Manual on p. 269 (:WAVeform:SEND?). */ @@ -77,8 +79,6 @@ struct scope_config { const uint8_t num_xdivs; const uint8_t num_ydivs; - - const char *(*scpi_dialect)[]; }; struct analog_channel_state { @@ -101,6 +101,7 @@ struct scope_state { int trigger_source; int trigger_slope; uint64_t sample_rate; + uint32_t samples_per_frame; }; /** Private, per-device-instance driver context. */ @@ -116,6 +117,9 @@ struct dev_context { uint64_t num_frames; uint64_t frame_limit; + + char receive_buffer[RECEIVE_BUFFER_SIZE]; + gboolean data_pending; }; /*--- api.c -----------------------------------------------------------------*/ @@ -130,4 +134,6 @@ SR_PRIV void dlm_scope_state_destroy(struct scope_state *state); SR_PRIV int dlm_scope_state_query(struct sr_dev_inst *sdi); SR_PRIV int dlm_sample_rate_query(const struct sr_dev_inst *sdi); +SR_PRIV int dlm_channel_data_request(const struct sr_dev_inst *sdi); + #endif