This is an old revision of the document!
This page contains information on the USB-based data acquisition running on the NSCL-supported devices. It is intended to provide a better understanding of the software and a way for users to setup or modify the configurations to their needs.
The USB-based data acquisition is built around the VM-USB (VME) and CC-USB (CAMAC) crate controllers available from Wiener Electronics. These controllers contain at their core an FPGA on which the controller firmware is loaded. The controllers have two modes of operation:
The first mode is typically used when setting up the modules contained in the crate, such as gains, thresholds and so on, while the second mode is used for acquiring event-driven data. The two modes are mutually exclusive, and issuing an interactive command while in data acquisition mode will typically result in an error or lockup of the controller.
The USB DAQ is a Tcl-based software using a simple API library to handle the low-level handling of the data. It is capable of handling multiple crate controllers (CC-USB or VM-USB) connected to the same computer. Each controller is polled by an independent thread which then sends the data through a predefined TCP/IP port.
The machine-level calls to the USB interface are handled by a library called “libusb” which is widely available on many platforms (Linux, OS X, Windows). The installation of this library is mandatory in order to use this data acquisition system. Wiener Electronics provides a C library called “libxxusb” built on top of libusb with subroutines tailored to the VM-USB and CC-USB. The USB DAQ in turn uses this library in a Tcl API written to interface the C subroutines of libxxusb to the Tcl world. The library implementing this API is called “libTclXXUSB”. It also contains custom subroutines used in sending data through TCP/IP ports.
The data streams coming from the various crates are synchronized and combined into a single stream by the event builder program (written in C). This program connects to the TCP/IP ports of the USB DAQ as a client. It also checks the sanity of the buffers before assembling them into NSCL standard buffers.
The software is distributed into the following folder structure: