From 1d3981ca37c35527cf9125859ac38510a31123b4 Mon Sep 17 00:00:00 2001 From: "Prof. Dr. Andreas Noack" Date: Tue, 19 May 2020 13:00:00 +0200 Subject: [PATCH] Remove NRZ-I to prevent mixing with NRZ + Invert, clarify names. (#776) * Change NRZ-I decoding from invert to differential encoding (see e.g. https://en.wikipedia.org/wiki/Non-return-to-zero). Fix #775 * skip bugged cython version * Remove "Non Return To Zero Inverted (NRZ-I)" due to contradictory definitions in literature. Co-authored-by: jopohl --- data/requirements.txt | 2 +- src/urh/signalprocessing/Encoding.py | 4 ---- src/urh/util/ProjectManager.py | 4 ++-- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/data/requirements.txt b/data/requirements.txt index 1a03352b56..8a163d4c7e 100644 --- a/data/requirements.txt +++ b/data/requirements.txt @@ -3,4 +3,4 @@ numpy>=1.9,!=1.16.0; sys_platform == 'win32' pyqt5; sys_platform != 'win32' pyqt5!=5.14.2; sys_platform == 'win32' psutil -cython +cython!=0.29.18 diff --git a/src/urh/signalprocessing/Encoding.py b/src/urh/signalprocessing/Encoding.py index 03e80aec70..8a82b8ce18 100755 --- a/src/urh/signalprocessing/Encoding.py +++ b/src/urh/signalprocessing/Encoding.py @@ -74,10 +74,6 @@ def name(self): def is_nrz(self) -> bool: return len(self.chain) <= 1 - @property - def is_nrzi(self) -> bool: - return len(self.chain) == 2 and self.chain[1] == self.code_differential - @property def contains_cut(self) -> bool: return self.code_cut in self.chain diff --git a/src/urh/util/ProjectManager.py b/src/urh/util/ProjectManager.py index 27a8cad3c3..5a33747ff9 100644 --- a/src/urh/util/ProjectManager.py +++ b/src/urh/util/ProjectManager.py @@ -122,8 +122,8 @@ def load_decodings(self): fallback = [Encoding(["Non Return To Zero (NRZ)"]), - Encoding(["Non Return To Zero Inverted (NRZ-I)", - settings.DECODING_DIFFERENTIAL]), + Encoding(["Non Return To Zero + Invert", + settings.DECODING_INVERT]), Encoding(["Manchester I", settings.DECODING_EDGE]),