X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;ds=inline;f=src%2Fhardware%2Fikalogic-scanaplus%2Fapi.c;h=2105bce130ed937ef4a9da75070a0c2c7f3b750f;hb=f670835f1fbc03525e995d6970a5495976ab7c1a;hp=520bf6fe94da19b3f29010a23ef555401daf88fa;hpb=43376f3324cddd257a0260b06d9db8180c35fdf3;p=libsigrok.git
diff --git a/src/hardware/ikalogic-scanaplus/api.c b/src/hardware/ikalogic-scanaplus/api.c
index 520bf6fe..2105bce1 100644
--- a/src/hardware/ikalogic-scanaplus/api.c
+++ b/src/hardware/ikalogic-scanaplus/api.c
@@ -14,8 +14,7 @@
* 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, write to the Free Software
- * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ * along with this program; if not, see .
*/
#include
@@ -44,8 +43,6 @@ static const char *channel_names[] = {
/* Note: The IKALOGIC ScanaPLUS always samples at 100MHz. */
static const uint64_t samplerates[1] = { SR_MHZ(100) };
-static int dev_acquisition_stop(struct sr_dev_inst *sdi);
-
static void clear_helper(void *priv)
{
struct dev_context *devc;
@@ -66,15 +63,12 @@ static int dev_clear(const struct sr_dev_driver *di)
static GSList *scan(struct sr_dev_driver *di, GSList *options)
{
struct sr_dev_inst *sdi;
- struct drv_context *drvc;
struct dev_context *devc;
unsigned int i;
int ret;
(void)options;
- drvc = di->context;
-
/* Allocate memory for our private device context. */
devc = g_malloc0(sizeof(struct dev_context));
@@ -331,9 +325,6 @@ static int dev_acquisition_start(const struct sr_dev_inst *sdi)
int ret;
struct dev_context *devc;
- if (sdi->status != SR_ST_ACTIVE)
- return SR_ERR_DEV_CLOSED;
-
devc = sdi->priv;
if (!devc->ftdic)
@@ -352,7 +343,7 @@ static int dev_acquisition_start(const struct sr_dev_inst *sdi)
if ((ret = scanaplus_start_acquisition(devc)) < 0)
return ret;
- std_session_send_df_header(sdi, LOG_PREFIX);
+ std_session_send_df_header(sdi);
/* Hook up a dummy handler to receive data from the device. */
sr_session_source_add(sdi->session, -1, 0, 0, scanaplus_receive_data, (void *)sdi);
@@ -362,9 +353,8 @@ static int dev_acquisition_start(const struct sr_dev_inst *sdi)
static int dev_acquisition_stop(struct sr_dev_inst *sdi)
{
- sr_dbg("Stopping acquisition.");
sr_session_source_remove(sdi->session, -1);
- std_session_send_df_end(sdi, LOG_PREFIX);
+ std_session_send_df_end(sdi);
return SR_OK;
}