Readout Controllers


Each front end crate (FASTBUS, VME, or CAMAC) contains a single board computer running a real-time operating system with networking support (TCP/IP). Currently the only the VxWorks real-time operating system is supported but there is a project to port the code to linux and other UNIX like operating systems. (We have also run the software on HP-UX running on an hp7431 PA-RISC single board computer.)


An Ethernet network is generally used for control and monitoring of the embedded controller, downloading calibration data. Ethernet may also be used for low rate data acquisition (test setup, spying, etc). A higher speed link is used for the main data flow if rates exceed the ethernet interface speed, (theoretically this is 1MByte/sec but for all practical purposes is 500 kByte/S). This faste link may take the form of a faster network (FDDI or ATM in VME), or may be a simple point-to-point data link to another controller such as an FSCC controller in FASTBUS which transmits data at 40MB/sec to a buffer memory in VME via a parallel data link.

Custom code must be written for each non-network link.


At present (July 1995) CODA is supported for the following bus architectures and hardware configurations. 
Here is an index of this page:


VME



CAMAC



VIC bus to CAMAC interface. The 2117 was designed as an interface between the VIC bus (originally a VME-VME interconnect) and CAMAC. The board has an onboard 25MHz 68030, up to 16MBytes of RAM and an Ethernet interface. The Jefferson lab. data acquisition group (i.e. us) ported the VxWorks operating system to this board so that it could be used as an embedded ROC in CAMAC. The limitations of this system are that data acquisition is limited to Ethernet speeds and only a single CAMAC crate is supported. With a little work multiple crates could be supported by making the VCC2117 the controller in an "executive CAMAC crate" which acts as the master to one or more CAMAC branches. Another alternative would be to modify the ROC code so that the data is transmitted on the VIC bus. As of this time no interest has been expressed in either option.



notes on CAMAC

The support of CAMAC was critical to the early releases of CODA which were used in detector tests using existing electronics, mostly CAMAC modules, and low budgets. The philosophy was taken that we should be able to support as many different CAMAC interfaces as possible. With this in mind CAMAC support in CODA is based on the IEEE standard "Subroutines for CAMAC" (ANSI/IEEE Std 758-1979) as outlined in "CAMAC instrumentation and interface standards (ISBN 0-471-89737-X). Any interface conforming to this standard (i.e. following the IEE library convention with calls like cssa, cdreg, cfsa,cccz etc.) may be used with CODA with minimal modifications to the code.


FASTBUS

Fastbus is a very popular bus standard in High Energy and Nuclear physics due to the large board area, fast data transfer rates (40MByte/S) and availability of a wide range of modules tailored to the needs of particle detectors.

Traditionally large scale FASTBUS systems were constructed from many individual crates connected via segment interconnects (basically an implimentation of the bus on a cable) in some hierachy to one or more mini computers. The individual controllers in FASTBUS crates were usually lacking in intelligence and contained only a command sequencer and large buffer memory. The sequencer was triggered by an external event and read all of the data out of the FASTBUS modules into the buffer memory. the high data rates (40MByte/S) on the backplane lead to a low deadtime and the buffer memories were read by the mini-computers during the inter-spill gap. This approach was clearly unacceptable at Jefferson lab since the accelerator has a continuouse wave electron beam with negligable spill structure.

Fortunaltely several commercial "intelligent" FASTBUS controllers now exist which allow us to run the readout controller software and VxWorks in the FASTBUS crate. All of these controllers have the traditional buffer memory and high speed FASTBUS sequencer which read the data off the backplane at the high rates required to reduce deadtime. They also have an embedded microprocessor and associated peripherals which can be used to format the data and transmit it on a network or over a parallel data link. The distributed "intelligence" allows data formatting and transport to take place in parallel increasing overall efficiency and reducing dead-time.

In order to use CODA with a controller to conditions must be met. Firstly, a port of VxWorks to the embedded microprocessor must exist. Secondly, there must be an implementation of the standard library for Fastbus for the controller. 



Triggering a Readout Controller

Trigger information for the readout controller may come from Trigger Supervisor (if used) or from other hardware, such as descrete NIM modules. The trigger may be detected either by an interrupt, or by polling an address (any memory mapped device), or polling a LAM in CAMAC. The CODA Readout Language has elements for selecting among these possibilities and having multiple trigger sources. When the ROC detects a trigger it handles the event and calles a user supplied routine (the done routine) which re-enables the trigger. It is important that the external trigger hardware should lock out new triggers until the ROC calls the re-enable routine otherwise triggers may be missed. In the cases when the ROC is unable to take a new trigger the re-enable routine is not called until the condition causing the delay disappears. This is usually that all the internal buffers are full and the ROC is waiting for the network transmission code to free up buffers.

The Jefferson lab data acquisition group has designed interface hardware for use with the supported readout controllers. These interfaces include level converters, CAMAC and VME interfaces to the trigger supervisor and FASTBUS auxillary cards for the SFI and FSCC which provide a high speed parallel data link and trigger supervisor interface.


FASTBUS Auxillary interfaces to the trigger supervisor, FSCC on right SFI on left. The FSCC Interface doubles as data sources for a 40 MByte/Sec parallel data link. The large grey connector on the SFI interface caries the outer two rows of pins from the VME P2 conector of the slot containing the VME processor.



VME interface to the trigger supervisor.



High speed (40 MByte/Sec parallel data link, VME end.

For more detail see: Readout controller user guide

Harsh Reality

Just in case you think this is all clean and easy here is a picture of a real Readout controller in a test setup in our lab.