fluidlab.objects.boards

Data Acquisition boards (fluidlab.objects.boards)

Provides two small classes, ObjectUsingBoard and the modules:

nidaqnx

National Instrument board (fluidlab.objects.boards.nidaqnx)

Remark: Can not import the module fluidlab.objects.boards.powerdaq in Linux… So no doc!

The classes for data acquisition boards should be obtained from this package. If the boards are not available, no error are raised and the classes are replaced by the class fluidlab.objects.boards.FalseBoard.

For example, with a computer without PowerDAQ board:

from fluidlab.objects.boards import PowerDAQBoard
board = PowerDAQBoard() # no error
assert(board.works == False) # no error
assert(not board) # no error
board.ain.configure(sample_rate=100) 
# AttributeError: You tried to use a false acquisition board.
class fluidlab.objects.boards.ObjectUsingBoard(board=None, VERBOSE=False)[source]

Useful to write classes for objects using a board.

class fluidlab.objects.boards.FalseBoard[source]

Represent a false acquisition board.

This object tested as a boolean is False. It has an attribute works equal to False and an AttributeError on it returns an understandable message.

Classes

FalseBoard()

Represent a false acquisition board.

ObjectUsingBoard([board, VERBOSE])

Useful to write classes for objects using a board.

PowerDAQBoard

alias of FalseBoard