== BFModule - BitFlow Python Bindings ==

Updated: 10/18/2024

For assistance, please contact support@bitflow.com

REQUIREMENTS

	BitFlow SDK v6.6 or BitFlow SDK v6.5 (available for download on the BitFlow Downloads page). The development SDK is not required. The free drivers-only intallation is sufficient.

	Python versions 3.8, 3.10 and 3.12 are supported.

	This version of the BFPython API is only supported on 64-bit Windows.
	
INSTALLATION:

  Windows:	
       	* Download and install the desired Python version using the given url.        
		It may be necessary that you add the path to the python.exe to your PATH variable like:
			set PATH=c:\PythoXX;%PATH%
	
	* BFModule : https://www.bitflow.com/support/request-downloads/
		Download the zip file containing the latest whl file, example programs, and the html documentation using the url above.
		
		[Optional] 	Create a virtual environment using the command:
						$ python.exe -m venv [venv-name]
					
					To activate the virtual environment run the following command:
						$ [venv-name]\Scripts\activate						
					
		To install BFModule using the wheel file:
			$ python.exe -m pip install BFModule-X.x.x-cpXX-cpXX-win_amd64.whl 

  Linux:
	* Download and install the BitFlow Linux Drivers and SDK along with the BitFlow Tools for Linux (BFT4Lin) package.

	* Download and install the latest supported Python version.

		$ sudo apt install python3


	* BFModule : https://www.bitflow.com/support/request-downloads/
		Download the zip file containing the latest whl file, example programs, and the html documentation and unzip the file to any location on your PC.

		[Optional]	Create a virtual environment using the command:
    					$ python3 -m venv [venv-name]

				To activate the virtual environment run the following command:
				        $ source [venv-name]/bin/activate

		To install BFModule using the wheel file: 
    			$ python.exe -m pip install BFModule-X.x.x-cpXX-cpXX-linux_x86_64.whl

			Where, BFModule-X.x.x-cpXX-cpXX-linux_x86_64.whl is the name of the WHL file in the extracted folder.

		Add the BFT4Lin library directory to the LD_LIBRARY_PATH variable.

			export LD_LIBRARY_PATH="/usr/local/lib/BitFlow:$LD_LIBRARY_PATH"
			
			
MODULES:

	BFModule consists of several sub-modules:
    
		1. BufferAcquisition
			Acquisition API and interface to the general frame grabber features.
			Supports both continuous circular acquisition using the BufferAcquisition.CircularAcquisition class, and fixed-length acquisition using BufferAcquisition.SequenceAcquisition. Methods for CoaXPress register access and image file save operations are also provided.

		2. BFGTLUtilities
			BitFlow Gen<i>Cam Transport Layer interface for camera control. Utilizing the Gen<i>Cam standard, any standard compliant CoaXPress camera and certain Camera Link cameras may be dynamically programmed using standardized named features and and intuitive values, exposed through a simple API.

		3. CXPReg
			Interface to the CoaXPress camera register space.

		4. CLComm
			Interface to the Camera Link serial port interface, supporting all standard CLSerial methods, plus several BitFlow extensions.

		5. Display
			Provides a simple GUI class for display of acquired frames.			


EXAMPLES:

	1. BFGTL.py
			Example program demonstrating the use of the BFGTLUtils sub-module to access and control GenICam devices.
	2. CircularAcquisition.py
			Example demonstrating the capture data to a circular buffer from a single frame grabber board, the use of software trigger, and reading and writing of registers
	3. CircAqNumpyArray.py
			Example demonstrating the capture data to a circular buffer from a single frame grabber board, the use of software trigger, and reading and writing of registers. Also demonstrates the use of NumPy arrays to acquire images and use the OpenCV imshow function to display the captured images.
	4. CLSerialCom.py
			A simple implementation of a Camera Link serial com terminal client using mutli-threading to handle user command input and data reception from the camera's serial device asynchronously.
	5. ExposureControl.py
			Opens a single BitFlow board for capture and allows the user to adjust the board's timing generator on the fly.
	6. SeqAcquisition.py
			A simple example demonstrating sequential acquisition using a BitFlow board.
	7. SimpleCirc.py
			A simple example of capturing data to a circular buffer from a single frame grabber board.
	8. SimpleCircNumpyArr.py
			A simple example of capturing data to a circular buffer from a single frame grabber board. Also demonstrates the use of NumPy arrays to acquire images and use the OpenCV imshow function to display the captured images.
	9. ReadImages.py
			A simple example of reading images from the disk into a buffer array and displaying them.
	10. UserAlloc.py
			A simple example of capturing data in to a user allocated buffer array from a single frame grabber board.