PHY 225H

EXERCISE 5

Lightbulb Demonstration of Computer-Controlled Data Taking

Objectives

To demonstrate the use of computer-controlled experimentation to measure, calculate and display data in near real-time. To learn something about why light-bulbs break!

Background

Very complicated things happen when you turn a light-bulb on. Within a very short period of time the temperature of the filament heats up through about 1000K. Since the resistance of the tungsten alloy which makes up the filament of the light-bulb is a function of its temperature, the electrical system undergoes some high-speed changes as well. Our eyes, being quite slow devices, do not register any of these changes, but by using faster electronic measuring systems we can measure these changes and store them for later perusal.

Since a light-bulb is simply a resistor as part of an electrical circuit, Ohm 's law applies and we can write I = V/R, where V is the voltage across the filament, R is the filament resistance and I is the current through the filament. We can write the power dissipated in the filament as VI = V2/R. Now when the filament is cold, R is small. All metals have a positive temperature coefficient of resistance, ie dR/dT > 0 and so if V is (roughly) constant, the current and the power dissipation will be relatively high at first and then decline as the temperature and resistance increase. This high initial current is known as the "in-rush current" and the sudden very high power dissipation when turned on is why light-bulbs almost invariably break when you turn them on, not when they are already running.

This effect only lasts a short period of time, so we need to make measurements very quickly. An

oscilloscope isn't really suitable, since the experiment isn't a repetitive one and we need something more sophisticated which can be supplied using a computer. You are going to use a program written in the LabView language which, together with the appropriate hardware, will enable you to make the measurements and record them.

Apparatus

The circuit is shown below. Two voltages are measured: The first, Vad0, is the total circuit voltage, the second, Vad1, is the voltage across the small sampling resistor, r. You can work out what arithmetic needs to be done to compute the resistance of the bulb. The LabView program makes these calculations to show you graphs of V, I and R vs time for the bulb alone.

The computer is also used to apply the voltage to the circuit. Any voltage between 0 and about 5 volts can be applied and you can choose the time profile using LabVIEW.

Setting Up

Since you will need a lot of current to run the bulb, you need a power supply with a lot of current capability. The HP3630A power supplies on the "+6V" scale with the voltage set to maximum are suitable, as is a 6V battery with banana plugs.

The connections to the computer are labeled by function: Analog-to-Digital (A/D) or Digital-to-Analog (D/A), direction: "In" is always into the computer, "Out" is always out from the computer (always connect "In" to "In" and "Out" to "Out"), and by channel starting from 0. The black box is the connection to the computer, the silver box is the one with your circuit in it. All the inputs measure in the range -5V to +5V and all the outputs produce voltages in the range -5V to +5V.

Experiment

The first thing to do is to run the experiment roughly to get an idea of what is going on. You are supplied with two different devices -the light-bulb which reacts as discussed above and a resistor which has a constant resistance (Note: When the boxes are stored, the resistor and the lightbulb are often "stacked" on top of one another, but you never use them that way!). To run the LabView program, start up the computer using your Faraday account and then start the LabView program (See notes at the end on starting the comp4ter and the LabView program).

The LabView program has four panels:

1)Upper left is a graph is what we think is the input voltage (vertical axis) as a function of time (horizontal axis). The horizontal axis is in "samples" which are taken at regular time intervals.

2)Upper right is a graph of what the input voltage actually is.

3)Lower left are the controls

4)Lower right is a graph which you are going to calibrate as the resistance of the light-bulb.

Use the plug-in 10 resistor and a ramp voltage. You should get a constant value of the resistance so long as the voltage is "reasonable" -what happens if it isn't reasonable, maybe even zero? [Note:

Sometimes the initial "value" of the resistance goes off the screen and you will need to change the graph scale to get it back on] Getting the actual value of the 10 resistor shown correctly on the graph depends upon knowing the exact value of the sampling resistor r. The value of r is an input to the LabVIEW program and you can adjust it until you get the program to show the right value for the 10 resistor. The nominal value of r is 0.22 but the default value in the program is different, and your value will, in all probability be higher than 0.22, why?

Now you can change to the bulb. Try the effect of changing the speed at which the bulb is turned on, the time it is on and the time it is off. You can control the number of samples taken and the rate at which they are taken and the overall cycle time of the experiment, so you have plenty of scope to choose from.

Measure the peak current and peak power dissipation as a function of the turn-on time.

You can change the form of the last graph by adjusting the LabView program. Stop the program and select windows>show diagram. You should see the wiring diagram of the program with a "formula box" which is currently set to give R = V/I. This is the box which determines the dependent variable (y-axis) of the third graph. Change it so that the result is the power output. To change it follow the instructions below. This changes the third graph to give bulb power instead of resistance. To go back to the "front panel" click on it or use windows>show panel.

What is the time constant for cooling of the bulb? How long before it is really cold and you can repeat the whole experiment "from cold"? [Hint: You can monitor the resistance of the bulb continuously by leaving a bit of voltage on the bulb at all times, but not enough to heat it up much].

In this circuit we can't actually apply a step voltage to the bulb and instantaneously change the voltage value at turn-on. What do you think would happen if we did? What would be the power dissipation and how does this compare to the running dissipation after infinite time? This is exactly what happens when we do turn on a light bulb. My friends in the theatre tell me that the lighting people often come in before the performance and "warm up" the stage lights -can you suggest any reasons why they might do that? Some new overhead projectors also turn their bulbs on slowly, although some even newer projectors use discharge bulbs rather than filament bulbs and these turn on slowly anyway.

Finally, let's go back to the resistor and the ramp. You will notice that at low voltages, the value of the resistor is "jagged" which is a function of the fact that data in a computer is "quantised", ie can only take a certain number of values. All the voltages that the computer measures are quantised to the same degree. The allowed values are equally spaced and separated by V. As the ramp voltage applied to the resistor gets larger the line representing the resistance value gets smoother. (You might want to enlarge the graph scale in order to see this better.) From a simple analysis of the errors, show that this is expected. From the data given, see if you can work out the value of V.

Things about the computer and the program

Before you start You need an UPSCALE username (usually begins with "x") and password. We are

assuming that you are familiar with the use of a keyboard and mouse.

Starting the computer You need to logon to the computer using the username "student" and the password "student". The computer may give you a number of messages about previous logons. You should answer with "cancel" or "yes" or "ok" as appropriate until you get a clean screen. Then double-click "network neighborhood" and then "faraday" at which point you should supply it with your UPSCALE username and password.

Starting the program The program is called "lightbulb" and is located on the "e" drive of Faraday which is called, with great originality, "e-drive", Double-click "e-drive" and then "Iightbulb".

Running the program When you have the LabVIEW program up and running, the Symbol at the top of the screen starts the program. Stop the program by pushing the "stop" button (you' d never have guessed that would you?).

Setting the voltage The control screen with the green background allows you to modify the voltage

profile. The scale is in "samples" and the sampling rate (samples/second) and the maximum number of samples is selectable below the graph. The voltage is set by four "cursors" which you can grab with the mouse and the left mouse button. There are various traps in the program so that you can't set insane values!!

On the main screen there are also cursors for each of the graphs which you can drag about to get the values from the graph. The x-value is the sample number, by comparing values at the same sample number you can make further calculations. The scale of any graph can also be set by dragging the left mouse button over the top or bottom of the scale and typing in a new number. In this way you can expand the scales to see things clearly.

Getting help LabVIEW has a built-in help system which you can activate from the menu or by typing CTRL-h. It only works if the programmer had the time/remembered/was sufficiently magnaminious to offer any help!

Changing values in the formula box. Stop the program running. Use

Windows>Show Tools Pallette to bring up the tools pallette and then select

"operate value" which is the "point finger" tool in the upper left-hand corner.

You select a tool by clicking on it. You should then be able to change the

formula in the formula box using simple word processing techniques.

The Dark(er) Side

For those of you who are interested, the LabVIEW program is written in a graphical fashion. If you look under windows>show diagram, you will see the graphical representation of the program. The overall box represents the outer loop of the program and the boxes with the dots at the top and bottom represent "sequences" of events that must happen in time order. Nesting of boxes implies a nesting of operations. The yellow triangle symbols are operators.

If you click on the small black triangle of the innermost sequence, you can work through the four items of the sequence which are:

  1. Subtract 1.5 from a number and output in on channel 0. This sets the voltage for the bulb for this time interval. In fact the regulator adds about 1.5 V to the voltage when it supplies it to the bulb and this is a way of nullifying this effect - a case of using software compensating for a less-than-ideal feature in the hardware. There are also two diodes in the circuit shown on the first page. These are there to stop the voltage going more than - 1.2V at that point which means that output is constrained to be >-0.3V. this is a case of hardware being used to ensure the safety of the circuit in the event of a software failure - I didn't want the output driven much negative because the regulator would then break and I don't entirely trust computers or their software!
  1. Divide 1000 by the number given and wait until the next time marker for that number of milliseconds.
  1. Read a voltage from channel 0
  1. Read a voltage from channel 1.

If there is time and you can find a demonstrator who knows LabVIEW, you can get a more comprehensive tour.