Commit Graph

32 Commits

Author SHA1 Message Date
Uwe Hermann 29a27196a1 s/DRIVER_LOG_DOMAIN/LOG_PREFIX/.
This is more correct anyway, and also a bit shorter and more readable.
2013-05-03 21:59:32 +02:00
Bert Vermeulen af51a7718e output: Use sr_config_get() wrapper
This obviates the need for a valid driver, and thus makes converting
from any (non-sr) input format to any output format possible; the only
thing missing is the samplerate.

Fixes bug 105.
2013-04-30 16:03:37 +02:00
Bert Vermeulen 17f63de642 Fix output API receive() function
This changes the new output API's recv() to receive(), and has it
return an integer status code. The output of the function, if any,
is stored in a new parameter as a pointer to a newly allocated GString.

All output modules using this API have been adjusted.
2013-04-27 17:29:46 +02:00
Martin Ling a1be7b6c3f vcd output: Replace fixed length array of indices with GArray. 2013-04-27 15:49:50 +02:00
Martin Ling d601c0e9b3 vcd output: Eliminate unnecessary array of probe names. 2013-04-27 15:49:50 +02:00
Martin Ling b050fc481b vcd output: fix for big-endian architectures. 2013-04-27 15:49:49 +02:00
Uwe Hermann 50985c2019 GPL headers: Use correct project name. 2013-04-23 22:24:30 +02:00
Bert Vermeulen ba6568c5ad output/vcd: Use selected probes, not lowest-numbered ones
Thanks to Andrew Bardsley for the patch.
2013-04-11 18:49:24 +02:00
Bert Vermeulen ec4063b83c input/output modules: Adjust to GVariant-based sr_config_* functions 2013-04-11 18:32:06 +02:00
Bert Vermeulen 13d8e03c4f Bump copyright year 2013-04-11 18:32:06 +02:00
Uwe Hermann bbe6e336b3 vcd output: Build fix for Windows/MinGW.
On Windows/MinGW 'recv' seems to be already defined in windows.h/winsock2.h.

Use 'receive' instead, for now, otherwise we get an error:

vcd.c:147:17: error: conflicting types for 'recv'
2013-04-09 18:57:20 +02:00
Bert Vermeulen d5585e32dd output/vcd: use new API 2013-03-06 23:14:00 +01:00
Bert Vermeulen 4d15e5c907 Rename sr_dev_has_hwcap() to sr_dev_has_option(). 2013-01-25 16:20:40 +01:00
Bert Vermeulen 123e131383 Deprecate SR_DI_CUR_SAMPLERATE.
This is replaced by SR_CONF_SAMPLERATE.
2013-01-25 03:17:36 +01:00
Bert Vermeulen 035a1078fd drivers: rename and reorganize config get/set
The driver API calls info_get() and dev_config_set() have been renamed
to config_get() and config_set(), respectively.
2013-01-24 19:19:09 +01:00
Bert Vermeulen 1953564a96 Rename SR_HWOPT_* and SR_HWCAP_* to SR_CONF_* 2013-01-21 23:32:50 +01:00
Uwe Hermann a944a84b17 Output modules: Use message logging helpers. 2012-11-11 18:14:17 +01:00
Uwe Hermann 545f978639 config.h usage cleanups.
- Drop config.h #include from files that don't actually use any of
   its contents (at the moment).

 - Add comment for those that do need it.
2012-10-24 00:41:21 +02:00
Bert Vermeulen 5c3c1241d2 sr: change input/output modules to use struct sr_dev_inst * 2012-08-03 11:27:31 +02:00
Bert Vermeulen 45c59c8bdd sr: moved sigrok.h so libsigrok/libsigrok.h
All frontends will have to include <libsigrok/libsigrok.h> from now on.
This header includes proto.h and version.h, both installed from the
distribution into $INCLUDE/libsigrok/ as well.

The only dynamically changed header is now version.h, which has both
libsigrok and libtool compile-time versions in it.
2012-07-05 01:17:28 +02:00
Uwe Hermann 054e670906 sr: out: Use uint8_t (not char) for buffers. 2012-03-31 11:33:43 +02:00
Uwe Hermann 8ec95d2282 sr/srd: Small fixes, constifications, doc updates. 2012-03-21 23:20:09 +01:00
Uwe Hermann c09f0b578c sr/cli/gtk/qt/: s/plugin/driver/. 2012-02-28 23:52:30 +01:00
Bert Vermeulen 2285cf9bc5 sr: code cleanup 2012-02-28 17:47:02 +01:00
Uwe Hermann 5097b0d091 sr/cli/gtk/qt: s/get_dev_info/dev_info_get/. 2012-02-18 11:41:21 +01:00
Uwe Hermann bb7ef79377 sr/cli/gtk/qt: s/device/dev/ in many places.
Also, a few s/instance/inst/ occurences.
2012-02-17 23:47:00 +01:00
Uwe Hermann 7b48d6e104 sr: Prefix log messages with subsystem string. 2012-02-17 22:40:51 +01:00
Bert Vermeulen c73d2ea421 sr: adjust copyright year 2012-02-13 14:31:51 +01:00
Bert Vermeulen 031685005b sr: rename all sr_device_* functions to sr_dev_* 2012-02-13 14:00:47 +01:00
Uwe Hermann 133a37bfba Use g_try_malloc/g_free/g_strdup consistently.
Avoid plain malloc()/free() in sr/srd, especially in the API calls.
Also avoid g_malloc*() in favor of g_try_malloc*().

Use g_strdup() instead of strdup() so that we can use g_free()
consistently everywhere.

Exceptions: Stuff that is allocated via other libs (not using glib),
should also be properly free'd using the respective free-ing function
(instead of g_free()). Examples: Stuff allocated by libusb, libftdi, etc.

Also, use sr_err() instead of sr_warn() for actual errors. sr_warn() is
meant for non-fatal/uncritical warnings.
2012-02-11 22:34:16 +01:00
Uwe Hermann 1a081ca67d sr: Mark API functions with SR_API/SR_PRIV.
Use SR_API to mark public API symbols, and SR_PRIV for private symbols.

Variables and functions marked 'static' are private already and don't
need SR_PRIV. However, functions which are not static (because they need
to be used in other libsigrok-internal files) but are also not meant to
be part of the public libsigrok API, must use SR_PRIV.

This uses the 'visibility' feature of gcc (requires gcc >= 4.0).

Details: http://gcc.gnu.org/wiki/Visibility
2012-02-02 00:03:17 +01:00
Uwe Hermann 0da5b6a9f5 sr: Remove useless filename prefixes. 2012-01-03 20:01:02 +01:00
Renamed from output/output_vcd.c (Browse further)