X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=hardware%2Fbeaglelogic%2Fprotocol.h;fp=hardware%2Fbeaglelogic%2Fprotocol.h;h=0000000000000000000000000000000000000000;hb=155b680da482cea2381becb73c51cfb838bff31e;hp=f2acfeb0151e84da53ae42fb7ab876edb4a4008b;hpb=43cd4637285833706f8a404ca027bcf0ee75b9ae;p=libsigrok.git diff --git a/hardware/beaglelogic/protocol.h b/hardware/beaglelogic/protocol.h deleted file mode 100644 index f2acfeb0..00000000 --- a/hardware/beaglelogic/protocol.h +++ /dev/null @@ -1,70 +0,0 @@ -/* - * This file is part of the libsigrok project. - * - * Copyright (C) 2014 Kumar Abhishek - * - * 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 - * the Free Software Foundation, either version 3 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program. If not, see . - */ - -#ifndef LIBSIGROK_HARDWARE_BEAGLELOGIC_PROTOCOL_H -#define LIBSIGROK_HARDWARE_BEAGLELOGIC_PROTOCOL_H - -#include -#include -#include "libsigrok.h" -#include "libsigrok-internal.h" - -#define LOG_PREFIX "beaglelogic" - -/* Maximum possible input channels */ -#define NUM_CHANNELS 14 - -#define SAMPLEUNIT_TO_BYTES(x) ((x) == 1 ? 1 : 2) - -/** Private, per-device-instance driver context. */ -struct dev_context { - /* Model-specific information */ - int max_channels; - uint32_t fw_ver; - - /* Acquisition settings: see beaglelogic.h */ - uint64_t cur_samplerate; - uint64_t limit_samples; - uint32_t sampleunit; - uint32_t triggerflags; - - /* Buffers: size of each buffer block and the total buffer area */ - uint32_t bufunitsize; - uint32_t buffersize; - - /* Operational state */ - int fd; - GPollFD pollfd; - int last_error; - - uint64_t bytes_read; - uint64_t sent_samples; - uint32_t offset; - uint8_t *sample_buf; /* mmap'd kernel buffer here */ - - void *cb_data; - - /* Trigger logic */ - struct soft_trigger_logic *stl; - gboolean trigger_fired; -}; - -SR_PRIV int beaglelogic_receive_data(int fd, int revents, void *cb_data); - -#endif