X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=hardware%2Fopenbench-logic-sniffer%2Fols.h;h=f452c74846876bb81d5e507b08710fdcb02a3b6f;hb=5af666a94e67e8a18c0dfa1f4314e1c3e93aa993;hp=b9bbc67c6287775496de21b9263db42bde2de9a3;hpb=4fe9a6da79561d82f2c88c39e222ae86c5507900;p=libsigrok.git diff --git a/hardware/openbench-logic-sniffer/ols.h b/hardware/openbench-logic-sniffer/ols.h index b9bbc67c..f452c748 100644 --- a/hardware/openbench-logic-sniffer/ols.h +++ b/hardware/openbench-logic-sniffer/ols.h @@ -1,7 +1,7 @@ /* * This file is part of the sigrok project. * - * Copyright (C) 2011 Bert Vermeulen + * Copyright (C) 2010-2012 Bert Vermeulen * * This program is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -17,9 +17,8 @@ * along with this program. If not, see . */ - -#ifndef OLS_H_ -#define OLS_H_ +#ifndef LIBSIGROK_HARDWARE_OPENBENCH_LOGIC_SNIFFER_OLS_H +#define LIBSIGROK_HARDWARE_OPENBENCH_LOGIC_SNIFFER_OLS_H #define NUM_PROBES 32 #define NUM_TRIGGER_STAGES 4 @@ -60,8 +59,8 @@ #define FLAG_CLOCK_INVERTED 0x80 #define FLAG_RLE 0x0100 - -struct ols_device { +/* Private, per-device-instance driver context. */ +struct context { uint32_t max_samplerate; uint32_t max_samples; uint32_t protocol_version; @@ -83,11 +82,14 @@ struct ols_device { int num_stages; unsigned int num_transfers; + unsigned int num_samples; + int rle_count; int num_bytes; - char last_sample[4]; unsigned char sample[4]; unsigned char tmp_sample[4]; unsigned char *raw_sample_buf; + + struct sr_serial_dev_inst *serial; }; -#endif /* OLS_H_ */ +#endif