0% found this document useful (0 votes)
112 views37 pages

Biomedical and Instrumentation Lab File

The document provides an introduction to virtual instrumentation using LabVIEW. It discusses opening a new VI from a template to generate and display a signal. The front panel contains controls and indicators, while the block diagram contains the graphical source code. Express VIs can be used for common measurement tasks. The LabVIEW documentation contains information about programming concepts, instructions, and reference materials. Controls and indicators can be configured using property dialog boxes.

Uploaded by

shadan alam
Copyright
© Public Domain
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
112 views37 pages

Biomedical and Instrumentation Lab File

The document provides an introduction to virtual instrumentation using LabVIEW. It discusses opening a new VI from a template to generate and display a signal. The front panel contains controls and indicators, while the block diagram contains the graphical source code. Express VIs can be used for common measurement tasks. The LabVIEW documentation contains information about programming concepts, instructions, and reference materials. Controls and indicators can be configured using property dialog boxes.

Uploaded by

shadan alam
Copyright
© Public Domain
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 37

BIOMEDICAL AND

INSTRUMENTATION LAB FILE

SHADAN ALAM SHADAB (16/IEE/050)


EED. SOE. GAUTAM BUDDHA UNIVERSTIY  GR. NOIDA, UP.
1

Acknowledgement
I would like to express my special thanks of gratitude to my Biomedical and Instrumentation lab
faculty Mr. Amit Jain for their able guidance and support in completing my lab work.

I would like to also thanks to my classmates who support me in completing my work.

Date:
21/05/2020 Shadan Alam Shadab
(16/IEE/050)
2

Experiment list:

S.NO. EXPERIMENT NAME PAGE NO.


01. Familiarization with Data Acquisition system. 3-4
02. Familiarization with labVIEW and virtual 5-9
instrumentation
03 To measure temperature using thermocouple 10-12
04 To study & measurement of Blood pressure using 13-19
labVIEW
05 To study and Analysis of ECG signal using ECG sensor 20-24
and labVIEW.
06 To measure temperature using RTD 25-27
07 To study and measurement of Electromyogram (EMG) 28-31
08 To study and measurement of Air flow using Spirometer 32-34
and LabVIEW
09 To study of Heart Rate using Heart rate monitor and 34-37
LabVIEW.
3

EXPERIMENT NO: 01
Aim: Familiarization with Data Acquisition system.

Theory:
Data Acquisition VI in Labview
1. We can find the data acquisition VIs in the function palette from block diagram in LabVIEW.
2. When we put your cursor over each of the icons in the function palette, labVIEW displays the
palette name we are about to access at the top of the functions palette. We can find the DAQ
icons near the bottom of the functions palette.
3. The DAQ contains 6 subpalette icons in the DAQ palette measure.

 DAQ VI organization:
In most of the DAQ subpalettes, the VIs are arranged in different levels according to their
functionality.
We can find some of the following and levels of DAQ VIs within the DAQ 6 subpalettes.

 Easy Vis:
The easy VIs perform simple DAQ operations and are typically the first row of VIs in the DAQ
palettes.
We can run these VIs from the front panel or use them as sub VIs in basic alone in that we only
need one easy VI to perform each basic DAQ operation.
Easy VIs automatically alert us to error with a dialog box that asks us to stop the execution of the
VI or to ignore the error.

 Intermediate VIs:
The intermediate VIs have more hardware functionality and efficiency in developing your
application than the easy VIs.
It gives us more control over error-handling than the easy VIs with each VIs we can check for
error or pass cluster on to other VIs.
It contains group of advanced VIs, but they use fewer parameters and don't have some of the
more advanced capabilities.

 Utility VIs:
The utility VIs, found in many of the labVIEW DAQ palettes, and are also intermediate level
VIs and thus have more hardware functionality and in developing your application than the easy
VIs.

 Advanced VIs:
It is the lowest level interface to the DAQ driver. Very few applications require the use of
advanced VIs.
It is used when easy or intermediate VIs don't have the I/P(s) necessary to control an unusual
DAQ function. It return the greatest amount of status information from the DAQ driver.

 VI parameter conventions:
4

1. In each labVIEW DAQ VI front panel or help window, the appearance of the control
and indicator labels denote the importance of the parameter.
2. Control and indicators not necessary for our program to operate appear in plain text.
3. The default I/Ps appears in parenteres to the right of the parameter names.
4. As the window text for this VI indicates, we should wire the device, channels, error in
and iteration I/P parameter & the voltage data and error out of the cluster of the
current VI to the error in cluster of the next VI.

Result:
Hence, the labVIEW Data Acquisition basic have been studied and thus DAQ syatem are known.
5

EXPERIMENT NO. 02
Aim: Familiarization with labVIEW and virtual instrumentation.

Apparatus:
Computer with labVIEW software.

Theory:
Getting started with labVIEW virtual instrumentation:
LabVIEW programs are called virtual instrumentation or VIs, because their appearance and
operation initiate physically instruments, such as oscilloscope and multimeters.

In labVIEW, we build a user interface, or front panel, with controls and indicators.

Building a virtual Instrument:


In the following experiments, we will build a VI that generates a signal and display that signal in
a graph.

 Launching labVIEW:
The getting started window appearance when we launch labVIEW. Use this window to create
new project and open existing files. We also can access resources to expand the capability of
labVIEW and info to help us about labVIEW.

The Getting started window disappears when we open an existing file or create a new file and
reappears when we close all open front panels and block diagrams.
View>> Getting started window.

Opening a New VI from a template:


labVIEW provides built-in-template VIs that include the sub VIs, functions, structure, & front
panel objects you need to get started building common means application.

Complete the following step to create a VI that generates a signal & displays it in the front panel
window.
Launch labVIEW.
Select File>> New to display the New dialog box.
From the create new list
Select VI >> from template >> Tutorial (getting started) >> Generate & display.
This template VI generates and display a signal.

A preview & a brief description of the template VI appears in the Description section.
Click the ok button to create a VI from the template.
Examine the front panel window.
Select Window >> show Block Diagram and examine the block diagram of the VI.
6
7

On the front panel toolbar, click the Run button, shown below. You can also press the <Ctrl-R>
keys to run a VI.

8

A sine wave appears on the graph in the front panel window.


Stop the VI by clicking the front panel STOP button, show below
STOP
 Block Diagram:
The block diagram contains the graphical source code also known as G code or block diagram
code, for how the VI runs. Front panel objects appear as icon terminals on the block diagram
wires connect control and indicator terminals to express VIs, VIs & functions. The movement of
data through the nodes on the block diagram determines the execution order of the VIs &
functions. This movement of data is known as dataflow programing.

 Front panel & Block diagram tools:


The positioning tool appears when you move the cursor over an object in the front panel window
or on the block diagram. The cursor becomes an arrow that you can use to select, position &
resize objects. The wiring tool appears when you move the cursor over terminal of a block
diagram object. The cursor becomes a spool that you can use to connect objects on the block
diagram through c you want data to flow.

 Running & stopping a VI:


Running a VI executes the solution of the VI. Click the Run button or press the <Ctrl-R> keys to
run a VI. The Run button changes to a darkened arrow to indicate the VI is running. You can
stop a VI immediately by clicking the abort execution button. However aborting a VI that uses
executional resources might leave the resources in an unknown state.

 Express VIs:
Use express VIs located on the functions palette for common measurement tasks. When you
place an express VI on the block diagram, the dialog box you see to configure that express VI
appears by default. You also can double click an express VI or right click on express VI & select
properties from the shortcut menu to display the configuration dialog box.

 LabVIEW Documentation resources:


The labVIEW help contains info about labVIEW programming concepts, step-by-step
instructions for using labVIEW & reference info about labVIEW VIs, functions, palettes menus
tools, properties, methods, events, dialogs box & so on.

After you install a labVIEW add-on a toolkit, module or driver the documentation for that add-on
appears in the labVIEW help by access Help >> Add-on Help.

 Property Dialog Boxes:


Use property dialog boxes or shortcut menus to configure how controls and indicators appear or
behave in the front panel window. Right- click a control or indicator on the front panel & select
properties from the shortcut menu to access the proportion dialog box for that object.

Shortcut:
 Ctrl-R = Run a VI
9

 Ctrl-Z = Undo the last action.


 Ctrl-E = Switches between the block diagram & the front panel window.
 Ctrl-S = Saves a VI

Result:
Hence the familiarization with labVIEW and virtual instrumentation is done.
10

EXPERIMENT NO: 03
Aim: To measure temperature using thermocouple

Apparatus required:
NI 92xx series sleeve.
NI 9211-4 channel thermocouple input module.
USB 2.0 cable.
Computer with labVIEW software.
Thermocouple.

Theory:
Thermocouple are normally used temperature sensors because of their activity to measure wide
ranges and they are inexpensive. Since the thermocouple output signal is in millivolt range we
need some sort of signal conditioning to amplify the signal also thermocouple can only measures
different in temperature so we need a second temperature reference also called cold junction
compensation and then at last we need a data acquisition device to measure the signal.

Temperature Measurement Accuracy considerations:


Temperature measurement errors depend partialy on the thermocouple type, the accuracy ofd
thermocouple, the temperature being measured, and the cold junction temperature. Refer to the
temperature measurement accuracy section in the specification for the error of each
thermocouple type when connected to NI9211. The errors do not account for the accuracy of
thermocouple itself.
11

Specifications:
The following specification are typically for the range of 40 to 70 deg C unless otherwise noted.
Accuracy within typical use can vary based on chasis, mounting parameters, other modules
present in the system and installed accessories.

Cold Junction temperature measurement accuracy:


Heat dissipated by adjacent modules or other nearby heat sources can cause errors in
thermocouple measurement by heating up the NI9211 terminals to a different temperature than
the cold junction compensation sensor. The thermal gradient across the terminals can cause the
terminals of different channels to be at different temperature, in which case the resulting
measurement creates error not only in absolute accuracy but also in relative.

Procedure:
1. Connect the thermocouple to its signal to NI9211 , connect the positive load of thermocouple
to+ terminal and -ve terminal load to TC- terminal.
2. Connect NI9211 to the NI92xx series sleeve.
3. Plug it with USB to computer.
4. Open labVIEW software.
5. Select "Blank VI" two popup windows appear.
6. Right click on the block diagram screen, from the list selected "input" and then click on DAQ
assist and place it on the screen.
7. Another window appears, here select the acquired signal to temperature >> thermocouple and
select its channel, next set the input range and sealed unit and click ok.
8. Next on the block diagram screen right click on to execution control and drag a while loop
around it.
9. To graph the data right click on front panel, go to graph indication and select and select and
select waveform chart and we will see terminal for chart on block diagram and just wire the
output of DAQ assist to the chart.
10. Now hit run and make contact with the thermocouple and note the change in signal on the
graph
12

Result:
We have studied the measurement of temperature using thermocouple by labVIEW software.
13

EXPERIMENT NO: 04
Aim: To study & measurement of Blood pressure using labVIEW.

Apparatus required:
 NI Biomedical startup kit 3.0
 NI ELVIs series Benchtop workstation
 NI ELVIs series prototyping Board
 AC/DC power supply
 NI ELVIsmx 4.0 or later CD
 USB 2.0 cable
 Computer
 Wires to build circuits
 Vernier Analog Proto Board Connector (Order Code BTA-ELV)
 Vernier Blood Pressure sensor (Order code BPS-BTA)

Theory:
14
15
16
17
18
19

Result:
Thus I have studied about how I measured Blood pressure using labVIEW.
20

EXPERIMENT NO: 05
Aim: To study and Analysis of ECG signal using ECG sensor and labVIEW.

Apparatus required:
 NI Biomedical startup kit 3.0
 NI ELVIs series Benchtop workstation
 NI ELVIs series prototyping Board
 AC/DC power supply
 NI ELVIsmx 4.0 or later CD
 USB 2.0 cable
 Computer
 Wires to build circuits
 Vernier Analog Proto Board Connector (Order Code BTA-ELV)
 Vernier Blood Pressure sensor (Order code BPS-BTA)

Theory:
Your heart is initially polarized at rest due to the excess of sodium ions (Na+) outside of the
membrane. This correlates to a resting potential of approximately 90mV. Muscle stimulation
increase the permeability of the membrane to these sodium ions. The entry of these sodium ions
into the membrane alters the electric field around the muscular cells, generating an action
potential and causing muscle contraction. Other ions, including potassium, calcium, and chlorine
are also involved in this process. Electrodes placed on the surface of the skin record a summation
of these action potentials. The resulting signal can be graphed as an electrocardiogram (ECG)
and illustrate cardiac electric potential. Various deflection in the ECG waveform corresponding
to the contraction of different areas of the heart. Each heart cycle is represented by P wave, a
QRS complex and a T wave. The P wave corresponding to the depolarization of the atria, the
QRS complex corresponds to the depolarization of the ventricles and the T wave corresponds to
the repolarization of the ventricles.
21
22
23
24

Result:
Hence I have studied about how to measure ECG signal using ECG sensor and labVIEW.
25

EXPERIMENT NO: 06
Aim: To measure temperature using RTD

Apparatus required:
NI 92xx series sleeve.
NI 9211-4 channel RTD input module.
USB 2.0 cable.
Computer with labVIEW software.
RTD.

Theory:
Resistance thermometers, also called resistance temperature detectors (RTDs), are sensors used
to measure temperature. Many RTD elements consist of a length of fine wire wrapped around a
ceramic or glass core but other constructions are also used. The RTD wire is a pure material,
typically platinum, nickel, or copper. The material has an accurate resistance/temperature
relationship which is used to provide an indication of temperature. As RTD elements are fragile,
they are often housed in protective probes.
26

Procedure:
1. Connect the thermocouple to its signal to NI9211 , connect the positive load of RTD to TO+
terminal and -ve terminal load to TC- terminal.
2. Connect NI9211 to the NI92xx series sleeve.
3. Plug it with USB to computer.
4. Open labVIEW software.
5. Select "Blank VI" two popup windows appear.
6. Right click on the block diagram screen, from the list selected "input" and then click on DAQ
assist and place it on the screen.
7. Another window appears, here select the acquired signal to temperature >> RTD and select
its channel, next set the input range and sealed unit and click ok.
8. Next on the block diagram screen right click on to execution control and drag a while loop
around it.
9. To graph the data right click on front panel, go to graph indication and select and select and
select waveform chart and we will see terminal for chart on block diagram and just wire the
output of DAQ assist to the chart.
10. Now hit run and make contact with the thermocouple and note the change in signal on the
graph
27

Result:
Hence I have studied about how to measuring temperature using RTD in this experiment.
28

EXPERIMENT NO: 07
Aim: To study and measurement of Electromyogram (EMG)

Apparatus required:
 CleveLabs Kit
 CleveLabs Course Software
 Five (5) Snap Electrodes and Snap Leads
 Calibrated Weights (Approximately 2.5, 5, and 10 lbs)
 LabVIEW

Theory:
Electromyography is a discipline that deals with the detection, analysis and use of electrical
signal that emanates from skeletal muscles. The electromyography is studied for various reasons
in the medical field. Even a superficial acquaintance with scientific literature will uncover
various current applications in fields such as neuro physiology, kinesiology, motor control,
psychology, rehabilitation, medicine and biomedical engineering.

The EMG signal is the electrical manifestation of the neuromuscular activation associated with
the contracting muscles. The signal represents the current generated by the ionic flow across the
membrane of the muscle fibers which propagates through the intervening tissues to reach the
detection surface of the electrode located in the environment.

It is an exceedingly complicated signal which is affected by anatomical and physiological


properties of muscles and the control scheme of the nervous system, as well as characteristics of
the instrumentation used to detect and observe it.

Most of the relationships between the EMG signal and the properties of contracting muscles that
are currently in use have evolved serendipitously. The lack of proper description of the EMG
signal is probably the greatest single factor that has hampered the development of
electromyography in to a precise discipline.
29

Procedure:
1. Run the CleveLabs Course software. Log in and select the “Electromyography I” laboratory
session under the Basic Physiology subheading and click on the “Begin Lab” button.
2. Turn the BioRadio ON.
3. Click on the EMG data Tab and then on the green “Start” button. Two channels of EMG
should begin scrolling across the screen.
4. First you will record isometric EMG from your biceps and wrist extensors. An isometric
contraction is one in which the arm does not move during the contraction. More specifically,
the length of the muscle does not change during the contraction. The subject can use their
opposing hand for this experiment. Record and save a few seconds of isometric biceps EMG
by instructing the subject to hold the experimental hand position fixed in space, place the
opposing hand on top of the experimental hand to resist the force, and then pull up against
the opposing hand using the biceps muscle to create the isometric contraction. Save a few
seconds of this data to file and label the file “Isobiceps”.
5. Repeat step 4 using the wrist extensor muscles. Save this data to a file named “Isowrist”.
6. Now save a few seconds of data while you use your biceps to dynamically change the angle
of your elbow. These are dynamic, unconstrained contractions since your arm will be moving
in space and the length of the muscle will be changing. Save a few seconds of this data to a
file named “Dynbiceps”.
7. Repeat step 6 using the wrist extensor muscles. Save this data to a file named “Dynwrist”.
8. Now click on the Spectral Analysis tab and then click on the time domain tab. Select the
channel to process to be channel 1 (biceps). Then instruct the subject to make quick elbow
flexion and extension movements. Notice what happens to the raw EMG signal during the
30

motion as a result of motion artifact. Save a few seconds of this data and also report a screen
shot of this to your report.
9. Now turn on the high pass filter and set the high pass cutoff to be 20 Hz. Set the switch to
filtered data. Now repeat the motion above and note what happens to the motion artifact.
Save a few seconds of this data and also report a screen shot of this to your report.
10. Turn the filtering off and turn on the rectification. Begin saving data and name the file
“weights”. The subject should hold their arm at a 90-degree angle with their palm facing up.
The subject will hold three weights for five seconds each. Approximate values of weights to
use are 2.5, 5.0, and 10.0 lbs. After recording 5 seconds of relaxed arm muscle activity, have
another lab group member gently place the lightest of the calibrated weights into the hand of
the subject’s test arm. The subject should maintain the arm position with the weight for five
seconds. Repeat with the middle value weight and then with the heaviest weight. Then stop
saving data. You should report a screen shot of the data at each weight level.
11. We will now examine the effects of fatigue on the EMG signal. Turn off the time plot and
turn on the frequency plot. Click on the frequency tab. Turn all filtering off. We are now
going to examine the frequency components of the EMG signal. Place the 10 lb weight in the
subject’s hand with them holding an isometric contraction as they did in the previous step.
However this time they will be instructed to hold the weight for approximately 2 minutes.
Save the two minutes of data to a file named “fatigue”.

Data Analysis
Calibrated Weights
1. Using Excel, MATLAB, LabVIEW, or the post processing toolbox, open the file
“weights.dat”. Plot Biceps EMG over time and print this plot.
2. Rectify the signal by taking the absolute value of it, and store the result in a column. Plot this
column versus time. For each weightlifting segment of the rectified signal (a total of three),
calculate the average value of the rectified EMG signal. You should have three data points.
Make a plot of Average Rectified EMG vs. weight using those 3 data points.
3. Using MATLAB, create a band pass filter with a cutoff frequency of 15Hz and 50Hz. Rectify
the signal from Channel 1 of the “Weights” data file, and apply the filter you just made.
Verify the filter is working correctly by looking at the resulting signal’s power spectrum.
Find the standard deviation of the noise when the weights are being lifted.
4. Using the Post Processing Toolbox, open each of the data files that you collected during
isometric and dynamic muscle contractions including “Isobiceps”, “Isowrist”, “Dynbiceps”,
and “Dynwrist”. For each of the data files examine the frequency components of each of the
recordings using the spectral analysis tab features. Note any differences in the frequency
components between dynamic and isometric motions of the arm.
5. Using the Post Processing Toolbox, open the data file named “fatigue”. Click on the JTFA
tab. Select the channel “Biceps” and complete a JFTA. You should be able to see a decrease
in the frequency of the EMG signal over time due to fatigue.
31

Result:
Hence I have studied about how to measuring Electromyogram.
32

EXPERIMENT NO: 08
Aim: To study and measurement of Air flow using Spirometer and LabVIEW.

Apparatus used:
 NI Biomedical startup kit 3.0
 NI ELVIs series Benchtop workstation
 NI ELVIs series prototyping Board
 AC/DC power supply
 NI ELVIsmx 4.0 or later CD
 USB 2.0 cable
 Computer
 Wires to build circuits
 Spirometer

Theory:
Spirometer is the measurement instruments most used in the evaluation of the pulmonary
capacity. From its invention in the year of 1846, its use has become popular at world-wide level.
At the present time, the spirometers are in their majority portable and usually computerized.
They are constituted by a mechanical and/or an electronic sensor, a processor and a printer or
another one alternative way of graphical data presentation of any of the following information:
• Graphical measurements of curves volume-time.
• Graphical measurements of flow-volume (spirograms).
• FVC (forced vital capacity); and:
• FEV1 (Forced Expiratory Volume in the first second).
• General Information about the patient.
33

Procedure:
1. Connect the spirometer to its signal to NI9211 , connect the positive load of spirometer to
T0+ terminal and -ve terminal load to TC- terminal.
2. Connect NI9211 to the NI92xx series sleeve.
3. Plug it with USB to computer.
4. Open labVIEW software.
5. Select "Blank VI" two popup windows appear.
6. Right click on the block diagram screen, from the list selected "input" and then click on DAQ
assist and place it on the screen.
7. Another window appears, here select the acquired signal to air flow >> spirometer and select
its channel, next set the input range and sealed unit and click ok.
8. Next on the block diagram screen right click on to execution control and drag a while loop
around it.
9. To graph the data right click on front panel, go to graph indication and select and select and
select waveform chart and we will see terminal for chart on block diagram and just wire the
output of DAQ assist to the chart.
10. Now hit run and make contact with the spirometer and note the change in signal on the graph.

Result:
Hence I have studied about how measurement of air flow using spirometer and LabVIEW.
34

EXPERIMENT NO: 09
Aim: To study of Heart Rate using Heart rate monitor and LabVIEW.

Apparatus required:
 NI Biomedical startup kit 3.0
 NI ELVIs series Benchtop workstation
 NI ELVIs series prototyping Board
 AC/DC power supply
 NI ELVIsmx 4.0 or later CD
 USB 2.0 cable
 Computer
 Wires to build circuits
 Heart rate monitor

Theory:
The HRV is a crucial factor in patient health monitoring and is considered to be a vital parameter
for heart attack. Here, we deal with monitoring of the heart rate by acquiring a
Ballistocardiography (BCG) signal through different means. The BCG reflects the mechanical
activity of the heart and is one of the oldest non-invasive methods for cardiac evaluation.
Nowadays, so many people are suffering from heart-related diseases such as cardiac arrest and
some other problems. The main objective is to design a continuous heart rate monitor using the
Lab VIEW tool. This prototype is a better way to monitor patient heart rate and give information
regarding the heart condition. People might not be diagnosed with heart disease until they have a
heart attack, heart failure or any other problem. It is important to notice heart rate variability and
discuss concerns with your doctor. Monitoring can be very helpful if cardiovascular diseases are
found at the early stages by having regular evaluations. Heart disease is easier to treat when
detected early than at later severe stages. If heart rate is too high or low a light and beep sensor
gives the sign of an emergency.

Procedure:
1. Connect the spirometer to its signal to NI9211 , connect the positive load of heart rate
monitor to TO+ terminal and -ve terminal load to TC- terminal.
2. Connect NI9211 to the NI92xx series sleeve.
35

3. Plug it with USB to computer.


4. Open labVIEW software.
5. Select "Blank VI" two popup windows appear.
6. Right click on the block diagram screen, from the list selected "input" and then click on DAQ
assist and place it on the screen.
7. Another window appears, here select the acquired signal to heart rate >> heart rate monitor
and select its channel, next set the input range and sealed unit and click ok.
8. Next on the block diagram screen right click on to execution control and drag a while loop
around it.
9. To graph the data right click on front panel, go to graph indication and select and select and
select waveform chart and we will see terminal for chart on block diagram and just wire the
output of DAQ assist to the chart.
10. Now hit run and make contact with the spirometer and note the change in signal on the graph.
36

Result:
Hence I have studied about how to measure heart rate using heart rate monitor and LabVIEW.

You might also like