[chronojump] Fixed bug in encoder capture



commit e51c8113c184142116a4c045cfa4e41041e51617
Author: Xavier de Blas <xaviblas gmail com>
Date:   Mon Apr 1 14:33:26 2013 +0200

    Fixed bug in encoder capture

 encoder/pyserial_pyper.py         |    4 ++--
 encoder/pyserial_pyper_windows.py |    4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/encoder/pyserial_pyper.py b/encoder/pyserial_pyper.py
index 8d27dd4..57e4843 100644
--- a/encoder/pyserial_pyper.py
+++ b/encoder/pyserial_pyper.py
@@ -158,9 +158,9 @@ def calculate_all_in_r(temp, top_values, bottom_values, direction_now,
                        start=bottom_values[len(bottom_values)-1]
                        end=top_values[len(top_values)-1]
                
-               if(eccon == "c")
+               if eccon == "c":
                        myR.assign('smoothingOne',smoothingOneC)
-               else
+               else:
                        myR.assign('smoothingOne',smoothingOneEC)
 
                myR.assign('a',temp[start:end])
diff --git a/encoder/pyserial_pyper_windows.py b/encoder/pyserial_pyper_windows.py
index 11ca93c..fd01bc9 100644
--- a/encoder/pyserial_pyper_windows.py
+++ b/encoder/pyserial_pyper_windows.py
@@ -161,9 +161,9 @@ def calculate_all_in_r(temp, top_values, bottom_values, direction_now,
                        start=bottom_values[len(bottom_values)-1]
                        end=top_values[len(top_values)-1]
                
-               if(eccon == "c")
+               if eccon == "c":
                        myR.assign('smoothingOne',smoothingOneC)
-               else
+               else:
                        myR.assign('smoothingOne',smoothingOneEC)
 
                myR.assign('a',temp[start:end])


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]