]> sigrok.org Git - sigrok-cli.git/log
sigrok-cli.git
8 years agosession: Supply filename to the output module directly
Soeren Apel [Wed, 29 Jul 2015 19:37:47 +0000 (21:37 +0200)]
session: Supply filename to the output module directly

This fixes parts of bug #570.

8 years agoBuild-depend on the upcoming libsigrok + libsigrokdecode 0.4.0.
Uwe Hermann [Sat, 18 Jul 2015 16:07:12 +0000 (18:07 +0200)]
Build-depend on the upcoming libsigrok + libsigrokdecode 0.4.0.

8 years agoBump version to 0.6.0 (the upcoming next major release).
Uwe Hermann [Sat, 18 Jul 2015 16:05:58 +0000 (18:05 +0200)]
Bump version to 0.6.0 (the upcoming next major release).

8 years agoAppend "-git" to the version string.
Uwe Hermann [Sat, 18 Jul 2015 16:05:36 +0000 (18:05 +0200)]
Append "-git" to the version string.

This avoids confusion with the released tarballs.

9 years agoCheck if hash table is NULL before accessing it.
Jens Steinhauser [Fri, 17 Apr 2015 21:28:44 +0000 (23:28 +0200)]
Check if hash table is NULL before accessing it.

This fixes bug 520.

9 years agoautogen.sh: Drop obsolete MinGW/MSYS items.
Uwe Hermann [Tue, 7 Apr 2015 00:38:39 +0000 (02:38 +0200)]
autogen.sh: Drop obsolete MinGW/MSYS items.

For Windows builds (which require MinGW-w64) we currently support:

 - cross-builds using MXE (mxe.cc) and possibly other cross-compile setups

 - native builds using MSYS2 (sf.net/projects/msys2/)

Neither of those require explicitly specifying ACLOCAL_DIR.

9 years agoUpdate due to sr_driver_list() now taking a context.
Uwe Hermann [Sat, 4 Apr 2015 17:34:06 +0000 (19:34 +0200)]
Update due to sr_driver_list() now taking a context.

9 years agoMinor cosmetics.
Uwe Hermann [Thu, 26 Mar 2015 20:56:29 +0000 (21:56 +0100)]
Minor cosmetics.

9 years agoDon't check g_free() arguments for NULL.
Uwe Hermann [Thu, 26 Mar 2015 20:51:37 +0000 (21:51 +0100)]
Don't check g_free() arguments for NULL.

The g_free() call is guaranteed to not segfault when NULL is passed.

9 years agoVarious #include file cosmetic fixes.
Uwe Hermann [Thu, 26 Mar 2015 20:39:28 +0000 (21:39 +0100)]
Various #include file cosmetic fixes.

Generally include system headers before local headers, unless there's
a technical reason to use another order.

9 years agosigrok-cli: Update for sr_session_{new,load} API change.
Martin Ling [Wed, 25 Mar 2015 01:54:52 +0000 (01:54 +0000)]
sigrok-cli: Update for sr_session_{new,load} API change.

9 years agoMinor cosmetics, whitespace- and consistency fixes.
Uwe Hermann [Fri, 20 Mar 2015 18:38:33 +0000 (19:38 +0100)]
Minor cosmetics, whitespace- and consistency fixes.

9 years agoUse sr_dev_channel_enable().
Martin Ling [Thu, 19 Mar 2015 22:00:34 +0000 (22:00 +0000)]
Use sr_dev_channel_enable().

9 years agoFix memory leak in config_key_has_cap().
Martin Ling [Wed, 18 Mar 2015 16:40:18 +0000 (16:40 +0000)]
Fix memory leak in config_key_has_cap().

9 years agosession.c: Indicate the error type when --config --set fails.
Bartosz Golaszewski [Thu, 26 Feb 2015 15:06:26 +0000 (16:06 +0100)]
session.c: Indicate the error type when --config --set fails.

When sigrok-cli fails to set a config option it doesn't indicate
the actual error as opposed to --get. Print the error message in
both cases.

Signed-off-by: Bartosz Golaszewski <redacted>
9 years agoshow: pass NULL parameter to config_key_has_cap() instead of uninitialized cg.
Aurelien Jacobs [Thu, 12 Feb 2015 16:08:33 +0000 (17:08 +0100)]
show: pass NULL parameter to config_key_has_cap() instead of uninitialized cg.

It doesn't make sense to pass a cg to this config_key_has_cap() call
as it is trying to retrieve the device's global SR_CONF_LIMIT_SAMPLES.

This fixes the following warning:

show.c: In function ‘show_dev_detail’:
show.c:392:8: warning: ‘cg’ may be used uninitialized in this function [-Wmaybe-uninitialized]
     && config_key_has_cap(driver, sdi, cg, key, SR_CONF_LIST)) {
        ^

9 years agosession: remove unused variable 'size'.
Aurelien Jacobs [Thu, 12 Feb 2015 15:00:54 +0000 (16:00 +0100)]
session: remove unused variable 'size'.

9 years agoImplement support for running transform modules.
Uwe Hermann [Wed, 11 Feb 2015 08:49:03 +0000 (09:49 +0100)]
Implement support for running transform modules.

Syntax:

 sigrok-cli ... -T <transformmodule>:opt1=val1:opt2=val2 ...

9 years agoAdd -T|--transform-module and show transform modules in -V output.
Uwe Hermann [Tue, 10 Feb 2015 19:01:07 +0000 (20:01 +0100)]
Add -T|--transform-module and show transform modules in -V output.

9 years agoREADME: Update build requirements list.
Uwe Hermann [Sat, 24 Jan 2015 19:52:31 +0000 (20:52 +0100)]
README: Update build requirements list.

9 years agoopt_to_gvar: notify the user in case of invalid values for --config
Bartosz Golaszewski [Thu, 4 Dec 2014 16:27:08 +0000 (17:27 +0100)]
opt_to_gvar: notify the user in case of invalid values for --config

sigrok-cli exits silently in many cases where values passed to --config are
empty strings or haven't been converted by GLib functions properly.

Check for errors and notify the user.

Signed-off-by: Bartosz Golaszewski <redacted>
9 years agoopt_to_gvar: support SR_T_KEYVALUE
Bartosz Golaszewski [Thu, 4 Dec 2014 16:27:07 +0000 (17:27 +0100)]
opt_to_gvar: support SR_T_KEYVALUE

The key-value data type is not supported as a configuration option. Implement
its support as a GLib dictionary.

Signed-off-by: Bartosz Golaszewski <redacted>
9 years agoopt_to_gvar: print an error message for unsupported data types
Bartosz Golaszewski [Thu, 4 Dec 2014 16:27:06 +0000 (17:27 +0100)]
opt_to_gvar: print an error message for unsupported data types

Unsupported data types are silently ignored in opt_to_gvar() switch
statement. This leads to confusion as sigrok-cli just exits without
giving the user any hint on what's the reason for not setting the option
properly.

Add an error message for unmatched data types.

Signed-off-by: Bartosz Golaszewski <redacted>
9 years agomingw: Drop libusb0.dll, always use libusb-1.0.
Uwe Hermann [Sun, 7 Dec 2014 16:48:29 +0000 (17:48 +0100)]
mingw: Drop libusb0.dll, always use libusb-1.0.

9 years agoAlways check config key capabilities before using them.
Bert Vermeulen [Tue, 18 Nov 2014 15:24:52 +0000 (16:24 +0100)]
Always check config key capabilities before using them.

9 years agoCheck for config key availability before using it.
Bert Vermeulen [Mon, 17 Nov 2014 12:59:42 +0000 (13:59 +0100)]
Check for config key availability before using it.

9 years agoUse the srzip output module instead of session save API.
Bert Vermeulen [Tue, 11 Nov 2014 23:03:16 +0000 (00:03 +0100)]
Use the srzip output module instead of session save API.

9 years agoUse getters now that 'struct sr_dev_inst' is opaque.
Uwe Hermann [Tue, 11 Nov 2014 15:32:33 +0000 (16:32 +0100)]
Use getters now that 'struct sr_dev_inst' is opaque.

9 years agoShow driver detail even if no device was found.
Bert Vermeulen [Mon, 27 Oct 2014 20:29:17 +0000 (21:29 +0100)]
Show driver detail even if no device was found.

9 years agoshow: Handle more datatypes in a generic way.
Bert Vermeulen [Mon, 27 Oct 2014 20:28:16 +0000 (21:28 +0100)]
show: Handle more datatypes in a generic way.

9 years agoFix memory leak.
Bert Vermeulen [Sun, 19 Oct 2014 09:52:37 +0000 (11:52 +0200)]
Fix memory leak.

9 years agoParse boolean command line options.
Jens Steinhauser [Sun, 19 Oct 2014 08:47:31 +0000 (10:47 +0200)]
Parse boolean command line options.

This fixes bug 450.

9 years agoClean up session file loading.
Bert Vermeulen [Thu, 2 Oct 2014 09:35:07 +0000 (11:35 +0200)]
Clean up session file loading.

9 years agoinput: Use sr_input_end() at end of input stream.
Bert Vermeulen [Tue, 23 Sep 2014 10:16:50 +0000 (12:16 +0200)]
input: Use sr_input_end() at end of input stream.

9 years agoinput: Don't use the sdi until it's ready.
Bert Vermeulen [Mon, 22 Sep 2014 13:28:40 +0000 (15:28 +0200)]
input: Don't use the sdi until it's ready.

9 years agoSet device options when called with --get.
Bert Vermeulen [Tue, 23 Sep 2014 20:39:40 +0000 (22:39 +0200)]
Set device options when called with --get.

9 years agoMake sure to treat all config keys as uint32_t.
Bert Vermeulen [Tue, 23 Sep 2014 20:38:29 +0000 (22:38 +0200)]
Make sure to treat all config keys as uint32_t.

9 years agoFix a compiler warning.
Uwe Hermann [Fri, 19 Sep 2014 10:39:33 +0000 (12:39 +0200)]
Fix a compiler warning.

input.c: In function ‘load_input_file’:
input.c:123:7: warning: ‘fd’ may be used uninitialized in this function
[-Wmaybe-uninitialized]
   len = read(fd, buf->str, BUFSIZE);
       ^
input.c:42:6: note: ‘fd’ was declared here
  int fd;
      ^

9 years agoAdapt to config key capabilities.
Bert Vermeulen [Wed, 17 Sep 2014 14:03:45 +0000 (16:03 +0200)]
Adapt to config key capabilities.

9 years agoReplace ann_format with ann_class.
Uwe Hermann [Mon, 15 Sep 2014 18:26:08 +0000 (20:26 +0200)]
Replace ann_format with ann_class.

The naming has been changed to "annotation class" a while ago.

9 years agoAlways save all channels to a session file.
Bert Vermeulen [Sat, 13 Sep 2014 13:17:49 +0000 (15:17 +0200)]
Always save all channels to a session file.

This works around limitations of the current API that screw up saving
only enabled channels. See bug 410.

9 years agoAdd --get option.
Bert Vermeulen [Wed, 10 Sep 2014 15:57:01 +0000 (17:57 +0200)]
Add --get option.

9 years agoFail on invalid channel group.
Bert Vermeulen [Tue, 9 Sep 2014 17:54:36 +0000 (19:54 +0200)]
Fail on invalid channel group.

9 years agoAdd missing --show pretty-printers.
Bert Vermeulen [Sun, 7 Sep 2014 12:58:16 +0000 (14:58 +0200)]
Add missing --show pretty-printers.

9 years agoSupport uint64 input/output module options.
Bert Vermeulen [Sat, 30 Aug 2014 18:17:34 +0000 (20:17 +0200)]
Support uint64 input/output module options.

9 years agoFix session file loading.
Bert Vermeulen [Fri, 29 Aug 2014 21:02:19 +0000 (23:02 +0200)]
Fix session file loading.

9 years agoUse sr_input_scan_*() API changes.
Bert Vermeulen [Wed, 27 Aug 2014 23:50:49 +0000 (01:50 +0200)]
Use sr_input_scan_*() API changes.

9 years agoAlways consider input from stdin as a non-session format.
Bert Vermeulen [Wed, 27 Aug 2014 22:17:05 +0000 (00:17 +0200)]
Always consider input from stdin as a non-session format.

9 years agoAllow input from stdin by specifying "-i -".
Bert Vermeulen [Tue, 19 Aug 2014 23:15:36 +0000 (01:15 +0200)]
Allow input from stdin by specifying "-i -".

9 years agoUse new input API.
Bert Vermeulen [Sun, 10 Aug 2014 14:58:36 +0000 (16:58 +0200)]
Use new input API.

9 years agoTrigger match on any edge is e, not c.
Peter Zotov [Sun, 24 Aug 2014 09:24:02 +0000 (13:24 +0400)]
Trigger match on any edge is e, not c.

9 years agoIf only one non-demo device is present, select it.
Peter Zotov [Sat, 23 Aug 2014 09:02:50 +0000 (13:02 +0400)]
If only one non-demo device is present, select it.

9 years agoFix generic sr_option enumeration.
Bert Vermeulen [Wed, 20 Aug 2014 15:31:17 +0000 (17:31 +0200)]
Fix generic sr_option enumeration.

9 years agoFix output module enumeration + code cleanup.
Bert Vermeulen [Mon, 18 Aug 2014 21:59:23 +0000 (23:59 +0200)]
Fix output module enumeration + code cleanup.

9 years agoEnumerate output module options according to API change.
Bert Vermeulen [Fri, 15 Aug 2014 20:32:17 +0000 (22:32 +0200)]
Enumerate output module options according to API change.

9 years agoBetter output module checking.
Bert Vermeulen [Sat, 2 Aug 2014 23:19:55 +0000 (01:19 +0200)]
Better output module checking.

9 years agoHandle floating point options for output modules.
Bert Vermeulen [Sat, 2 Aug 2014 01:43:53 +0000 (03:43 +0200)]
Handle floating point options for output modules.

9 years agoShow PD annotation row members by name, not number.
Bert Vermeulen [Fri, 1 Aug 2014 14:04:08 +0000 (16:04 +0200)]
Show PD annotation row members by name, not number.

This fixes bug 388.

9 years agoRemove stray debug output.
Bert Vermeulen [Sun, 27 Jul 2014 21:33:37 +0000 (23:33 +0200)]
Remove stray debug output.

9 years agoUse finished output API.
Bert Vermeulen [Fri, 25 Jul 2014 20:39:48 +0000 (22:39 +0200)]
Use finished output API.

9 years agoFree results of device scan as soon as possible.
Bert Vermeulen [Thu, 24 Jul 2014 18:31:55 +0000 (20:31 +0200)]
Free results of device scan as soon as possible.

9 years agoAdd analog output module to default output.
Bert Vermeulen [Thu, 24 Jul 2014 02:28:26 +0000 (04:28 +0200)]
Add analog output module to default output.

The default output module is bits, which only handles logic data.
When a user queries a device which outputs analog data, this results
in no output at all, which often confuses new users.

9 years agoProperly handle saving logic data packets of any size.
Bert Vermeulen [Wed, 23 Jul 2014 17:21:54 +0000 (19:21 +0200)]
Properly handle saving logic data packets of any size.

9 years agoDrop references to obsolete sigrok-commits mailing list.
Uwe Hermann [Tue, 22 Jul 2014 22:02:30 +0000 (00:02 +0200)]
Drop references to obsolete sigrok-commits mailing list.

9 years agoUse new session API.
Bert Vermeulen [Thu, 17 Jul 2014 20:49:20 +0000 (22:49 +0200)]
Use new session API.

9 years agooptions: Make sure there are no extra arguments.
Jens Steinhauser [Tue, 15 Jul 2014 21:40:20 +0000 (23:40 +0200)]
options: Make sure there are no extra arguments.

9 years agooptions: Allow input/output file names only once.
Jens Steinhauser [Tue, 15 Jul 2014 21:31:34 +0000 (23:31 +0200)]
options: Allow input/output file names only once.

9 years agooptions: String options are only allowed once.
Jens Steinhauser [Tue, 15 Jul 2014 20:52:35 +0000 (22:52 +0200)]
options: String options are only allowed once.

9 years agoRemove unnecessary extern option variable declarations.
Jens Steinhauser [Tue, 15 Jul 2014 15:19:55 +0000 (17:19 +0200)]
Remove unnecessary extern option variable declarations.

9 years agoPut option parsing into a separate file.
Jens Steinhauser [Tue, 15 Jul 2014 15:14:03 +0000 (17:14 +0200)]
Put option parsing into a separate file.

9 years agoAdd some missing headers.
Bert Vermeulen [Wed, 9 Jul 2014 23:53:17 +0000 (01:53 +0200)]
Add some missing headers.

9 years agomanpage: Document -M and -B options.
Bert Vermeulen [Sun, 10 Nov 2013 13:00:32 +0000 (14:00 +0100)]
manpage: Document -M and -B options.

9 years agoCheck srd_decoder_get_by_id() output.
Bert Vermeulen [Fri, 20 Jun 2014 15:01:48 +0000 (17:01 +0200)]
Check srd_decoder_get_by_id() output.

This fixes bug 370. Thanks to Sander Alberink for the bug report
and patch.

9 years agofix a potential use of uninitialized variable
Aurelien Jacobs [Tue, 3 Jun 2014 14:46:03 +0000 (16:46 +0200)]
fix a potential use of uninitialized variable

show.c: In function ‘show_dev_detail’:
show.c:214:11: warning: ‘c’ may be used uninitialized in this function [-Wmaybe-uninitialized]
  char *s, c;
           ^

9 years agoUse sr_trigger_stage_add().
Bert Vermeulen [Sat, 31 May 2014 08:36:15 +0000 (10:36 +0200)]
Use sr_trigger_stage_add().

9 years agoUse new trigger API.
Bert Vermeulen [Sun, 25 May 2014 22:58:42 +0000 (00:58 +0200)]
Use new trigger API.

9 years agosigrok-cli: AC_ARG_WITH uses withval, not enableval
Cody P Schafer [Wed, 7 May 2014 04:18:38 +0000 (21:18 -0700)]
sigrok-cli: AC_ARG_WITH uses withval, not enableval

Signed-off-by: Cody P Schafer <redacted>
9 years agoconfigure.ac: Bump package version to 0.5.0. sigrok-cli-0.5.x sigrok-cli-0.5.0
Uwe Hermann [Tue, 6 May 2014 21:19:15 +0000 (23:19 +0200)]
configure.ac: Bump package version to 0.5.0.

9 years agoBump libsigrok/libsigrokdecode dependencies to 0.3.0 each.
Uwe Hermann [Tue, 6 May 2014 21:17:43 +0000 (23:17 +0200)]
Bump libsigrok/libsigrokdecode dependencies to 0.3.0 each.

9 years agoNEWS: Add list of user-visible changes so far.
Uwe Hermann [Tue, 6 May 2014 07:00:00 +0000 (09:00 +0200)]
NEWS: Add list of user-visible changes so far.

9 years agoAdapt to SR_T_CHAR -> SR_T_STRING rename.
Uwe Hermann [Tue, 6 May 2014 18:20:04 +0000 (20:20 +0200)]
Adapt to SR_T_CHAR -> SR_T_STRING rename.

9 years agomanpage: Document the --frames option.
Uwe Hermann [Sun, 4 May 2014 23:54:48 +0000 (01:54 +0200)]
manpage: Document the --frames option.

9 years agoUpdate the manpage.
Uwe Hermann [Sun, 4 May 2014 21:14:25 +0000 (23:14 +0200)]
Update the manpage.

 - Don't refer to the not yet existing nexus-osciprime driver.

 - Update an example sigrok-cli --scan output to match the current format.

 - Update some sections to honor that channels are now specified by
   name (not number). Example: "-P uart:rx=FTDIRX" instead of "-P uart:rx=6"
   (if channel 6 has been actually named "FTDIRX" by the user/frontend).

   This fixes bug #332.

 - SPI PD: The 'sck' pin is now called 'clk', update the manpage example.

 - Fix a typo in the -S documentation: s/-A/-P/.

 - The --time option currently only supports "ms" and "s" as units.

 - Various minor cosmetic changes.

9 years agoUse a non-recursive automake setup.
Uwe Hermann [Sun, 4 May 2014 14:49:01 +0000 (16:49 +0200)]
Use a non-recursive automake setup.

(fewer files, less clutter)

9 years agoFix compile without decoding support.
Bert Vermeulen [Sat, 26 Apr 2014 19:11:16 +0000 (12:11 -0700)]
Fix compile without decoding support.

This fixes bug 351.

9 years agosession: Show unitsize of the received data.
Uwe Hermann [Fri, 25 Apr 2014 17:32:01 +0000 (19:32 +0200)]
session: Show unitsize of the received data.

Also, minor consistency fixes.

9 years agoFix saving to session file.
Bert Vermeulen [Thu, 24 Apr 2014 18:58:35 +0000 (20:58 +0200)]
Fix saving to session file.

9 years agoDon't output anything else when decoding.
Bert Vermeulen [Tue, 22 Apr 2014 21:37:14 +0000 (23:37 +0200)]
Don't output anything else when decoding.

10 years agoUse new output module API wrappers.
Bert Vermeulen [Sun, 20 Apr 2014 21:13:16 +0000 (23:13 +0200)]
Use new output module API wrappers.

10 years agoDrop obsolete output API support.
Bert Vermeulen [Sat, 19 Apr 2014 13:34:14 +0000 (15:34 +0200)]
Drop obsolete output API support.

10 years agoRename 'probe' to 'channel' (libsigrokdecode change).
Uwe Hermann [Sat, 12 Apr 2014 11:42:30 +0000 (13:42 +0200)]
Rename 'probe' to 'channel' (libsigrokdecode change).

The -p|--probes option is renamed to -C|--channels.

Variables of type 'struct srd_channel *' are consistently named 'pdch' to
make them easily distinguishable from libsigrok's 'struct sr_channel *'
variables that are consistently named 'ch'.

10 years agoAlways get samplerate at the start of acquisition.
Bert Vermeulen [Sun, 13 Apr 2014 18:51:59 +0000 (20:51 +0200)]
Always get samplerate at the start of acquisition.

10 years agoDeal with empty sessions nicely.
Bert Vermeulen [Mon, 7 Apr 2014 13:26:39 +0000 (15:26 +0200)]
Deal with empty sessions nicely.

10 years agoconfigure.ac: Clearly mark required and optional libs.
Uwe Hermann [Sun, 13 Apr 2014 16:17:04 +0000 (18:17 +0200)]
configure.ac: Clearly mark required and optional libs.

10 years agonsis: Drop embedded Python installer, ship local DLL and modules.
Uwe Hermann [Fri, 4 Apr 2014 17:57:23 +0000 (19:57 +0200)]
nsis: Drop embedded Python installer, ship local DLL and modules.

10 years agoRename 'probe' to 'channel' in most places.
Uwe Hermann [Mon, 24 Mar 2014 21:32:47 +0000 (22:32 +0100)]
Rename 'probe' to 'channel' in most places.

This is an update related to bug #259.

10 years agoRename 'probe group' to 'channel group' everywhere.
Uwe Hermann [Fri, 14 Mar 2014 20:46:10 +0000 (21:46 +0100)]
Rename 'probe group' to 'channel group' everywhere.

This is required to adapt to the same rename in libsigrok.

The --probe-group command-line option is now called --channel-group
(however, the short version -g remains the same as it means "group").

This is an update related to bug #259.

10 years agoAdd support for setting double ranges.
Bert Vermeulen [Thu, 20 Mar 2014 23:50:30 +0000 (00:50 +0100)]
Add support for setting double ranges.

This is used for SR_CONF_VOLTAGE_THRESHOLD.

10 years agoconfigure.ac: Only check for things we actually use.
Uwe Hermann [Thu, 20 Mar 2014 13:01:22 +0000 (14:01 +0100)]
configure.ac: Only check for things we actually use.

Drop checks where we don't use the result (yet). We might bring back
some of those once we start actually using the result in the code.

10 years agonsis: Put sigrok-dumps *.sr files into the installer.
Uwe Hermann [Thu, 20 Mar 2014 12:15:50 +0000 (13:15 +0100)]
nsis: Put sigrok-dumps *.sr files into the installer.

These are useful for people to have around for conveniently testing
various frontend features and protocol decoders etc.