diff options
author | Arno Morbach <59687682+morri-od@users.noreply.github.com> | 2020-01-13 14:30:16 +0100 |
---|---|---|
committer | Uwe Hermann <uwe@hermann-uwe.de> | 2020-07-20 23:19:03 +0200 |
commit | 028589e66b614059224939e4fbc18ed35b2ae64b (patch) | |
tree | 1397d630a17166ade9e7223551161ebfbc3581b3 /decoders/rfm12 | |
parent | b094fdfc1c1cfe1e34f95c62e73241cff5e4074c (diff) | |
download | libsigrokdecode-028589e66b614059224939e4fbc18ed35b2ae64b.tar.gz libsigrokdecode-028589e66b614059224939e4fbc18ed35b2ae64b.zip |
spdif: Fix various issues.
Bug #897 and my own experience caused me to improve the SPDIF decoder.
The following issues were addressed and resolved:
1. The Error: "srd: ValueError: Protocol decoder instance spdif-1:
invalid literal for int() with base 2: '121111012112021111012120'"
This error can happen if the sample rate is marginal. The correct function
of the decoder depends on the position of the data stream. The pulse width
calculation was wrong and the pulse width detection sometimes thought the
same pulse classes to be different.
The new decoder explicitly checks for short pulses and reports an error
with a corresponding message.
2. Bitrates were calculated wrong: The shown results were not usable at all.
The new decoder uses the first ten frames to calculate the bit rates and
uses the correct measurement units.
Possible issue: The bit rate calculation assumes an ongoing data stream.
It uses the time between the first and 10th frame.
They need to be sent without interruption. But this should be no problem
because SPDIF is meant to be a continuous stream.
3. A missing samplerate, e.g. when used in sigrok-cli with binary input, lead
to an error message on the original decoder.
The new decoder just skips the output of the bitrate if the samplerate is
missing. A missing samplerate no longer raises an error but only a message
in the data output.
4. The user was not informed about the integral steps of the decoder.
The new decoder shows the results of the synchronisation process at the
beginning. This can help to understand the behaviour of the decoder.
This fixes bug #897.
Diffstat (limited to 'decoders/rfm12')
0 files changed, 0 insertions, 0 deletions