mwavepy.virtualInstruments.futekLoadCell | index /usr/local/lib/python2.6/dist-packages/mwavepy/virtualInstruments/futekLoadCell.py

`# futekLoadCell.py
#
# Copyright 2011 alex arsenovic <arsenovic@virginia.edu>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
# MA 02110-1301, USA.`

Modules
`` |  |
numpy | os | pylab | subprocess

Classes
`` |  | __builtin__.object FutekMonitor Futek_USB210_pipe mwavepy.virtualInstruments.generalSocketReader.GeneralSocketReader Futek_USB210_socket
class FutekMonitor(__builtin__.object)
`` |  | Methods defined here: __init__(self, ax=None, window_length=-1, **kwargs) get_data_and_plot(self) update_axis_scale(self) update_data(self) update_line(self) Data descriptors defined here: __dict__ `dictionary for instance variables (if defined)` __weakref__ `list of weak references to the object (if defined)`
class Futek_USB210_pipe(__builtin__.object)
`` |  | Methods defined here: __init__(self, sample_rate=2.5, avg_len=1) close(self) read(self) write(self, data='gimme data\n') Data descriptors defined here: __dict__ `dictionary for instance variables (if defined)` __weakref__ `list of weak references to the object (if defined)` data
class Futek_USB210_socket(mwavepy.virtualInstruments.generalSocketReader.GeneralSocketReader)
`` |  | Methods defined here: __init__(self, *args, **kwargs) Methods inherited from mwavepy.virtualInstruments.generalSocketReader.GeneralSocketReader: close(self) connect(self, host, port) receive(self) send(self, data) Data descriptors inherited from mwavepy.virtualInstruments.generalSocketReader.GeneralSocketReader: data `tmp = [] for n in range(self.avg_len): sleep(1./self.sample_rate) send(self.query_string) tmp.append(float(receive())) return npy.mean(tmp)`

Functions
`` |  | sleep(...) `sleep(seconds) Delay execution for a given number of seconds. The argument may be a floating point number for subsecond precision.`