Commit Graph

778 Commits

Author SHA1 Message Date
Daniel Elstner 567674b4f8 sysclk-lwla: Remove double USB set configuration
This was a pointless attempt to make the reset hiccups go away.
It didn't help, the problem must be something else.
2015-11-27 21:26:13 +01:00
Daniel Elstner 7ed808179f sysclk-lwla: Cut down on size_t overuse
Do not use size_t for values whose width is defined by the device,
not the host. Also don't use size_t for simple indices with known
small range, unless type compatibility considerations apply.
2015-11-27 15:07:56 +01:00
Daniel Elstner 43af7604d0 sysclk-lwla: Fix copy'n'paste mistake in comment 2015-11-27 03:19:43 +01:00
Uwe Hermann 9e9dba7b41 Use the ALLZERO macro in more places. 2015-11-27 00:55:09 +01:00
Hannu Vuolasaho 2c5bdf1bbd Support for Korad KA3005P 2015-11-27 00:54:07 +01:00
Uwe Hermann 16fc7ee29f korad-kdxxxxp: Rename driver to korad-kaxxxxp.
This matches the supported / supportable devices better.
2015-11-27 00:54:07 +01:00
Uwe Hermann 89b3a0d8d1 doxygen: Only use @since on public API functions. 2015-11-27 00:17:31 +01:00
Petteri Aimonen db0e5c999d VCD input: Chunk up the samples in 1MB blocks.
This gives about 100x speed improvement when converting VCD->SR.

Also should allow practically unlimited number of channels.

This fixes bug #551.
2015-11-26 21:44:31 +01:00
Daniel Elstner 3393f185a5 session: Remove debug spew on I/O events
This really is a bit much with some drivers that do lots of small
I/O transfers.
2015-11-26 21:44:31 +01:00
Daniel Elstner be64f90b53 sysclk-lwla: Implement support for LWLA1016
Refactor the sysclk-lwla driver to separate the generic logic from
the model-specific implementation. Based on this, implement support
for the SysClk LWLA1016 device.
2015-11-26 21:44:31 +01:00
Daniel Elstner ce19d4c615 sysclk-lwla: Remove global driver instance pointer
Obtain the sr_dev_driver pointer from the device instance so that
the remaining references to the global di pointer can be removed.
2015-11-26 21:44:31 +01:00
Uwe Hermann e4ce146fef sr_usb_find(): Increase the 'bus' limit to 255.
On some systems it can happen that the USB 'bus' number is a lot larger
than 64, but sr_usb_find() currently errors out if it is > 64.

Example:
Bus 250 Device 006: ID 1ab1:04ce 1ab1 DS1000Z Series[...]

Increase that limit so that the code will work everywhere. This bus number
is queried via libusb_get_bus_number() which returns an uint8_t, so we're
limiting to 255 here.

Thanks to 'ssi' on IRC for reporting the issue.
2015-11-21 20:27:25 +01:00
Matthieu Gaillet d79244dc34 serial-dmm: Add support for Velleman DVM4100 & PeakTech 3415.
(both are using the new dtm0660 DMM parser)
2015-11-15 23:54:37 +01:00
Matthieu Gaillet eed3dec849 Add dtm0660 15-byte DMM protocol parser. 2015-11-15 23:54:37 +01:00
Uwe Hermann b98b70222f usb.c: Fix usb_get_port_path() issue on Mac OS X.
Apparently (some versions of) Mac OS X have the same problem with
usb_get_port_path() as FreeBSD does. Work around this in the same way.

Thanks to hanyazou@gmail.com for the patch!

This fixes bug #673.
2015-11-15 19:11:54 +01:00
Uwe Hermann 382bea8250 chronovu-la: Add missing libusb dependencies.
The chronovu-la driver now uses libusb (in addition to libftdi), so add
a missing <libusb.h> #include and libusb dependency in configure.ac.
2015-11-15 16:20:07 +01:00
Uwe Hermann 67f890d5bb chronovu-la: Properly handle multiple devices.
The driver should now be able to cope with e.g. multiple ChronoVu LA8
and/or ChronoVu LA16 devices being connected to the same PC.

It now also provides the serial number and connection ID, which can be
used by frontends to differentiate multiple devices.

Also improve the scanopts / drvopts / devopts lists handling.

This fixes bug #504.
2015-11-09 01:54:41 +01:00
Uwe Hermann d0f1fa0758 asix-sigma: Drop unneeded asix_sigma_driver_info.
This is not needed, but also causes linker issues on some platforms.
2015-11-08 19:11:25 +01:00
Uwe Hermann 2c24077466 Constify a lot more items.
This fixes various compiler warnings when -Wdiscarded-qualifiers is used.
2015-11-08 19:11:25 +01:00
jry 3ba56876b4 asix-sigma: Split into api.c and protocol.[ch] modules. 2015-11-05 21:26:39 +01:00
Daniel Elstner 8105e82913 openbench-logic-sniffer: Avoid recreating event source
With the current driver API and the corresponding session event
handling, it is not possible to destroy and then re-create an
event source with the same key within the same main loop iteration.

The next generation driver API will fix this problem. But for now,
just change the driver to make do without that sort of thing. Also
increase the I/O timeout to 100 ms to be safer in the event of all
kind of delays the OS environment may induce.

This fixes bug #678.
2015-11-01 19:38:40 +01:00
Bert Vermeulen d09a82a8fe Remove obsolete SR_INPUT_META_MIMETYPE metadata key.
This was never really implemented, since getting the mimetype of a
file or stream in a cross-platform way is a gigantic tangle.
2015-10-31 18:56:34 +01:00
Bert Vermeulen c958ab59d6 input/csv: Remove obsolete mimetype format match.
Mimetypes never worked, and in any case this caused a segfault due to a
missing SR_INPUT_META_REQUIRED flag.

This fixes bug #681.
2015-10-31 18:54:50 +01:00
Daniel Elstner 58cc125b0f sysclk-lwla: Read full 64 bit of capture duration field
Evaluate all 64 bit of the duration field in the capture status
record. Although unlikely in practical use, due to compression
it is possible for the duration in ms to exceed 32 bit.
2015-10-31 10:19:51 +01:00
Daniel Elstner 30f34dbdf0 sysclk-lwla: Define constants for long registers 2015-10-31 01:39:03 +01:00
Daniel Elstner 586ff70a21 sysclk-lwla: Clarify use of SRAM control registers
Assign more meaningful names to things and introduce new constants.
2015-10-31 01:11:31 +01:00
Daniel Elstner a6dc3dacab zip: Provide fallback if zip_discard() is unavailable
zip_discard() was introduced in libzip 0.11, which some systems
do not have yet. Provide a fallback replacement for zip_discard(),
and reduce the requirement to libzip 0.10 again.

This fixes bug #674.
2015-10-30 15:09:46 +01:00
Daniel Elstner e1172cf847 sysclk-lwla: Read test word twice during initialization
During initialization of the LWLA1034, read the 64-bit test word
twice and verify the result of the second read only. This better
matches what the original vendor software does.
2015-10-30 12:51:16 +01:00
Daniel Elstner 3a322bbc3b sysclk-lwla: Clarify function of registers 10B0 to 10BC
Apparently, these four registers form an interface for indirect
access to another internal 64 bit wide memory. This is likely the
same memory as that accessed by the bulk transfer commands 7 and 8.
2015-10-30 12:51:16 +01:00
Uwe Hermann 9e5366df4f korad-kdxxxxp: Minor cosmetics and consistency changes. 2015-10-29 18:51:09 +01:00
Hannu Vuolasaho c40ed60f27 Over voltage and current protection support
Developed against Velleman LABPS3005D and seems to work.
2015-10-29 18:43:09 +01:00
Hannu Vuolasaho b16d975a5c Support for regulation status and fix for mysterious M
Added support for SR_CONF_REGULATION which returns value for CH1
Also VELLEMAN LABPS3005D (only device currently supported) sends single
'M' character in beginning of return value, which is specially discarded.
2015-10-29 18:43:09 +01:00
Martin Ling a00106b7f8 scpi: Move closing of discovered devices to sr_scpi_scan_resource(). 2015-10-25 22:40:35 +01:00
Martin Ling b7b873cea3 rigol-ds: After successfully finding a device, close it properly. 2015-10-24 22:50:37 +02:00
Aurelien Jacobs 7977054d61 scpi_usbtmc_libusb: remove libusb_clear_halt() hack which is not useful anymore 2015-10-24 22:11:38 +02:00
Uwe Hermann a73665a3fa transform/scale: Fix g_variant_new() argument. 2015-10-24 21:44:20 +02:00
Aurelien Jacobs 938bdc25b7 scpi_usbtmc_libusb: set_configuration only if it is not already set
This avoids the issues described here:
http://libusb.sourceforge.net/api-1.0/caveats.html#configsel
2015-10-24 21:32:13 +02:00
Aurelien Jacobs e40e9ca28d scpi_usbtmc_libusb: add Rigol DS2000 to the RL1 blacklist
The Rigol DS2000 series also give a USB timeout when trying to apply
RL1 lock or unlock.
2015-10-24 21:32:13 +02:00
Uwe Hermann 222fdfd526 Drop unneeded sr_analog_float_to_string().
A simple g_strdup_printf() is sufficient, no need for an extra
libsigrok API call here.
2015-10-24 21:21:50 +02:00
Tilman Sauerbeck a5c38703ee drivers: Fix behaviour when trying to set an invalid capture ratio.
Trying to configure an invalid capture ratio would reset the
previously configured value. Instead, we should just reject the
new value and keep the original one.
2015-10-24 21:10:29 +02:00
Uwe Hermann 087c4d59c0 fx2lafw: Drop obsolete macro usage. 2015-10-24 20:55:40 +02:00
Uwe Hermann 3e91de2bd6 fx2lafw: Add the official fx2lafw sigrok VID/PID pairs.
As supported by sigrok-firmware-fx2lafw >= 0.1.3:

 - 1D50:608C: fx2lafw-sigrok-fx2-8ch.fw

 - 1D50:608D: fx2lafw-sigrok-fx2-16ch.fw
2015-10-22 19:19:40 +02:00
Uwe Hermann 22fb1bffc3 analog.c: Various Doxygen additions and improvements. 2015-10-21 00:29:29 +02:00
Uwe Hermann 5cee3d08e4 analog.c: Return SR_ERR_ARG upon invalid arguments.
(instead of segfaulting)
2015-10-21 00:29:29 +02:00
Uwe Hermann 8ea0c90268 sr_analog_float_to_string(): Make 'digits' argument unsigned. 2015-10-21 00:29:29 +02:00
Uwe Hermann edb691fced SR_DF_ANALOG2 and sr_datafeed_analog2 renames.
Rename SR_DF_ANALOG2 to SR_DF_ANALOG, and 'struct sr_datafeed_analog2'
to 'struct sr_datafeed_analog'.
2015-10-20 23:32:45 +02:00
Uwe Hermann 5faebab290 SR_DF_ANALOG_OLD and sr_datafeed_analog_old renames.
Rename SR_DF_ANALOG to SR_DF_ANALOG_OLD, and 'struct sr_datafeed_analog'
to 'struct sr_datafeed_analog_old'.
2015-10-20 23:32:45 +02:00
Martin Ling ca79993bba session: Convert from SR_DF_ANALOG to SR_DF_ANALOG2 automatically.
This fixes bus #640.
2015-10-20 23:32:45 +02:00
Martin Ling 453629c137 output/csv: Support SR_DF_ANALOG2. 2015-10-20 23:32:45 +02:00
Martin Ling b73cac758e output/wav: Support SR_DF_ANALOG2. 2015-10-20 23:32:45 +02:00