p09alinsunorin.weebly.comp09alinsunorin.weebly.com/uploads/4/3/2/4/43245433/b… · web...
TRANSCRIPT
Microcontroller based BMI Calculator
Chapter 1
THE PROBLEM AND ITS BACKGROUND
1.1 Introduction
Body Mass Index (BMI) can approximately calculate the total fats of the
person present in the body. It is based on the two variables such as the height
and the weight of the person. The most common way of calculatingit is by
dividing ones’mass in kilograms or pounds by the square ofthe stature in meters
or inches. Present BMI calculators are based on the BMI-for-age chart that
contains the height, the weight, and the age brackets in determining the
approximate BMI value and its classification.
As technology rises, online BMI calculators became available through the
internet. This requires the height and the weight of the user, and some asks for
age and gender too. After filling up the informations needed, just click the
calculate button and then the BMI will be determined. To find out the BMI
classification (underweight, normal, overweight and obese), there is a reference
chart wherein the range of the designated category will be based. Because of
this, manual calculation can now be eliminated.
Last April 2014, the Bachelor of Science in Electronics Engineering
students from the Technological University of the Philippines–Taguig Campus
successfully created a Microcontroller based BMI Calculator with Database and
Monitor Display. The system was designed to get the accurate height and weight
of the user and automatically calculate the BMI with the help of the
Technological University of the Philippines –Taguig Campus Page 1
Microcontroller based BMI Calculator
microcontroller. All the data will be saved in the database and could also be
printed.
1.2 Background of the Study
Overweight and obesity are defined as abnormal or excessive fat
accumulation that may damage health. Body mass index (BMI) is a simple index
of weight-for-height that is commonly used to classify the two. The World Health
Organization definition is that a BMI greater than or equal to 25 is overweight,
and a BMI greater than or equal to 30 is obese.
According to the World Health Organization stated on August 2014 article,
worldwide obesity has nearly doubled since 1980.In 2008, more than 1.4 billion
adults, 20 and older, were overweight. Of these, over 200 million men and nearly
300 million women were obese. Sixty five percent of the world's population living
in countries where overweight and obesity kills more people than underweight.
More than 40 million children under the age of 5 were overweight or obese in
2012.These two are the leading risks for global deaths. Around 3.4 million adults
die each year as a result of being overweight or obese. In addition, 44% of the
diabetes burden, 23% of the heart disease burden and between 7% and 41% of
certain cancer burdens are attributable to overweight and obesity.
In the Philippines, a 2011 survey by the Food and Nutrition Research
Institute (FNRI) showed that 22.3% of Filipino adults were overweight, and 6.1%
were obese. The FNRI-DOST also stated that the problem of obesity was
increasing in an alarming rate in the Philippines where 7 out of 10 women and 1
Technological University of the Philippines –Taguig Campus Page 2
Microcontroller based BMI Calculator
out of 10 men were affected. The occurrence of overweight Filipinos is expected
to increase significantly by 2015, which means more health problems ahead.
According to the World Health Organization, obesity kills 2.8 million people
worldwide while in the Philippines, it accounts for 37,000 deaths annually
according to FNRI-DOST.
Based on the data gathered by the proponents of the Microcontroller
based BMI calculator with Database and Monitor Display,126 TUPT students as
the respondents, female students have higher percentage of overweight, obese
class 1 and underweight; and lower percentage of normal weight compared to
male students. Normal weight percentage for female students was 61.91% only
compared to male students having 77.96%. Overweight percentage for female
was 28.57% while 15.25% for male. Underweight and obese class1 for women
was 4.76% while 3.38% only for men.
With those collected informations,it only shows that most people are not
conscious about their health status. Thus,the researchersdecided to propose a
new version of an automated Body Mass Index calculator by the aid of a
microcontroller. It is designed to help obese, overweight and underweight
persons to monitor the BMI and its classification. This will also benefit the users
to be more aware of possible health diseases that can lead to death because of
overweight and underweight conditions.
Technological University of the Philippines –Taguig Campus Page 3
Microcontroller based BMI Calculator
1.3 Objectives of the Study
1.3.1 General Objective:
To design and develop a Microcontroller based BMI Calculator.
1.3.2 Specific Objectives:
1. To design a Microcontroller based BMI calculator with notification
through buzzer by means of a microcontroller programmed using C++
language.
2. To create a database that will add, updateand save the data for
monitoring purposes.
3. To print the collected data with a recommendation message depending
on the BMI classification using thermal printer.
4. To test and assess the accuracy, reliability and functionality of the
device including every parts and components used.
1.4 Significance of the Study
This study is worth pursuing because of its capability to provide a device
as medical equipment. This will benefit the following:
University Clinic. This study can help the University Clinic by providing a
device that can accurately measure the height and the weight of a student,
automatically calculate the BMI of the user, and easily determine the body status.
Technological University of the Philippines –Taguig Campus Page 4
Microcontroller based BMI Calculator
Professors. This study can help the Physical Education Professors by providing
equipment that can automatically calculate the BMI of a freshman student during
PE1 subject.
Students.This study can help students who are health conscious to monitor their
body mass status.
1.5 Scope and Delimitation
1.5.1 Scope:
1. The weight of the user will be measured through a load cell.
2. The ultrasonic sensor will measure the height of the user.
3. The data from the weighing scale and ultrasonic sensor will be sent to
the microcontroller where the calculation of BMI takes place and the
result will be displayed in the monitor.
4. The calculated data will be stored in the database and can be viewed
for monitoring purposes.
5. All the measurements will be both in Metric and English units.
6. The data stored can be edited or updated.
7. There will be a picture in the program that will show the user’s image.
8. The device is applicable forpersons aged 15 years old and above.
9. The result can be printed using thermal printer.
10. The printed data will have a recommendation message based on the
BMI classification.
11. The collected data will be stored in the archive after a year.
Technological University of the Philippines –Taguig Campus Page 5
Microcontroller based BMI Calculator
1.5.2 Delimitation:
1. The maximum height that the ultrasonic sensor can detect is up to 7
feet or 2.13 meters only.
2. The maximum weight that the load cell can measure is up to 770
pounds or 350 kilograms.
3. The device is not applicable for people who cannot stand alone.
Technological University of the Philippines –Taguig Campus Page 6
Microcontroller based BMI Calculator
Chapter 2
REVIEW OF RELATED LITERATURE AND STUDIES
2.1 Research Literature
2.1.1BMI Calculation
Quetelet Index of Obesity was introduced by a Belgian statistician named
Adolph Queteletin the 19th century. According to his index, BMI is calculated by
dividing the weight of a person in kilograms by the square of height in meters.
Before 1980, physicians were generally using tables forweight and height
estimations and there were different charts formen and women with incorporated
ranges of body weightsfor height in inches. But these tables were imperfect as
itrelied on weight only, not on the body composition.
Currently there is so much advancement in the BMIcalculation like the
height and weight is calculatedautomatically with the help of formula and the data
is thenautomatically fed in the computer which shows the BMI ofthe person on
the monitor screen or on LCD display.
Analternative way of calculating Body Mass Index (BMI) has been
proposed by mathematician Nick Trefethen, a Professor of Numerical Analysis at
Oxford University last January 2013.
Current formula:
Metric: BMI = weight (kg) / height (m) ^ 2
English: BMI = 703 * weight (lb) / height (in) ^ 2
Technological University of the Philippines –Taguig Campus Page 7
Microcontroller based BMI Calculator
New formula:
Metric: BMI = 1.3* weight (kg) / height (m) ^ 2.5
English: BMI = 5734*weight(lb)/height(in)^2.5
The numbers 1.3 and 5734 are designed to make the BMI reading
unchanged for an adult of average height.The change means that some tall
people previously classified as "overweight" are "normal" under the new
proposed formula, and some short people who were "normal" are now
"overweight".
2.1.2 BMI-for-Age Growth Charts
The BMI-for-age charts for boys and girls aged 2 to 20 years are a major
addition to the new CDC Pediatric Growth Charts. The recommended BMI-for-
age cut-offs for teens according to Himes and Dietz (1994) are:
≥ 95th percentile = Overweight
85th to < 95th percentile = Risk of overweight
5th to <85th percentile = Normal
< 5th percentile = Underweight
Overweight rather than obesity is the term preferred for describing children
andadolescents with a BMI-for-age equal to or greater than the 95th percentile of
BMI-for-age.The cut-off for underweight of less than the 5th percentile is based
on recommendations bythe World Health Organization Expert Committee in
Physical Status on 1996.
Technological University of the Philippines –Taguig Campus Page 8
Microcontroller based BMI Calculator
Figure 2.1 BMI-for-Age Growth Charts for 2-20 years old
Figure 2.2BMI-for-Age Growth Charts for Adults
Technological University of the Philippines –Taguig Campus Page 9
Microcontroller based BMI Calculator
For adults, BMI is not age or gender specific and the classification of
overweight and underweight is different as it is for children and adolescents. For
adults, overweight and underweight categories are defined by fixed BMI cut-
points. Clinical guidelines established in 1998 by the National Heart, Lung, and
Blood Institute are as follows:
BMI less than 18.5 = Underweight
BMI of 18.5 through 24.9 = Normal
BMI of 25.0 through 29.9 = Overweight
BMI of 30.0 or greater = Obese
The Philippine Association for the Study of Overweight and Obesity
(PASOO) with the FNRI and other medical societies conducted a national survey
to assess the applicability of the BMI cut-off points for Asians among Filipino
adults. With the study, it was determined that the temporary BMI cut-off for
overweight among Filipino men and women is 23 kg/m2, while the cut-off for
obesity is 27 kg/m2.
2.1.3 Weight and Height Sensors
a. Load Cell
Load cell is a sensor that detects force (mass, torque, etc.).
When force is applied to a load cell, it converts the force into an electrical signal.
In the dictionary, a load cell is defined as a weight measurement device
necessary for electronic scales that display weights in digits.
Technological University of the Philippines –Taguig Campus Page 10
Microcontroller based BMI Calculator
Figure 2.3 Load Cell
Load cells are also known as load transducers because they convert a
load (force) into electrical signals.This electrical signal can be a voltage change,
current change or frequency change depending on the type of load cell and
circuitry used.
b. Ultrasonic Sensor
Ultrasonic sensoris an electronic device that emits an acoustic wave
beyond the upper range of human hearing called the audible range ( 20 hertz to
20 kilohertz), and determines the distance between the sensor and an object
based on the time it takes to send the signal and receive the echo.
Figure 2.4 Ultrasonic sensor
Technological University of the Philippines –Taguig Campus Page 11
Microcontroller based BMI Calculator
Ultrasonic sensors have many applications including: parking assistance
sensors in cars, proximity alarms, medical ultrasounds, generic distance
measurement, etc.
To generate the ultrasonic wave, ultrasonic sensor uses a vibrating device
known as a transducer to emit ultrasonic pulses that travel in a cone-shaped
beam. The range of an ultrasonic sensor is determined by the frequency of
vibration of the transducer.
Ultrasonic sensors work best when positioned in front of materials that
readily reflect ultrasonic waves, such as metal, plastic and glass. This enables
the sensor to give an accurate reading at a greater distance from the object in
front of it. However, when the sensor is placed in front of an object that readily
absorbs ultrasonic waves, such as fiber material, the sensor must move closer to
the object to give an accurate reading. The angle of the object also has an
impact on the accuracy of the reading, with a flat surface at a right angle to the
sensor offering the longest sensing range. This accuracy decreases with a
change in the angle of an object in relation to the sensor.
2.1.4 Microcontroller
A microcontroller (µC, uC or MCU) is a small computer on a
single integrated circuit containing a processor core, memory, and
programmable input and output peripherals. It is an integrated circuit that is
programmed to do a specific task and sometimes called as mini computers.By
reducing the size and cost compared to a design that uses a separate
Technological University of the Philippines –Taguig Campus Page 12
Microcontroller based BMI Calculator
microprocessor, memory, and input/output devices, microcontrollers make it
economical to digitally control even more devices and processes.
a. Arduino Programming
The Arduino integrated development environment (IDE) is a cross-
platform application written in Java, and is derived from the IDE for
the Processing programming language and the Wiring projects. It is designed to
introduce programming to artists and other newcomers unfamiliar with software
development. Arduino programs are written in C or C++. The Arduino IDE comes
with a software library called "Wiring".
b. C++ language
C is a high-level programming language developed in the mid-1970s. C++
is derived from the C language; it has object-oriented feature which allows the
programmer to create objects within the code. This makes programming easier
and more efficient. Because of the power and flexibility of the language, most
software programs today are written in C++. The main highlight of C++ is a
collection of pre-defined classes, which are data types that can be initiated
multiple times.
c. Gizduino X
GizduinoXis the latest addition to the growing family of Arduino compatible
controllers. It is based on an ATMEGA1281 MCU, a family member of the
ATMEGA1280 used in Arduino Mega board. This kit offers 54 I/Os, 1 hardware
SPI, 2 hardware UART, not to mention its large memory capacities: 128K
Technological University of the Philippines –Taguig Campus Page 13
Microcontroller based BMI Calculator
FLASH, 8K SRAM, and 4K EEPROM. Other hardware peripherals additions
inherited from ATMEGA1281 chip includes 3 additional timers, 10 additional
timer OCR, 1 additional ICR, and 2 additional PWMs.
Figure 2.5Gizduino X
2.1.5 Database
A database is a data structure that stores organized information. Most
databases contain multiple tables, which may each include several different
fields. For example, a company database may include tables for products,
employees, and financial records. Each of these tables would have different
fields that are relevant to the information stored in the table.
Nearly all e-commerce sites use database to store product inventory and
customer information. These sites use a database management system (or
DBMS), such as Microsoft Access, FileMaker Pro, or MySQL as the "back end"
to the website. By storing website data in a database, the data can be easily
searched, sorted, and updated. This flexibility is important for e-commerce sites
and other types of dynamic websites.
Early databases were relatively "flat," which means they were limited to
simple rows and columns, like a spreadsheet. However, today's relational
Technological University of the Philippines –Taguig Campus Page 14
Microcontroller based BMI Calculator
databases allow users to access, update, and search information based on the
relationship of data stored in different tables. Relational databases can also run
queries that involve multiple databases. While early databases could only store
text or numeric data, modern databases also let users store other data types
such as sound clips, pictures, and videos.
a. Visual Basic .NET –VB.Net is a simple, modern, object-oriented computer
programming language developed by Microsoft to combine the power of .NET
Framework and the common language runtime with the productivity benefits that
are the hallmark of Visual Basic.VisualBasicis a programming language and
development environment created by Microsoft. It is an extension of the BASIC
programming language that combines BASIC functions and commands with
visual controls. Visual Basic provides a graphical user interface GUI that allows
the developer to drag and drop objects into the program as well as manually
write program code.
b. MySQL – pronounced either "My S-Q-L" or "My Sequel," is an open source
relational database management system. It is based on the structure query
language (SQL), which is used for adding, removing, and modifying information
in the database. Standard SQL commands, such as ADD, DROP, INSERT, and
UPDATE can be used with MySQL. MySQL can be used for a variety of
applications, but is most commonly found on Web servers. A website that uses
MySQL may include Web pages that access information from a database. These
pages are often referred to as dynamic.Websites that use dynamic Web pages
are often referred to as database-driven websites.
Technological University of the Philippines –Taguig Campus Page 15
Microcontroller based BMI Calculator
2.1.6 Thermal Printer
Thermal printing (or direct thermal printing) is a digital printing process
which produces a printed image by selectively heating coated thermochromic
paper, or thermal paper as it is commonly known, when the paper passes over
the thermal print head. The coating turns black in the areas where it is heated,
producing an image. Two-colour direct thermal printers can print both black and
an additional colour (often red) by applying heat at two different temperatures.
A thermal impact printer or electrothermal printer is a printer that uses
heated pins to "burn" images onto heat-sensitive paper. These printers are
commonly used in calculators and fax machines; and although they are
inexpensive and print relatively fast, they produce low resolution print jobs.
Figure 2.6 Thermal Printer
This printer is ideal for interfacing with a microcontroller, simply need a
3.3V-5V TTL serial output from the microcontroller to print text, barcodes, bitmap
graphics, even a QR code. Easy to use with Arduino board, just connect the
Serial interface (RX, TX).
Technological University of the Philippines –Taguig Campus Page 16
Microcontroller based BMI Calculator
2.2 Research Studies
2.2.1Foreign Studies:
a. Microcontroller Based Automated Body Mass Index (BMI) Calculator with
LCD Display
This study was conducted by Burhanuddin Ismail, Syed Fahad Akbar Ali
and Ali AsgharAyaz on April 2012.The aim of the project was to design
amicrocontroller based automated Body Mass Index (BMI)calculator with LCD
display, which calculates the body mass indexusing the two basic parameters
that are weight and height.
Thehardware of the project consists of a load cell or a
weighingmechanism, which is used to calculate the body weight of a person,and
a built in height calculating mechanism, which is used tocalculate the height of a
person. The weight of the person iscalculated in kilograms and the height in
meters in accordance of the BMI standard formula.
The microcontroller basedautomated Body Mass Index calculator is a
useful device when itcomes to controlling your weight and maintaining a healthy
lifestyle. The calculated weight of the person through load cell converts the
mechanical force into electrical signals that can beeasily obtain after processing
through microcontroller. While theheight of the person is calculated by the
ultrasound sensor withbuilt-in transmit and receive circuitry as when it transits
theultrasound signal by transmitter, it reflect back to the receiver afterstriking the
object or person and height is then calculated bymultiplying the speed of the
ultrasound signal and the time takenby the it to return back to the sensor.
Technological University of the Philippines –Taguig Campus Page 17
Microcontroller based BMI Calculator
All this data is manipulatedthrough microcontrollerand then the result is
displayed on theLCD display.
b.Advanced BMI Calculator with under and overweight alerts
This project by Sooxma Technology aims at developing a BMI calculator
which playsa major role in alerting the risk of diseases due to overweight. The
proposed system notonly shows the calculated value through LCD display but
also, alerts through buzzerregarding over and under weights.
BMI stands for “Body Mass Index,” a ratio between weight and height. BMI
is astandard “tool” for helping you judge your body weight and the amount of
body fat youhave. Carrying excess body fat, not muscle, puts you at greater risk
for health problemssuch as heart disease, cancer, diabetes and stroke.
The controlling device of the whole system is a Microcontroller. The data
fromthe load cell and ultrasonic sensor are processed to calculate the BMI. The
calculatedBMI is displayed on to a LCD. Also, the Microcontroller continuously
monitors the BMIvalue and judges whether the person is overweight or
underweight and alerts throughBuzzer.
To perform the above mentioned intelligent task, intelligent program
writtenusing embedded “C” is loaded into it.
Technological University of the Philippines –Taguig Campus Page 18
Microcontroller based BMI Calculator
c.Ultrasonic Height and Weight BMI machine
Figure 2.7 IPR-scale06
Table 2.1 IPR-scale06 Details:
Place of Origin: Henan China (Mainland)Type: Medical / Personal ScaleRated Load: 200kgSticker: PVC stickerAdvertisement: Setting freelyStand Platform Size: 340mm*360mmBrand Name: IPRPower Supply: AC 100V~ 240VAccuracy: 0.1kgPrinter: ThermalLanguage: AlternativeCertificate: CE ISO9001Model Number: IPR-scale06 height weight BMI machineDisplay Type: LED screenOEM: AvailableMaterial: Aluminium alloy caseSelf size: 2350*490*340(mm)Warranty: One yearPrice: $600-900
Technological University of the Philippines –Taguig Campus Page 19
Microcontroller based BMI Calculator
Table 2.2 Product Specifications
Product name IPR-scale06 height weight BMI machineFunctions weight/height/BMI/blood pressure/pulse/ ideal weightOEM AvailableMaterial Iron case, PVC stickerPower supply AC 100V~ 240V 50/60HZ Size
Self size: 2350*490*340(mm)Stand Platform Size: 340mm*360mm
Major Technical Features
1) Height measurement range: 0~200cm (Minimum division: 0.5cm)2) Weight measurement range: 5~200kg (Minimum division: 0.1kg)1) Printing tickets (thermal printer)2) voice reporting (alternative languages)3) displaying measurement results (LED screen)1) Proper coins (Diameter: 18-29mm. Thickness: 1.2-3.0mm)2) Bill acceptor: ICT, ITL3) Blood pressure: OMRON4) Ultrasonic probe: made in the USAPrint out of your name, telephone NO., advertisement, and logos and so on freely after connecting to computer.(4 lines of ads, each one inputted into 30 characters)
MOQ 1 setSample AvailablePayment T/T, Western Union
Delivery 3~15days
Packaging carton with Foam and Packing Belt 0.27CBM
2Cartons/Set 1750*360*240mm and 660*450*400mmApplicable occasion
shopping mall, supermarket, hospital, pharmacy, shoe shop, check-up center, fitness center and bath center, even hotel
Technological University of the Philippines –Taguig Campus Page 20
Microcontroller based BMI Calculator
2.2.2 Local Studies:
d. Five Peso (5 Php) Body Check Up Machine at Mercury Drug Store
This vendo machine offers individual’s measurements of height, weight,
Body Mass Index (BMI), blood pressure and body fat percentage and it will just
take the user less than five minutes to measure everything.After all the
measurements,the result will be issued and is printed on a thermal paper. It
gives the measurements, the percentage and normal range.
Figure 2.8 Mercury Drug Machine Figure 2.9 Sample Receipt
e. Microcontroller based BMI Calculator with Database and Monitor Display
Microcontroller based BMI Calculator with Database and Monitor Display
was successfully created by Bachelor of Science in Electronics Engineering
students of the Technological University of the Philippines-Taguig Campus last
April 2014.
Technological University of the Philippines –Taguig Campus Page 21
Microcontroller based BMI Calculator
Figure 2.10 Microcontroller based BMI Calculator with Database and
Monitor Display
The Body Mass Index (BMI) is used for measuring the human body
shaped on an individual’s mass and height and the proportionality of it. The study
was all about measuring Body Mass Index automatically with the help of a
microcontroller.MCU Based BMI Calculator with Database and Monitor Display
will measure the height, weight, and calculated BMI once the user stepped on the
prototype. The data from the microcontroller will be saved in the database. The
project used ultrasonic sensor to be able to determine the height, load cell to get
the weight and a microcontroller to calculate the Body Mass Index of the user.
The ultrasonic sensor can measure a maximum of 2 meters while the load cell
can measure 350 kilograms maximum.
Technological University of the Philippines –Taguig Campus Page 22
Microcontroller based BMI Calculator
2.3 Synthesis
Microcontroller based Body Mass Index Calculatoris designed to improve
the recent BMI calculator. With this proposal, BMI calculation will be more
convenient to the users. This project will measure the height and the weight of
the user, automatically calculate the BMI and easily determine the BMI
classification. After the system calculates the data, there will be a notrification
through buzzer that will be activated if it detects that the user is in the
underweight, overweight or obese category.
The formula to be used in computing the BMI will be the proposed formula
by Nick Trefethen. The weight sensor to be used is a load cell with a maximum
capacity of 350 kilograms while the height will be measured using an ultrasonic
sensor with a 3cm to 400 cm distance range. And the microcontroller to be used
is the Gizduino X with 54 I/Os.
This project will also have a database that will provide the storage of the
data. This will also help an individual to monitor their health status. This project
doesn’t need the help of the internet and can be utilize conveniently anytime.The
database will include user’s personal information and picture. The unit of
measurements will be both in Metric and English system. The collected data can
also be printed for the user to have a copy of the BMI result with a
recommendation message depending on the BMI classification.
Technological University of the Philippines –Taguig Campus Page 23
Microcontroller based BMI Calculator
2.4 Conceptual Framework
Diagram 2.1 Conceptual Framework
Technological University of the Philippines –Taguig Campus Page 24
Knowledge: Ideas about the existing related studies. Microcontroller basic principle of operation.Ultrasonic sensor and load cell basic principle of operation. Outsourcing
People Ware: Programmer End User: -Students -Clinic Staff -PE Instructors
Hardware: CPU Monitor Keyboard Mouse Load Cell Height sensor Gizduino X (microcontroller)
Software: C++ VB.Net My SQL
INPUT PROCESS OUTPUT
Microcontroller
Based
Automated
BMI
Calculator
Citation of Problem
Data Gathering
Is the prototype functioning well?
Yes
No
Design
Development
Adjustments
Testing and Evaluation
Project Implementation
Microcontroller based BMI Calculator
2.5 Definition of Terms
Body Mass Index – is used for measuring approximate total fat of a
person present in the bodybased on their body weight and stature height.
C++ Language – is a programming language that is used in Arduino. It
has object-oriented feature that makes programming easier.
Database – is a collection of information that can easily be access,
manage, and update.
Load Cell – is a sensor that detects force (mass or torque).
Load cells are also known as load transducers because they convert a
load (force) into electrical signals.
MySQL – is an open source relational database management system. It is
a software product whose primary function is to store and retrieve data as
requested by other software applications.
Ultrasonic Sensor – is an electronic device that emits an acoustic wave
beyond the upper range of human hearing called the audible range ( 20
hertzto 20 kilohertz), and determines the distance between the sensor and
an object based on the time it takes to send the signal and receive the
echo.
Visual Basic.Net – is a programming language and development
environment created by Microsoft.Visual Basic is designed to make
software development easy and efficient, while still being powerful enough
to create advanced programs.
Technological University of the Philippines –Taguig Campus Page 25
The data will be displayed on the monitor. As the system detects user as underweight, overweight or obese, the alarm will be activated.
Input: User’s InformationFill-up the required information needed to access the system. The data will be stored at the database.
Press the start button to begin the calculation.Press the print button to have a copy of the data.
Database
Weighing scale
Height sensor
Function buttons
Printer
Microcontroller based BMI Calculator
Chapter 3
RESEARCH DESIGN
3.1 Project Conceptualization
Diagram 3.1 Process Flow Diagram of the MCU Based BMI Calculator
Technological University of the Philippines –Taguig Campus Page 26
Microcontroller based BMI Calculator
The concept of this project is to measure the BMI of a person
automatically and will be stored in a database. To begin the process, the user
needs to register or input personal information including name, age, and gender
in the User Information. Then the user has to push the start button. As the user
stepon the machine the weighing scale and the height sensor make it possible to
the system to automatically calculate the Body Mass Index (BMI).
The controlling device of the whole system is a Microcontroller. The data
from the load cell and the height sensor are processed to calculate the BMI. The
calculated BMI is displayed on the monitor screen and stored in the database
with complete details and classification. Also, the microcontroller continuously
monitors the BMIvalue and judges whether the user is normal, but if the user is
either obese, overweight or underweight, the system will give an alert through
buzzer.
All the data gathered like the height, weight, BMI and BMI classification of
the user can be documented with the aid of the thermal printerwitha
recommendation message also appear on the printout.
Technological University of the Philippines –Taguig Campus Page 27
START
LOAD CELL
HEIGHT SENSOR
DATA BASE
BUZZER
LEDs
PRINTER
MICROCONTROLLER
Microcontroller based BMI Calculator
3.2 Project Design and Specifications
3.2.1 Block Diagram
Diagram 3.2 MCU Based BMI Calculator Block Diagram
The initial component of the diagram is the start button; when being
pressed, the load cell and the ultrasonic sensor will automatically detect the
height and the weight of the user. All the data will be transferred to the
microcontroller which is assigned to do the calculation of the BMI. After the
computation, the data willbetransferred to the database and will be stored. When
the system detects that the user is in the underweight, overweight, or obese
classification, the buzzer will be activated and the corresponding LED indicator
will lit. The measured data can also be printed afterwards.
Technological University of the Philippines –Taguig Campus Page 28
1.3ft
2.0ft
1.2ft
7.0ft
1.0ft
1.3ft
1.2ft
1.0ft
1.0ft
2.3ft
Microcontroller based BMI Calculator
3.2.2 Structural Design
Figure 3.1 MCU Based BMI Calculator Structural Design
3.2.3 Mechanical Design
Technological University of the Philippines –Taguig Campus Page 29
1.3ft
1.5ft
Height sensor
Weight sensor
Microcontroller based BMI Calculator
Figure 3.2 MCU Based BMI Calculator Mechanical Design
The intended design for the system is made up of stainless steel. The
height sensor will be placed on top while the weight sensor at the bottom. The
length of the holder of the ultrasonic sensor will be 1.2 ft. The base carrying the
load cell is 1.3 ft. long.
3.2.4 Instrumentation
Technological University of the Philippines –Taguig Campus Page 30
Microcontroller based BMI Calculator
3.2.4.1 Hardware Components
a. Load Cell – has350 kilograms capacity.It can be used in platform scales,
small weighing platforms as well as electronic scales and weighing systems. The
load cell will weigh within the tolerance regardless of the load application point.
Figure 3.3Load Cell
b. Ultrasonic Sensor – is a non-contact sensor distance measurement module.
This is dual transducer device and best in 30 degrees angle. It has a supply
voltage of 5V and a global consumption of 15mA. It also has an ultrasonic
frequency of 40 KHz with a minimal range of 3cm and a maximum range of
400cm.
Figure 3.4Ultrasonic sensor
Technological University of the Philippines –Taguig Campus Page 31
Microcontroller based BMI Calculator
c. Gizduino X – is the latest addition to the growing family of Arduino compatible
controllers. It is based on an ATMEGA1281 MCU, a family member of the
ATMEGA1280 used in Arduino Mega board. This kit offers 54 I/Os, 1 hardware
SPI, 2- hardware UART, not to mention its large memory capacities: 128K
FLASH, 8K SRAM, and 4K EEPROM. Other hardware peripherals additions
inherited from ATMEGA1281 chip includes 3 additional timers, 10 additional
timer OCR, 1 additional ICR, and 2 additional PWMs.
Figure 3.5Gizduino X
d. Computer set – have a specification of Intel core i5 and a 2Ghz processor
and a minimum 2Gb for the RAM, 120Gb for the hard drive, DVD-RW for the
optical drive, 10/100 MBPS for wired network card and a 802.11B/G compatible
for wireless network card.
Figure 3.6 Computer Set
Technological University of the Philippines –Taguig Campus Page 32
Microcontroller based BMI Calculator
e. Thermal Printer – is also known as receipt printer. This printer is ideal for
interfacing with a microcontroller, simply need a 3.3V-5V TTL serial output from
the microcontroller to print text, barcodes, bitmap graphics, even a QR code.
Easy to use with Arduino board, just connect the Serial interface (RX, TX).
Figure 3.7Thermal Printer
3.2.4.2Software Components
a. Arduino – The open-source Arduino environment makes it easy to write code
and upload it to the I/O board. It runs on Windows, Mac OS X, and Linux. The
environment is written in Java and based on Processing, avr-gcc, and other open
source software.
b. Visual Basic .NET – VB.Net is a simple, modern, object-oriented computer
programming language developed by Microsoft to combine the power of .NET
Framework and the common language runtime with the productivity benefits that
are the hallmark of Visual Basic.
Technological University of the Philippines –Taguig Campus Page 33
Microcontroller based BMI Calculator
Visual Basicis a programming language and development environment
created by Microsoft. It is an extension of the BASIC programming language that
combines BASIC functions and commands with visual controls. Visual Basic
provides a graphical user interface GUI that allows the developer to drag and
drop objects into the program as well as manually write program code.
c. MySQL – pronounced either "My S-Q-L" or "My Sequel," is an open source
relational database management system. It is based on the structure query
language (SQL), which is used for adding, removing, and modifying information
in the database. Standard SQL commands, such as ADD, DROP, INSERT, and
UPDATE can be used with MySQL.
3.3 Project Actualization
3.3.1 Financial Feasibility
Table 3.1 Estimated Bill of Materials
Description Price
Computer Set 15,000
Thermal Printer 2,100
Stainless Steel 4,000
Load Cell 1,800
Gizduino X 1,090
Ultrasonic Sensor 350
Miscellaneous 3,000
Total 27,340
Technological University of the Philippines –Taguig Campus Page 34
Microcontroller based BMI Calculator
3.3.2 Gantt Chart
Table 3.2 Gantt Chart for Project Study I
PROJECT STUDY 1
ACTIVITY TERM WEEK (September to December)
STEP PROCEDURE 1 2 3 4 5 6 7 8 9 10
11
12
13 14
1 Title Research
2 Brain Storming
3 Data Gathering
4Documentation and Revision (Chapter 1)
5Documentation and Revision (Chapter 2)
6Documentation and Revision (Chapter 3)
7Pre-canvassing of materials
8 Title Defense
Proponents:
ALINSUNORIN
ALONZO
Technological University of the Philippines –Taguig Campus Page 35
Microcontroller based BMI Calculator
3.3.2 Gantt Chart
Table 3.3 Gantt Chart for Project Study IIPROJECT STUDY 2
ACTIVITY TERM WEEK (January to April)
STEP PROCEDURE 1 2 3 4 5 6 7 8 9 10 11 12 13 14
1 Finalization of Project Concept
2 Canvassing of Materials
3 Purchasing of Materials
4 Programming of Microcontroller
5 Database Making
6 Construction of the Prototype
7 Testing and Troubleshooting
8 Prototype Evaluation
9 Finalization of Documents
10 Project Defense
Proponents: ALINSUNORIN ALONZO
Technological University of the Philippines –Taguig Campus Page 36
Microcontroller based BMI Calculator
BIBLIOGRAPHY
Theses/ Dissertations
Burhanuddin Ismail, Syed Fahad Akbar Ali and Ali AsgharAyaz. (April 2012).
Microcontroller Based Automated Body Mass Index (BMI)
Calculator with LCD Display.
Sooxma Technology. (n.d).
Advanced BMI Calculator with under and overweight alerts.
Rachelle A. Alvarez, Roi M. Javier, Joyce P. Lapitan, Mark Jonald A. Tanay.(April
2014).
MCU based BMI Calculator with Database and Monitor Display.
Websites
[1]CDC Pediatric Growth Charts. Using the BMI-for-Age Growth ChartsRetrieved
(October 2014) fromhttp://www.cdc.gov/nccdphp/dnpa/growthcharts/training/
modules/module1
[2](Orlistat) Xenical Philippines (2014). BMI For Filipinos Retrieved (October
2014) from http://www.newyou.com.ph/bmi-for-filipinos
[3]Nutritionist-Dietitians' Association of the Philippines (2014). Healthier You
Facts: OBESITY Retrieved (October 2014) from http://www.ndap.org.ph/obesity
[4]Load Cells - Loadstar Sensors (2014) Load Cell Retrieved (October 2014)
from http://www.loadstarsensors.com/what-is-a-load-cell.html
[5]A&D Company, Limited (2014) Load Cell Retrieved (October 2014) from
http://www.aandd.jp/products/weighing/loadcell/introduction/loadcells_qa_01.html
Technological University of the Philippines –Taguig Campus Page 37
Microcontroller based BMI Calculator
[6]Wesley Stephenson (January 29 2013). BMI: Does the Body Mass Index need
fixing? Retrieved (October 2014) from http://www.bbc.com/news/magazine-
21229387
[7]Jumbo Dumbo Thoughts ( June 15, 2014). On the Overweight and Obese: 1 in
4 Filipino adults are overweight, 1 in 20 are obese Retrieved (October 2014) from
http://www.jumbodumbothoughts.com/2014/06/obesity-ihme.html
[8]Jonathan Marker (July 28, 2014) How Do Ultrasonic Sensors Work? Retrieved
(October 2014) from http://www.ehow.com/how-does_4947693_ultrasonic-
sensors-work.html
[9]e-Gizmo Mechatronix Central (2014) Gizduino X Retrieved (October 2014)
from http://www.e-gizmo.com/KIT/gizDuino%20X.html
[10]Techterms (November 5, 2007). Visual Basic Retrieved (October 2014) from
http://www.techterms.com/definition/visualbasic
[11]Techterms (March 6, 2007). Visual Basic Retrieved (October 2014) from
http://www.techterms.com/definition/mysql
[12]Alibaba (2014) most popular IPR-scale06 ultrasonic height weight BMI
machine (October 2014) from http://www.alibaba.com/product-detail/most-
popular-IPR-scale06-ultrasonic-height_478736894.html
[13]Stacy Liong (2011). Five Peso (5 php) Body Check Up Machine
at Mercury Drug Store Retrieved (October 2014)
fromhttp://www.crumpylicious.com/2011/06/five-peso-5-php-body-check-up-
machine.html
Technological University of the Philippines –Taguig Campus Page 38