]> sigrok.org Git - libsigrok.git/log
libsigrok.git
11 years agosr: comments/docs
Bert Vermeulen [Sun, 22 Jul 2012 18:06:13 +0000 (20:06 +0200)]
sr: comments/docs

11 years agosr: change sr_dev_probe_name_set() to use sdi
Bert Vermeulen [Sun, 22 Jul 2012 18:05:36 +0000 (20:05 +0200)]
sr: change sr_dev_probe_name_set() to use sdi

11 years agosr: remove dead/obsolete code
Bert Vermeulen [Sun, 22 Jul 2012 17:44:20 +0000 (19:44 +0200)]
sr: remove dead/obsolete code

11 years agosr: cosmetic changes
Bert Vermeulen [Sun, 22 Jul 2012 13:32:35 +0000 (15:32 +0200)]
sr: cosmetic changes

11 years agosr: change session API/code to use sdi
Bert Vermeulen [Sun, 22 Jul 2012 13:31:56 +0000 (15:31 +0200)]
sr: change session API/code to use sdi

11 years agosr: remove obsolete dev_status_get() API call from session driver
Bert Vermeulen [Sun, 22 Jul 2012 13:19:53 +0000 (15:19 +0200)]
sr: remove obsolete dev_status_get() API call from session driver

11 years agosr: cosmetic changes
Bert Vermeulen [Sun, 22 Jul 2012 13:15:26 +0000 (15:15 +0200)]
sr: cosmetic changes

11 years agosr: change sr_datafeed_callback_t to use sdi
Bert Vermeulen [Sun, 22 Jul 2012 13:05:47 +0000 (15:05 +0200)]
sr: change sr_datafeed_callback_t to use sdi

11 years agosr: convert sr_dev_has_hwcap() to use sdi
Bert Vermeulen [Sun, 22 Jul 2012 12:33:28 +0000 (14:33 +0200)]
sr: convert sr_dev_has_hwcap() to use sdi

11 years agosr: convert sr_parse_triggerstring() to use sdi
Bert Vermeulen [Sun, 22 Jul 2012 12:28:40 +0000 (14:28 +0200)]
sr: convert sr_parse_triggerstring() to use sdi

11 years agosr/drivers: remove driver API call dev_status_get()
Bert Vermeulen [Sun, 22 Jul 2012 10:37:59 +0000 (12:37 +0200)]
sr/drivers: remove driver API call dev_status_get()

It's obsolete: no frontend ever used it, and neither did libsigrok.
The sdi->status field is only used internally by some drivers, and
should probably be moved to the driver-specific context structs.

11 years agools: change driver dev_acquisition_start/_stop calls to use sdi
Bert Vermeulen [Sun, 22 Jul 2012 10:35:57 +0000 (12:35 +0200)]
ols: change driver dev_acquisition_start/_stop calls to use sdi

...yeah, forgot OLS.

11 years agosr: add sr_dev_probe_enable(), abstraction wrapper around device probes
Bert Vermeulen [Sun, 22 Jul 2012 10:23:59 +0000 (12:23 +0200)]
sr: add sr_dev_probe_enable(), abstraction wrapper around device probes

11 years agosr: convert session load/save code to use sr_dev_inst
Bert Vermeulen [Sun, 22 Jul 2012 10:18:34 +0000 (12:18 +0200)]
sr: convert session load/save code to use sr_dev_inst

11 years agogenericdmm: cosmetic change
Bert Vermeulen [Sun, 22 Jul 2012 09:49:00 +0000 (11:49 +0200)]
genericdmm: cosmetic change

11 years agozeroplus: comment out 32-probe models for now
Bert Vermeulen [Sun, 22 Jul 2012 00:09:58 +0000 (02:09 +0200)]
zeroplus: comment out 32-probe models for now

11 years agozeroplus-logic-cube: fix scan to correctly find model
Bert Vermeulen [Sun, 22 Jul 2012 00:08:59 +0000 (02:08 +0200)]
zeroplus-logic-cube: fix scan to correctly find model

11 years agosr/drivers: change driver dev_acquisition_start/_stop calls to use sdi
Bert Vermeulen [Sat, 21 Jul 2012 20:41:58 +0000 (22:41 +0200)]
sr/drivers: change driver dev_acquisition_start/_stop calls to use sdi

11 years agosr/drivers: change driver dev_open/dev_close calls to use sdi
Bert Vermeulen [Sat, 21 Jul 2012 20:04:47 +0000 (22:04 +0200)]
sr/drivers: change driver dev_open/dev_close calls to use sdi

11 years agosr: change sr_dev_trigger_set() to use sdi
Bert Vermeulen [Sat, 21 Jul 2012 17:11:49 +0000 (19:11 +0200)]
sr: change sr_dev_trigger_set() to use sdi

11 years agosr: change input/output modules to use struct sr_dev_inst *
Bert Vermeulen [Fri, 20 Jul 2012 19:37:36 +0000 (21:37 +0200)]
sr: change input/output modules to use struct sr_dev_inst *

11 years agosr/drivers: use sr_dev_inst instead of device index for dev_config_set()
Bert Vermeulen [Mon, 16 Jul 2012 01:52:14 +0000 (03:52 +0200)]
sr/drivers: use sr_dev_inst instead of device index for dev_config_set()

All driver API calls using device index as a parameter will instead use a
const struct sr_dev_inst.

11 years agochronovu-la8: adjust to multi-vid/pid patch
Bert Vermeulen [Sun, 15 Jul 2012 17:24:10 +0000 (19:24 +0200)]
chronovu-la8: adjust to multi-vid/pid patch

11 years agosr: use new info_get API call in session driver
Bert Vermeulen [Sun, 15 Jul 2012 02:33:38 +0000 (04:33 +0200)]
sr: use new info_get API call in session driver

11 years agozeroplus-logic-cube: don't use deprecated hwcap_get_all() driver API call
Bert Vermeulen [Sun, 15 Jul 2012 02:33:10 +0000 (04:33 +0200)]
zeroplus-logic-cube: don't use deprecated hwcap_get_all() driver API call

11 years agools: don't use deprecated hwcap_get_all() driver API call
Bert Vermeulen [Sun, 15 Jul 2012 02:32:53 +0000 (04:32 +0200)]
ols: don't use deprecated hwcap_get_all() driver API call

11 years agohantek-dso: don't use deprecated hwcap_get_all() driver API call
Bert Vermeulen [Sun, 15 Jul 2012 02:32:37 +0000 (04:32 +0200)]
hantek-dso: don't use deprecated hwcap_get_all() driver API call

11 years agofx2lafw: don't use deprecated hwcap_get_all() driver API call
Bert Vermeulen [Sun, 15 Jul 2012 02:32:21 +0000 (04:32 +0200)]
fx2lafw: don't use deprecated hwcap_get_all() driver API call

11 years agodemo: don't use deprecated hwcap_get_all() driver API call
Bert Vermeulen [Sun, 15 Jul 2012 02:31:58 +0000 (04:31 +0200)]
demo: don't use deprecated hwcap_get_all() driver API call

11 years agochronovu-la8: don't use deprecated hwcap_get_all() driver API call
Bert Vermeulen [Sun, 15 Jul 2012 02:31:37 +0000 (04:31 +0200)]
chronovu-la8: don't use deprecated hwcap_get_all() driver API call

11 years agoasix-sigma: don't use deprecated hwcap_get_all() driver API call
Bert Vermeulen [Sun, 15 Jul 2012 02:31:22 +0000 (04:31 +0200)]
asix-sigma: don't use deprecated hwcap_get_all() driver API call

11 years agools: scan fix
Bert Vermeulen [Sun, 15 Jul 2012 02:08:49 +0000 (04:08 +0200)]
ols: scan fix

11 years agohantek-dso: scan/info_get fixes
Bert Vermeulen [Sun, 15 Jul 2012 02:08:21 +0000 (04:08 +0200)]
hantek-dso: scan/info_get fixes

11 years agodemo: scan/info_get fixes
Bert Vermeulen [Sun, 15 Jul 2012 02:07:51 +0000 (04:07 +0200)]
demo: scan/info_get fixes

11 years agochronovu-la8: scan/info_get fixes
Bert Vermeulen [Sun, 15 Jul 2012 02:07:34 +0000 (04:07 +0200)]
chronovu-la8: scan/info_get fixes

11 years agoasix-sigma: scan/info_get fixes
Bert Vermeulen [Sun, 15 Jul 2012 02:06:57 +0000 (04:06 +0200)]
asix-sigma: scan/info_get fixes

11 years agozeroplus-logic-cube: use new driver info_get() API call
Bert Vermeulen [Sun, 15 Jul 2012 01:53:09 +0000 (03:53 +0200)]
zeroplus-logic-cube: use new driver info_get() API call

11 years agools: use new driver info_get() API call
Bert Vermeulen [Sun, 15 Jul 2012 01:52:57 +0000 (03:52 +0200)]
ols: use new driver info_get() API call

11 years agohantek-dso: use new driver info_get() API call
Bert Vermeulen [Sun, 15 Jul 2012 01:52:45 +0000 (03:52 +0200)]
hantek-dso: use new driver info_get() API call

11 years agodemo: use new driver info_get() API call
Bert Vermeulen [Sun, 15 Jul 2012 01:52:37 +0000 (03:52 +0200)]
demo: use new driver info_get() API call

11 years agochronovu-la8: use new driver info_get() API call
Bert Vermeulen [Sun, 15 Jul 2012 01:52:22 +0000 (03:52 +0200)]
chronovu-la8: use new driver info_get() API call

11 years agoasix-sigma: use new driver info_get() API call
Bert Vermeulen [Sun, 15 Jul 2012 01:52:04 +0000 (03:52 +0200)]
asix-sigma: use new driver info_get() API call

11 years agoasix-sigma: don't attempt to free static struct
Bert Vermeulen [Sat, 14 Jul 2012 14:14:01 +0000 (16:14 +0200)]
asix-sigma: don't attempt to free static struct

Added more debugging as well.

11 years agodemo: use new scan API
Bert Vermeulen [Sat, 14 Jul 2012 13:49:30 +0000 (15:49 +0200)]
demo: use new scan API

11 years agozeroplus-logic-cube: init and scan fixes
Bert Vermeulen [Sat, 14 Jul 2012 11:00:47 +0000 (13:00 +0200)]
zeroplus-logic-cube: init and scan fixes

libusb context needs to be initialized only once, not ever scan.
Every scan invalidates the last one, so clean up any previous run's
results first.

11 years agozeroplus-logic-cube: use new scan API
Bert Vermeulen [Sat, 14 Jul 2012 10:45:07 +0000 (12:45 +0200)]
zeroplus-logic-cube: use new scan API

11 years agohantek-dso: use new scan API
Bert Vermeulen [Sat, 14 Jul 2012 10:28:45 +0000 (12:28 +0200)]
hantek-dso: use new scan API

11 years agoasix-sigma: use new scan API + fixes
Bert Vermeulen [Sat, 14 Jul 2012 10:28:15 +0000 (12:28 +0200)]
asix-sigma: use new scan API + fixes

Now freeing FTDI context and driver-private context.

11 years agochronovu-la8: use new scan API + fixes
Bert Vermeulen [Sat, 14 Jul 2012 10:27:02 +0000 (12:27 +0200)]
chronovu-la8: use new scan API + fixes

Now freeing FTDI context and driver-private context.

11 years agohantek-dso: instance list fix
Bert Vermeulen [Fri, 13 Jul 2012 20:18:01 +0000 (22:18 +0200)]
hantek-dso: instance list fix

11 years agools: use new scan API
Bert Vermeulen [Fri, 13 Jul 2012 20:16:37 +0000 (22:16 +0200)]
ols: use new scan API

11 years agoasix-sigma: use driver struct-based device instance list
Bert Vermeulen [Fri, 13 Jul 2012 12:18:27 +0000 (14:18 +0200)]
asix-sigma: use driver struct-based device instance list

11 years agochronovu-la8: use driver struct-based device instance list
Bert Vermeulen [Fri, 13 Jul 2012 12:15:54 +0000 (14:15 +0200)]
chronovu-la8: use driver struct-based device instance list

11 years agodemo: use driver struct-based device instance list
Bert Vermeulen [Fri, 13 Jul 2012 11:47:27 +0000 (13:47 +0200)]
demo: use driver struct-based device instance list

11 years agozeroplus-logic-cube: use driver struct-based device instance list
Bert Vermeulen [Fri, 13 Jul 2012 11:43:41 +0000 (13:43 +0200)]
zeroplus-logic-cube: use driver struct-based device instance list

11 years agohantek-dso: use driver struct-based device instance list
Bert Vermeulen [Fri, 13 Jul 2012 11:37:35 +0000 (13:37 +0200)]
hantek-dso: use driver struct-based device instance list

11 years agools: use driver struct-based device instance list
Bert Vermeulen [Fri, 13 Jul 2012 11:26:30 +0000 (13:26 +0200)]
ols: use driver struct-based device instance list

11 years agogenericdmm: device scan fixes
Bert Vermeulen [Fri, 13 Jul 2012 00:37:17 +0000 (02:37 +0200)]
genericdmm: device scan fixes

11 years agogenericdmm: don't use deprecated hwcap_get_all() driver API call
Bert Vermeulen [Fri, 13 Jul 2012 00:34:58 +0000 (02:34 +0200)]
genericdmm: don't use deprecated hwcap_get_all() driver API call

11 years agogenericdmm: use new driver info_get() API call
Bert Vermeulen [Fri, 13 Jul 2012 00:34:10 +0000 (02:34 +0200)]
genericdmm: use new driver info_get() API call

11 years agofx2lafw: don't use deprecated hwcap_get_all() driver API call
Bert Vermeulen [Fri, 13 Jul 2012 00:31:16 +0000 (02:31 +0200)]
fx2lafw: don't use deprecated hwcap_get_all() driver API call

11 years agofx2lafw: device scan fixes
Bert Vermeulen [Fri, 13 Jul 2012 00:30:42 +0000 (02:30 +0200)]
fx2lafw: device scan fixes

11 years agofx2lafw: a device scan always invalidates any previous scans
Bert Vermeulen [Fri, 13 Jul 2012 00:30:09 +0000 (02:30 +0200)]
fx2lafw: a device scan always invalidates any previous scans

11 years agofx2lafw: use new driver info_get() API call
Bert Vermeulen [Fri, 13 Jul 2012 00:28:07 +0000 (02:28 +0200)]
fx2lafw: use new driver info_get() API call

11 years agosr: deprecate driver API call hwcap_get_all()
Bert Vermeulen [Fri, 13 Jul 2012 00:08:27 +0000 (02:08 +0200)]
sr: deprecate driver API call hwcap_get_all()

This is now handled with a call to info_get(SR_DI_HWCAPS). This brings
it in line with the new driver opts: info_get(SR_DI_HWOPTS).

11 years agosr: new sr_info_get() API call, wrapper for driver info_get()
Bert Vermeulen [Thu, 12 Jul 2012 20:41:57 +0000 (22:41 +0200)]
sr: new sr_info_get() API call, wrapper for driver info_get()

This will replace sr_dev_info_get(), the wrapper for driver dev_info_get()

11 years agosr: add new driver API call info_get()
Bert Vermeulen [Thu, 12 Jul 2012 19:34:30 +0000 (21:34 +0200)]
sr: add new driver API call info_get()

This will replace dev_info_get(), and will be used to fetch both
driver and device instance-specific information. The sr_dev_inst
argument is NULL in case of a driver info fetch. In line with the
libsigrok wrapper, this function returns an error code, using the
supplied void ** to return the requested data.

11 years agosr: add driver field to sr_dev_inst, to bring it on a par with sr_dev.
Bert Vermeulen [Thu, 12 Jul 2012 19:00:18 +0000 (21:00 +0200)]
sr: add driver field to sr_dev_inst, to bring it on a par with sr_dev.

11 years agosr: split driver options into separate list
Bert Vermeulen [Thu, 12 Jul 2012 18:54:45 +0000 (20:54 +0200)]
sr: split driver options into separate list

11 years agogenericdmm: use new scan API
Bert Vermeulen [Sun, 8 Jul 2012 21:49:04 +0000 (23:49 +0200)]
genericdmm: use new scan API

11 years agogenericdmm: more flexible device discovery
Bert Vermeulen [Sun, 8 Jul 2012 21:48:04 +0000 (23:48 +0200)]
genericdmm: more flexible device discovery

11 years agogenericdmm: use driver struct-based device instance list
Bert Vermeulen [Sun, 8 Jul 2012 21:33:48 +0000 (23:33 +0200)]
genericdmm: use driver struct-based device instance list

11 years agofx2lafw: use driver struct-based device instance list
Bert Vermeulen [Sun, 8 Jul 2012 17:07:38 +0000 (19:07 +0200)]
fx2lafw: use driver struct-based device instance list

11 years agofx2lafw: use new instance-based probe list
Bert Vermeulen [Sun, 8 Jul 2012 17:06:23 +0000 (19:06 +0200)]
fx2lafw: use new instance-based probe list

11 years agofx2lafw: use new init/scan API
Bert Vermeulen [Sun, 8 Jul 2012 17:03:36 +0000 (19:03 +0200)]
fx2lafw: use new init/scan API

11 years agosr: add GSList of instances to the driver struct
Bert Vermeulen [Sun, 8 Jul 2012 14:40:54 +0000 (16:40 +0200)]
sr: add GSList of instances to the driver struct

This gives the driver a private place to keep its instances, without
polluting the global namespace.

11 years agosr: add probe list to device instance
Bert Vermeulen [Sun, 8 Jul 2012 14:37:39 +0000 (16:37 +0200)]
sr: add probe list to device instance

There is no point in libsigrok copying probe lists around. The driver now
builds a list of probes according to the model device it found, and will
make that available to a frontend. The frontend thus has a reference of
what the driver has, including default names, and doesn't need libsigrok
to provide an unnecessary level of abstraction.

The sr_probe_new() library-private function is a helper for drivers.

11 years agosr: split driver init into init() and scan()
Bert Vermeulen [Sun, 8 Jul 2012 14:25:23 +0000 (16:25 +0200)]
sr: split driver init into init() and scan()

init() now only does whatever administrative stuff it needs (typically not
much), and returns an error code.

scan() can be called multiple times during the life of an application, and
returns a GSList of struct sr_dev_inst * of devices found during that scan.
The instances are a copy of the ones stored in the driver's own instance
list, to be freed by the caller with g_slist_free() only.

The scan() call can be passed a GSList of struct sr_hwopt *, to direct the
scanning.

11 years agosr: move SR_HWOPT into its own enum, and create struct sr_hwopt
Bert Vermeulen [Sun, 8 Jul 2012 12:56:54 +0000 (14:56 +0200)]
sr: move SR_HWOPT into its own enum, and create struct sr_hwopt

SR_HWOPT_* entries are driver options, not device instance parameters, so
they will never be mixed together.

Also, driver options are always passed in a GSList, where the data field
is a struct sr_hwopt.

11 years agogenericdmm: better subdriver API arguments
Bert Vermeulen [Sun, 8 Jul 2012 02:17:56 +0000 (04:17 +0200)]
genericdmm: better subdriver API arguments

11 years agogenericdmm/fs9922: no initialization needed
Bert Vermeulen [Sun, 8 Jul 2012 02:15:51 +0000 (04:15 +0200)]
genericdmm/fs9922: no initialization needed

11 years agogenericdmm: allow for default options in DMM profiles
Bert Vermeulen [Sun, 8 Jul 2012 02:09:55 +0000 (04:09 +0200)]
genericdmm: allow for default options in DMM profiles

Much better than the special-cased USB vid.pid

11 years agogenericdmm: use vid.pid as USB conn spec
Bert Vermeulen [Sun, 8 Jul 2012 02:01:04 +0000 (04:01 +0200)]
genericdmm: use vid.pid as USB conn spec

: is just too hard for the CLI

11 years agogenericdmm: fix header guard
Bert Vermeulen [Sun, 8 Jul 2012 01:59:58 +0000 (03:59 +0200)]
genericdmm: fix header guard

11 years agosr: add new driver API call: scan()
Bert Vermeulen [Thu, 5 Jul 2012 09:27:48 +0000 (11:27 +0200)]
sr: add new driver API call: scan()

This changes the semantics of the init() call as well. That now only
initializes the driver -- an administrative affair, no hardware gets
touched during this call. It returns a standard SR_OK or SR_ERR* code.

The scan() call does a discovery run for devices it knows, and returns
the number found. It can be called at any time.

11 years agosr: remove unused argument from hardware driver function init()
Bert Vermeulen [Tue, 3 Jul 2012 10:55:46 +0000 (12:55 +0200)]
sr: remove unused argument from hardware driver function init()

It was actually used in one way: the session file loaded abused it for
passing in the filename -- something it definitely wasn't intended for.
This now uses the proper way to pass arguments to a driver: the new
SR_HWCAP_SESSIONFILE.

The OLS driver could also use it as an indication of the serial port to
use instead of actively probing all serial ports on the system, but there
wasn't any frontend code that passed in such a parameter, making it
entirely useless. That will soon be handled differently with the new
scan() API call, regardless.

11 years agosr: fix gnuplot script for USBee DX and clones
Ivan Fedorov [Thu, 2 Aug 2012 21:31:36 +0000 (01:31 +0400)]
sr: fix gnuplot script for USBee DX and clones

 - Now channels order is right
 - Added 16bit version

11 years agosr: fx2lafw: Add 16bit support for USBee DX and clones
Ivan Fedorov [Thu, 2 Aug 2012 19:49:00 +0000 (23:49 +0400)]
sr: fx2lafw: Add 16bit support for USBee DX and clones

gnuplot script support only 8 channels

11 years agosr: add gnuplot script for USBee DX and clones
Ivan Fedorov [Tue, 31 Jul 2012 20:11:40 +0000 (00:11 +0400)]
sr: add gnuplot script for USBee DX and clones

11 years agosr: fx2lafw: Add basic support for USBee DX and clones
Ivan Fedorov [Tue, 31 Jul 2012 20:11:33 +0000 (00:11 +0400)]
sr: fx2lafw: Add basic support for USBee DX and clones

11 years agosr: always use uint64_t for samplerate
Bert Vermeulen [Sun, 29 Jul 2012 00:45:40 +0000 (02:45 +0200)]
sr: always use uint64_t for samplerate

11 years agosr: extra checks for properly handling driverless devices
Bert Vermeulen [Sun, 29 Jul 2012 00:15:34 +0000 (02:15 +0200)]
sr: extra checks for properly handling driverless devices

11 years agosr: fix struct sr_input for parameter passing
Bert Vermeulen [Sun, 29 Jul 2012 00:13:22 +0000 (02:13 +0200)]
sr: fix struct sr_input for parameter passing

11 years agoAllow setting samplerate when reading binary files
Tomaž Šolc [Wed, 4 Jul 2012 14:29:13 +0000 (16:29 +0200)]
Allow setting samplerate when reading binary files

I had a binary file that I needed to decode using UART decoder. UART
decoder needs to know the sample rate for the data, but currently it's
not possible to pass parameters to input formats and so the "binary"
file format always sets the samplerate to 0.

This patch adds the possibility to append a colon-separated list of
key=value options to the -I argument, in the same way -d supports it.
Also, it makes the "binary" format support the "samplerate" option.

I included the GHashTable containing input format options directly in
the sr_input struct. I'm not sure if that's the right way to do it. I
saw that -d uses a much more elaborate system with device capabilities
and typed options, but that seemed like an overkill for input formats.

11 years agosr: chronovu-la8: fix segfault on discovery
Bert Vermeulen [Mon, 23 Jul 2012 22:50:02 +0000 (00:50 +0200)]
sr: chronovu-la8: fix segfault on discovery

If the uninitialized value didn't happen to contain 0, and there
is no Chronovu LA8 connected, the la8_close() causes a segfault
in libftdi.

11 years agosr: la8: Support for newer USB VID/PID of the device.
Uwe Hermann [Sat, 14 Jul 2012 22:34:27 +0000 (00:34 +0200)]
sr: la8: Support for newer USB VID/PID of the device.

Thanks to Jerry Jacobs for the patch!

11 years agosr: la8: Drop useless cast.
Uwe Hermann [Thu, 12 Jul 2012 19:39:18 +0000 (21:39 +0200)]
sr: la8: Drop useless cast.

11 years agosr: Add sr_strerror() and sr_strerror_name().
Uwe Hermann [Thu, 12 Jul 2012 19:30:49 +0000 (21:30 +0200)]
sr: Add sr_strerror() and sr_strerror_name().

11 years agosr: session: Deprecate sr_session_halt()
Lars-Peter Clausen [Thu, 5 Jul 2012 19:15:09 +0000 (21:15 +0200)]
sr: session: Deprecate sr_session_halt()

sr_session_halt() in its current state is kind of useless and even dangerous.
All it will do is mark the session as not running, but wont signal the devices
to stop to capture data. This is not so much of a problem with the blocking
sr_session_run(), but once there is support for asynchronous data acquisition by
attaching the session sources to the applications mainloop sr_session_halt()
basically becomes a no-op. sr_session_stop() already does what needs to be done,
marking the session as not running and signal the devices to stop acquisition,
so make sr_session_halt() an alias for sr_session_stop() and deprecate its
usage.

Signed-off-by: Lars-Peter Clausen <redacted>
11 years agosr: session: Do not cleanup the driver state in sr_session_stop()
Lars-Peter Clausen [Thu, 5 Jul 2012 19:15:08 +0000 (21:15 +0200)]
sr: session: Do not cleanup the driver state in sr_session_stop()

By cleaning up the driver state all devices will become inaccessible, which
means that is neither possible to query any information from it (like sample
rate) and it is also not possible to restart data acquisition.

sr_session_save() tries to query the sample rate from the device, as a result
calling sr_session_save() after calling sr_session_stop() - which is for example
done by sigrok-cli - will cause a segfault. This patch resolves the issue.

Signed-off-by: Lars-Peter Clausen <redacted>