From 0b7572e55936977d9ce91c0e0932939708776161 Mon Sep 17 00:00:00 2001 From: "W. Trevor King" Date: Wed, 2 Jun 2010 01:21:31 -0400 Subject: [PATCH] Flip deflection sign for hooke.driver.wtk. We want +deflection for +chain tension. --- hooke/driver/wtk.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/hooke/driver/wtk.py b/hooke/driver/wtk.py index 46bf92e..640f056 100644 --- a/hooke/driver/wtk.py +++ b/hooke/driver/wtk.py @@ -185,7 +185,11 @@ class WTKDriver (Driver): * info['z piezo sensitivity (m/V)'] ) - ret[:,d_scol] = ( + # Leading '-' because deflection voltage increases as the tip + # moves away from the surface, but it makes more sense to me + # to have it increase as it moves toward the surface (positive + # tension on the protein chain). + ret[:,d_scol] = -( (data[:,d_rcol] * info['deflection sensitivity (V/bit)'] - info['deflection offset (V)']) -- 2.26.2