Index: /fact/tools/pyscripts/pyfact/SignalGenerator.py
===================================================================
--- /fact/tools/pyscripts/pyfact/SignalGenerator.py	(revision 12976)
+++ /fact/tools/pyscripts/pyfact/SignalGenerator.py	(revision 12977)
@@ -55,6 +55,6 @@
 
     def __call__(self, option_str = ''):
-        self.option_str = option_str.lower()
-        if self.option_str:
+        if option_str:
+            self.option_str = option_str.lower()
             self.options = make_options_from_str(self.option_str)
             self.parse_options()
@@ -120,6 +120,6 @@
 if __name__ == '__main__':
     """ test the class """
-    myGenerator = SignalGenerator()
-    sig = myGenerator('len 100 noise 0.3 bsl -2.5 step 20.3 12 24 triangle 10.2 50 10 30 spike 2 50. 20 50')
+    myGenerator = SignalGenerator('len 100 noise 0.3 bsl -2.5 step 20.3 12 24 triangle 10.2 50 10 30 spike 2 50. 20 50')
+    sig = myGenerator()
     print myGenerator
-    plotter(sig, myGenerator.option_str)
+    plotter(sig, myGenerator.option_str)    
