The goal of this practicum is to use an oscilloscope and other related tools to visualize the time response of a temperature sensor, which has first order transient behavior. Please watch this oscilloscope video tutorial.
This behavior is encapsulated in certain variables of the equation, which depend on the SYSTEM parameters (i.e. time constant for first order systems) rather than the input, as noted in tutorial. You will extract one such parameter for a first order equation, the time constant.
Use of oscilloscope probes and manipulation of the oscilloscope trigger, vertical and horizontal scale, acquisition mode, cursors and data export options.
Use of the function generator.
Extracting circuit pinouts and critical design information from simple datasheets.
Acquisition and extraction of parameters from first order transients.
8 .CSV files
Output Voltage / Temperature Curve
Turn in Submission Sheet (found on Canvas)
1 x MCP9701 solid state thermistor
Thermometer
Hot water from dispenser by sink
Ice water
Room temperature water
Mineral oil
Oscilloscopes are electronic test devices that give you the ability to observe time-varying voltages and are very helpful in debugging and analyzing circuits. Figure 4.1 shows you an example of the digital oscilloscope that you will use.
Figure 4.1: Agilent DSO-X 2024A storage oscilloscope.
Whenever you want to measure a signal, you can use an oscilloscope probe to view the signal on the oscilloscope. This probe should be located in the top drawer of your work bench, seen in Figure 4.2. It is not just a cable like the one you used last week, it is a tool designed specifically for measuring signals.
Note: Oscilloscope probes are expensive. Please handle them with care, especially the retractable hook tip. Do not wrap wire around the hook tip.
Figure 4.2: Image of a common oscilloscope probe.
One end of the oscilloscope probe terminates into a male BNC connector; this end gets plugged into the oscilloscope. The other end is where the probe (retractable hook) and ground clip are located. Recall that all voltages are measured relative to some common ground. In order to measure meaningful voltages in your circuit with the probe, the ground clip must be connected to your circuit’s ground.
Turn on the oscilloscope (the power button is located on the bottom left of the oscilloscope) and connect the probe to input channel 1 on the oscilloscope, as shown in Figure 4.3. Be careful that you do not accidentally connect it to Gen. Out. Gen. Out is used as an output for the waveform generator function of the oscilloscope, not for measuring signals. The probe should only ever be connected to one of the four input channels.
At this point, you should still see nothing interesting on the oscilloscope’s monitor. Conveniently, the Agilent DSO-x 2024A oscilloscope has “demonstration” probes right next to the input pin that can be used as a means of testing your equipment.
Figure 4.3: Oscilloscope probe connected to the first input. Display the signal from the input pin by making sure the number above it is illuminated.
Connect the black ground clip to the ground terminal, which is the horizontal metal bar between Demo 1 and Demo 2, as seen in Figure 4.4. Then use the hook to grab onto the Demo 2 terminal, seen in Figure 4.4. Demo 2 is used as a demonstration terminal, and it is continuously outputting a square voltage waveform.
Figure 4.4: Ground clip connected to Demo ground terminal and probe hook connected to Demo 2 terminal.
Press the Auto Scale button highlighted in Figure 4.5. This will automatically adjust the vertical and horizontal settings on your oscilloscope to focus on the signal. Your monitor should look similar to Figure 4.6; if not, consult with an instructor or proctor for some assistance.
Note: This should be the only time you use Auto Scale, because without a clear, periodic signal, it can lock onto other misleading signals. More importantly, you will achieve the best understanding of the signal you’re measuring by zooming in on it by yourself rather than having the scope guess what is important.
In addition to displaying the signal’s voltage as a function of time, you can also measure the magnitude of the voltage. Located close to the top left corner of the screen is a number that indicates the current volts per division. In Figure 4.6, the auto scale automatically set the volts/div to 500 mV/ . This means that the difference between every horizontal line represents 500 mV. Similarly, the time/div should be set to 200µs/, which means the division between each vertical gridline is 200 µs. If your scale reads anything other than 500mV/ and 200µs/, then your probe may be misconfigured. Ask an instructor or proctor to fix this before moving on.
Try to estimate the peak-to-peak amplitude and period of the square wave! For the amplitude, count the height (number of grid divisions) of the entire square wave and multiply the result by the volts per division. For the period, count the number of grid divisions of one cycle of the square wave and multiply the result by the time per division. If the trace on the oscilloscope is noisy – it appears fuzzy and has some width – do your best to measure from the middle of the trace. If you can’t see grid lines, ask for help setting display intensity.
Figure 4.5: Auto scale button.
Figure 4.6: Auto scaled Demo 2 signal with volts per division and time per division.
To manually adjust the vertical scaling, you will need to use the vertical scale adjustment knob, as shown in Figure 4.7. The vertical scale adjustment knob (the knob above the number button) changes the volts per division of the display, thus scaling the height of the waveform on the screen. Each channel has its own vertical adjustment knob, giving you the ability to scale and fit multiple inputs into the same window. The vertical offset knob (the knob below the number button) changes the location of the ground cursor on the screen, thus moving the waveform up and down.
Vary the vertical scale of Channel 1 by turning the knob, and observe how the vertical scaling of the square wave changes. Also note how the volts/div in the upper left corner is affected. Turning the knob one way should increase the volts/div, making the waveform appear smaller or shorter; and as expected, turning the knob the other way will decrease the volts/div, making the waveform appear larger or taller. Vary the vertical offset and observe how the position of the wave changes. Turning the knob one way should move the wave up, and turning the knob the other way should move the wave down.
Figure 4.7: Vertical scale adjustment knob (top) and vertical offset knob (bottom).
Next, locate the horizontal scaling knob on the oscilloscope, shown in Figure 4.8. The horizontal scaling knob adjusts the time per division which can be seen on the top of the screen, near the right. Since oscilloscopes capture time-varying voltages, adjusting the knob changes the amount of time that is captured and displayed. For higher frequency signals, you would want a shorter time/div. For lower frequency or slow signals (like what you might get from placing a temperature sensor in a hot water bath), you would want a longer time/div.
Figure 4.8: Horizontal scaling knob.
In addition to scaling the input to fit nicely in the display, most oscilloscopes give you the ability to measure voltages using controllable lines on the screen called cursors. Cursors represent an improvement over counting divisions to estimate amplitudes and times as you did earlier.
Press the button labeled Cursors located in the Measure section of the oscilloscope, shown in Figure 4.9. You should notice pairs of dashed horizontal and vertical lines appear on the screen. The two vertical lines indicate the x1 and x2 values, while the two horizontal lines indicate the y1 and y2 values.
To use the cursors to measure voltage, push the knob labeled Cursors seen in Figure 4.9. This will make a list of cursors appear. Select y2 by turning the cursor knob and then pushing the cursor knob again to select.
Turn the cursors knob to move the y2 cursor line. To the top of your signal waveform. Then push the knob again to get the list to appear and select y1, and put this cursor at the bottom of your waveform. Notice that numerical values for the cursor positions are in the bottom right corner of the screen. Have the other partner adjust the x1 and x2 values to measure one period of the signal.
Figure 4.9: Cursors button and knob.
There are two main indicators located on the left side of the oscilloscope screen: the ground indicator (Figure 4.10) and the trigger indicator (Figure 4.11).
The ground indicator shows where the measured voltage is equal to zero volts. Since you can shift the waveform up and down, this cursor might not always be centered on the screen.
The trigger indicator shows the location of the trigger cursor, which will be discussed in the following section.
Figure 4.10: Ground indicator.
Figure 4.11: Trigger indicator.
Press the Default Setup button shown in Figure 4.12 to reset the oscilloscope display to its default settings. Change the vertical scaling to 500mV/, change the horizontal scaling to 200µs/, and use the offset knob to move the signal to the middle of the screen. You might expect the display to look a lot like the display from the last section, but it should look fuzzy. It looks fuzzy because the square wave is a time-varying signal, so the display is changing faster than you can see. In order to learn something about a measured signal, it helps to observe each period of the signal stacked on top of each other rather than the real-time dynamic signal. Luckily, the oscilloscope has features that allow you to make the display static.
One way to see a static signal is to pause the acquisition. Press the green button labeled Run/Stop near the top right corner of the oscilloscope as shown in Figure 4.13. The button will turn red to signify that continuous acquisition has been paused. The image on the screen should freeze. Press the button again to resume the continuous acquisition mode.
Figure 4.12: Default Setup Button.
Figure 4.13: Run/Stop button.
Oscilloscopes have another key feature that make them valuable in analyzing periodic signals: triggering. Most digital oscilloscopes have the ability to “lock on” to a periodic signal.
As seen in Figure 4.11, the trigger indicator shows where the horizontal trigger line is located. The oscilloscope will attempt to automatically capture any time-varying signals that periodically cross this horizontal line.
To see the what an untriggered signal looks like, locate the Trigger adjustment knob in the Trigger section of the controls panel. The location of the knob is shown in Figure 4.14. Turn the knob until the horizontal trigger cursor is above or below the square wave. You should then see a moving, untriggered signal.
Move the trigger cursor to the center of the signal by turning the knob, or click on it to reset its position. The trigger can lock on to a periodic signal when it is inside the signal, that is, when it is somewhere between the maximum and minimum values of the periodic signal.
Figure 4.14: Horizontal trigger adjustment knob.
In addition to observing the time-varying signal (continuous acquisition), many digital oscilloscopes give you the ability to take screenshots which will be helpful for your submission sheet! Taking a screenshot entails freezing the screen then saving that screen, and is fairly simple on the Agilent oscilloscopes.
Save your current screen by inserting the USB drive and pressing the Save/Recall button located in the File section of the oscilloscope controls panel, shown in Figure 4.15. Then, press the Save softkey.
Press the Format softkey and use the Entry knob seen in Figure 4.15 to select the CSV data (.csv) file format. The .csv file format can be opened in many different types of programs, including Excel.
If you would like to save the waveform in a specific directory within your USB device, use the second (Save to) softkey to navigate to the desired directory. The scope saves waveforms in the main directory, by default. Saving in the main directory is fine practice unless you have many, many files.
To finally save to the directory, press the Press to Save softkey on the right. You should receive a message confirming your file has been saved after a quick loading bar.
(Answer Question 1. You can either save a CSV and plot your data or save your acquisition as a PNG)
Figure 4.15: Save/Recall button (white) and Entry knob (green).
Oscilloscopes and function generators are traditionally two separate pieces, but the Agilent oscilloscopes in our lab have a built-in function generator. Function generators (also called waveform generators) can produce a wide array of signals (sine, saw tooth, square, etc.) with varying amplitudes and frequencies. They are useful in testing circuitry that relies on periodic inputs. We will use a different set of cables to test the function generator.
Attach a BNC-to-hook cable, which can be found in the metal tool box at your station, to the terminal labeled Gen Out, and connect the hooks to short, stripped wires so that they are not damaged when connecting the scope probe. Attach the scope probe to the wires connected to the BNC hooks, as shown in Figure 4.16. Do not attach hooks directly to hooks.
Note: Never use oscilloscope probes to carry output signals. For you this means that you should never connect them to the Gen Out terminal.
Figure 4.16: Scope probes connected to function generator output.
To turn on the function generator, press the Wave Gen button in the Tools section of the oscilloscope shown in Figure 4.17. Then, press the button corresponding to the Waveform option on the scope’s display and choose the Sine option. Set the Frequency to 1.000kHz, Amplitude to 1.0Vpp, and Offset to 0V. You might immediately see an output on the scope display. If not, adjust the horizontal and vertical settings until the signal is clear. Move the trigger cursor to the middle of the signal to lock onto the periodic signal.
Take a moment to answer question 2 on your submission sheet: record the time at which you finished this section.
Figure 4.17 Wave Gen button. The button will turn blue when there is a wave being generated, even if the menu is not on the screen.
Recall from the second practicum you used a MyDAQ to read temperature data from a linear temperature sensor (MCP9701). In this section of the practicum, you will use the data sheet to help you identify the role of each wire on the temperature sensor. You will be using the sensor to collect temperature data and eventually experimentally determine the time constant of the sensor.
Almost all electronic sensors or devices have a corresponding data sheet written by the manufacturer of the component.
A data sheet has multiple functions:
Explains how the electronic component is used,
Sometimes provides circuit suggestions for optimal performance,
Lists the maximum/minimum operating conditions, and
Describes the characteristics of the device or sensor.
The MCP9701 data sheet has a very thorough description of the sensor’s features and performance. This data sheet actually describes three different sensor package types, two of which are surface mount components (you will be using the 3-pin TO-92).
Take a few minutes to skim the data sheet and understand its structure; pay close attention to pages 1 and 4. Identify and record the following information from the data sheet listed on the submission sheet, question 3 (be sure both partners understand how to find the information) .
Maximum operating temperature
Minimum operating temperature
Purpose of the left lead when looking at the flat face
Operating voltage range of the sensor
Sensor's time constant
Data sheets are one of the very first places to refer to when encountering new electrical components.
In a later section of the lab, you will experimentally determine the time constant of this temperature sensor. You will use the value you obtained from the data sheet to verify the results from the experiment in the next section. Do note that the data sheet time constant was calculated from an air-to-fluid-bath step response.
First you need to set up your sensor by connecting it to a power supply. You will use a breadboard and power supply wires to do this. Connect a banana plug-female BNC adapter to the 6V output of your supply (remember that the tab goes into COM, it must be on the right). Attach a BNC cable to the adapter and attach a BNC-hooks connector on the end of the BNC cable seen in Figure 5.1. Make sure the power supply is off when manipulating your circuit.
Figure 5.1: Power supply connection through adapters to hooks.
Strip short red and black wires and place them into the power and ground rails (+ and – columns) of your board seen in Figure 5.2. Connect your BNC-hooks connectors to the appropriate columns. Connect one more short, stripped wire to the ground column and leave the other end disconnected for now, we’ll attach the ground clip of your oscilloscope probe to it later.
Figure 5.2: Power wires in breadboard.
Strip the ends of your temperature sensor wires if they are not already stripped. Place the red wire into the power column, the black wire into the ground column, and leave the output wire disconnected see in Figure 5.3. Do not get the red and black wires backwards, you will destroy your temperature sensor if you do.
Figure 5.3: Temperature sensor attached to breadboard.
Connect your oscilloscope probe’s ground clip to the short wire in your ground rail. Connect your oscilloscope probe to the temperature sensor signal wire that is not yet connected seen in Figure 5.4. You may add a capacitor between your signal wire and ground if you observe high levels of noise on your signal.
Figure 5.4: Complete sensor setup.
Turn the +6V power supply knob all the way counterclockwise to zero (double check that your supply cable is connected to the 6V supply). Turn on the supply and then ramp the supply voltage to 5V.
Change the horizontal scale of the oscilloscope to 2 second/div. This will give you enough time to capture the step response on the oscilloscope screen.
In the next section of the practicum, you will use four different fluid baths: (1) a cold water bath at approximately 0°C, (2) a water bath at room temperature, (3) a hot water bath above 80°C, and (4) an oil bath at room temperature. The room temperature oil beaker should be at your station already. Fill the other beaker at least halfway with water from the sink. Fill one of the thermos cups at least halfway with hot water from the dispenser near the sink in the room with the robot storage cabinets and the other with ice water from the cooler there.
Make sure that the oscilloscope is wired correctly by inserting the temperature sensor into the hot or cold bath. You should see the sensor voltage change and then settle to a final value within a few seconds. If not, check in with a proctor or instructor.
Verify your oscilloscope setup and settings with a proctor or instructor before moving to the next section of the practicum.
In this section you are going to perform a series of measurements examining the time response of a temperature sensor to various inputs. You can treat the temperature sensor as a linear system with a temperature input and a voltage output.
Don't forget add your answers to the questions you find in your practicum manual to your submission sheet for the day! (Question 4)
As you may expect, sensors are not perfect. Although they are designed to accurately measure a specific physical quantity, there is often a small lag due to sudden changes in measurement. Sensors are systems, the physical world is the input, and the sensor output is the response. Like the temperature sensor you are using in this practicum, most sensors have a first-order response to sudden changes in input. First-order step-input responses for sensors are characterized by exponential growths/decays of the form in Equation 6.1.
Given a step input, the time constant describes the amount of time it takes the sensor response to travel 63% of the way from the initial to the final value. You will now conduct an experiment to determine the time constant of the MCP9701 temperature sensor.
Equation 6.1 First-order step response.
Vout(t) is the voltage at some time, t
Vf is the final, steady state voltage
Vi is the initial voltage
𝜏 is the time constant
Read the rest of section 6 before beginning it – there is useful advice towards the end.
Use a thermometer to measure the temperature of each of the baths. Record the values for each, for example on Excel, as they will be used to create a calibration curve. Use the cursors on the oscilloscope to obtain voltage values. Be aware that the hot water bath will be cooling down as you conduct the experiment, so make sure you record the temperature at the same time you run a trial and collect data with the oscilloscope.
Place the temperature sensor in each of the baths to get a voltage reading for calibration. Record these in conjunction with the temperatures from the thermometer.
You will collect and save the transient responses from step changes in the sensor’s temperature. For the submission sheet (Question 5) you will collect a single example screenshot, but you will need the .csv files from every trial in order to determine the time constant. Generate the step changes by moving the sensor from one bath (or the air) into another. Four step responses that you need to generate and capture are listed in Table 6.1. Once you generate these four step responses, reverse the order to get another four step responses (e.g. hot water to oil and oil to hot water are two separate step inputs).
When a sensor is inserted into a bath, stir the bath gently with the sensor after insertion.
Table 6.1: List of step inputs to be applied to temperature sensor. Once you generate these four step responses, reverse the order to get another four step responses (e.g. hot water to oil and oil to hot water are two separate step inputs).
Make sure that the temperature sensor has settled to the ambient temperature of its environment before moving it to a new bath. Wait for the oscilloscope to restart collecting data on the left side of the screen before moving the temperature sensor to its destination (see tip below).
After moving the sensor, hold it in place (or gently stir) until it reaches a steady state value. Have your partner then press the Run/Stop button to stop collecting more data. The result should be very similar to Figure 6.1. Be sure you capture the initial and steady state value for each case.
Note: Be aware that some of these trials will have long time constants, especially those that move to air. Adjust your time/div accordingly.
Note: Return the oil beaker to the center table. DO NOT POUR OUT!
Be sure the traces you are recording are long enough to include the initial and final steady state values!
Figure 6.1: Example of a first order transient on an oscilloscope.
Note that if you have too large a time/division then the oscilloscope won’t start recording data until after the delay marker (orange mark on the top of the plot). If that is the case, then adjust the delay to capture more data. Move it close to the left edge of the screen using the knob indicated in Figure 6.2. Also note that when you save your data using the Save/Recall feature, only the data that is currently displayed on the screen will be saved. Since adjusting your horizontal or vertical scale restarts signal acquisition, try to get your scales set up properly before acquiring a signal. Try to make your waveform fill the screen.
From here, you can save the resulting waveform to your USB stick. Upload your USB data to a location that you can access for your homework. Make sure that your file naming conventions indicate which baths you used and include your names.
Figure 6.2: Knob for adjusting horizontal delay.
You need only one screenshot (either from the scope or of your Excel plot) to put as an example on the submission sheet (#4).
BUT, you need to save all eight .CSV files to use to fill out the submission sheet and for homework. Make sure they're in a place accessible to you and your partner after practicum! (Email, Drive, etc.)
Now that you have collected all your data in lab, it is time to begin data processing. More specifically, you will be finding a calibration curve relating temperature and voltage of your sensor. In Section 6, you should have recorded the temperatures of each bath, as well as the corresponding voltage output from the sensor.
Plot the output voltage versus the recorded temperature from the thermometer. Make sure to include this plot in your submission sheet (question 6).
6)Using Excel (or any other capable software) fit a linear function to the results.
To complete the practicum please
· Return all tools that came from the grey box to the grey box. Check to make sure all the materials shown on the inside of the lid of the grey metal toolbox are accounted for. If anything is missing let a proctor or an instructor know (Question 9 on submission sheet)
· Return the oscilloscope probe to the top drawer of your station. Confirm that your partner knows that an oscilloscope probe is only used to measure signals (on one of the four numbered channels) and never as a cable to deliver a signal from Gen Out or elsewhere.
· Hang all cables neatly on the rack on the side of your station.
· Be sure the power supply and oscilloscope are off.
· Return any tools or supplies that came from the central table to the central table.
· Leave the oil beaker (filled) at your station.
· If your cold water bath is still icy, pour it back into the cooler. Otherwise pour it out into the sink.
· Pour out the room temperature and hot water baths into the sink.
· Clean up scrap wire and any other debris from your station.
1. Extract the time constants from each of your transient responses.
2. How many time constants do you expect to find among your curves? Does your data support this?
Does the size of the temperature step affect the time constant you observe?
What controls the time constant of a thermal system?
1. Temperature Sensor Datasheet: https://drive.google.com/file/d/0B7Ols9Km9Pa1TWZacFEwZVZGNnM/view?usp=sharing
2. Oscilloscope user manual: https://drive.google.com/a/g.hmc.edu/file/d/0B5CbydLeATOMenY0Tm9CdWpVdkU/view?usp=sharing
3. Full Parts List (below):
Tools Per Station
Power supply
Thermometer
Soldering iron
Solder sponge
Oscilloscope
Function generator (built into oscilloscope)
Oscilloscope probe
3 x H20 bath
1 x oil bath
USB drive
Materials Centrally Available
1 x MCP9701 solid state thermistor
Hot water
Ice water
Water spray bottle for solder sponge
Roll of solder
Computer (or use your own)