libsigrokdecode.git
3 years agoShow lib versions in the debug output.
Uwe Hermann [Fri, 26 May 2017 15:19:53 +0000 (17:19 +0200)]
Show lib versions in the debug output.

3 years agocan: Skip stuff bit inspection where not applicable
Gerhard Sittig [Sun, 14 May 2017 17:08:37 +0000 (19:08 +0200)]
can: Skip stuff bit inspection where not applicable

Bit stuffing does not apply to the last fields of a frame, specifically
the CRC delimiter, the ACK, and the end-of-frame fields. Adjust the
respective bit handling logic.

This fixes bug #656.

3 years agocan: Convert to PD API version 3
Gerhard Sittig [Sun, 14 May 2017 17:36:17 +0000 (19:36 +0200)]
can: Convert to PD API version 3

Don't inspect each individual sample in the Python based PD. Instead use
the backend's query API to detect the start of a frame and to advance to
the sample point position.

3 years agocan: Add warnings for various invalid bits and fields.
Uwe Hermann [Thu, 25 May 2017 21:42:58 +0000 (23:42 +0200)]
can: Add warnings for various invalid bits and fields.

3 years agosdcard_sd: reference latest command when displaying response
Wolfram Sang [Fri, 12 May 2017 11:58:28 +0000 (13:58 +0200)]
sdcard_sd: reference latest command when displaying response

Replace the hardcoded value with the last cmd used. I'd think the whole
ACMD handling could be simplified if we make further use of this new
variable. But for now, let's keep it simple and make it work.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
3 years agosdcard_sd: output CMD8 in cmd8-handler
Wolfram Sang [Fri, 12 May 2017 11:58:27 +0000 (13:58 +0200)]
sdcard_sd: output CMD8 in cmd8-handler

Probably a typo, currently 'cmd0' gets pushed out.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
3 years agotiming: Drop obsolete self.oldpin variable.
Uwe Hermann [Sat, 13 May 2017 13:51:59 +0000 (15:51 +0200)]
timing: Drop obsolete self.oldpin variable.

3 years agotiming: "normalize" negative times too
Karl Palsson [Fri, 20 Jan 2017 16:23:50 +0000 (16:23 +0000)]
timing: "normalize" negative times too

Use the same scale.

Signed-off-by: Karl Palsson <karlp@etactica.com>
3 years agotiming: add edge-edge mode and delta calculation
Karl Palsson [Fri, 20 Jan 2017 16:24:29 +0000 (16:24 +0000)]
timing: add edge-edge mode and delta calculation

Instead of only measuring the timing from any edge to any edge, provide
a mode to measure the times from falling->falling and rising->rising
edges. This works better to monitor timing of an IRQ pin for instance,
that drives one direction under hardware, and is only cleared by
software reading a value.

Include time delta measurements as an optional annotation to help track
jitter in measurements.

Signed-off-by: Karl Palsson <karlp@etactica.com>
3 years agotiming: disable averaging if set to zero
Karl Palsson [Fri, 20 Jan 2017 16:03:21 +0000 (16:03 +0000)]
timing: disable averaging if set to zero

The extra row of the average isn't always useful. Allow it to be
disabled by setting the average window to zero.

Signed-off-by: Karl Palsson <karlp@etactica.com>
3 years agoRename ade7758 decoder to ade77xx.
Uwe Hermann [Thu, 11 May 2017 22:24:41 +0000 (00:24 +0200)]
Rename ade7758 decoder to ade77xx.

There are multiple devices in the ADE77xx series that are similar enough
to be supportable via this decoder in the future.

3 years agoade7758: Slightly shorten some code chunks.
Uwe Hermann [Sun, 30 Apr 2017 16:16:21 +0000 (18:16 +0200)]
ade7758: Slightly shorten some code chunks.

3 years agoAdd an ADE7758 protocol decoder.
Karl Palsson [Fri, 13 Jan 2017 16:55:26 +0000 (16:55 +0000)]
Add an ADE7758 protocol decoder.

No value decoding, that can be fairly complicated.

Signed-off-by: Karl Palsson <karlp@etactica.com>
3 years agosdcard_sd: remove unused functions
Wolfram Sang [Wed, 3 May 2017 19:00:57 +0000 (21:00 +0200)]
sdcard_sd: remove unused functions

putr2 is unused, so let it go.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
3 years agoeeprom93cxx: Improve longname.
Uwe Hermann [Sat, 6 May 2017 18:07:09 +0000 (20:07 +0200)]
eeprom93cxx: Improve longname.

3 years agomicrowire/eeprom93cxx: Use 'es' instead of 'se' abbrevation.
Uwe Hermann [Fri, 5 May 2017 18:33:26 +0000 (20:33 +0200)]
microwire/eeprom93cxx: Use 'es' instead of 'se' abbrevation.

(for consistency with all other decoders)

3 years agoeeprom93cxx: Update wrt Python output namedtuple usage.
Uwe Hermann [Fri, 5 May 2017 18:31:20 +0000 (20:31 +0200)]
eeprom93cxx: Update wrt Python output namedtuple usage.

3 years agoeeprom93cxx: Shorten put_word() a bit.
Uwe Hermann [Wed, 3 May 2017 20:37:15 +0000 (22:37 +0200)]
eeprom93cxx: Shorten put_word() a bit.

3 years agoAdd a 93Cxx Microwire EEPROM protocol decoder.
Kevin Redon [Wed, 3 May 2017 20:21:46 +0000 (22:21 +0200)]
Add a 93Cxx Microwire EEPROM protocol decoder.

This fixes parts of bug #931.

3 years agomicrowire: Use namedtuple in some more cases.
Uwe Hermann [Fri, 5 May 2017 18:21:22 +0000 (20:21 +0200)]
microwire: Use namedtuple in some more cases.

3 years agomicrowire: Use namedtuple for the Python output.
Uwe Hermann [Fri, 5 May 2017 18:18:54 +0000 (20:18 +0200)]
microwire: Use namedtuple for the Python output.

This has two advantages:

 - The Python output is always deterministic, which was not the case for
   the dict-based version since dict items have no guaranteed order in
   Python. This caused issues with the sigrok-test use-case.

 - The code is slightly more readable.

3 years agomicrowire: Drop some trailing whitespace.
Uwe Hermann [Fri, 5 May 2017 06:45:07 +0000 (08:45 +0200)]
microwire: Drop some trailing whitespace.

3 years agomicrowire: Shorten decode() a bit.
Uwe Hermann [Fri, 5 May 2017 06:11:32 +0000 (08:11 +0200)]
microwire: Shorten decode() a bit.

3 years agomicrowire: Make Ready/Busy extra annotation classes.
Uwe Hermann [Wed, 3 May 2017 20:07:29 +0000 (22:07 +0200)]
microwire: Make Ready/Busy extra annotation classes.

3 years agomicrowire: Make the start bit an extra annotation class.
Uwe Hermann [Wed, 3 May 2017 20:06:51 +0000 (22:06 +0200)]
microwire: Make the start bit an extra annotation class.

3 years agoAdd a Microwire protocol decoder.
Kevin Redon [Wed, 3 May 2017 19:29:49 +0000 (21:29 +0200)]
Add a Microwire protocol decoder.

This fixes parts of bug #931.

3 years agosdcard_sd: really show result of SET_BLOCKLEN
Wolfram Sang [Wed, 26 Apr 2017 15:17:32 +0000 (17:17 +0200)]
sdcard_sd: really show result of SET_BLOCKLEN

Now that self.arg is populated, we can finally use it.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
3 years agosdcard_sd: always show CMD argument in hex
Wolfram Sang [Wed, 26 Apr 2017 15:17:31 +0000 (17:17 +0200)]
sdcard_sd: always show CMD argument in hex

This is especially useful with the default handler, so you can better
understand the transfer if you are already familiar with CMD numbers and
their arguments. It makes it also easier to compare with the debug
output of the e.g. Linux Kernel.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
3 years agosdcard_sd: don't interate over not implemented command
Wolfram Sang [Wed, 26 Apr 2017 15:17:30 +0000 (17:17 +0200)]
sdcard_sd: don't interate over not implemented command

There is no handler for CMD4 yet.

Signed-off-by: Wolfram Sang <wsa+renesas@sang-engineering.com>
3 years agoonewire_link: (Re-)convert to PD API version 3.
Uwe Hermann [Fri, 7 Apr 2017 06:09:56 +0000 (08:09 +0200)]
onewire_link: (Re-)convert to PD API version 3.

3 years agoonewire_link: Factor out some helper methods.
Uwe Hermann [Thu, 6 Apr 2017 17:27:37 +0000 (19:27 +0200)]
onewire_link: Factor out some helper methods.

This avoids some boilerplate in the decode() method itself.

3 years agoImplement new 1-Wire link decoder using time ranges
King Kévin [Sun, 26 Mar 2017 17:31:56 +0000 (19:31 +0200)]
Implement new 1-Wire link decoder using time ranges

Rewrite of the 1-Wire link decoder.

Existing outputs are kept and new warnings are added.

Instead of sampling at fixed user defined time, time ranges as
specified by the "Book of iButton Standards" are used.

The user does not have to tweak the timing values anymore.

Overdrive speed is detected automatically.

This fixes bugs #666 and #926.

3 years agoiec: Convert to PD API version 3
Marcus Comstedt [Fri, 31 Mar 2017 18:21:08 +0000 (20:21 +0200)]
iec: Convert to PD API version 3

3 years agoDon't show a harmless/confusing warning on stdout.
Uwe Hermann [Fri, 31 Mar 2017 17:18:19 +0000 (19:18 +0200)]
Don't show a harmless/confusing warning on stdout.

Some Python versions will lead to the following message on stdout currently:

  srd: Attribute Error: Failed to load decoder common: no 'Decoder' \
  attribute in imported module: 'module' object has no attribute 'Decoder'

This is a harmless (though confusing for users) warning, since "common"
is not an actual PD and it shouldn't be loaded as PD (it just has to
be present).

3 years agoeeprom24xx: add Xicor X24C02 variant
fenugrec [Mon, 20 Mar 2017 22:56:25 +0000 (18:56 -0400)]
eeprom24xx: add Xicor X24C02 variant

3 years agodali: Use a slightly better variable name.
Uwe Hermann [Sat, 18 Mar 2017 22:03:17 +0000 (23:03 +0100)]
dali: Use a slightly better variable name.

3 years agodsi: Use a slightly better variable name.
Uwe Hermann [Sat, 18 Mar 2017 22:01:56 +0000 (23:01 +0100)]
dsi: Use a slightly better variable name.

3 years agodsi: Small fix for the longname.
Uwe Hermann [Sat, 18 Mar 2017 21:58:41 +0000 (22:58 +0100)]
dsi: Small fix for the longname.

3 years agoAdd a DALI protocol decoder.
Jeremy Swanson [Thu, 16 Feb 2017 16:29:47 +0000 (16:29 +0000)]
Add a DALI protocol decoder.

3 years agoAdd a DSI protocol decoder.
Jeremy Swanson [Thu, 16 Feb 2017 16:29:47 +0000 (16:29 +0000)]
Add a DSI protocol decoder.

3 years agouart: Minor cosmetic changes.
Uwe Hermann [Wed, 15 Mar 2017 08:27:43 +0000 (09:27 +0100)]
uart: Minor cosmetic changes.

3 years agouart: Use consistent order of steps when processing samples
Gerhard Sittig [Tue, 14 Mar 2017 18:01:04 +0000 (19:01 +0100)]
uart: Use consistent order of steps when processing samples

Slightly rearrange some of the methods which are involved in UART frame
inspection. Use a consistent sequence of steps: Grab the signal's
current value, accumulate and process the information, emit respective
annotations, and advance to the next stage in the UART frame inspection.

3 years agouart: Remove redundant "reached bit" checks
Gerhard Sittig [Tue, 14 Mar 2017 18:15:31 +0000 (19:15 +0100)]
uart: Remove redundant "reached bit" checks

After the decode() method got adjusted to call wait() with custom made
conditions and to check .matched[] before inspecting samples, the check
whether a bit time's sample point was reached has become obsolete.

3 years agouart: Improve robustness of query API result processing
Gerhard Sittig [Tue, 14 Mar 2017 17:46:32 +0000 (18:46 +0100)]
uart: Improve robustness of query API result processing

Since either of the UART signals (RX, TX) is optional, and in the
absence of Decoder.wait() conditions that "will never match", we cannot
construct a constant layout. Instead we need to explicitly keep track of
which item in the list of wait conditions corresponds to which signal.

Once the index in the list of wait conditions is known, inspection of
samples can depend on the Decoder.matched[] attribute. Before this
change, redundant reached_bit() checks kept us from processing samples
that should not have been inspected. Tests pass before and after this
very commit.

3 years agouart: Reduce redundancy in sample inspection (state machine)
Gerhard Sittig [Tue, 14 Mar 2017 17:15:51 +0000 (18:15 +0100)]
uart: Reduce redundancy in sample inspection (state machine)

Factor out the logic which inspects samples that were provided by the
PD version 3 query API, and dispatches their processing depending on
the progress of UART frame inspection. "Unroll" a loop over the RX and
TX signals.

This commit replaces some complicated variable assignments by easier to
verify invocations.

3 years agouart: Convert to PD API version 3
Gerhard Sittig [Tue, 14 Mar 2017 17:00:06 +0000 (18:00 +0100)]
uart: Convert to PD API version 3

Adjust the UART protocol decoder, to make use of the query based API.
Have edges detected and unrelated samples skipped by common code.

This implementation keeps some redundancy in place (like checking for
having reached specific sample numbers, while the backend managed that
for us). This approach reduces the diff and shall simplify review.

Only some common checks in decode() were moved to the start of the
routine, outside of the sample inspection loop.

3 years agouart: Minor readability nit (position of start bit in calculation)
Gerhard Sittig [Tue, 14 Mar 2017 16:10:28 +0000 (17:10 +0100)]
uart: Minor readability nit (position of start bit in calculation)

Rephrase the bit slot index calculation for UART frames such that it
becomes more apparent whether a start bit is involved or whether an
array index needs adjustment due to Python range semantics.

This shall improve readability, and reduce the probability of off-by-one
errors during maintenance.

3 years agouart: Immediately skip reception of parity bits when not applicable
Gerhard Sittig [Tue, 14 Mar 2017 14:35:27 +0000 (15:35 +0100)]
uart: Immediately skip reception of parity bits when not applicable

When the UART frame does not contain a parity bit, then immediately
advance to reception of stop bits after all data bits were received.

This eliminates the necessity to run the parity check routine when
parity does not apply in the first place. Without this change, some
"dummy" sample needs to get inspected for correct operation of the
state machine.

3 years agouart: Remove an obsolete unused routine
Gerhard Sittig [Tue, 14 Mar 2017 14:33:07 +0000 (15:33 +0100)]
uart: Remove an obsolete unused routine

3 years agodecoder: terminate .wait() and .decode(), join threads for v3 instances
Gerhard Sittig [Sun, 5 Mar 2017 17:09:59 +0000 (18:09 +0100)]
decoder: terminate .wait() and .decode(), join threads for v3 instances

Add support to terminate blocking .wait() and .decode() method calls of
v3 decoder instances. This terminates the decoder thread's main routine
and allows to release associated resources. Cope with requested as well
as unexpected termination of decode() calls. Add debug messages to
thread related code paths.

Make sure to unblock the main thread which feeds the decoder thread.
This unbreaks situations where decoders e.g. throw "need samplerate to
decode" exceptions.

Drain Python errors which might remain from the most recent .decode()
execution, to not affect other code paths. This avoids an issue where
the creation of a new decoder instance fails in the presence of errors
from a previous run.

This fixes bug #902.

3 years agoconfigure summary: Show linker flags.
Uwe Hermann [Sun, 5 Mar 2017 16:05:06 +0000 (17:05 +0100)]
configure summary: Show linker flags.

3 years agoconfigure summary: Show whether shared/static build is enabled.
Uwe Hermann [Sun, 5 Mar 2017 16:04:38 +0000 (17:04 +0100)]
configure summary: Show whether shared/static build is enabled.

3 years agorgb_led_ws281x: Use self.samplenum.
Uwe Hermann [Sat, 4 Mar 2017 13:30:18 +0000 (14:30 +0100)]
rgb_led_ws281x: Use self.samplenum.

This is currently just a cosmetic change, but will make the conversion
to the PDv3 API slightly easier and more readable.

3 years agoDrop obsolete workarounds in PDs.
Uwe Hermann [Wed, 1 Mar 2017 23:03:16 +0000 (00:03 +0100)]
Drop obsolete workarounds in PDs.

Some PDs were using a temporary workaround for (as it turned out) a
refcounting issue that was fixed in 066fbafdc3ba734a73b5f7fcfa1dbae67ddebf8a.

3 years agosrd_decoder_load(): Drop dead code.
Uwe Hermann [Tue, 28 Feb 2017 08:04:55 +0000 (09:04 +0100)]
srd_decoder_load(): Drop dead code.

In 'except_out' the fail_txt variable is always non-NULL.

3 years agoFix memory leak in get_current_pinvalues()
Marcus Comstedt [Mon, 27 Feb 2017 21:33:17 +0000 (22:33 +0100)]
Fix memory leak in get_current_pinvalues()

The ownership of the tuple reference is transferred to the caller, so
the refcount should not be increased.

3 years agoMore refcounting fixes
Marcus Comstedt [Mon, 27 Feb 2017 21:24:23 +0000 (22:24 +0100)]
More refcounting fixes

PyList_SetItem steals a reference, so code calling that must either
transfer ownership or increase the refcount.

3 years agoinstance.c: Add a debug message for thread creation.
Uwe Hermann [Mon, 27 Feb 2017 07:42:44 +0000 (08:42 +0100)]
instance.c: Add a debug message for thread creation.

3 years agosrd_inst_decode(): Slightly more verbose error message.
Uwe Hermann [Sun, 26 Feb 2017 14:55:00 +0000 (15:55 +0100)]
srd_inst_decode(): Slightly more verbose error message.

3 years agoFix examples to show abs_end_samplenum as exclusive
Marcus Comstedt [Sun, 26 Feb 2017 12:10:06 +0000 (13:10 +0100)]
Fix examples to show abs_end_samplenum as exclusive

3 years agoReturn SRD_ERR_ARG from srd_inst_decode if samplenums are wrong
Marcus Comstedt [Sun, 26 Feb 2017 12:07:03 +0000 (13:07 +0100)]
Return SRD_ERR_ARG from srd_inst_decode if samplenums are wrong

This validates the requirements that
* abs_start_samplenum continues where the previous decode ended
* abs_end_samplenum is not lower than abs_start_samplenum

Failure to meet these requirements will make v3 decoders crash.

3 years agoFix refcounting bug in set_new_condition_list()
Marcus Comstedt [Sun, 26 Feb 2017 11:52:12 +0000 (12:52 +0100)]
Fix refcounting bug in set_new_condition_list()

py_conditionlist is an owned reference (it gets passed to Py_DecRef()
at the end), so we need to increment the refcount when assigning it
from the borrowed reference py_conds.

3 years agoinstance.c: fix a 'matched' vs 'matches' typo
Gerhard Sittig [Sun, 26 Feb 2017 08:16:36 +0000 (09:16 +0100)]
instance.c: fix a 'matched' vs 'matches' typo

The Decoder_wait() routine will populate the .matched attribute before
returning to the caller. The srd_inst_start() routine used to setup a
.matches attribute which is unexpected. Make both routines consistently
assign to 'matched' as that is what Python decoder implementations are
referencing.

3 years agoAdd an initial serial GPIB (IEC) decoder.
Marcus Comstedt [Wed, 15 Feb 2017 18:14:27 +0000 (19:14 +0100)]
Add an initial serial GPIB (IEC) decoder.

3 years agoClarify that {start,end,cur}_samplenum are absolute numbers.
Uwe Hermann [Tue, 21 Feb 2017 21:10:35 +0000 (22:10 +0100)]
Clarify that {start,end,cur}_samplenum are absolute numbers.

3 years agoinstance.c: Fix a compiler warning.
Uwe Hermann [Tue, 7 Feb 2017 09:40:29 +0000 (10:40 +0100)]
instance.c: Fix a compiler warning.

  ../instance.c: In function ‘srd_inst_find_by_id’:
  ../instance.c:485:3: warning: suggest parentheses around assignment used as truth value [-Wparentheses]
     if (di = srd_inst_find_by_id_stack(inst_id, tmp))
     ^~

3 years agoLook up instances by ID in the full stack
Karl Palsson [Mon, 28 Nov 2016 17:31:55 +0000 (17:31 +0000)]
Look up instances by ID in the full stack

srd_inst_find_by_id() previously only searched for instance IDs at the
bottom of any stacked decoders. Make it properly search all stacks,
just like srd_inst_find_by_obj() and more usefully when trying to
generate unique instance IDs.

No external API change, only the explicit behaviour of the API.

This fixes parts of bug #868.

Signed-off-by: Karl Palsson <karlp@etactica.com>
3 years agoSupport adding multiple instances of a decoder
Karl Palsson [Mon, 11 Apr 2016 15:25:42 +0000 (17:25 +0200)]
Support adding multiple instances of a decoder

srd_inst_new() used the decoder ID as the instance ID, preventing the use
of multiple instances of the same decoder in the same session. Simply
append a numerical suffix to later instances to allow more.

Required changes to cleanup to reliably free all memory. Valgrind checked.

This fixes parts of bug #868.

Based on original work by: Soeren Apel <soeren@apelpie.net>
Signed-off-by: Karl Palsson <karlp@etactica.com>
3 years agoAdded intial ADF4350/1 decoder
Joel Holdsworth [Mon, 13 Feb 2017 04:44:19 +0000 (21:44 -0700)]
Added intial ADF4350/1 decoder

3 years agoz80: Convert to PD API version 3 (brute force)
Gerhard Sittig [Sun, 15 Jan 2017 10:26:19 +0000 (11:26 +0100)]
z80: Convert to PD API version 3 (brute force)

This implementation technically uses v3 API calls, but has yet to come
up with appropriate wait() conditions, to spend less time in the decoder
and have more tedious work done in the backend.

3 years agot55xx: Convert to PD API version 3
Gerhard Sittig [Sun, 15 Jan 2017 10:20:09 +0000 (11:20 +0100)]
t55xx: Convert to PD API version 3

3 years agosdcard_sd: Convert to PD API version 3
Gerhard Sittig [Sun, 15 Jan 2017 10:12:13 +0000 (11:12 +0100)]
sdcard_sd: Convert to PD API version 3

3 years agoqi: Convert to PD API version 3
Gerhard Sittig [Sun, 15 Jan 2017 10:09:45 +0000 (11:09 +0100)]
qi: Convert to PD API version 3

3 years agops2: Convert to PD API version 3
Gerhard Sittig [Sun, 15 Jan 2017 09:56:16 +0000 (10:56 +0100)]
ps2: Convert to PD API version 3

3 years agomdio: Convert to PD API version 3
Gerhard Sittig [Sun, 15 Jan 2017 09:50:46 +0000 (10:50 +0100)]
mdio: Convert to PD API version 3

3 years agoem4305: Convert to PD API version 3
Gerhard Sittig [Sun, 15 Jan 2017 09:48:44 +0000 (10:48 +0100)]
em4305: Convert to PD API version 3

3 years agoem4100: Convert to PD API version 3
Gerhard Sittig [Sun, 15 Jan 2017 09:44:19 +0000 (10:44 +0100)]
em4100: Convert to PD API version 3

3 years agolicense: remove FSF postal address from boiler plate license text
Gerhard Sittig [Thu, 20 Oct 2016 07:55:29 +0000 (09:55 +0200)]
license: remove FSF postal address from boiler plate license text

Remove the FSF postal address as it might change (it did in the past).
Reference the gnu.org website instead which is more stable.

3 years agoconfigure.ac: Also check for Python 3.6.
Uwe Hermann [Mon, 26 Dec 2016 22:28:58 +0000 (23:28 +0100)]
configure.ac: Also check for Python 3.6.

3 years agoavr_pdi: Don't pass self.samplenum (use it), simplify code.
Uwe Hermann [Mon, 26 Dec 2016 17:47:10 +0000 (18:47 +0100)]
avr_pdi: Don't pass self.samplenum (use it), simplify code.

3 years agoavr_pdi: Convert to PD API version 3.
Gerhard Sittig [Sun, 4 Dec 2016 20:08:51 +0000 (21:08 +0100)]
avr_pdi: Convert to PD API version 3.

Switch to the v3 decoder API: The decode() methods takes no arguments,
instead it calls wait() and has common code find edges on input signals.

3 years agoavr_pdi: introduce decoder for Atmel Program and Debug Interface
Gerhard Sittig [Sat, 12 Nov 2016 22:19:47 +0000 (23:19 +0100)]
avr_pdi: introduce decoder for Atmel Program and Debug Interface

Introduce a decoder for Atmel's proprietary programming and debugging
interface which got introduced with ATxmega chips. This implementation
supports the UART style physical (two wires PDI_CLK and PDI_DATA).

3 years agousb_power_delivery: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:21:39 +0000 (15:21 +0200)]
usb_power_delivery: Convert to PD API version 3.

3 years agotlc5620: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:21:08 +0000 (15:21 +0200)]
tlc5620: Convert to PD API version 3.

3 years agotiming: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:21:03 +0000 (15:21 +0200)]
timing: Convert to PD API version 3.

3 years agoswd: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:20:17 +0000 (15:20 +0200)]
swd: Convert to PD API version 3.

3 years agostepper_motor: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:19:54 +0000 (15:19 +0200)]
stepper_motor: Convert to PD API version 3.

3 years agospdif: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:19:21 +0000 (15:19 +0200)]
spdif: Convert to PD API version 3.

3 years agoparallel: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:17:52 +0000 (15:17 +0200)]
parallel: Convert to PD API version 3.

3 years agoonewire_link: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:16:48 +0000 (15:16 +0200)]
onewire_link: Convert to PD API version 3.

3 years agojtag: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:15:12 +0000 (15:15 +0200)]
jtag: Convert to PD API version 3.

3 years agojitter: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:14:40 +0000 (15:14 +0200)]
jitter: Convert to PD API version 3.

3 years agoir_nec: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:14:29 +0000 (15:14 +0200)]
ir_nec: Convert to PD API version 3.

3 years agoi2s: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:14:07 +0000 (15:14 +0200)]
i2s: Convert to PD API version 3.

3 years agoi2c: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:13:49 +0000 (15:13 +0200)]
i2c: Convert to PD API version 3.

3 years agoguess_bitrate: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:13:21 +0000 (15:13 +0200)]
guess_bitrate: Convert to PD API version 3.

3 years agodcf77: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:12:53 +0000 (15:12 +0200)]
dcf77: Convert to PD API version 3.

3 years agoaud: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:11:16 +0000 (15:11 +0200)]
aud: Convert to PD API version 3.

3 years agoam230x: Convert to PD API version 3.
Uwe Hermann [Fri, 26 Aug 2016 13:09:41 +0000 (15:09 +0200)]
am230x: Convert to PD API version 3.

3 years agoAdd support for the new query-based PD v3 decoder API.
Uwe Hermann [Fri, 26 Aug 2016 13:09:17 +0000 (15:09 +0200)]
Add support for the new query-based PD v3 decoder API.

For the time being, both APIs (2 and 3) will remain supported until all
decoders have been converted to API version 3. Then, support for API
version 2 will be dropped.

Decoders using PD v3 API can benefit from both readability improvements
as well as performance improvements. Up to 10x speedup has been measured
in some situations (depends a lot on the decoder, the amount of data,
the amount of edges in the signals, the amount of oversampling etc. etc.).

This is only the first set of (basic) performance improvements for
libsigrokdecode, there are various additional opportunities for further
changes to improve performance.

This changeset has been tested to survive a run of all the test-cases in
the sigrok-test repo without issues (for the converted PDs), however it is
not very well-tested yet, so there might be regressions that need to be
addressed.