# Using the Universal Library

## Board Detetction Options

### InstaCal Detection

Most users will use InstaCal to detect and add MCC devices to their system for use by the Universal Library. This is the easiest method, and the one used by almost all of the example programs. When InstaCal is run, it adds all the MCC devices discovered automatically and all the MCC devices added manually by the user to a configuration file (cb.cfg). Any changes to the device configuration, such as input mode, are also stored in this file. When an application that uses the Universal Library is run, this file is used to determine what devices are installed and what configuration to set (if programmable) or has been manually set.

### Runtime Detection

Many devices can be discovered programmatically at run-time in lieu of, or in addition to, using InstaCal-discovered devices. Refer to the InstaCal, API Detection, or Both? section for more information. Using this method, any change from the default configuration of your MCC hardware requires setting at runtime using API configuration features.

## Buffer Management

The Universal Library contains numerous functions and methods for managing Windows global memory buffers. Refer to the Windows Memory Management topics listed in the UL Function Reference section.

## Real-Time Acquisition

Data streaming hardware must have an onboard FIFO buffer for full speed operation in Windows. Processor speeds will affect this. If you are using a device that applies calibration in real time, and overruns or underruns are occurring, consider using the NOCALIBRATEDATA option (if supported by your hardware).

## Single-process

Only one application program (process) that calls the Measurement Computing driver can be running at a time, although multiple threads within that application can call the Measurement Computing driver.

For example, when you are running a program created with the Universal Library, you cannot change any hardware configuration settings using InstaCal until you first exit the UL program. This is because InstaCal stores the hardware configuration settings in a file (cb.cfg) which is read by the Universal Library when you run an application. To change device settings using InstaCal, first exit the UL application.