Introduction to Digital Data Acquisition Increasingly, experimental data is acquired digitally. This means that the measured quantity, whatever it may be, is transformed into a number stored in digital form. Almost always, before being converted to a digital signal, the measured quantity must be converted to an analog signal, usually a voltage. An analog signal is one that, at least in principle, can take on any value whatsoever and can vary continuously with time. In contrast, digital representations of analog signals, as we shall see, can take on only certain discrete values and are not continuous functions of time. Usually, we measure experimental quantities with the aid of transducers. A transducer is a device that converts the quantity of interest, be it pressure, displacement, strain, temperature, or whatever, into an electrical voltage. Frequently, although not always, the output of the transducer will be linear in the quantity of interest, at least over a certain range. Suppose, to fix ideas, that we wish to measure the linear displacement x of an actuator in millimeters. Then, if the output of the transducer v, expressed in millivolts, is linear in x, we then have v kx , 9 8 7 Q 6 5 4 3 2 1 0 1 2 3 4 5 6 time (sec) Figure 1 - Analog signal 9 8 7 6 Q assuming that the transducer has been calibrated so that v = 0 when x = 0 (If not, then we would simply write v = kx + b). Here k is the constant of proportionality, having units of millivolts/millimeter. The constant k is known as the sensitivity of the transducer. If x varies with time, the voltage output v will likewise vary with time according to the equation above. v(t) represents the analog signal which we wish to convert to digital form. In order to convert the analog signal to digital form, we will sample the analog signal at fixed intervals of time. This simply means that we will take the value of the analog signal at certain times and convert this value to digital form. The effect of this is to take the continuous analog signal and replace it with a discrete digital representation, for which we know the value of the signal only at certain instants of time (the values of time at which we have sampled the analog signal). If we sample the signal sufficiently often, of course, and if the analog signal does not change too rapidly between sampling points, it is easy to estimate the value of the signal at a time other than the sampling times by simple interpolation. The rate at which we sample the signal is known as the sampling rate (usually expressed as number of samples/sec, or hertz). Sampling rates on the order of 1000 Hz (1 kHz) can be achieved in practice. Obviously, the higher the sampling rate, the more accurate our representation of the analog signal will be. The figures at right show an analog signal and its digital representation, 5 4 3 2 1 0 1 2 3 4 5 time (sec) Figure 2 - Digital representation 6 sampled at 0.5 sec intervals. Conversion of the analog signal to digital form is done by a device known as an analogto-digital converter (A/D converter). We do not want to go into detail as to how this is accomplished. In practice, the typical A/D converter is simply an integrated circuit (IC) board which takes one or more analog voltages which one wishes to place in digital form and outputs their digital representations into one of the ports of a personal computer (PC). However one of the aspects of the operation of the A/D converter is of importance to the experimenter. This is the number of bits used by the A/D converter. For the sake of illustration, suppose that we wish to sample an analog signal which varies between 0 and 100 mV, but that our A/D converter has but a single bit. This means that any analog signal can be only represented as a 0 or as a 1. Thus any signal between 0 and 50 mV would be represented by a 0 and any signal between 50 and 100 mV would be represented by a 1. Obviously, this converter can only distinguish between two signal values if they are greater than 50 mV apart. Thus we say that the resolution of the converter is 50 mV. Now suppose that we have a two-bit A/D converter. Then our signal can be represented by one of four digital combinations: (0 0), (0 1), (1 0), and (1 1). In this case, (0 0) would represent signals between 1 and 25 mV, (0 1) signals between 25 and 50 mV, and so on. In this case, the converter would have a resolution of 25 mV. If we continue this process, it is not difficult to see that, for a converter having N bits, the resolution of the converter is given by Resolution V 2N where V is the range of voltages over which the signal varies. At present, 16-bit A/D converters are in widespread use, although it is not uncommon to encounter older, 8-bit devices. As might be expected, the use of 16-bit converters results in a dramatic improvement in resolution. For the example just discussed, with a signal varying over a range of 100 mv, we have Resolution 100 . x10 3 mV 16 152 2 The Experiment We want to use a digital data acquisition system (the LabVIEW package) in conjunction with a standard 16-bit A/D converter to determine the sensitivity of the LVDT (the slope of the linear portion of the output voltage vs. displacement curve). We will then use this information to measure the deflection at the tip of several cantilever beams. The LVDT is a device that measures linear displacement.. There exist somewhat similar devices that measure angular rotation. The LVDT operates by sensing the difference in voltage induced in two adjacent coils by a moving inner rod. Its operation is described in somewhat more detail on the attached sheet. Unfortunately the output of the LVDT cannot be used in raw form; it must first be passed through a signal conditioner in order to be converted to usable form. The output of the signal conditioner is then fed directly into the A/D converter. Over a certain range, the output of voltage most transducers such as the LVDT is linear, that is, the output voltage at the signal conditioner is a linear function of the displacement of the LVDT core. Over the displacement entire range of motion of the LVDT, however, the behavior of the device usually k departs somewhat from linearity, and might look somewhat like the sketch at right. For linear the LVDT that we will be using, however, the range departure from linearity is so slight that the LVDT is effectively usable over its entire range. The goal of the first part of this experiment is to calibrate the LVDT. In this instance, calibration simply means determining the slope of the linear portion of the voltage vs. displacement curve. Denote this number by k. Then, if we wish to use the LVDT to determine linear displacement, we have simply that displacement = voltage / k, where voltage is the change in voltage induced by the motion of the LVDT core. In practice, we have to be a little careful here, however. The slope k depends upon the voltage supplied by the power supply to the LVDT. As long as this remains constant, k will remain constant as well. However if the input voltage level is changed, k will change, and the LVDT must be recalibrated. The LVDT is initially clamped in a fixture in series with a micrometer head, so that the position of the LVDT core may be precisely adjusted by moving the micrometer head. The micrometer has a range of 25 mm, and may be adjusted to within 0.01 mm. From the computer, start the LabVIEW program. Open the FILE menu and, under the ME 21 subdirectory, open the LVDT Calibration file, and then the program DAQ_lvdt. There are only two keyboard inputs: first, the number of data points to be taken, and second, for each data point, the value of the micrometer reading. The voltage reading corresponding to a particular LVDT core position is read by clicking on the large button icon at the left center. Clicking on the button icon tells the computer to read and store the voltage output of the LVDT. After the specified number of (micrometer reading, voltage) points are taken, the computer does a linear, least-squares fit through the data, and displays the results graphically in the window which occupies most of the display. The points plotted in the window are the input points, while the straight line is the result of the least-squares fit. Also calculated, and displayed in a small window at center bottom, is the slope of the fit, which is the calibration factor k that we want. We calibrate the LVDT by taking five data points. Make sure that is the number of data points to be taken which appears on the program display. Adjust the micrometer head so that the LVDT is almost fully compressed, and then back the head off several millimeters. To start program execution, click on the icon at the extreme upper left of the screen. Input the initial value of micrometer reading, and take a data point (voltage reading) by clicking on the button on the program display. Then back the micrometer head off by 2-3 millimeters, and repeat the procedure until you have taken a total of 5 data points. The program will then do a linear leastsquares fit to the data, and output the slope of the displacement vs. voltage curve at the bottom of the display. Record this value on your data sheet. Now we want to use the LVDT with the measured sensitivity (slope) value to measure the deflection at the tip of several cantilever beams that are loaded at their ends by a known force, and from this data to obtain the stiffness of the beams. As long as we do not exceed the yield stress anywhere in the beam, the beam will obey Hooke’s law. This implies that we can expect a linear relation of the form F k between the load F applied at the end of the beam and the tip deflection . The constant k, which plays the role of the spring constant in Hooke’s law, is known here as the stiffness. It is this constant that we want to measure. Later in Mech 12, you will learn how to calculate this calculate from the properties of the beam. Our beams will consist of thin-walled tubes of length L, mean radius r, and wall thickness t. From Mech 12, the relation between force and deflection is given by P 3Er 3t L3 where E is Young’s modulus. Right away, the stiffness k is seen to be k 3Er 3t L3 Note that k increases linearly with Young’s modulus E and as the cube of the mean radius r. We will measure k for three different beams: two which are approximately 1 in. in diameter, one of steel and the other of aluminum, and a third which is approximately 1 ¼ in. in diameter and is fabricated from aluminum. For each of these three beams, measure or calculate the wall thickness and the mean radius with a set of calipers. Also measure the length L of the beam from the support to the point of load application. Record these values on your data sheet. Remove the LVDT from the calibration fixture, and place it in the instrument holder, so that the tip of the LVDT rests in the compressed position on top of the beam at the point of load application. Now open the Beam_Deflection folder in LabVIEW and start the program DAQ_disp. Click on the icon to begin data acquisition. Enter “0” in the load window, and then take a data point with no load on the beam. Then load the beam in one pound increments, taking a data point at each load level (don’t forget to include the weight of the load pan). Do this up to a load level of 4 pounds. LabVIEW will then carry out a linear, least-squares fit to the data. The slope of this fit is the stiffness k, which will appear on the program display. Record this value for each of the three beams tested. For the two aluminum beams of different radii, the stiffnesses should be in the ratio k1 r13 k2 r23 where ( )1 refers to the smaller diameter aluminum beam and ( ) to the larger. Calculate the experimental value of the ratio k1/k2 and compare it to the ratio r13 / r23 . Record both values. How do the values agree. How might you explain any discrepancies? Likewise, for the steel and aluminum beams of equal diameter, the ratio of stiffnesses should be in the ratio ks E s kal Eal where Es is the Young’s modulus for steel and Eal is that for aluminum. A typical value of this E ratio is s 3 . Calculate and record the ratio ks / kal and compare it to the ratio of Young’s Eal moduli. How do you account for any discrepancies?