code: def stateDict(self):
          
          state = {
                  'duration' : self._duration,
                  'intensity' : self._intensity,
                  'risefall' : self._risefall,
                  'stim_type' : self.name
                  }
          return state
docs: Saves internal values to be loaded later
  
          :returns: dict -- {'parametername': value, ...}