INTRODUCTION TO COMPUTER-BASED DATA ACQUISITION
Data Acquisition and Measurement
Student Name: ___________________________________________________ 
Acknowledgements
Subject Matter Expert: Roy Brixen, College of San Mateo, CA
Purpose
The purpose of this lab is to familiarize the student with the basic principles of computer based data acquisition, data store, and display.  With the advent of low cost data conversion hardware and modules, plus the availability of configurable software, the capability of interfacing an analog measurement system to a computer is very easy and used throughout industry.  Being able to explain and implement computer-based data acquisition becomes a valuable skill for any technician.
Systems Rationale
Computer systems are used everywhere.  They store data, they analyze data, and they display data.  The only thing they don’t do is have the ability to deal with the events of the analog world.  A system needs to be developed that will take the smoothly changing voltage and/or current that represents analog events (temperature, level, pressure, flow, vibration) and convert that voltage/current into a proportional binary number understandable by a computer.  This lab activity will lead the student through a process designed to measure temperature in the analog voltage domain, convert that voltage to a binary number, transfer that number to a computer via a USB data link, and display and store the results of the measurement.        
System Concepts
This system covers the following system concepts (signified by an X):
_X_ 	S1. A system can be defined in terms of its functional blocks i.e., a “structured functional unit.”
_X_ 	S2. A system has a purpose, transforms inputs into outputs to achieve a goal.
_X_ 	S3. A system is defined by the flow of materials, energy and information, between its functional units.
_  _ 	S4. A system may be open or closed. In an open system additional inputs are accepted from the environment.
_X_ 	S5. A system is more than the sum of its parts. Individual components can never constitute a system.
_X_ 	S6. A system provides feedback to the operator and services to the user. Some system functions may involve operator action.
_X_ 	S7. Systems have unique problems.

Learning Outcomes
These LOs maybe found at the SLO tab of the course.  http://www.esyst.org/Courses/Acquisition_Measurement/_delivery/index.php
  
11.	Define data acquisition.
12.	Draw a generic block diagram of a data acquisition (DAQ) system and identify each section and explain how it works.  
13.	State and defined the various methods of signal conditioning in a DAQ system.
14.	State the function of a multiplexer in a DAQ system.
15.	Name the main specifications of an analog-to-digital (ADC) used in a DAQ system.
16.	Explain how data acquired in a DAQ system is stored.  

LABORATORY
3.	Build a simple DAQ system with sensors, signal conditioning, ADC and other components as needed to collect data. 
Prerequisite Knowledge & Skills
•	A basic understanding of temperature measurement using a thermocouple is necessary to complete this lab activity.
•	Basic Windows navigation skills are necessary to complete this lab activity. 
Learning Objectives
Relevant knowledge (K), skill (S), or attitude (A) student learning outcomes include:  

K1.  Define and describe the key foundation concepts of computer-based data acquisition. 
K2.  Name the parts that make up a computer-based data acquisition system.
K3.  Identify the function of the parts that make up a computer-based data acquisition system.
S1.  Install, configure, and test a computer-based data acquisition system.
S2.  Construct and demonstrate a computer-based data acquisition system that converts an analog voltage representing temperature into a computer-based graphic display.
S3.  Demonstrate basic system troubleshooting skills involving a computer-based data acquisition system.
A1.  Demonstrate a desire to maintain a safe working environment by putting on eye shields before touching any lab materials/equipment.
Process Overview
The lab introduces you to the basic system hardware and concepts involving data acquisition.  In this lab activity you will learn how to connect a data acquisition module to a desktop or laptop computer via a USB port, configure the module to select appropriate I/O connections, check the modules for basic operation, launch and operate a data acquisition and display program, and construct a system to plot temperature.  
Time Needed
Lab Performance: 
It should take students approximately 2.5 hours to work through the entire lab.

Lab Deliverables: 
It should take students approximately 2.5 hours of homework time to create the written lab report.
Equipment & Supplies
Item	Quantity	
Measurement Computing USB-1208LS Data Acquisition module with USB cable	1	
10k ohm potentiometer	1	
Thermocouple/AD595 thermometer circuit	1	
5 volt DC Power Supply 	1	
#22 AWG hookup wire	4 feet	
Special Safety Requirements
You will be using boiling water to create a reference source of high temperature.  Be careful of the heat source and do not spill the boiling water.  First and second degree skin burns will be the result.  

You will also be using water, boiling water, and ice at some point around electrical/electronic hardware.  Water and electricity do not mix.  Be aware that there is a danger of electrocution should you accidently spill water and allow it to mix with electrical hardware.
Lab Preparation
1.	Measurement Computing’s InstaCalc software needs to be installed on the lab computer.
2.	TracerDAQ or TracerDAQ Pro needs to be installed on the lab computer.
3.	You will need to attach, via soldering, three wires to a 10k ohm pot.  One wire per terminal hub.
4.	The thermometer, using a thermocouple and the AD595 is necessary to complete this lab activity.
5.	Unpack the Measurement Computing’s USB-1208LS Data Acquisition module and locate the USB cable.
Introduction
Modules used to implement computer-based data acquisition systems are available in a number of different hardware profiles.  Some are external modules connected to the PC via USB or more conventional serial communications hardware.  Other modules are PC board designed to mount in ISA-16 slots or PCI slots inside the computer.  Cables are used to bring necessary connections out to the user for easy access.  For laptop computers, some companies manufacture DAQ cards that insert into memory slots normally used for expansion.  For this lab, you will use a hardware module manufactured by Measurement Computing Corp. and bears the model number USB-1208LS.

The Measurement Computing Corp. USB-1208LS Data Acquisition Module consists of five sections that include the analog input section, an analog output section, an event counter, a parallel digital I/O section, and a USB compatible interface.  All five sections are managed by an on-board microcontroller.

The analog input section consists of 8 single-sided 11-bit input channels or 4 differential 12-bit input channels.  The eight single-sided input channels are fed, via an 8-input multiplexer to the A2D converter in the USB-1208LS Module.  If the four differential inputs are selected, they are also fed, via the 8-input multiplexer, to the A2D converter in the USB-1208LS Module.

The analog output section consists of two 10-bit D2A converters.  The computer feeds binary data from memory or a data file to the D2A converts.  These converters produce an analog output voltage that is proportional to the 10-bit input code.

The event counter is a configurable 32-bit down counter.  The configuration program loads the counter with a 32-bit number and an externally connected trigger signal decrements the counter -- one decrement per trigger signal.  When the counter reaches terminal count (all zeros) an output bit is activated signaling that terminal count has been achieved.

The 16-bit parallel digital input/output section gives the module the capability to read up to 16 input switches or write to 16 output loads (like LEDs or sonic alarms).

Finally, the USB compatible interface permits easy plug-and-play serial communications with a desktop or laptop computer.

A block diagram of the USB-1208 is provided on the next page of this lab for further study.

Task
Using a computer to acquire analog or digital data, store the information, and display the information in usable form is a modern skill all electronics technicians need to understand and be able to perform.  This lab takes you through the process of configuring both the DAQ hardware module, the configuration software, and the DAQ software.  You will learn how to configure the DAQ software for proper data display and you will use DC voltages and the output of a thermocouple based thermometer to provide the DAQ module with appropriate electrical signals.
Performance
The MMC USB-1208SL DAC hardware components need to be identified and explained.  
  External components 
The USB-1208LS has the following external components, as shown below: 
	! USB connector 
	! LED 
	! Screw terminal banks (2) 

 USB connector 
The USB connector is on the right side of the USB-1208LS housing. This connector provides +5V power and communication. The voltage supplied through the USB connector is system-dependent, and may be less than 5V. No external power supply is required. 
 LED 
The LED on the front of the housing indicates the communication status of the USB-1208LS.  It uses up to 5 mA. of current and cannot be disabled.  The table below defines the function of the USB-1208LS LED.
 
When the LED is. 	It indicates. 	
Steady green 	The USB-1208LS is connected to a computer or external USB hub. 	
Blinks continuously 	Data is being transferred. 	
Blinks three times 	Initial communication is established between the USB-1208LS and the computer. 	
Blinks at a slow rate 	The analog input is configured for external trigger. The LED stops blinking and illuminates steady green when the trigger is received. 	

  Screw terminal wiring 
The USB-1208LS has two rows of screw terminals; one row on the top edge of the housing, and one row on the bottom edge.  Each row has 20 connections.  Pin numbers are identified below: 

  Screw terminals, pins 1-20 
The screw terminals on the top edge of the USB-1208LS (pins 1 to 20) provide the following connections: 
	! Eight analog input connections (CH0 IN to CH7 IN) 
	! Two analog output connections (D/A OUT 0 to D/A OUT 1) 
	! One external trigger source (TRIG_IN) 
	! One external event counter connection (CTR) 
	! Seven GND connections (GND) 
	! One calibration terminal (CAL) 

  Screw terminals, pins 21-40 
The screw terminals on the bottom edge of the (pins 21 to 40) provide the following connections: 
	! 16 digital I/O connections (PortA0 to Port A7, and Port B0 to Port B7) 
	! One power connection (PC+5 V) 
	! Three ground connections (GND) 

The diagram below illustrates the screw terminal definition.  The diagram on the left is used for differential analog input while the diagram on the right is used for single-ended analog input.

  Connecting the USB-1208LS to Your System

To connect the USB-1208LS to your system, turn your computer on, and connect the USB cable to a USB port on your computer or to an external USB hub that is connected to your computer.  The USB cable provides power and communication to the USB-1208LS. 
When you connect the USB-1208LS for the first time, a Found New Hardware popup balloon (Windows XP) or dialog (other Windows versions) opens as the USB-1208LS is detected by your computer. 
Another Found New Hardware balloon or dialog opens after the first closes that identifies the USB-1208LS as a USB Human Interface Device. 
When this balloon or dialog closes, the installation is complete.  The LED on the USB-1208LS should flash and then remain lit.  This indicates that communication is established between the USB-1208LS and your computer. 
	Caution! Do not disconnect any device from the USB bus while the computer is communicating with the USB-1208LS, or you may lose data and/or your ability to communicate with the USB-1208LS. 

  If the LED turns off 
If the LED is illuminated but then turns off, the computer has lost communication with the USB-1208LS.  To restore communication, disconnect the USB cable from the computer, and then reconnect it.  This should restore communication, and the LED should turn back on. 

  Launching InstaCalc Software

1.	When the US B-1208 module is connected to a USB port on your computer, Windows will ID the device and record it.
2.	Launch the InstaCalc software by double clicking on the InstaCalc icon.
3.	When the program is running, you will get a message that InstaCalc has located the USB-1208 module.  Select the USB-1208 module and press OK.  
4.	Select the Configuration icon on the InstaCalc top menu.  A dialog box will open IDing the DAQ module, the module serial number, and allowing you to select either 4-channel differential input or 8-channel single ended operation.  Select the 8-channel option. 
5.	Click on the Flash LED dialog box and watch the LED on the 1208 module.  Be sure it flashes indicating proper configuration and communications.

  Launching the TracerDAQ Software

1.	Launch the TracerDAQ software by double clicking on the TracerDAQ icon.
2.	Click on the Strip Chart recorder option to highlight.  Then click on RUN.
3.	When the strip chart launches, select the EDIT menu.  On the EDIT menu, select CHANNEL SETTING.  For Number of Channels, select 1.  For units, select V.  For LANE, select 0.  Click on OK.
4.	Select the EDIT menu.  On the EDIT menu, select DISPLAY SETTING.  For NUMBER of LANES, select 1.  For UPPER LIMITS, select +10.0.  For LOWER LIMIT, select -10.0.  Click on OK.
5.	Select the EDIT menu.  On the EDIT menu, select DAQ DEVICES.  For DAQ DEVICES, select USB-1208.  Click on OK.
6.	To run the Strip Chart, there are three small rectangular buttons at the upper left of the Strip Chart screen.  The button with the arrow icon STARTS the Strip Chart recorder.  The button with the two vertical line icon PAUSES the Strip Chart recorder.  The button with the square icon STOPS the Strip Chart recorder.

  Analog Input Testing

1.	Connect a 4” length of wire to the following screw terminals on the USB-1208 modules:

	Terminal 1--Ai0
	Terminal 30--+5 volts
	Terminal 29--Ground

2.	Following the schematic shown below, connect a 10k pot to the three wires attached to the USB-1208 module screw terminals.

3.	Set the pot at the 50% position so that about 2.50 volts will be applied to Pin 1 of the USB-1208 module.
4.	Start the Strip Chart recorder by clicking on the arrow iron.  You should get a display at the 2.5 volt graticule line.
5.	Vary the shaft of the pot from 0% to 100%.  The display graph should trace from 0 volts to 5 volts.  Test this in both directions.
6.	If you are satisfied that the Analog Input is working properly, remove the pot and the wire from Pin 30.  Also, click on the STOP icon of the Strip Chart recorder.

  Acquiring and Displaying an Analog Input Signal.  

1.	Power up the analog thermometer that you constructed and tested in the thermocouple lab.
2.	Connect pin 8, the output, of the thermometer circuit to pin 1 of the USB-1208 module.  Connect the ground of the thermometer circuit to Pin 29 of the USB-1208 module.
3.	Allow the hot junction of the TC to sit in open air and reach room temperature.
4.	Select the EDIT menu and then select DISPLAY SETTING.  Adjust the voltage limits for the strip chart to +1 volt and -1 volt.  Then click on OK. 
5.	Click on the START icon so that the Strip Chart recorder will begin to plot the temperature data.
6.	If the system is working properly, you should see a waveform begin to trace out at about .24 volts or 240 millivolts.  Assuming that room temperature is 24° C., then the AD595 produces 10 mV./°C., or 240 millivolts.
7.	Grab the hot junction of the TC and watch the plotted trace increase to match the temperature of your hand.
8.	Dip the hot junction into a cup of ice slush and watch the plotted trace decrease to almost zero.
9.	Dip the hot junction into a pot of boiling water and watch the plotted trace increase to almost 990 millivolts, maybe even 1000 millivolts.
10.	Be sure to review this measurement and display process several times as your understanding of and your proficiency doing these measurements will be part of the evaluation process. 
Deliverable(s)
In this lab, you will be required to demonstrate the ability to connect the DAQ hardware module to the computer, launching the configuration software and adding the hardware to the configuration list, connecting a dynamic analog signal to an input channel on the DAQ hardware module, and launch, configure, and operate the strip chart recorder display system.  This demonstration is to be done professionally, properly, and with an eye to safety.  You will be required to demonstrate you data acquisition skills to your instructor as if you were doing a presentation at a staff meeting.  Charts and handouts are encouraged for clarity.  

Model Deliverable Example(s)
Using your skills learned in public speaking, you will be graded on technical accuracy and presentation skills.  Clarity, accuracy, and professional conduct are essential elements of the grading process.
Grading 
Your instructor will let you know how this lab will be graded.