yokogawa-dlm: Integrate driver skeleton

This commit is contained in:
Soeren Apel 2014-08-25 13:09:42 +02:00
parent 6e8d95a50c
commit 107639373d
9 changed files with 167 additions and 0 deletions

View File

@ -332,6 +332,14 @@ libsigrok_la_SOURCES += \
src/hardware/victor-dmm/protocol.c \
src/hardware/victor-dmm/api.c
endif
if HW_YOKOGAWA_DLM
libsigrok_la_SOURCES += \
src/hardware/yokogawa-dlm/protocol.h \
src/hardware/yokogawa-dlm/protocol.c \
src/hardware/yokogawa-dlm/protocol_wrappers.h \
src/hardware/yokogawa-dlm/protocol_wrappers.c \
src/hardware/yokogawa-dlm/api.c
endif
if HW_ZEROPLUS_LOGIC_CUBE
libsigrok_la_SOURCES += \
src/hardware/zeroplus-logic-cube/analyzer.c \

View File

@ -83,6 +83,7 @@ The following drivers/devices do not need any firmware upload:
- uni-t-dmm (including all subdrivers)
- uni-t-ut32x
- victor-dmm
- yokogawa-dlm
- zeroplus-logic-cube
@ -141,6 +142,7 @@ The following drivers/devices do not require a serial port specification:
- uni-t-dmm (including all subdrivers)
- uni-t-ut32x
- victor-dmm
- yokogawa-dlm (USBTMC or TCP)
- zeroplus-logic-cube

View File

@ -140,6 +140,7 @@ DRIVER([Tondaj SL-814], [tondaj-sl-814])
DRIVER([UNI-T DMM], [uni-t-dmm])
DRIVER([UNI-T UT32x], [uni-t-ut32x])
DRIVER([Victor DMM], [victor-dmm])
DRIVER([Yokogawa DL/DLM], [yokogawa-dlm])
DRIVER([ZEROPLUS Logic Cube], [zeroplus-logic-cube])
AC_ARG_ENABLE(libserialport,
@ -638,6 +639,11 @@ if test "x$HW_VICTOR_DMM" = "xyes"; then
AC_DEFINE(HAVE_HW_VICTOR_DMM, 1, [Victor DMM support])
fi
AM_CONDITIONAL(HW_YOKOGAWA_DLM, test x$HW_YOKOGAWA_DLM = xyes)
if test "x$HW_YOKOGAWA_DLM" = "xyes"; then
AC_DEFINE(HAVE_HW_YOKOGAWA_DLM, 1, [Yokogawa DL/DLM support])
fi
AM_CONDITIONAL(HW_ZEROPLUS_LOGIC_CUBE, test x$HW_ZEROPLUS_LOGIC_CUBE = xyes)
if test "x$HW_ZEROPLUS_LOGIC_CUBE" = "xyes"; then
AC_DEFINE(HAVE_HW_ZEROPLUS_LOGIC_CUBE, 1, [ZEROPLUS Logic Cube support])

View File

@ -187,6 +187,9 @@ extern SR_PRIV struct sr_dev_driver uni_t_ut32x_driver_info;
#ifdef HAVE_HW_VICTOR_DMM
extern SR_PRIV struct sr_dev_driver victor_dmm_driver_info;
#endif
#ifdef HAVE_HW_YOKOGAWA_DLM
extern SR_PRIV struct sr_dev_driver yokogawa_dlm_driver_info;
#endif
#ifdef HAVE_HW_ZEROPLUS_LOGIC_CUBE
extern SR_PRIV struct sr_dev_driver zeroplus_logic_cube_driver_info;
#endif
@ -358,6 +361,9 @@ SR_PRIV struct sr_dev_driver *drivers_list[] = {
#ifdef HAVE_HW_VICTOR_DMM
&victor_dmm_driver_info,
#endif
#ifdef HAVE_HW_YOKOGAWA_DLM
&yokogawa_dlm_driver_info,
#endif
#ifdef HAVE_HW_ZEROPLUS_LOGIC_CUBE
&zeroplus_logic_cube_driver_info,
#endif

View File

@ -0,0 +1,42 @@
/*
* This file is part of the libsigrok project.
*
* Copyright (C) 2014 abraxa (Soeren Apel) <soeren@apelpie.net>
* Based on the Hameg HMO driver by poljar (Damir Jelić) <poljarinho@gmail.com>
*
* 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 <http://www.gnu.org/licenses/>.
*/
#include <stdlib.h>
#include "protocol.h"
SR_PRIV struct sr_dev_driver yokogawa_dlm_driver_info = {
.name = "yokogawa-dlm",
.longname = "Yokogawa DL/DLM driver",
.api_version = 1,
.init = NULL,
.cleanup = NULL,
.scan = NULL,
.dev_list = NULL,
.dev_clear = NULL,
.config_get = NULL,
.config_set = NULL,
.config_list = NULL,
.dev_open = NULL,
.dev_close = NULL,
.dev_acquisition_start = NULL,
.dev_acquisition_stop = NULL,
.priv = NULL,
};

View File

@ -0,0 +1,22 @@
/*
* This file is part of the libsigrok project.
*
* Copyright (C) 2014 abraxa (Soeren Apel) <soeren@apelpie.net>
* Based on the Hameg HMO driver by poljar (Damir Jelić) <poljarinho@gmail.com>
*
* 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 <http://www.gnu.org/licenses/>.
*/
#include "protocol.h"

View File

@ -0,0 +1,30 @@
/*
* This file is part of the libsigrok project.
*
* Copyright (C) 2014 abraxa (Soeren Apel) <soeren@apelpie.net>
* Based on the Hameg HMO driver by poljar (Damir Jelić) <poljarinho@gmail.com>
*
* 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 <http://www.gnu.org/licenses/>.
*/
#ifndef LIBSIGROK_HARDWARE_YOKOGAWA_DLM_PROTOCOL_H
#define LIBSIGROK_HARDWARE_YOKOGAWA_DLM_PROTOCOL_H
#include <glib.h>
#include <stdint.h>
#include <string.h>
#include "libsigrok.h"
#include "libsigrok-internal.h"
#endif

View File

@ -0,0 +1,21 @@
/*
* This file is part of the libsigrok project.
*
* Copyright (C) 2014 abraxa (Soeren Apel) <soeren@apelpie.net>
*
* 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 <http://www.gnu.org/licenses/>.
*/
#include "protocol_wrappers.h"

View File

@ -0,0 +1,30 @@
/*
* This file is part of the libsigrok project.
*
* Copyright (C) 2014 abraxa (Soeren Apel) <soeren@apelpie.net>
*
* 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 <http://www.gnu.org/licenses/>.
*/
#ifndef LIBSIGROK_HARDWARE_YOKOGAWA_DLM_PROTOCOL_WRAPPERS_H
#define LIBSIGROK_HARDWARE_YOKOGAWA_DLM_PROTOCOL_WRAPPERS_H
#include <glib.h>
#include <stdint.h>
#include <string.h>
#include "libsigrok.h"
#include "libsigrok-internal.h"
#include "protocol.h"
#endif