Commit Graph

3796 Commits

Author SHA1 Message Date
Alexandru Gagniuc db23af7fc2 hp-3457a: Implement basic configuration and sampling
KNOWN ISSUES:
- When sampling with 100 NPLC, the poll function will timeout a few
times before the first sample is acquired. Increasing the timeout
passed to sr_scpi_source_add() will cause all the other commands to
be processed slowly, producing a sampling rate of about one sample
every ten seconds.
- Support for plug-in cards (44491A and 44492A) is not implemented.
- Support for AC, AC+DC and four-wire resistance measurements is not
implemented.
- Support for configuring the frequency measurement source is not
implemented.
2016-03-30 12:50:27 +02:00
Alexandru Gagniuc fadb19ac96 hwdriver: Add configuration key for number of powerline cycles
High precision multimeters have a special setting, called "number of
powerline cycles" (NPLC) which determines the integration time of the
ADC in terms of the power line period. Some devices need their NPLC
adjusted from the default value before they can measure at their full
rated precision.
2016-03-30 12:39:25 +02:00
Alexandru Gagniuc 8b0ad3a559 scpi/libgpib: Place device in local mode before closing handle
Devices connected on a real GPIB bus are placed in remote mode when
opening them. libgpib does not automatically place devices back in
local mode when closing the handle. It is thus possible to lock out a
GPIB device by probing it with libsigrok.

This happens on the HP 3457A meter, which does not have a "LOCAL"
command, and must be put back in local mode via GPIB handshake.
ibloc() takes care of this, and it does it on a per-device basis,
such that other devices on the GPIB bus are not affected.
2016-03-30 12:39:20 +02:00
Alexandru Gagniuc daf13c570f scpi/libgpib: Print error string instead of number on errors
libgpib has an error_string which formats a numeric error code into a
human-readable description. Use that instead of printing the numeric
code, as it makes debugging easier.
2016-03-30 12:32:55 +02:00
Alexandru Gagniuc 00b2a092c3 hp-3457a: Initial driver skeleton. 2016-03-30 12:32:55 +02:00
Soeren Apel 0586a0ef59 srzip: Optimize analog output saving
- Don't set capturefile if no logic channels are saved
 - Don't set total probes if no logic channels are saved
 - Save analog channels without index gaps (e.g. probe1/probe4)
2016-03-28 01:06:29 +02:00
Soeren Apel f476dd2d2b Enable loading of session files without total probes defined 2016-03-28 01:06:29 +02:00
Soeren Apel 9cfc695ffe Enable loading of session files without the unit size defined 2016-03-28 01:06:29 +02:00
Soeren Apel 7c69b528e4 Enable loading of session files without the capture file defined 2016-03-28 01:06:28 +02:00
Soeren Apel e5b280e4c7 analog save: Avoid index duplication between analog & logic channels. 2016-03-24 08:55:42 +01:00
Soeren Apel 1393bccfcb input/raw_analog: Prevent "duplicate const decl specifier" warning
Warnings emitted by gcc before this patch:
src/input/raw_analog.c:51:13: warning: duplicate 'const' declaration specifier [-Wduplicate-decl-specifier]
        const char const *fmt_name;
                   ^
src/input/raw_analog.c:55:35: warning: duplicate 'const' declaration specifier [-Wduplicate-decl-specifier]
static const struct sample_format const sample_formats[] =
                                  ^
2016-03-22 08:29:25 +01:00
Soeren Apel d9d57ceb28 Bindings: Update create_analog_packet() to the new analog format 2016-03-22 08:25:08 +01:00
Uwe Hermann 74a9c0adc0 output/srzip: Minor whitespace fixes. 2016-03-15 18:40:50 +01:00
Martin Ling 2dc4081540 session_driver: Process analog chunks into analog packets. 2016-03-14 00:34:09 +01:00
Martin Ling 906921bad2 session_driver: Read analog chunks from file. 2016-03-14 00:34:09 +01:00
Martin Ling b317d1bbfb sr_session_load(): Create analog channels from loaded file. 2016-03-14 00:34:09 +01:00
Martin Ling 26918dced0 srzip: Renumber analog channels from zero in output file. 2016-03-14 00:34:09 +01:00
Martin Ling 7163dcbe18 srzip: Save analog data. 2016-03-14 00:34:09 +01:00
Martin Ling eab052996c srzip: Store total number of analog channels. 2016-03-14 00:34:09 +01:00
Martin Ling 828832194f srzip: Count only logic channels in "total probes". 2016-03-14 00:34:09 +01:00
Uwe Hermann 8ccf5ceb17 udev rules file: Add entry for Hantek 6022BE. 2016-03-13 23:33:56 +01:00
Uwe Hermann c940b7a32f hantek-6xxx: libusb_get_device_descriptor() cannot fail. 2016-03-13 23:33:56 +01:00
Chriter f2a66a8ee6 hantek-6xxx: Initial driver implementation.
Note: This commit is based on the initial implementation by
Christer Ekholm (but stashed into one commit), with some adaptations
(forward porting, coding style and consistency fixes) by Uwe Hermann.
2016-03-13 23:33:56 +01:00
Chriter 6c6bc80a99 hantek-6xxx: Initial driver skeleton. 2016-03-09 19:20:13 +01:00
Uwe Hermann 5af975b587 maynuo-m97: Fix a typo in an error message. 2016-03-05 18:51:39 +01:00
Alexandru Gagniuc 6cc931283d scpi-pps: Add profile for Agilent N5763A 12.5V 120A supply 2016-03-05 18:49:30 +01:00
Uwe Hermann ba4dfbde11 fluke-dmm: Add support for the Fluke 289.
Thanks to Julien Bresciani <julien.bresciani@free.fr> for providing
the information about the required changes!
2016-03-04 17:38:35 +01:00
Wolfram Sang b84f91ff2e session: allocate correct amount of memory in sr_packet_copy
We want the size of the struct, not of a pointer to the struct. And to
be absolutely future proof, dereference the pointer we are assigning the
memory to (not the one we are copying the data from). Found by Coverity,
CID 50858.

Signed-off-by: Wolfram Sang <wsa@the-dreams.de>
2016-02-28 18:21:18 +01:00
Uwe Hermann 2217be1dd4 arachnid-labs-re-load-pro: Handle undervoltage condition.
Support the SR_CONF_UNDER_VOLTAGE_CONDITION* keys.

Undervoltage (and overtemperature) conditions now emit a
warning-level message as well.
2016-02-11 14:42:50 +01:00
Uwe Hermann 2fe1011f1d Add SR_CONF_UNDER_VOLTAGE_CONDITION* config keys.
Add two new config keys:

 - SR_CONF_UNDER_VOLTAGE_CONDITION

 - SR_CONF_UNDER_VOLTAGE_CONDITION_ACTIVE
2016-02-11 14:42:50 +01:00
Uwe Hermann 8084e0fa81 arachnid-labs-re-load-pro: Only support firmware >= 1.10.
The "on\n" and "off\n" commands require this.
2016-02-11 14:42:50 +01:00
Uwe Hermann 8501448cfe arachnid-labs-re-load-pro: Add support for setting SR_CONF_ENABLED.
The firmware has "on\n" and "off\n" commands since 1.10, so use them.

Apparently you can only set the state (on/off) of the load, but it's
not possible to query the current state.
2016-02-11 14:42:50 +01:00
Uwe Hermann 6e68da5140 arachnid-labs-re-load-pro: Convert to SR_DF_ANALOG. 2016-02-11 14:42:50 +01:00
Uwe Hermann 803db07a1a arachnid-labs-re-load-pro: Add initial driver. 2016-02-08 15:02:29 +01:00
Uwe Hermann 6e8d31d468 arachnid-labs-re-load-pro: Initial driver skeleton. 2016-02-08 15:02:29 +01:00
Aurelien Jacobs 83bf4762e4 beaglelogic: use standard # operator instead of ugly __STRING macro
Also note that the __ namespace is reserved by POSIX for its private
usage, so user land software should never rely on any kind of API
with a __ prefix.
2016-02-06 17:24:34 +01:00
Uwe Hermann 29d3876a0b configure.ac: Bump package version to 0.5.0.
0.5.0 will be the next major, API-changing release. Bump now, so that
there is no confusion of tarball 0.4.0 and 0.5.0-git snapshots.
2016-02-06 15:19:06 +01:00
Uwe Hermann 89c82260b0 Bump libtool version (not package version) to 3:0:0.
The last release (0.3.0) had the libtool version (current:revision:age)
set to 2:0:0. Since this release adds, removes, and changes interfaces,
the new version is 3:0:0.

http://www.gnu.org/software/libtool/manual/libtool.html#Updating-version-info

This changes the library filename (e.g. on Linux) from libsigrok.so.2.0.0
to libsigrok.so.3.0.0, the SONAME (+symlink) becomes libsigrok.so.3.
2016-01-29 23:23:06 +01:00
Uwe Hermann 18b9bbb39c NEWS: Update for upcoming 0.4.0 release. 2016-01-29 23:23:06 +01:00
Soeren Apel 10c4ca9c5b hameg-hmo/yokogawa-dlm: Fix warning about pointer typecast 2016-01-29 23:13:32 +01:00
Soeren Apel a084a8f2a4 SCPI: Do not use RL1 lockout for Yokogawa devices 2016-01-29 21:59:06 +01:00
Soeren Apel b18b8a9202 yokogawa-dlm: Fix array_float_get() 2016-01-29 21:39:20 +01:00
Soeren Apel 8cccbac8da hameg-hmo: Fix array_float_get() and also use it for the time base 2016-01-29 21:35:16 +01:00
Soeren Apel fe227d17ae hameg-hmo: Add missing 20/50V vdiv entries 2016-01-29 21:13:07 +01:00
Soeren Apel e786b19467 hameg-hmo: Add more supported scope models 2016-01-29 21:08:49 +01:00
Uwe Hermann b90400ed89 README: Bump bindings requirements to the upcoming 0.4.0 release. 2016-01-29 18:31:00 +01:00
Uwe Hermann db5449b918 README: Mention the missing libieee1284 requirement. 2016-01-29 18:30:32 +01:00
Lars-Peter Clausen b165a24234 hung-chang-dso-2100: Fix session source fd
For session sources without a file descriptor to poll a negative number
should be passed for the fd parameter. The hung-chang-dso-2100 driver
currently passes 0 instead, which is the stdin stream. Fix the issue by
passing -1 for the fd parameter.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
2016-01-29 18:24:42 +01:00
Uwe Hermann eb8e6cd2cb Use libusb_error_name() more often for better diagnostics. 2016-01-29 18:00:11 +01:00
Aurelien Jacobs 9dfacd8706 demo: fix infinite loop with 0 channels of one type
The following command line exhibits the inifinit loop:
  sigrok-cli -d demo:analog_channels=0 --samples=8
2016-01-28 23:41:19 +01:00