-# Copyright (C) 2010 W. Trevor King <wking@drexel.edu>
+# Copyright (C) 2010-2011 W. Trevor King <wking@drexel.edu>
#
# This file is part of Hooke.
#
"""Driver for W. Trevor King's velocity clamp data format.
-See my related projects:
+See my blog post:
-* http://www.physics.drexel.edu/~wking/code/git/git.php?p=unfold_protein.git
-* http://www.physics.drexel.edu/~wking/code/git/git.php?p=calibrate_cantilever.git
-* http://www.physics.drexel.edu/~wking/code/git/git.php?p=data_logger.git
-* http://www.physics.drexel.edu/~wking/code/git/git.php?p=piezo.git
-* http://www.physics.drexel.edu/~wking/code/git/git.php?p=pycomedi.git
+* http://www.physics.drexel.edu/~wking/unfolding-disasters/Hooke/
-And the deprecated projects (which Hooke replaces):
+related projects:
-* http://www.physics.drexel.edu/~wking/code/git/git.php?p=scale_unfold.git
-* http://www.physics.drexel.edu/~wking/code/git/git.php?p=sawmodel.git
+* http://www.physics.drexel.edu/~wking/code/git/gitweb.cgi?p=unfold_protein.git
+* http://www.physics.drexel.edu/~wking/code/git/gitweb.cgi?p=calibrate_cantilever.git
+* http://www.physics.drexel.edu/~wking/code/git/gitweb.cgi?p=data_logger.git
+* http://www.physics.drexel.edu/~wking/code/git/gitweb.cgi?p=piezo.git
+* http://www.physics.drexel.edu/~wking/code/git/gitweb.cgi?p=pycomedi.git
+
+and the deprecated projects (which Hooke replaces):
+
+* http://www.physics.drexel.edu/~wking/code/git/gitweb.cgi?p=scale_unfold.git
+* http://www.physics.drexel.edu/~wking/code/git/gitweb.cgi?p=sawmodel.git
"""
import calendar
import numpy
from .. import curve as curve
-from .. import experiment as experiment
from ..config import Setting
from . import Driver as Driver
-try:
- import calibcant.config
- calibcant_dir = calibcant.config.LOG_DIR
-except ImportError:
- calibcant_dir = None
-
-try:
- import data_logger
-except ImportError:
- data_logger = None
-
class WTKDriver (Driver):
"""Handle W. Trevor King's data_logger data format.
Setting(section=self.setting_section, help=self.__doc__),
Setting(section=self.setting_section,
option='cantilever calibration directory',
- value=calibcant_dir, type='path',
+ value='~/rsrch/data/calibrate_cantilever', type='path',
help='Set the directory where cantilever calibration data is stored'),
]
unlabeled_approach_data, params, 'approach')
retract = self._scale_block(
unlabeled_retract_data, params, 'retract')
- info = {'filetype':self.name, 'experiment':experiment.VelocityClamp()}
+ info = {}
return ([approach, retract], info)
def _paths(self, path):
if basedir == None:
basedir = self.config['cantilever calibration directory']
YYYYMMDD = time.strftime("%Y%m%d", time.localtime(timestamp))
- dir = os.path.join(data_logger.normalize_logdir(basedir), YYYYMMDD)
+ basedir = os.path.expanduser(basedir)
+ dir = os.path.join(basedir, YYYYMMDD)
if not os.path.exists(dir):
return []
all_calibfiles = os.listdir(dir) # everything in the directory