SlideShare a Scribd company logo
!
!
CELLULAR PHONE DETECTOR
(PHONE SPOTTER)
FINAL CAPSTONE PROJECT REPORT
!
!
!
!
!
!
Prof. Abdulmotaleb El Saddik, P.Eng.
University of Ottawa
School of Electrical Engineering and Computer Science
Team Members
Nabila Fairuz Rahman 5129121
Nourhan Eid 6164009
Tilly Ndjiapanda 5800573
Vladimir François 5760018
!
20 December 2013
ABSTRACT
Currently there is a great deal of news spreading around regarding the misuse of cell phones.
They are being used in restricted areas disregarding the rules and regulations of such places.
Many such scenarios exist where people abuse their rights of using mobile phones. Keeping all
these examples in mind, it is our intention to build a cell phone detection unit that will help users
find out if cell phones are being used in a restricted area. It will also be useful for detecting the
use of a mobile phone for spying and unauthorized video transmission.
!
It is our intention to make our unit reliable and inexpensive, as well as lightweight so the device
can be portable. This device will detect precisely cellphones as well as smartphones using 2G,
3G, LTE and Wi-Fi within 110 feet. Also, our product will have a microcontroller which will
make it possible to give a higher level of detection of cellphones in use in prohibited environ-
ment.
!
We want to create a device that can be depended on to work accurately. It is expected that this
device will have a good market, with potential clients such as airlines, government and military
facilities, hospitals, educational institutions etc. Since there is an increasing trend of companies
and institutions taking drastic measures to secure their facilities and property information, this
team is hopeful that the market for our product will increase. In addition, we claim that the cost
of developing the product will allow our unit to be cheaper than its competitors.
!
This report will also discuss the technical aspects of the device, detailing all the features it is
supposed to be implemented with and the proposed design for the device. In addition, we
demonstrated in this report that we have successfully build prototype for such device that works
according to the set requirements. Lastly, we have presented a business case that we will use to
move forward with our device for commercialization.
!
!
!
!
TABLE OF CONTENTS
Abstract 2............................................................................................................................................
Table of Figures 6..............................................................................................................................
Introduction 7.....................................................................................................................................
Design Objectives: Features 9............................................................................................................
Product Design 11...............................................................................................................................
Transition to a newer design 12......................................................................................................
Detailed Design 15........................................................................................................................
Antenna 15.................................................................................................................................
Logartihmic Amplifier 16...........................................................................................................
Signal Conditioning Circuit 18...................................................................................................
Micro-controller 20....................................................................................................................
Design Methodology 25.....................................................................................................................
Design Constraints 27.........................................................................................................................
Experimental Results: Simulation and Testing 27..............................................................................
Component Simulation 27..............................................................................................................
Instrumentation Amplifier 28....................................................................................................
Log Amplifier 28.......................................................................................................................
Component Testing 29....................................................................................................................
Antenna 30.................................................................................................................................
Log Amplifier 33........................................................................................................................
Signal conditioning testing 36....................................................................................................
Integration System Testing 37........................................................................................................
Testing for phone detection 37...................................................................................................
Part 2: Connecting to Signal Conditioning Circuit 38...............................................................
Part 3: Connecting the microcontroller 39...............................................................................
Testing for distance of phone 40.................................................................................................
Physical Implementation and Prototype 42........................................................................................
Device Output 46...........................................................................................................................
Precautionary measure 49...........................................................................................................
Detection for text Messages and data 50....................................................................................
Project Work Distribution 50..............................................................................................................
Business Proposal 53..........................................................................................................................
Business Description 53.................................................................................................................
Traits and features for our successful product 54...........................................................................
The commercialization process 54.................................................................................................
Launch method 56......................................................................................................................
Marketing Strategy 56................................................................................................................
Targeted Market and Customers 56...............................................................................................
Main Customers 56.....................................................................................................................
!
!
!
!
!
!
Targeted Market: North and south America, Europe, Asia and africa 57.................................
(SPECIALLY- Example for customers in north america) 57.....................................................
Growth Trends in this Business, Pricing Power, Mean Time between Failures 58........................
Project Cost Estimate and Cash Flow Analysis 59.........................................................................
Project Cost Estimate 59.............................................................................................................
Description 61.................................................................................................................................
Project Risks and Assumptions 62.................................................................................................
Description 62.............................................................................................................................
Conclusion 63.....................................................................................................................................
References 64.....................................................................................................................................
Appendix A 65....................................................................................................................................
Cell Phone Detector Circuit 65...................................................................................................
Appendix B 65....................................................................................................................................
Flowchart of PIC24F (MCU) Program 66..................................................................................
C CODE of PIC24F (MCU) Program 66...................................................................................
Appendix C 78....................................................................................................................................
Gantt chart and project schedule 78.........................................................................................
!
!
!
!
!
!
TABLE OF FIGURES
Figure 1: Cellbusters Zone Protector 8...............................................................................................
Figure 2: Block Diagram Of Old Proposed Design 11.......................................................................
Figure 3: Cell Phone Detector System Block Diagram Of The New Proposed Design 13................
Figure 4: ANT-ELE-S01-006 Antenna (Left) And Its Magnetic Base (Right) 15..............................
Figure 5: Basic Connections For The RSSI Mode As Suggested By The Datasheet 16....................
Figure 6: AD8313 Output Voltage Versus Power Level In Dbm (Taken From Datasheet [6]) 17.....
Figure 7: Cell Phone Detector Signal Conditioning Circuit 17..........................................................
Figure 8: Test Setup For ADC And LCD Libraries Using The Explorer 16 Board 21.......................
Figure 9: Instrumentation Amplifier Circuit In Multisim 27..............................................................
Figure 10: Log Amplifier Multisim Simulation 28............................................................................
Figure 11: Log Amplifiera Simulation Output 28..............................................................................
Figure 12: Spectrum Analyzer Capture Of Signal Detected From Cell Phone 1 30..........................
Figure 13: SPECTRUM ANALYZER CAPTURE OF SIGNAL DETECTED FROM CELL
PHONE 2 31.......................................................................................................................................
Figure 14: Spectrum Analyzer Capture Of Signal Detected From Cell Phone 3 31..........................
Figure 15:Log Amplifier Circuit On Breadboard 32..........................................................................
Figure 16: Results Of Log Amplifier Testing 34................................................................................
Figure 17: Signal Conditioning Prototype On The Breadboard 35....................................................
Figure 18: Voltmeter Results Of Antenna And Log Amplifier Testing 36.........................................
Figure 19: Voltmeter Results From Signal Conditioning Circuit 37..................................................
Figure 20: Microcontroller Output At Phone Detection 38................................................................
Figure 21: Variation Of Voltage With Distance 39.............................................................................
Figure 22: Circuit Soldered On Veraboard 41....................................................................................
Figure 23: Prototype Circuit Connected To MCU 42.........................................................................
Figure 24: Circuit In The Metal Enclosure 43....................................................................................
Figure 25: Physical Appearance Of Final Prototype 43.....................................................................
Figure 26: Device Output When Battery Is Off 44.............................................................................
Figure 27: Places Where Cell Phone Detectors Are Sold Worlwide 53.............................................
!
INTRODUCTION
Cell phones have been a significant scientific leap, helping people remain connected to each oth-
er more profoundly than before. Nowadays, everyone has a cell phone and as with every tech-
nology, the misuse of cell phone is also becoming more and more emergent.
Recently there is a growing number of information leakage, security breach and examination
cheating cases linked to the use of cell phones. Even if there are signs asking people to not use
their cell phones, it is often ignored and people use their mobile phones in restricted areas. Some
scenarios include: take-off and landing period in airplanes where, despite warnings, people still
use their phones; exam halls, where students smuggle in their smart phones and use internet to
get answers; jails and correctional facilities, where inmates can smuggle in phones and plan
mutiny or prison breaks to escape. It is shown that 65% teens use cell-phones in school building
despite school policy, and 35% use phones in tests [1]. The use of cell-phones while driving can
also be dangerous as it leads to the increase of road accidents [9].
Also, the signal emitted from cell phones can be harmful in the sense that it can cause electro-
magnetic interference (EMI) with devices in the hospitals. This can be dangerous to patients. A
Dutch research carried out showed that, out of 63 hospital devices, 26 were disrupted due to EMI
[10]. That’s almost 43% of hospital devices. The same research showed that out of all the inter-
ference, 75% were considered “hazardous”.
!
As a result of scenarios such as the ones discussed above, this team proposes to build a cell
phone detector that can detect RF (radio frequency) signals made by cellular phones, especially
when they are making calls. The detector can alert the user of any cell phone being used in the
vicinity, thus limiting the use of the phones in restricting areas. This device can be used in air-
planes, military facilities, prisons, hospitals as well as examination halls in schools, universities
and other educational institutions.
The concept our project is not a very new invention. Similar sophisticated products exist. Com-
panies such as Cell Busters, whose produce zone protector shown in Figure 1, as well as
Wolfhound have similar cell phone detectors [2] [3]. But their components are either not portable
or doesn’t use a microcontroller and thus not flexible and are unreliable . More importantly, both
companies produce very expensive devices. Compared to that, we are looking to produce a de-
vice that is portable and less expensive, but still work just as efficient. These were our main in-
tentions when thinking of doing this project.
!
FIGURE 1: CELLBUSTERS ZONE PROTECTOR
DESIGN OBJECTIVES: FEATURES
At the beginning of the design phase, we compiled a list of requirements or features that we
wanted our final product to posses and which will make it better than the other products in the
market. The following lists a number of features that was intended to be incorporated in the final
product.
1. Dimensions
The design will be portable, light weight and if possible, pocket sized. Hence, the ideal dimen-
sions that were thought of are given as follows:
• Dimensions: Height – 20 cm, Width – 19 cm, Depth – 6 cm
• Weight: 900 grams without directional antenna
2. Power Supply
To make the device effectively portable, the device is made to be battery operated rather than us-
ing an adapter to power it. A 3.7 volts lithium-ion battery with 1100 – 1500 mA is to be used.
This battery is chosen because it is rechargeable and it has an expected life time of 12 hours.
3. Frequency Bands
Cell phones use radio frequency (RF) signals to communicate with the outside world. Most
phones nowadays also use Wi-Fi besides the traditional RF signals assigned for cellular commu-
nication. Therefore, it is necessary to expand the design of the product to detect Wi-Fi signals as
well. This lead to making the RF design to be wideband, since the range of the frequencies will
expand up to 5 GHz. The primary goal is to detect following range of frequencies:
• GSM/EDGE (850, 1900 MHz)
• UMTS/HSPA+ (850, 1700, 1900, 2600 MHz)
• W-CDMA/CDMA/CDMA2000 (800, 1900 MHz)
• LTE (700, 1700, 2100, 2600 MHz) (Band 2, 3, 4, 5, 13, 17, 25)
• Wi-Fi 802.11a/b/g/n (2.4, 3.7, 5 GHz)
4. Detection range
The detector should detect signal as farthest as possible in large rooms such as the end of an air-
plane when standing at the other end. This is made possible through the use of high gain antenna.
Using directional antenna can be useful because they boost the range of detection due to their
higher gain as compared to an omnidirectional antenna. However, the device will incorporate a
build-in omnidirectional antenna and the directional antenna will be optional to connect external-
ly to the device. The following are the range this device should be able to detect:
• 0 - 110 feet under typical conditions
• 0 - 150 feet when using directional antenna under typical conditions
5. Alert option
The user is alerted that a cell phone has been detected via three possible options, which form
part of the user interaction. The options that are available in the device are:
• Buzzer: Which sounds an alarm once a cell-phone is detected and the sound stops once
the detected device is switched off.
• Two multi-color LED indicators:
a. “detect” LED: Phone detection indicators which have two states: LED lights
green when a phone is detected and the detector is moving away from the phone,
as well as, LED lights orange when phone is detected and the detector is getting
closer to it.
b. “fail” LED: LED lights red when a error or fail occurs.
• Vibration alarm: Is an optional feature that produces a vibration instead of a buzzer
sound. When switched on the buzzer is automatically switched off.
6. Display
The final design is intended to have a 16 x 4 LCD to display the following:
• Error messages
• Battery level
• Message when a phone is detected
PRODUCT DESIGN
The idea behind phone detection is that when a cell phone call is being made then the cellar sig-
nal in the area will demonstrate an increase in their power level. Therefore, we need to introduce
a design that continuously scans for cellular signals and evaluates their power levels, and accord-
ingly detects a sudden increase in power which indicates a detected phone. Using this method
and in light of previously mentioned goals , the team proposed a system design last semester for
the cell phone detector which is shown in Figure 2. In summary, the device was proposed to
function by receiving cell phone signals in the surrounding environment via an antenna and a
receiving unit, and then feed the detected signals to a microprocessor, namely, a Digital Signal
Processor (DSP). The DSP will analyze the signals and decide if it belongs to an active phone
transmission and alarm the user accordingly. The aim of this device is to preserve the RF signals
to be processed in the DSP which will give our device the uniqueness of having most of the in-
formation about the signal.
!
FIGURE 2: BLOCK DIAGRAM OF OLD PROPOSED DESIGN
In more details of design Figure 2, the antenna picks-up cellular RF signals propagating around
the device. The received cellular signals are then passed through a band-pass filter that blocks
signals with frequencies outside the cellular frequency bands, such as, 824-849 MHz for
GSM-850. Following the filter, signals are passed through a RF module which consists of a low-
noise amplifier (LNA), down-converter and local oscillator. The low-noise amplifier amplifies
the received signal while reducing its noise level; this is important because the received signal
has a significantly low power and any level of noise will distort the signal power. The signals are
then fed to a down-converter where the signal frequencies are changed from high radio frequen-
cies to lower frequencies in the intermediate range (less than 1MHz). For the down-converter to
operate, it is connected to a local oscillator that produces a signal at a pre-defined frequency.
The last stage is the digital signal processor (DSP) which is the core unit of the device. The de-
sign intends to preserve the signal for the DSP to make all the decisions and analyses of the de-
tection. The DSP will receive the signal at every time instance, scan it to determine the power
level of the signal, compare the data to a stored threshold (for example, from a lookup table of
the expected range of power levels of the signal) and give out a final result on the Liquid Crystal
Display (LCD) of the device.
!
!
!
TRANSITION TO A NEWER DESIGN
While working on this design, theoretically it sounded right to us and seemed executable. How-
ever throughout the implementation phase, we faced numerous technical challenges, especially
with the RF module. The main problem faced was from the RF down converter, in which all
down-converter chips sold in the market produces an output signal much larger in frequency than
what the ADC in the microprocessor was capable of handling. As a result, we found a work-
around for the problem faced, but this solution involved adding other stages to our design which
increased its complexity. Thus, while trying to make this work-around work we were shifting
more toward designing and implementing a receiver unit because of its sophisticated and de-
manding design. More importantly, this lead to gradually shift our scope from implementing a
cell phone detector, which should simply detect cellular transmission within vicinity of the de-
vice, to a receiving unit, and as a consequence, more effort was focused on implementing the RF
module although it formed a small peripheral unit of our overall system.
Therefore, we realized that this excessive focus on the complex RF module will eventually lead
to a negative impact on the implementation of our overall product. In addition, designing the RF
module required immense microwave circuit design experience and resources that we lacked.
Some of the components that theoretically sounded perfect ended up being more complicated to
apply in reality. In the light of that, we sought to find a better yet simpler design that will
achieve our goal without the need to implement the complex RF module.
Fundamentally, the device is expected to detect cellular signals; this is comprised of detecting the
presence of signal power from the antenna. This is in an essence a RF power meter but instead of
measuring power and displaying it, the device uses the power level to alert the user of the pres-
ence of cell phone in the area. In the previous design we were trying to accomplish this by using
a more advanced yet complex approach by down-converting the signal to be analyzed in the DSP
for power calculation. Whereas, a simpler method would be to replace the RF module with a
component that will act as an envelope detector or a power detector, which has the function to
measure RF power of the received signal. This replacement will make our design simpler with-
out compromising the functions to be performed by our original design as well as maintain the
same level efficiency that was claimed by our product. As a result, the team decided to make
changes to the original proposed design. In our new design, we replaced the RF module with a
log amplifier. The log amplifier is an amplifier that converts the input signal to its power level in
decibels (dB) by producing an almost DC voltage output that is proportional to that power level.
!
FIGURE 3: CELL PHONE DETECTOR SYSTEM BLOCK DIAGRAM OF THE NEW PROPOSED DESIGN
The new proposed design that uses the log amplifier is shown in Figure 3. Similar to the old de-
sign, the cellular signals are received by an antenna and passed through a band-pass filter to re-
move any stray signals not belonging to cell phones [5]. These two components are the same
components that were to be used by the old design which is to our advantage since it allowed us
to progress with implementing this stage. The next stage is the log amplifier which is new to this
design; the amplifier outputs a voltage level that is an indication of the power level in dB of the
received signal. The output voltage is applied to an amplifier and a low-pass filter which re-
moves the noise and amplifies the signal. This is done in order to increase the resolution and pre-
cision of the voltage that will be read by the microcontroller. Since this circuit is prone to noise,
there is future proposal to add a LNA after the BPF which will help to amplify the signal while
eliminating noise. However, such a component was not incorporated as part of the prototype.
The microcontroller used is a Microchip PIC24F that has an integrated a 10-bit Analog to Digital
Converter. From Figure 3 we notice that we replaced the DSP used previously with a micro-con-
troller. This is because the function of the DSP of performing signal processing to calculate the
power level has moved from the microprocessor to the log amplifier. In other words, the previous
design required the microprocessor to perform digital filtering and other complex calculations
rapidly which can only be performed by the DSP, but these operations are not done in the micro-
processor of the new design. Therefore, the goal of the microprocessor to perform complex cal-
culations has been eliminated, and for this reason we used a normal micro-controller instead.
This change has not caused complication to the team since the development board originally
used with the DSP, Explorer 16 development board, had the option of changing the processor to a
PIC24F, through plug-in module technology. Thus, the team was capable of retaining their origi-
nal board and this saved the effort needed to adapt the code to another processor.
DETAILED DESIGN
We will discuss each of the components of the new design in details; refer to Appendix A for
complete circuit design of the system in Figure 3.
ANTENNA
For this device an antenna that can operate at cellular frequencies was needed. To get such an
antenna there was two options, either to build our own antenna or buy off-the shelf antenna.
However, it was preferred to buy an antenna which will reduce the risk of building an antenna
that doesn’t meet the specification. An omni-directional monopole antenna (ANT-ELE-S01-006 )
was found which operated at two frequency bands: 824-960MHz and 1710-1880MHz. The an-
tenna requires a magnetic base to connect to which will provide a 50Ω matching to the antenna.
The magnetic base will allow the antenna to be attached to a ground plane through it magnetic
properties.
! !
FIGURE 4: ANT-ELE-S01-006 ANTENNA (LEFT) AND ITS MAGNETIC BASE (RIGHT)
In addition, the voltage standing wave ratio (VSWR) is known which enable us to determine the
power reflected and power transmitted to the antenna. The parameter VSWR is a measure that
numerically describes how well the antenna is impedance matched to the radio or transmission
line it is connected to. From the datasheet we found out that the antenna is less than 1.5 VSWR,
which is actually good, because it only reflect 4% of the power, which is -14dB power reflected,
that means at least 96% of the power will be deliver. And typically antenna is matched to 50
ohms impedance, which is also in our case.
LOGARTIHMIC AMPLIFIER
In general, a logarithmic amplifier is a non-linear amplifier that received signal at radio frequen-
cies and outputs a DC voltage level that is proportional to the log power level of the input signal
and thus the log amplifier can be used a power detector or envelope detector. The log amplifier to
be used in this design is intended to operate at radio frequencies; namely, it should operate at cel-
lular frequencies which are 850 MHz, 1700MHz and 1900MHz. For this reason we choose a log
amplifier from Analog Devices, AD8313. AD8313 operates between 0.1GHz and 2.7 GHz as
well as it can detect signals with power levels as low as -70 dBm; this specification is very suit-
able for our design because the received signal by the antenna has an extremely low power from
attenuation. In addition, AD8313 requires a low supply voltage of around 2.7 V to 5.5V which
reduces power consumption in the circuit. However, the amplifier chip only comes in surface
mount packages (8-lead MSOP), but there is a way around it by buying a surface mount to
through hole adapter (8 MSOP to DIP adapter) for prototyping and given that the chip has only 8
pins it is not as cumbersome to solder it. AD8313 needs biasing and connections around it to op-
erate; the connections shown in Figure 5 are suggested by the datasheet [6] which was used for
our design after setting RPROT to 500Ω; refer to Appendix A for the detailed circuit of the log am-
plifier as part of the complete product circuit.
!
FIGURE 5: BASIC CONNECTIONS FOR THE RSSI MODE AS SUGGESTED BY THE DATASHEET
The AD8313 is expected to produce an output voltage that varies with the input power level lin-
early via the following equation:
!
Where Slope is the line slope in V/dBm and intercept is the y interecept in dBm.
The response in Figure 6 obeys this equation. This equation will later be used by the micro-con-
troller to deduce the received signal power level from voltage level read by the micro-controller.
!
FIGURE 6: AD8313 OUTPUT VOLTAGE VERSUS POWER LEVEL IN DBM (TAKEN FROM DATASHEET [6])
SIGNAL CONDITIONING CIRCUIT
The purpose of signal conditioning circuit is to remove any noise imposed on the voltage from
the log amplifier, as well as amplify the voltage to around 3.3V (maximum input level to the mi-
cro-controller) to increase precision at the micro-controller. The signal conditioning circuit is de-
signed by the team as in Figure 7.
!
FIGURE 7: CELL PHONE DETECTOR SIGNAL CONDITIONING CIRCUIT
The circuit consists of two stages: an instrumentation amplifier and a second-order Butterworth
low pass filter. The instrumentation amplifier has two non-inverting amplifiers at the first stage
followed by a differential amplifier. The gain of such a 3 op-amp instrumentation amplifier is
given as
!
From the graph in Figure 6 we observe that the maximum voltage level will reach around 1.7V.
Although in our application the voltage level will range from 0.7V to 1V, we choose our input
voltage of 1.7V, to protect the micro-controller from over-driving in case the voltage surged to
1.7V.
Using the above equation, R1 and R2 were designed to be 1.2 kΩ, and R3 was designed to be 2.4
kΩ. A variable resistor, Rgain is used to control the overall gain of the circuit. The higher the value
of Rgain the better the output voltage becomes i.e. the closer the output voltage becomes to be-
coming perfect for the ADC, where it will go next. For example, when Rgain = 56 kΩ, the output
voltage is approximately 3.2 V, giving an approximate gain of 2.096, and thus this is the resistor
value that we will use.
In the design, we have used an operational amplifier manufactured by Microchip (MCP602) in-
stead of the traditional 741 amplifiers. This is because MCP602 amplifiers require single low DC
supply (+5V) as opposed to the dual DC supply (VCC+ and VCC-) required by other amplifiers,
as well as, there were numerous technical issues experienced by 741 amplifiers especially when
used in specialized applications such as in our case. Furthermore, MCP602 packages contain two
amplifiers in their packages, and hence they will significantly save space, and they come in
through hole as well as surface mount packages so can be utilized in both prototyping and prod-
uct manufacturing using PCB.
There are high frequency components that might affect the accuracy of our measurements for the
power level. Therefore, we designed a Low-Pass filter as our last stage with cut-off frequency of
50Hz. It will be implemented after the instrumentation amplifiers. The equation for a low-pass
filter is
!
Since Fc (cut-off frequency) is 50 Hz, we designed R4 to be 33KΩ and C1 to be 100 nF. For the
low-pass filter we choose a passive filter as opposed to an active filter because this application
doesn’t require an efficient filter and thus using an operational amplifier for the filter will in-
crease cost, power consumption and component count unnecessarily.
MICRO-CONTROLLER
The last stage of the design is the micro-controller. As mentioned earlier the antenna receives cel-
lular signals which are then converted by the log amplifier to a DC voltage level. Lastly the DC
voltage is then amplified and filtered to be fed to the micro-controller via the analog input port.
The intention of the microcontroller is to advance the detection capabilities of the device; in oth-
er words to add flexibly and accuracy to detection and thus making the device smarter. The mi-
crocontroller achieves this by reading input voltage levels via a built-in Analog to Digital Con-
verter (ADC) and the processor scans and analyzes the data to make decision regarding cell
phone detection, and accordingly inform the user through the appropriate output ports. The out-
put port will include: LED, buzzer and LCD screen. The algorithm used by the micro-controller
for accurate detection will be discussed in further details in ‘Algorithm’ section.
Besides detecting active cell-phone signals in the area, the micro-controller is capable of calcu-
lating the power of the received signal in dBm and displaying the power level to the user on the
LCD screen. The micro-controller calculates power. Furthermore, the micro-controller will be-
come more useful in future proposed features to be added to the device. These features include
phone positioning in which the position of the detected phone can be identified using wireless
network sensor (WNS) approach [8], as well as computer communication in which the device
will be able to send the results to a remote computer.
The microcontroller used is a PIC24F (PIC24FJ128GA010) manufactured by Microchip Tech-
nology. A PIC microcontroller is used because it is proven to have higher analog to digital con-
version speeds and accuracy than other microcontrollers in the market. This is important since
phone detection relies on reading a series of voltage levels and analyzing them, and hence a fast
and accurate ADC will reflect directly on the quality of detection. In addition, the PIC is cheaper
than other microcontrollers in the market with the same specifications. For the prototype, an Ex-
plorer 16 development board is used; this board houses the PIC24FJ128GA010 and has built-in
4*16 LCD screen, 8 LEDs as well as In-circuit debugger connector for the programmer.
!
ALGORITHM
The microcontroller has one input from the analog input pin that is connected directly to the
ADC. The output is then send via 2 digital output pins one connected to the LED and the other to
the buzzer, as well as output ports that are connected to the LCD screen controller. Before im-
plementing the program, an algorithm is developed for the microcontroller. The idea behind the
phone detection is that when the input voltage level exceeds a certain threshold a phone is being
detected. In addition, the microcontroller can determine if a detected phone is close when the
voltage level suddenly rises to a higher threshold than the first one. The algorithm developed is
illustrated in the flowchart in Appendix B. As illustrated in the flowchart, the input voltage is
first read by the ADC which is used to calculate the input power level in dBm using the follow-
ing equation. The calculated power level is displayed on the first row of the LCD screen.
!
Where Vin is the voltage read by the ADC
Gain is the gain of the signal conditioning circuit
Slope: is the slope of the log amp
yintercept: is the y intercept of the log amp response
Simultaneously, the input voltage is compared against a predefined threshold voltage; the pro-
gram has two thresholds one when the detected phone is close to the device (V2) and the other
when the detected phone is away from the device (V1) . If the voltage exceeds the threshold V1
for a certain time (number of samples) then a phone is detected with 90% confidence. As a re-
sponse to this the LED will turn on, buzzer will sound and a message will be displayed on the
second row of the LCD screen saying “Cell Phone Detected!”. However, if the voltage exceeded
the threshold for a very short time which is one or two time samples, then there is only a 50%
chance that a phone is detected. As a result only the LED will turn on which means that it is just
a warning to the user that a phone might be detected. If the voltage exceeds both thresholds V1
and V2 for a significant time, then a phone is detected and within a close distance to the device.
Consequently, the buzzer will sound and LED will turn on, but “Cell Phone Close!” message will
be displayed on the second row of the LCD screen. Lastly, if the voltage is below both thresholds
then no phone is detected, and thus no LED will be turned on, buzzer won’t sound and nothing
will be displayed on the second row of the LCD screen.
From the flowchart, it can be observed that for a phone to be considered as detected it should ex-
ceed the threshold for a considerable time, in order to prevent false alarms due to rapid fluctua-
tions from noise. In addition, the device is capable of differentiating whether the detected phone
is close or distant besides detecting a cellular signal. It can be noted that this feature has been
added at the end of the implementation phase after the device was established; the testing per-
formed to arrive to the algorithm regarding this feature is explained in details in the Testing sec-
tion.
SOFTWARE
The algorithm is then implemented in C code for the PIC microcontroller. The MPLABX C30
compiler was used to create a hex file which is then loaded to the microcontroller using PICKIT2
programmer. Two library files were created for this project: LCD and ADC. The LCD library is
used to provide interface to the LCD screen, namely, to initializes the registers and prints a string
on the screen. The ADC library is used to initialize and read from ADC-specific registers. The
libraries were then tested by varying the input voltage from an external circuit and observe the
voltage level on the LCD screen, shown in Figure 8 is the setup for the testing done on the li-
braries
!
FIGURE 8: TEST SETUP FOR ADC AND LCD LIBRARIES USING THE EXPLORER 16 BOARD
Apart from the LCD and ADC files, the main file is implemented where the code is run by the
microcontroller indefinitely. The main code implements the algorithm discussed in the flowchart;
Appendix B shows the c code for the LCD, ADC and main files. The first step in the code is to
initialize the I/O pins as shown below. The I/O pins include digital output pins A where A1 to A8
are connected to the built in LED and A15 is connected to the buzzer, and analog input pin 8.
AD1PCFG = 0xFFFF; // all ANs are digital I/O
PORTB =0;
AD1PCFGbits.PCFG8 = 0; //AN8 is analog
TRISA = 0;
The ADC and LCD are then initialized; initialization involves setting the appropriate registers
with the right settings.
InitADC();
InitLCD();
clrLCD();
!
In the indefinite loop, the voltage is read via the ADC; the ADC reads levels instead of voltage,
and thus the levels are converted to voltage in mV knowing that the highest attainable voltage is
3300 mV and the numbers of levels are 1024.
//Read input voltage by ADC
adc_val = ReadADC ();
__delay_ms (2);
//Convert the ADC level to voltage in mV
volt_in =(adc_val*3300)/1024;
!
The voltage is then used to calculate power in dBm and display it on the first row of the LCD
screen.
//Calculate Power in dBm
// Map voltage to input of signal conditioning
Vin = volt_in / Gain;
// Change the voltage to power in dBm via log amp
Pin = (Vin / slope ) + y_intercept ;
!
The voltage then goes through a series of comparisons with both of the thresholds, and if the
voltage exceed threshold V1 for prolonged time then a phone is detected, but if the voltage ex-
ceed threshold V2 for a prolonged time then a phone is detected and close.
if (volt_in>V1 )
{
// When voltage is more than threshold V1 turn LED on and increase
// the count it exceeded threshold V1
volt_count++;
LATA = 0xFF;
if (volt_in>V2)
{
// When voltage is more than threshold V2 increase the count it
// exceeded V2
volt_count2++;
if (volt_count2 > maxCount )
{
// If the voltage exceeded threshold V2 for more than max_count2
// then phone detected and close
// Display Phone Close on second row of LCD
putsLCD(1,1,"Phone Close!");
// Sound the buzzer (connected to pin A15)
_LATA15 = 1;
}
else
{
// If the voltage exceeded threshold V2 but not for prolonged
time
// then phone is only detected
putsLCD(1,1,"Phone Detected!");
_LATA15 = 1;
}
}
else
{
volt_count2 =0;
if (volt_count > maxCount )
{
// If the voltage exceeded threshold V1 for more than max_count
// then phone detected and away
putsLCD(1,1,"Phone Detected!");
_LATA15 = 1;
}
}
!}
else
{
// If voltage didnt exceed neither thresholds then no phone detected
// Turn LED and buzzer off
LATA= 0x0000;
// Clear second row of LCD screen
putsLCD(1,1," ");
// Reset the counts
volt_count =0;
volt_count2=0;
}
!!
In summary, the device will pass through four statuses with the following responses shown in
Table 1.
!
TABLE 1: STATUS AND OUTPUT OF THE DEVICE
DESIGN METHODOLOGY
Status LED Buzzer LCD (2 LCD (1
Phone detected for
very short time (50%
chance of detection)
ON OFF
“Power = xx
dBm”
Phone detected for
long time and far
away (90% chance of
detection)
ON ON "Phone Detected!”
“Power = xx
dBm”
Phone detected with
90% confidence and
close
ON ON "Phone Close!”
“Power = xx
dBm”
Phone not detected OFF OFF
“Power = xx
dBm”
When we first chose the project, our main question was: how do we detect the desired signal? To
that end, we decided to follow the theories that we have learnt in our classes, as well as search
for similar projects where people have worked with signal detection.
The first stage in our project was to find a way to capture the cell phone signal. The answer was
of course to use an antenna. Then depending on our need, we had to decide the specifications of
the antenna. Our antenna is a monopole whip antenna which will detect certain bands for our de-
vice.
In the last stage we had to find a way to analyze the detected signal, decide whether it is in the
intended band and alert the user that a cell phone has been detected nearby. This kind of analysis
is best done using a microcontroller. So we went ahead and found a microcontroller with an LCD
attached that will help to show the alert on display.
The middle stage is crucial in the sense that we had to decide in which way we are going to do
the detection. There are several ways to detect signal, such as detecting the power level of the
coming signal, transforming the coming RF signal into IF and processing that IF signal to use for
detection etc. We opted to go for power level detection. In this method, the frequency of the com-
ing signal from the antenna is transformed into power level according to the each frequency. We
decided to choose this method as it is less complex and therefore easier to implement than other
methods of detection. We had some help from various research papers that helped us understand
how the method works. We found a logarithmic amplifier which does this job best, so it was cho-
sen for our project.
Since to use the microcontroller we had to change the coming analog signal to digital, we real-
ized that we needed an Analog to Digital Converter (ADC) to do the conversion. We have learnt
in our classes that to do so, the coming input signal had to be conditioned so that the ADC could
work on it. So we needed to do some signal conditioning prior to the signal going in the ADC.
Based on our theories from Electronics III (ELG4139) course, we decided to go for an instru-
mentation amplifier followed by a low pass filter to do the signal conditioning, as the instrumen-
tation amplifier has a high CMRR (common mode rejection ratio) which would help us more to
keep away unwanted frequencies.
These were the train of thoughts that led us to have our present design for the project. Last, we
are working toward implementing a prototype that we will be demonstrating. We expect to proof
that with our current design, our device will be capable to correctly detect and alert the user
when a phone call is being made with a phone operating in either 1700 MHz or 19000 MHz
DESIGN CONSTRAINTS
The product is built on the assumption that it will be used in cell phones restricted area, which
means it will work in an environment where a maximum of five cell-phones signals are in use. In
addition, all the device tests will be performed on the ground and thus there will be no tests per-
formed on an airplane like environment before the deployment and shipment of the device, but
we claim that it can function in an airplane within an acceptable range of accuracy.
Detecting a wide range frequency is more useful and more needed in the market, but designing
our circuit to work with frequencies that operate at 5 GHz will be challenging, as the higher the
frequency goes, the more complicated the RF circuitry becomes, thus making it more difficult to
implement. Also, most components do not work properly at very high frequencies. Therefore, we
are planning to design our device to operate at the traditional cell-phone RF transmission fre-
quency and Wi-Fi in the 2.4 GHz band.
EXPERIMENTAL RESULTS: SIMULATION AND TEST-
ING
COMPONENT SIMULATION
Within the last two months we have also went upon testing some of the components that we or-
dered. This step was very important to verify the response of the components especially after the
changes in the design that we did. We needed simulation models that we can go back to incase
we experienced any technical problem during physical implementation.
INSTRUMENTATION AMPLIFIER
We have modeled the instrumentation amplifier circuit suggested in Figure 7 of “Detailed De-
sign” section. The aim of the model to easily go back to it to change resistor in case we wanted to
tune the gain. Figure 9 below is the simulation in Multisim of the instrumentation amplifier part
of our conditioning circuit used in our product. We calculate precisely the gain needed in order to
increase our output voltage going into the ADC to around 3.3V.
!
FIGURE 9: INSTRUMENTATION AMPLIFIER CIRCUIT IN MULTISIM
LOG AMPLIFIER
Besides the instrumentation amplifier simulation, we wanted to verify the response of the
AD8313 amplifier. In particular, the aim is to prove that the amplifier will produce a DC voltage
that follows the slope response in Figure 6. Unfortunately, it was difficult to simulate AD8313
because it doesn’t have a component in Multisim and the PSPICE model fails to simulate on Ca-
dence OrCAD. Thus, we decided to simulate a similar log amplifier, which is AD8310, that has
the same connections but operate at lower frequencies.
Figure 10 shows the Multisim model of AD8310 log amplifier circuit in RSSI mode simulated on
Multisim Component Evaluator 13.0. From Figure 11, we observe that at an output of DC volt-
age level of 2.012V was produced which was the same value interpolated from the AD8310 re-
sponse curve in its datasheet [7]. From the result, we verified that the log amplifier will in fact
produce a DC voltage proportional to the input power level.
!
FIGURE 10: LOG AMPLIFIER MULTISIM SIMULATION
!
FIGURE 11: LOG AMPLIFIERA SIMULATION OUTPUT
COMPONENT TESTING
In this step, the aim was to make sure that the log amplifier and signal conditioning circuit re-
spond to our criteria, which most importantly being able to detect our cell phone signals, as ex-
plained below, in a certain frequency range. For the log amplifier we ordered samples for two
amplifiers: AD8307 and AD8313. AD8307 has a range frequency of up to 500MHz, but we
wanted to be able to reach at least ~849MHz, which was our initial goal.
!
!
ANTENNA
We built an antenna for last semester in order to test cellular signal that will be detected, but de-
cided to buy an antenna for this semester due to problems we had with the previous antenna. The
previous antenna was only able to detect one cell phone, and from that result we made all our
calculations according to 849MHz
However, for this session we used three cell phones and none of them were around that frequen-
cy range. They used a higher frequency. Because of the changes in frequency, we could not use
AD8307 as our log amplifier. So we had to use the other log amplifier (AD8313), which re-
sponds to our criteria.
From the new log amplifier we are able to detect frequencies from 0.1 GHz to 2.7GHz. Accord-
ingly, we built a circuit and made our calculation in order to have the desired voltage at the out-
put of the AD8313 log amplifier. As shown in the Figure 6, we expect a signal between
0.7<V<1.0 at the output of our AD8313 log amplifier. We will use the output value of our log
amplifier and inject it at the input of our signal conditioning.
Moreover, from the beginning we were going to detect a frequency range of 824-849MHz from
our monopole antenna that we built last session and it was fixed on the uplink (which means only
catching signals being sent to a source). In fact, that was only from one cell phone that we tested.
But for this session, we bought an antenna which has 2 bands:
a. Band1: 824-960MHz, gain 0dbi
b. Band2: 1710-1880MHz, gain 4dbi
From the datasheet we knew that the new antenna will be more efficient than the first one, so we
first gathered information about the antenna, to make sure that we will be able to detect within
our ranges. So from that entire information gather we decided to confirm with our measurement,
by testing three different cell phones.
TEST SETUP
The test setup involves connecting the antenna directly to a spectrum analyzer. The spectrum an-
alyzer used in this experiment is ‘Rohde and Schwartz HMS3010’ that can operate at frequencies
up to 3 GHz which made it beneficial to the experiment since we are dealing with radio frequen-
cies. The spectrum analyzer input port is a SMA female which was the same as the one of the
antenna connector, and thus we bought an SMA male to male adapter for this experiment.
RESULTS
Connecting the antenna and spectrum analyzer as the test setup, calls were being made and the
results observed on the analyzer. Since we have three different phones with three different carri-
ers each operating at a band that is of interest to us, we used each of the phones for the experi-
ment. The results of conducting the experiment with each of the three phones:
i. Cell phone1: Wind mobile as its carrier and operates at 1700MHz ASM; result is shown in
Figure 12
!
!
FIGURE 12: SPECTRUM ANALYZER CAPTURE OF SIGNAL DETECTED FROM CELL PHONE 1
Once a cell is being made a spike is observe on the analyzrer as shown in Figure 12, which signi-
fies that the spike belong to the call we made and thus concluded to us that a phone call leads to
a power spike. In addition, we were able to observe from the spectrum analyzer that the cell
phone signal frequency of operation is at around 1.73520GHz as shown in Figure 12. Thus, we
confirmed that the signal is detected because it is in the frequency range of the antenna.
ii. Cell phone 2: Fido as its carrier and operates at 850/1900MHz GSM
!
!
FIGURE 13: SPECTRUM ANALYZER CAPTURE OF SIGNAL DETECTED FROM CELL PHONE 2
It can be observed from the spectrum analyzer a cell phone signal being detect at around
1.90600GHz as shown in Figure 13. From the result, it can be deduced that the signal is slightly
out of the antenna range, and hence from the spectrum analyzer the power level of the signal is
lower than cell phone 1 while making a call. Therefore, there is weak signal appearing, which is
normal due to that the signal is out of range.
iii. Cell phone 3: Chatr as its carrier and operates at 850/1900MHz GSM
!
!
FIGURE 14: SPECTRUM ANALYZER CAPTURE OF SIGNAL DETECTED FROM CELL PHONE 3
It can be observed from the spectrum analyzer results in Figure 14, a cell phone signal is detected
at around 1.90600GHz. For this case, it is the same as the cell phone2, and so the frequency of
operation is the same for both cases. It can be concluded that a strong we signal level is observed
in cellphone1 compared to cellphone2 and cellphone3, which have a weak signal level received
by the antenna. As a result, the antenna main band of operation is around 1700 MHz with the
ability to pick up signal at 1900 MHz the power level at the output of the antenna is of weaker
strength.
LOG AMPLIFIER
Besides simulating the AD8310, we wanted to ensure our log amplifier circuit works. Thus using
the circuit proposed in Figure 5, a log amplifier circuit was implemented on a breadboard as
shown in Figure 15. It is known that the breadboard is not the best choice when testing mi-
crowave circuit since it introduces noise due to parasitic; however, the breadboard was a better
option for preliminary testing that soldering the components on a Veraboard..
!
FIGURE 15:LOG AMPLIFIER CIRCUIT ON BREADBOARD
TEST SETUP
To test the log amplifier AD8313 circuit, a signal frequency from a function generator was in-
jected. The function generator used is a microwave function generator operating up to 1.1GHz of
frequency which we borrowed from Prof. Yao graduate lab. This experiment enabled us to read
the output signal of the log amplifier which is a DC voltage measured with the voltmeter. It was
were expecting to get an output from the log amplifier of a noise floor of around 0.6V, which
from that we had to differentiate with our input signal injected. Thus, the test setup involved
connecting a microwave function generator operating in the range 100MHz to 1.1GHz to the in-
put of the log amplifier circuit whose output is connected to the voltmeter.
RESULTS
We inject a frequency of 900 MHz within different input signal from -60 dBm to 10 dBm, and
read the variation in voltage from the output while changing the input and then we plot it to
compare from the plot of the datasheet. The input power level is read from the function genera-
tor and the output voltage is read from the voltmeter. The data is measured and collected at the
table below which is then plotted in the graph in Figure 16 .
!
!
!
FIGURE 16: RESULTS OF LOG AMPLIFIER TESTING
As we can see from the graph in Figure 16 and the table above, we have some similarity with
values gather from the datasheet in Figure 6, except in our case, because we were using a bread-
Input (dBm) Output (Volts)
-60 0.850
-50 0.821
-40 0.828
-30 0.865
-20 1.009
-10 1.189
0 1.377
10 1.567
board we automatically have noises added to our circuit. This is why we have some differences
of values comparing to the one from the datasheet. In general, the result in Figure 16 verifies that
the log amplifier circuit works as per specifications.
SIGNAL CONDITIONING TESTING
Based on the design described previously in the ‘Detailed Design’ section, the signal condition-
ing circuit was built in a prototype. Shown below in Figure 17 is its physical implementation.
!
FIGURE 17: SIGNAL CONDITIONING PROTOTYPE ON THE BREADBOARD
For our testing, we wanted to confirm that the circuit worked similarly to the simulation. The
main goal of the testing was to make sure that the output voltage of the circuit stays well below
3.3V. This is because the output of this circuit goes to the input of the micro controller, and our
microcontroller was unable to take in voltage above the limit of 3.3V.
Keeping that in mind, we first tested the circuit by measuring the output voltage. We had some
initial trouble with our gain (it was close to 4) which gave us a higher output voltage than de-
sired. So we recalculated and chose 56kΩ as our Rgain. This gave us a gain of approximately 2.1
which in turn produced an output voltage that was below the 3.3V limit. Once we were
INTEGRATION SYSTEM TESTING
During this testing phase we combined all the components of the circuit that has been tested in-
dividually and tested when they are integrated together to form a complete device. The system
testing was divided to two main parts; testing for phone detection where the capabilities of the
system to detect cell phone signal is tested, and testing for distance measurement where the ca-
pability of the system to distinguish between close and far phones is tested. Through this testing
phase all prototypes are carried out on a breadboard, and the power is supplied via a lab power
supply.
TESTING FOR PHONE DETECTION
The plan to test our device was simple. Since we were dealing with voltage levels to detect cell
phones, our prediction regarding detection was that, when a cell phone is being used to make a
call, send a text or use data, the voltage level would increase significantly, thus showing the user
that there is a phone in the area.
Also, we tested each component one after the other to ensure that the device worked impeccably
at each stage, and we only moved on to the next part after making sure the present one is work-
ing accurately.
Presented below is an in depth description of our testing procedures. It will be shown that the
outcome of the tests followed our predictions perfectly.
PART 1: ANTENNA AND LOG AMPLIFIER
We next connect the monopole antenna ANT-ELE-S01-006 to first stage of the circuit, the log
amplifier AD8313. Then we used voltmeters to measure the voltages at the input and output
nodes, i.e. the input and output of the log amplifier. Finally we took measurements for a period
of time to see the changes on the voltmeters
!
FIGURE 18: VOLTMETER RESULTS OF ANTENNA AND LOG AMPLIFIER TESTING
Figure 18 shows the voltmeter results at the output of the log amplifier; these are two of the
many measurements that were taken to make sure that the two components were working as ex-
pected. We first made a test without making a call and we were expecting a noise output voltage
of around 0.6V as the datasheet explained which is what we obtained as shown on the left of
Figure 18. Then we made a test making a call, we observe the voltage increasing once a call
made as shown on the right of Figure 18. The test was repeated with different cell phones to
compare signal output of difference from different company providers. As expected the output
voltage was not we the same value at each call made because each company has different fre-
quency band and the signal strength varies according to the environment and obstacle. Thus, it
can be explained why we were getting different values and also why they weren`t stable. So we
concluded that the log amplifier connected with antenna works as per our intentions.
PART 2: CONNECTING TO SIGNAL CONDITIONING CIRCUIT
The next step in the testing process is to connect the setup from previous testing to the signal
conditioning circuit where the output of the log amplifier goes to the input of the signal condi-
tioning. The same testing procedure as in the last testing has been following with the expectation
to observe a similar response as with the log amplifier.
!
FIGURE 19: VOLTMETER RESULTS FROM SIGNAL CONDITIONING CIRCUIT
In Figure 19, the pictures on the left column show the voltage results before a call being made
and the ones on the right columns shows the voltage results after a call is made. The top voltages
are from the output of the signal conditioning circuit, the bottom ones are from the output of the
log amplifier circuit. The results at the bottom of Figure 19, that shows the output of the log am-
plifier, are the same as the testing is part 1. In addition, the results at the output of the signal
conditioning demonstrates the same response in which a there is significant voltage increase
when a call is being made. However, the values out of the conditioning circuit are higher due to
the amplification undergone by the instrumentation amplifier. Therefore, the results matched our
expectations and that verifies that the signal conditioning circuit works correctly.
!
!
PART 3: CONNECTING THE MICROCONTROLLER
As per this step, it was proved that the circuit implementation works as expected, however we
want to verify that the microcontroller works as part of the system. The microcontroller is con-
nected to the rest of the circuit where the signal conditioning circuit output (from LPF) goes into
the input of the microcontroller, which is analog input pin AN15.
As discussed in ‘Detailed Design’, the microcontroller detects if a phone call is being made by
comparing the incoming input to a threshold level of voltage. If the incoming signal is higher
than the threshold, then the micro controller “detects” a phone nearby.
The value of the threshold was found through experimentation. By making a large amount of
calls, we checked how high the voltage level rises for each call. Then, an average of these values
was chosen, above which if the voltage level rose then it guaranteed that the level was high
enough to be sure that a call was being made. That value was used as a threshold in the micro-
controller; this value was chosen around 1.6 V. However, the value was continuously tweaked to
improve performance.
After determining the correct threshold value and editing the code to match such improvement,
the output was observed on the microcontroller as shown in Figure 20.
!
FIGURE 20: MICROCONTROLLER OUTPUT AT PHONE DETECTION
The microcontroller displays the message “Phone Detected!” on the LCD screen and the LEDs
light up. Also, a buzzer is attached to the device which sounds whenever a phone has been de-
tected. In addition, the power level of the input signal is shown on the first row of the LCD
screen.
TESTING FOR DISTANCE OF PHONE
Following testing the system, we wanted to add a feature such that the device can differentiate if
the phone detected is close to the device. To add such a feature an experiment was carried out
using three different phones, and numerous calls were made from them with the experiment re-
peated at two distances 0m from the device and 1.25m from the devie. The output was recorded
via a voltmeter connected to the output of the circuit that is fed to the microcontroller. During
each of the experiments the variation of the voltage level at two different distances were noted
and recorded.
!
FIGURE 21: VARIATION OF VOLTAGE WITH DISTANCE
The data was then plotted in graphs for comparison, shown in Figure 21 above is the result from
one of the phones. The blue line shows the voltage level when the phone is right near to the an-
tenna (i.e. 0 meters away) and the red line shows the voltage level when it’s approximately 1.25
meters away from the antenna of our device. As it can be seen, there is a clear difference between
the two levels. From this experiment, we observed that our device can detect if a phone is next to
the device or some distance away. Consequently using the data plotted, we extracted a second
threshold than can be used for distance differentiation (V2) which from the result is apparent to
be 2.2 V. The microcontroller code was then edited to add the distance detection feature. Another
observation from the results is that the probability that a phone is detected when a call is made
decrease beyond a certain distance, after that distance the quality of detection decrease and con-
tinues to decrease as we move further away until the capability of detection vanishes. From the
result, it can be concluded that the device best operation between 0m and 1.25 meters, and the
device can detect up to 11m.
PHYSICAL IMPLEMENTATION AND PROTOTYPE
From the experimentation and testing, it have been verified that the complete system works as
expected. Thus, the next step was to import this circuit to a prototype. For prototyping, we had
two options: a PCB and a Veraboard; the PCB seemed like the best choice but since it was the
first time to do a layout the risk was higher. Although, the PCB layout development was executed
and started already we opted for soldering the components on a Veraboard because it will give us
extra time to add another feature which is the distance detection in our case. For the Veraboard
we found a type of board that is connected from the back horizontally and thus will reduce the
need to connect components with wires making it as close as possible to a PCB. The signal con-
ditioning and log amplifier circuits were soldered on the Veraboard and the board is shown in
Figure 22.
!
!
FIGURE 22: CIRCUIT SOLDERED ON VERABOARD
During testing the power supply was used as a voltage source, but in thus phase the power supply
was replaced with battery in a battery holder with a switch to make it portable. The antenna is
connected to the circuit through an SMA connector soldered to the circuit. Before connecting the
circuit to the microcontroller, the output voltage and all pins in the circuit were measure to make
sure they correspond to our expected values observed during system and component testing.
After testing the soldered circuit, it was connected to the microcontroller input pin AN15. The
connection to the microcontroller is done through a breadboard that can be hooked to the exten-
sion board and has header pins for each of the I/O pins. Figure 23 shows the prototype after con-
necting the soldered circuit to the microcontroller.
!
FIGURE 23: PROTOTYPE CIRCUIT CONNECTED TO MCU
The system in Figure 23was then tested by connecting the output to a voltmeter, making numer-
ous calls, and observing the output on the microcontroller and voltmeter. Unfortunately, the out-
put from the system was not stable and it was deduced that it is due to interference affecting mi-
crowave part of the circuit. In order, to shield the circuit we suggested to put the circuit in a met-
al enclosure, as shown in Figure 24, which will prevent interference and can act as a ground
plane to the antenna. Following this step, the prototype of the device which will be used for
demonstration and proof of concept is shown in Figure 25.
!
FIGURE 24: CIRCUIT IN THE METAL ENCLOSURE
!
FIGURE 25: PHYSICAL APPEARANCE OF FINAL PROTOTYPE
DEVICE OUTPUT
The device passes through four different situations as shown in Table 1; our aim is to recreate
these 4 statuses and verify that the output is within the expected responses. Before turning the
battery on the LCD will show “Turn Battery On”, which is a precaution for us to remind us when
a battery is on or off. This situation and its output is shown in Figure 26.
!
FIGURE 26: DEVICE OUTPUT WHEN BATTERY IS OFF
Once the battery is turned on, the device will display received power strength in dBm on the
LCD as shown below
!
When a phone call is made and is placed beside the device, the device shows the following mes-
sage on the LCD: “Phone close!” as shown below. In addition to that, the LED (shown at the bot-
tom of the picture) will turn on and the buzzer will sound.
!
As the phone making the call moves farther from the device to around a distance of 1.25 meters
away from the antenna, then the LCD displays: “Phone detected” instead of “Phone Close” as
shown below, thereby showing that a phone is being detected but it is not right near to the device.
In this case, the LED will also be turned on and the buzzer will sound.
!
PRECAUTIONARY MEASURE
As an extra feature against errors, the device has a warning sign. To make sure that the device is
actually detecting a phone and not just some random signal, the micro-controller of the device
samples the incoming signals three times. If the micro controller samples two inputs one after the
other, it is taken as a sign that there may or may not be a phone nearby. At this point, the buzzer
doesn’t ring and the LCD doesn’t display anything. Only the LEDs light up as a warning to the
user as shown below
!
However, if right after the two inputs the microcontroller samples a third input, then it is taken as
a sure sign of detection, in which case the LCD displays one of the aforementioned messages and
the buzzer rings.
DETECTION FOR TEXT MESSAGES AND DATA
When sending a text, the device detects the phone while the text is being sent. As it doesn’t take
too long to send a text, the device can detect it for only a couple of seconds. In addition, the de-
vice can detect if a phone is using the internet via a phone data network.
PROJECT WORK DISTRIBUTION
Work has been divided upon team members based on their knowledge and academic background.
The design of this product requires knowledge in mostly RF circuitry, electronic components
such as microprocessor, and experience in antenna design. Apart from engineering expertise,
some knowledge in business studies is also helpful to understand the business prospect of the
project. The members of this project have various backgrounds that accommodate the division of
responsibility agreeably, not to mention that they are all currently studying their Bachelor of Sci-
ence in Electrical Engineering.
!
Because of her knowledge in RF and C programming, Nourhan Eid was in charge of designing
the device system and suggesting how the main blocks of the circuits should work. In addition,
she was responsible for implementing the microcontroller software.
!
Since they both had taken a course on antenna design, Tilly Ndjiapanda, worked on designing
and testing the antenna part. This required coming up with a basic design for the antenna to con-
duct the experiment with. In addition, she build and tested the log amplifier circuit.
!
Nabila Fairuz Rahman being the team leader of the project, was also responsible for organization
of duties and workloads. She had to keep an eye out for deadlines and regularly update the team
about how the work is going. Moreover, due to her electronics discipline she worked along with
Vladimir Francois on designing and simulating the signal conditioning circuit.
!
Vladimir Francois was in charge of the business aspect of the project. He was responsible for
coming up with a well prepared business proposal that specifies the reasons behind doing this
project and why it will be a worthy project financially. He created a budget with price assump-
tions that gave an idea of how much the design would cost. Apart from that, he was also in
charge of overall formatting of the reports and presentations. Apart from working with Nabila on
the signal conditioning circuit, he soldered the circuit on the Veraboard.
!
All other tasks were divided between team members; the following table, Table 2, shows the de-
tailed work distribution between team members.
!
!
!
!
!
!
Tasks
Nabila Rahman
(Team Lead)
Nourhan Eid
Vladimir
Francois
Tilly
Ndjiapanda
Overall research 30% 30% 10% 30%
Main system design 0% 100% 0% 0%
Antenna testing 0% 0% 0% 100%
Log amplifier design,
implementation,
verification
0% 0% 0% 100%
Signal conditioning
research and design
60% 0% 40% 0%
Signal conditioning
implementation and
verification
60% 0% 40% 0%
!
!
TABLE 2: WORK DISTRIBUTION
!
!
BUSINESS PROPOSAL
BUSINESS DESCRIPTION
Micro-controller
coding and
verification (for
detection) and distance
measurement)
0% 100% 0% 0%
Micro-controller
coding and
verification (for
distance measurement)
0% 100% 0% 0%
Business case 0% 0% 100% 0%
Team management and
organization
100% 0% 0% 0%
Circuit soldering 0% 0% 65% 35%
Various testing (testing
for detection, distance,
accuracy etc)
25% 25% 25% 25%
Our product is a cell phone detector that can detect any device operating within a range from 1.7
GHz to 1.9 GHz. Specially; it allows users to detect precisely within a diameter of 11 meters any
cell phones receiving a call, making a call, receiving a text message or sending texts messages,
as well as being able to display information on whether the phone is close or far away from our
device. Our Cell phone detector is portable, reliable and less expensive compared to other similar
products in the market.
TRAITS AND FEATURES FOR OUR SUCCESSFUL PRODUCT
In the industry, there are traits which are used as guidelines on whether a product will be success-
ful in the market or not. And, after extensive research and investigation, we have come to the
conclusion that our device is an engineering innovation which meets the three main requirements
of a successful product.
• Novelty: Our cell phone detector has a specific and original design system compare to
the other similar devices in the market which are not flexible or portable and three to four
times more expensive than ours.
• Usefulness: Our device can help fighting industrial Espionage, counterterrorism, inap-
propriate transmission in casino, workers in hazardous areas distracted and student who
are cheating during tests and exams by using cell phones.
• Profitability: We have built for our product a cash flow analysis which present the detail
strategy on how we are going to make a name for our product in the market and as well
as an exponential business model progression. We assume, we can find an investment or
borrow $ 100, 000 dollars to start a company with 6 people. And, by the end of 15 years,
the company can have a net present value of cash flow of over $ 6,000,000 dollars, while
paid off all debt.
THE COMMERCIALIZATION PROCESS
Commercialization of a product requires fulfilling the following criteria:
1. Launching time
Factors such as market conditions, more time for improvement of product, or potential eclipsing
of sales of other products are important to when it comes to determining the time of launch.
Keeping this in mind, it can be seen that the present time is perfect to launch our device, or at
least a basic version of it. With different types of organizations trying to secure their buildings
from spying eyes, now is a ripe time to introduce our device. Cell phones are the most common
way of disregarding privacy, and our device works to help prevent cell phone usage.
2. Potential customer
Research and marketing are used to identify primary consumer groups. The ideal primary con-
sumer group should consist of innovators, early adopters etc. This ensures adoption by other
buyers in the market during the product-growth period.
Based on this, we came up with a list of potential primary customers:
• Government offices: Many offices contain places that have sensitive data and facts that
should not be leaked out. A device that can detect cell phones would come pretty handy
in these places to detect if cell phones are being used to compromise these data.
• Airlines: Passengers on a plane are not allowed to use cell phones, but often people don’t
pay attention to this rule. With our device, the cabin crew can find out if anyone is using
phones and stop them from doing so.
• Educational Institutions: Exams halls and classrooms are supposed to be free from call
phone usage. Our device can make sure students are not using cell phones to cheat in ex-
ams.
A whole list of potential customer will be stated in next section.
Apart from applied use of our product, we believe it can also be used in various research and ex-
periments. Our device shows the power of the incoming call. And by knowing the power of a
signal, much information can be gathered from it. So we believe that this can help in different
researches.
LAUNCH METHOD
An action plan should be proposed by addressing the issues talked above. A marketing strategy
has to be developed to launch the product.
MARKETING STRATEGY
The following are the steps that will be adopted to market our product
1. Concentrate our resources on optimal opportunities to increase sales and achieve a sustain-
able competitive advantage
2. Initially low price to rapidly capture sales and market share
3. Retail channels and direct sales
4. Media Campaign
TARGETED MARKET AND CUSTOMERS
In order to justify that our product will make a successful business model, we have carried out a
market research. In this section we are presenting our market and customers that we have con-
cluded from our research.
MAIN CUSTOMERS
The following is the list of the main customers that we are expecting to sell our product to:
• Government’s institutions
• Military bases
• Casinos
• Airlines
• Education institutions
• Pharmaceutical companies
• Hobby enthusiasts
• Private wireless security companies that are in need of enforcing their cell-phones usage
policies
TARGETED MARKET: NORTH AND SOUTH AMERICA, EUROPE, ASIAAND AFRICA
!
FIGURE 27: PLACES WHERE CELL PHONE DETECTORS ARE SOLD WORLWIDE
(SPECIALLY- EXAMPLE FOR CUSTOMERS IN NORTH AMERICA)
Given the list of customer we mentioned earlier, we present below the number of our customers
in groups. This helped us to determine the market share that our product may have in North
America:
!
● Hobby enthusiast person 100 000
● Total Number of colleges and universities in North America 3000
● Total Number of Military Bases
400
● Total Government institutions with restricted areas
500
● Total pharmaceutical companies 100
● Private Businesses
1000
According to the Association of American Colleges and Universities there are two thousand six
hundred eighteen accredited four-year colleges and universities in the Unites States.
GROWTH TRENDS IN THIS BUSINESS, PRICING POWER, MEAN
TIME BETWEEN FAILURES
Governments, educational institutions and private businesses are in need for a reliable product
which can allow them to enforce their cell phones restricted areas policies. We have identified
this market and implemented a cell phone detector which is very efficient in detecting any cell
phone being used in unauthorized areas.
The growth in our business will base on the fundamental economics’ theory which is: Decreasing
the price or keeping it stable; the demand will increase. Also, we will keep improving our device,
so we can keep selling more quantity to our customers and make new customers at the same
time.
The mean time between failures (MTBF) for our device is the estimated elapsed time between
inherent failures of our product during operation. We calculated it to be 4 years based on the
components we are intended to use to build our device. Below is a graph of how to calculate the
MTBF.
!
!
PROJECT COST ESTIMATE AND CASH FLOW ANALYSIS
Our project cost estimate is determined based on the components that we have used to build our
device.
!
PROJECT COST ESTIMATE
The following includes the quantity and the price of essential the components for our project:
Product Quantity = 1 Cost ($)
!
Log-amplifier (AD8313) (Sample / Free)
Monopole antenna (ANT-ELE-S01-006)
$
4.17
Magnetic base for the antenna $7.63
Micro-controller (PIC24F) (Borrowed from Lab)
Antenna adapter $1.79
BPS StripBoard-3U (Prototype Board) $13.99
Operational Amplifiers (x5) (MCP602) $3.80 ($0.76/ea)
Buzzer $2.00
Total = $33.38
!
Now, we are going to present in details the economic feasibility of our project. We use an excel
spreadsheet to elaborate a cash flow analysis table with a loan of $100,000 and payback period is
15 years.Each column of the resulting table corresponds to one year of operation, and each row
accounts for a contributing factor to analyze our business.
This technique is one of the most flexible and powerful ways to analyze an investment and study
the economic feasibility of a business. It takes into account some complicating factors such as
tax-deductible interest 8%, salaries $ 300,000 available, rent 3,000, number of units sold 1000
units first year and 1,500 for each year during the next 14 years, the price per unit $ 400, the net
income, the cash flow and the most important the total profit we can make in the end of the 15
years of operation.
On the table 1 above, we assumed for the first year we will sell 1000 units, and unit cost $120 to
be made and the unit price is $ 400. We can see clearly, our total revenue for that first year will
be $ 400,000; our direct costs $ 120,000 and our gross margin $280, 000 which result in a lost in
the net income of - $27,000 the first year. However, during the subsequent years, we assumed
our units sold will pass from 1000 to 1500 units and that we will result in an average net income
of $79,000 and an average cash flow of approximately $73,000 after salaries, rent and opera-
tional costs deducted. And, by year 3, we can see our revenue is approximately $ 1,800,00 dol-
lars and by year 8, our revenue is over $ 2,000, 000 dollars
Finally, we assume that we will be able to sell 22, 000 units during 15 years and open an account
with an interest rate of 4% to put the cash flow of each year; the total future value is expected to
be over $ 6,000,000 as a present value of our cash flow and our initial loan balance
will be $ 0.
!
!
DESCRIPTION
Identify all business risks that may compromise our success. A risk is a factor or event that may
jeopardize our company from achieving the anticipated benefits or increase the cost production.
The following are the examples of our business risks:
• Legislative changes
• Insufficient training
• Inadequate communication
• Conflicting priorities
• Lack of Experience: Due to the inexperience in management and entrepreneurship
• Inability to free-up critical business resources
!
Taking into account all these risks and other possible undesired situations which may come up,
we feel confident in our product and our business model will be able to grow.
PROJECT RISKS AND ASSUMPTIONS
The reason for writing the Project Risk Assessment is to provide an understanding of the risks
that are related to the project and how these risks may vary.
DESCRIPTION
Identify all project risks that may relate to the project. A risk is a factor or event that may jeop-
ardize the project from achieving the anticipated benefits or increase the cost of the project. The
following are the examples of the project risks:
• Programming: Most of the project designers have little to none experience in program-
ming microcontrollers and hence, Schedule may be affected by this.
• Lack of Experience: Due to the inexperience in using and operating electrical compo-
nents we might cause some damage to the components and might have to reorder compo-
nents which may affect our schedule.
• Inability to free-up critical business resources
Lastly we will create our proposed product based on the assumptions that the implementation
part will be completed on time, and we will maintain the level of commitment that we have now.
CONCLUSION
Different scenarios prove how people misuse their mobile phones. It is clear that the need for a
good cell phone detector is essential in many places to protect privacy and security. But when
enquires were carried out, it seemed that cell-phone detectors are expensive to obtain. Also, they
have other problems that could cause hindrance, such as lack of portability, and use of more dis-
crete components in the circuitry that was harder to debug.
We felt there was a need to come up with a better alternative, thereby coming up with the idea of
this project. The proposition was to design and build a cell-phone detector that will have the de-
sirable features of both of the previously mentioned products, but also make it less expensive and
more flexible to user needs.
In light of these requirements we proposed a design that is based on the idea of using a sudden
increase in the power level of received cellular signal as an indication of a phone detected. In ad-
dition, our proposed design incorporated a microcontroller to add a accuracy and novelty to our
product.
The circuit was then tested on the component and system scale. From the results, we were able to
verify that our device meets the set requirements. Moreover, we were able to add a feature such
that the device can tell when a the detected phone is close. Lastly, as per that date we were able
to implement the device physically and demonstrate it. Therefore, we have confidence that we
are able to create a cell phone detector that is a better option than other competitors in the mar-
ket.
Given the milestone that we have reached to that date, we are planning to take our device to the
next step and commercialize it. This included finding the potential market for our device and
building a strong business case as well as a financial plan.
!
REFERENCES
[1] C. Paslay, “Teens and Cell-phones: Some Startling Statistics”. Internet: http://chalkandtalk.-
wordpress.com/2009/11/27/teens-and-cellphones-some-startling-statistics-2/ [November 2007]
[2] “The Zone Protector Cellular, WiFi and Mobile Device Detection.” Internet: http://www.-
cellbusters.com/zone-detector-the-ultimate-in-cell-phone-detection/ [September 2013]
[3] “Wolfhound Pro Cell phone detector.” Internet: http://www. bvsystems.com/Products/Securi-
ty/Wolfhound-Pro/wolfhound-pro.htm#specs [September 2013]
[4] Analog Devices Inc, “Log Amp Basic” “Internet: http://www.analog.com/static/imported-
files/tutorials/MT-077.pdf”, 2007 MT-077 Tutorial.
[5] ARPN Journal of Science and Technology [Online], Vol. 2, No. 1, January 2012, ISSN 2225-
7217
[6] Analog Devices Inc, “0.1 GHz to 2.5 GHz 70 dB Logarithmic Detector/Controller”, AD8313
datasheet, 2004 [Rev D]
[7] Analog Devices Inc, “Fast, Voltage-Out, DC to 440 MHz, 95 dB Logarithmic Amplifier”
AD8310 datasheet, 2005-2010 [Rev F]
[8] F. Viani, L. Lizzi, P. Rocca, M. Benedetti, M. Donelli and A. Massa, “Object tracking
through RSSI measurements in wireless sensor networks”, IEEE Xplore, Vol. 44, No. 10, 8th
May 2008
[9] J.T. Cohen et al, “Cellular Phone Use While Driving: Risks and Benefits”, Harvard Center
for Risk Analysis, Harvard School of Public Health, Boston, Massachusetts
[10 ] C. Masters, “Cell-Phones in Hospitals: Bad Prescription” Internet: http://www.time.com/
time/health/article/0,8599,1659417,00.html [September 2007]
APPENDIX A
CELL PHONE DETECTOR CIRCUIT
!
!
!
!
!
!
!
APPENDIX B
FLOWCHART OF PIC24F (MCU) PROGRAM
!
!
!
!
!
!
!
!
!
C CODE OF PIC24F (MCU) PROGRAM
The following is the C code implemented to be used with the microcontroller.
MAIN.C
/
*****************************************************************************
*/
/* Main FUNCTION FOR PIC24FJ128GA010
* Author: Nourhan Eid
* Date: 10 November 2013
*/
/
*****************************************************************************
*/
/
*****************************************************************************
*/
/* Files to Include
*/
/
*****************************************************************************
*/
//#include <stdint.h> /* Includes uint16_t definition
*/
//#include <stdbool.h> /* Includes true/false definition
*/
#include <stdio.h>
#include <stdlib.h>
!
#include "system.h" /* System funct/params, like osc/peripheral config
*/
#include "user.h" /* User funct/params, such as InitApp
*/
#include "LCD.h"
#include "ADC.h"
!
/
*****************************************************************************
*/
/* CONFIG */
/
*****************************************************************************
*/
_CONFIG1( JTAGEN_OFF & GCP_OFF & GWRP_OFF & COE_OFF & FWDTEN_OFF & ICS_PGx2)
_CONFIG2( FCKSM_CSDCMD & OSCIOFNC_OFF & POSCMOD_XT & FNOSC_PRI)
!
/
*****************************************************************************
*/
/* Global Variable Declaration
*/
/
*****************************************************************************
*/
const unsigned int ADC_channel = ADC_CHANNEL;
const unsigned int REF_volt = REF_VOLT;
const unsigned int maxCount =3;
const unsigned long V1 = 1470; //mV threshold voltage for far phone
const unsigned long V2 = 2200; //mV threshold voltage for close phone
const double Gain = 2.096; //linear gain
const double y_intercept = -100; //Y interecept of log amp (-100) dBm
const double slope = 17.5 ; //slope of log amp 17.5 mV/dBm
unsigned long adc_val;
long volt_in;
long volt_count;
long volt_count2;
char msg[16] = "Power: dBm";
char msg2[15];
!
/
*****************************************************************************
*/
/* Main Program
*/
/
*****************************************************************************
*/
!
int main(void)
{
int inum;
double Vin,Pin ;
volt_count = 0;
volt_count2 = 0;
/*
* I/O Pin Configurations
*/
AD1PCFG = 0xFFFF; // all ANs are digital I/O
PORTB =0;
AD1PCFGbits.PCFG8 = 0; //AN8 is analog
TRISA = 0;
!
/*
* Initialization
*/
InitADC();
InitLCD();
clrLCD();
__delay_ms(3);
!
while(1)
{
//Read input voltage by ADC
adc_val = ReadADC ();
__delay_ms (2);
//Convert the ADC level to voltage in mV
volt_in =(adc_val*3300)/1024;
clrLCD();
homeLCD();
!
//If Voltage is very low then circuit not operating and battery is
Off
if (volt_in<1000)
{
putsLCD(1,1,"Turn Battery on..");
}
else
{
//Calculate Power in dBm
// Map voltage to input of signal conditioning
Vin = volt_in / Gain;
// Change the voltage to power in dBm via log amp
Pin = (Vin / slope ) + y_intercept ;
!
//Change the value to a string to be displayed on LCD
if (Pin<0)
{
msg[6] ='-';
Pin = Pin *-1;
}
!
inum = (int)(Pin /10);
msg[7] = inum+48;
inum = ((int)(Pin) %10);
msg[8]= inum+48;
msg [9] = '.';
inum = ((int)(Pin*10)%10);
msg[10]= inum+48;
inum = ((int)(Pin *100)%10);
msg[11]= inum+48;
__delay_ms(1);
!
//Display on LCD
putsLCD(1,1,msg);
}
__delay_ms (2);
!
//Move LCD cursor to second row
cmdLCD (0xC0);
if (volt_in>V1 )
{
// When voltage is more than threshold V1 turn LED on and in-
crease
// the count it exceeded threshold V1
volt_count++;
LATA = 0xFF;
if (volt_in>V2)
{
// When voltage is more than threshold V2 increase the count
it
// exceeded V2
volt_count2++;
if (volt_count2 > maxCount )
{
// If the voltage exceeded threshold V2 for more than
max_count2
// then phone detected and close
// Display Phone Close on second row of LCD
putsLCD(1,1,"Phone Close!");
// Sound the buzzer (connected to pin A15)
_LATA15 = 1;
}
else
{
// If the voltage exceeded threshold V2 but not for pre-
longed time
// then phone is only detected
putsLCD(1,1,"Phone Detected!");
_LATA15 = 1;
}
}
else
{
volt_count2 =0;
if (volt_count > maxCount )
{
// If the voltage exceeded threshold V1 for more than
max_count
// then phone detected and away
putsLCD(1,1,"Phone Detected!");
_LATA15 = 1;
}
}
!
}
else
{
// If voltage didnt exceed neither thresholds then no phone de-
tected
// Turn LED and buzzer off
LATA= 0x0000;
// Clear second row of LCD screen
putsLCD(1,1," ");
// Reset the counts
volt_count =0;
volt_count2=0;
}
__delay_ms(1000);
}
!
return (EXIT_SUCCESS);
}
!
LCD LIBRARY
/*
** LCD.h
**
* Author: Eid
*
* Created on November 9, 2013, 2:48 AM
*/
!
#ifndef LCD_H
#define LCD_H
!
/* Device header file */
#include "user.h"
!
#define HLCD 16 // LCD width = 16 characters
#define VLCD 2 // LCD height = 2 rows
!
#define LCDDATA 1 // address of data register
#define LCDCMD 0 // address of command register
!
void InitLCD( void);
void writeLCD( int addr, char c);
char readLCD( int addr);
!
#define putLCD( d) writeLCD( LCDDATA, (d))
#define cmdLCD( c) writeLCD( LCDCMD, (c))
!
#define clrLCD() writeLCD( LCDCMD, 1); __delay_ms(1)
#define homeLCD() writeLCD( LCDCMD, 2)
!
#define setLCDG( a) writeLCD( LCDCMD, (a & 0x3F) | 0x40)
#define setLCDC( a) writeLCD( LCDCMD, (a & 0x7F) | 0x80)
!
#define busyLCD() ( readLCD( LCDCMD) & 0x80)
#define addrLCD() ( readLCD( LCDCMD) & 0x7F)
#define getLCD() readLCD( LCDDATA)
!
void putsLCD( int row,int col, char *s);
!
#endif /* LCD_H */
!
/
*****************************************************************************
*/
/* LCD.c : LCD library
* Author: Nourhan Eid
* Date: 9 November 2013
*/
/
*****************************************************************************
*/
//#include <p24fxxxx.h>
#include "LCD.h"
!
void InitLCD( void)
{
// PMP initialization
PMCON = 0x83BF; // Enable the PMP, long waits
PMMODE = 0x3FF; // Master Mode 1
PMAEN = 0x0001; // PMA0 enabled
// init TMR1
//T1CON = 0x8030; // Fosc/2, 1:256, 16us/tick
!
// wait for >30ms
__delay_ms (32); // 2000 x 16us = 32ms
//initiate the HD44780 display 8-bit init sequence
PMADDR = LCDCMD; // command register
PMDIN1 = 0b00111000; // 8-bit interface, 2 lines,5x7
__delay_us (48); // 3 x 16us = 48us
PMDIN1 = 0b00001100; // disp ON, cursor off, blink off
__delay_us (48); // 3 x 16us = 48us
PMDIN1 = 0b00000001; // clear display
__delay_us(1600); // 100 x 16us = 1.6ms
PMDIN1 = 0b00000110; // increment cursor, no shift
__delay_us(1600); // 100 x 16us = 1.6ms
} // InitLCD
!
!
char readLCD( int addr)
{
int dummy;
while( PMMODEbits.BUSY); // wait for PMP to be available
PMADDR = addr; // select the command address
dummy = PMDIN1; // initiate a dummy read cycle
while( PMMODEbits.BUSY); // wait for PMP to be available
return( PMDIN1); // read the status register
!
} // ReadLCD
!
!
void writeLCD( int addr, char c)
{
while( busyLCD());
while( PMMODEbits.BUSY); // wait for PMP to be available
PMADDR = addr;
PMDIN1 = c;
} // WriteLCD
!
void putsLCD(int row,int col, char *s)
{
int i;
cmdLCD(6); //Increment cursur
__delay_ms(1);
if (row<=2 && col<=16){
if (row==2){
cmdLCD (0xC0);
__delay_ms(1);
}
i=1;
while (i< col){
putLCD(32);
__delay_ms(1);
i++;
}
}
while( *s) {
putLCD( *s++);
__delay_ms(1);
}
} //putsLCD
!
ADC LIBRARY
/*
* File: ADC.h
* Author: Eid
*
* Created on November 9, 2013, 2:48 AM
*/
!
#ifndef ADC_H
#define ADC_H
!
#include "user.h"
!
#ifdef __cplusplus
extern "C" {
#endif
!
!
!
!
#ifdef __cplusplus
}
#endif
!
void InitADC ();
//unsigned int ReadADC (unsigned int ch);
unsigned long ReadADC (void);
!
#endif /* ADC_H */
!
/*
* File: ADC.c
* Author: Eid
*
* Created on November 9, 2013
*/
!
#include <stdio.h>
#include <stdlib.h>
!
#include "ADC.h"
!
// initialize the ADC, select Analog input pins
void InitADC( void)
{
/* AD1CON1 = 0x00E0; // auto convert after end of sampling
AD1CSSL = 0; // no scanning required
AD1CON3 = 0x1F3F; // max sample time = 31Tad, Tad = 2 x Tcy
AD1CON2 = 0; // use MUXA, AVss and AVdd are used as Vref+/-
AD1CON1bits.ADON = 1; // turn on the ADC*/
!
AD1CON1 = 0x80E4; //Turn on, auto sample start, auto-
convert
AD1CON2 = 0; //AVdd, AVss, int every conversion,
MUXA only
AD1CON3 = 0x1F05; //31 Tad auto-sample, Tad = 5*Tcy
AD1CSSL = 0; // no scanning required
AD1CHS = ADC_CHANNEL;
!
_TRISB8 = 1;
_LATB8=0;
!
// Explorer 16 Development Board Errata (work around 2)
// RB15 should always be a digital output
_LATB15 = 0;
_TRISB15 = 0;
} // InitADC
!
!
// sample/convert one analog input
unsigned long ReadADC(void)
{
unsigned long Result;
//AD1CHS = ADC_CHANNEL; // select analog input channel
//AD1CON1bits.SAMP = 1; // start sampling, automatic conversion
will follow
while (!AD1CON1bits.DONE); // wait to complete the conversion
Result = (long) ADC1BUF0; // read the conversion result
return Result;
} // readADC
!
!
!
!
!
APPENDIX C
GANTT CHART AND PROJECT SCHEDULE
Gantt chart for the implementations phase:
!
Project Schedule (For the year 2013, during the months of September to December):
TASKS Start Date Duration (Days) End Date
Component
Ordering and
finishing last
minute design
details
03-Sep 22 24-Sep
Setback - Transition
to New design -
Design Stage and
New Component
Ordering
25-Sep 21 15-Oct
Circuit
Implementation
16-Oct 11 26-Oct
Component testing 27-Oct 10 05-Nov
Partial System
Testing 06-Nov 10 16-Nov
Full System Testing
17-Nov 10 26-Nov
Distance
Measurement
Testing
27-Nov 6 02-Dec
!
!
The presentation and demonstration date was on December 3rd, 2013. The deadline to finish the
work was December 2nd, 2013. As per the chart, it can be seen that despite a setback, the work
was finished on time. Moreover, an important milestone was achieved by December 3rd ,2013
when we managed to demonstrate a working prototype for our device.

!

More Related Content

What's hot

Cell Phone Detector Presentation
Cell Phone Detector Presentation Cell Phone Detector Presentation
Cell Phone Detector Presentation
Hitesh Kumar Singh
 
Mobille phone detector
Mobille phone detectorMobille phone detector
Mobille phone detectorJitendra Malav
 
Cell Phone Detector
Cell Phone DetectorCell Phone Detector
Cell Phone Detector
elprocus
 
Project work (2014-2015)1
Project work (2014-2015)1Project work (2014-2015)1
Project work (2014-2015)1mukthar mohamed
 
Project report of Cell phone detector circuit
Project report of Cell phone detector circuitProject report of Cell phone detector circuit
Project report of Cell phone detector circuitMoin Aman
 
MINI PROJECT ON CELLPHONE DETECTOR
MINI PROJECT ON CELLPHONE DETECTORMINI PROJECT ON CELLPHONE DETECTOR
MINI PROJECT ON CELLPHONE DETECTOR
Prannoy Chakravarthi
 
DESIGN & WORKING OF A MOBILE PHONE DETECTOR
DESIGN & WORKING OF A MOBILE PHONE DETECTORDESIGN & WORKING OF A MOBILE PHONE DETECTOR
DESIGN & WORKING OF A MOBILE PHONE DETECTOR
pgayatrinaidu
 
Mobile phone detector
Mobile phone detectorMobile phone detector
Mobile phone detector
Sumedh Vartak
 
A project report_at_cell_phone_detector - copy
A project report_at_cell_phone_detector - copyA project report_at_cell_phone_detector - copy
A project report_at_cell_phone_detector - copy
Pranoosh T
 
Cell phone detector
Cell phone detectorCell phone detector
Cell phone detector
Madhusudan Sharma
 
Mobile sniffer
Mobile snifferMobile sniffer
Mobile sniffer
Rincy Ben
 
Cellphone signal detector and jammer ppt
Cellphone signal detector and jammer pptCellphone signal detector and jammer ppt
Cellphone signal detector and jammer ppt
Amar Raj
 
Hidden Active Cell Phone Detectorv
Hidden Active Cell Phone DetectorvHidden Active Cell Phone Detectorv
Hidden Active Cell Phone Detectorv
Edgefxkits & Solutions
 
Mobile phone detector
Mobile phone detectorMobile phone detector
Mobile phone detectorKundan Kumar
 
Smart Autonomous Mobile detector Robot
Smart Autonomous Mobile detector RobotSmart Autonomous Mobile detector Robot
Smart Autonomous Mobile detector Robot
Punit Tiwari
 
Cell phone detector
Cell phone detectorCell phone detector
Cell phone detector
JAYASHRI NARAYANAN
 
Mobile sniffer
Mobile snifferMobile sniffer
Mobile sniffer
Raman Sanoria
 

What's hot (20)

Cell Phone Detector Presentation
Cell Phone Detector Presentation Cell Phone Detector Presentation
Cell Phone Detector Presentation
 
Mobille phone detector
Mobille phone detectorMobille phone detector
Mobille phone detector
 
Cell Phone Detector
Cell Phone DetectorCell Phone Detector
Cell Phone Detector
 
Project work (2014-2015)1
Project work (2014-2015)1Project work (2014-2015)1
Project work (2014-2015)1
 
Project report of Cell phone detector circuit
Project report of Cell phone detector circuitProject report of Cell phone detector circuit
Project report of Cell phone detector circuit
 
MINI PROJECT ON CELLPHONE DETECTOR
MINI PROJECT ON CELLPHONE DETECTORMINI PROJECT ON CELLPHONE DETECTOR
MINI PROJECT ON CELLPHONE DETECTOR
 
DESIGN & WORKING OF A MOBILE PHONE DETECTOR
DESIGN & WORKING OF A MOBILE PHONE DETECTORDESIGN & WORKING OF A MOBILE PHONE DETECTOR
DESIGN & WORKING OF A MOBILE PHONE DETECTOR
 
Mobile phone detector
Mobile phone detectorMobile phone detector
Mobile phone detector
 
A project report_at_cell_phone_detector - copy
A project report_at_cell_phone_detector - copyA project report_at_cell_phone_detector - copy
A project report_at_cell_phone_detector - copy
 
Cell phone detector
Cell phone detectorCell phone detector
Cell phone detector
 
Mobile sniffer
Mobile snifferMobile sniffer
Mobile sniffer
 
Cellphone signal detector and jammer ppt
Cellphone signal detector and jammer pptCellphone signal detector and jammer ppt
Cellphone signal detector and jammer ppt
 
Mobile jammer
Mobile jammerMobile jammer
Mobile jammer
 
Mobile detector grp9
Mobile detector grp9Mobile detector grp9
Mobile detector grp9
 
Hidden Active Cell Phone Detectorv
Hidden Active Cell Phone DetectorvHidden Active Cell Phone Detectorv
Hidden Active Cell Phone Detectorv
 
Mobile phone detector
Mobile phone detectorMobile phone detector
Mobile phone detector
 
Simple cell phone jammer
Simple cell phone jammerSimple cell phone jammer
Simple cell phone jammer
 
Smart Autonomous Mobile detector Robot
Smart Autonomous Mobile detector RobotSmart Autonomous Mobile detector Robot
Smart Autonomous Mobile detector Robot
 
Cell phone detector
Cell phone detectorCell phone detector
Cell phone detector
 
Mobile sniffer
Mobile snifferMobile sniffer
Mobile sniffer
 

Similar to ELG4913 Final Report

5G Antennas Market :- A Global Market Report
5G Antennas Market :- A Global Market Report5G Antennas Market :- A Global Market Report
5G Antennas Market :- A Global Market Report
BIS Research Inc.
 
White Paper Indoor Positioning in Healthcare
White Paper Indoor Positioning in HealthcareWhite Paper Indoor Positioning in Healthcare
White Paper Indoor Positioning in Healthcare
infsoft GmbH
 
Alcatel U5 Manual / User Guide
Alcatel U5 Manual / User GuideAlcatel U5 Manual / User Guide
Alcatel U5 Manual / User Guide
manualsheet
 
Smart Traffic Management System using Internet of Things (IoT)-btech-cse-04-0...
Smart Traffic Management System using Internet of Things (IoT)-btech-cse-04-0...Smart Traffic Management System using Internet of Things (IoT)-btech-cse-04-0...
Smart Traffic Management System using Internet of Things (IoT)-btech-cse-04-0...
TanuAgrawal27
 
Plugin anrit sitemasterseri30416
Plugin anrit sitemasterseri30416Plugin anrit sitemasterseri30416
Plugin anrit sitemasterseri30416Rohit Chintu
 
final report (parking project).pdf
final report (parking project).pdffinal report (parking project).pdf
final report (parking project).pdf
gamefacegamer
 
Catalogue 08 ing_v0208
Catalogue 08 ing_v0208Catalogue 08 ing_v0208
Catalogue 08 ing_v0208
Ryme
 
2016XXXX_Sensor_system_WEB
2016XXXX_Sensor_system_WEB2016XXXX_Sensor_system_WEB
2016XXXX_Sensor_system_WEBShan Guan
 
Hi-Tech Crime Trends 2014
Hi-Tech Crime Trends 2014Hi-Tech Crime Trends 2014
Hi-Tech Crime Trends 2014
Group-IB
 
Instruction Manual | Flir Scout BTS Thermal BI-Ocular | Optics Trade
Instruction Manual | Flir Scout BTS Thermal BI-Ocular | Optics TradeInstruction Manual | Flir Scout BTS Thermal BI-Ocular | Optics Trade
Instruction Manual | Flir Scout BTS Thermal BI-Ocular | Optics Trade
Optics-Trade
 
Motorola mtm5400 197380
Motorola mtm5400 197380Motorola mtm5400 197380
Motorola mtm5400 197380
ivan ion
 
Motorola MTM5400 Inst. manual.pdf
Motorola MTM5400 Inst. manual.pdfMotorola MTM5400 Inst. manual.pdf
Motorola MTM5400 Inst. manual.pdf
ivan ion
 
Eb1304%20 Net%20 En
Eb1304%20 Net%20 EnEb1304%20 Net%20 En
Eb1304%20 Net%20 Enguestcce874d
 
advancing-the-automotive-industry-by-collaboration-and-modularity
advancing-the-automotive-industry-by-collaboration-and-modularityadvancing-the-automotive-industry-by-collaboration-and-modularity
advancing-the-automotive-industry-by-collaboration-and-modularityStefano Marzani
 
Gigaset S820A Digital Cordless Telephone User Guide
Gigaset S820A Digital Cordless Telephone User GuideGigaset S820A Digital Cordless Telephone User Guide
Gigaset S820A Digital Cordless Telephone User Guide
Telephones Online
 
Gigaset R630H Pro Digital Cordless Phone
Gigaset R630H Pro Digital Cordless PhoneGigaset R630H Pro Digital Cordless Phone
Gigaset R630H Pro Digital Cordless Phone
Telephones Online
 
Gigaset QV830 Tablet User Guide
Gigaset QV830 Tablet User GuideGigaset QV830 Tablet User Guide
Gigaset QV830 Tablet User Guide
Telephones Online
 
Rapport veille salon-mobile IT & bigdata
Rapport veille salon-mobile IT & bigdataRapport veille salon-mobile IT & bigdata
Rapport veille salon-mobile IT & bigdata
Viedoc
 
White Paper: Indoor Positioning in Industry & Logistics
White Paper: Indoor Positioning in Industry & LogisticsWhite Paper: Indoor Positioning in Industry & Logistics
White Paper: Indoor Positioning in Industry & Logistics
infsoft GmbH
 
alcatel Pop 4S Manual / User Guide
alcatel Pop 4S Manual / User Guidealcatel Pop 4S Manual / User Guide
alcatel Pop 4S Manual / User Guide
manualsheet
 

Similar to ELG4913 Final Report (20)

5G Antennas Market :- A Global Market Report
5G Antennas Market :- A Global Market Report5G Antennas Market :- A Global Market Report
5G Antennas Market :- A Global Market Report
 
White Paper Indoor Positioning in Healthcare
White Paper Indoor Positioning in HealthcareWhite Paper Indoor Positioning in Healthcare
White Paper Indoor Positioning in Healthcare
 
Alcatel U5 Manual / User Guide
Alcatel U5 Manual / User GuideAlcatel U5 Manual / User Guide
Alcatel U5 Manual / User Guide
 
Smart Traffic Management System using Internet of Things (IoT)-btech-cse-04-0...
Smart Traffic Management System using Internet of Things (IoT)-btech-cse-04-0...Smart Traffic Management System using Internet of Things (IoT)-btech-cse-04-0...
Smart Traffic Management System using Internet of Things (IoT)-btech-cse-04-0...
 
Plugin anrit sitemasterseri30416
Plugin anrit sitemasterseri30416Plugin anrit sitemasterseri30416
Plugin anrit sitemasterseri30416
 
final report (parking project).pdf
final report (parking project).pdffinal report (parking project).pdf
final report (parking project).pdf
 
Catalogue 08 ing_v0208
Catalogue 08 ing_v0208Catalogue 08 ing_v0208
Catalogue 08 ing_v0208
 
2016XXXX_Sensor_system_WEB
2016XXXX_Sensor_system_WEB2016XXXX_Sensor_system_WEB
2016XXXX_Sensor_system_WEB
 
Hi-Tech Crime Trends 2014
Hi-Tech Crime Trends 2014Hi-Tech Crime Trends 2014
Hi-Tech Crime Trends 2014
 
Instruction Manual | Flir Scout BTS Thermal BI-Ocular | Optics Trade
Instruction Manual | Flir Scout BTS Thermal BI-Ocular | Optics TradeInstruction Manual | Flir Scout BTS Thermal BI-Ocular | Optics Trade
Instruction Manual | Flir Scout BTS Thermal BI-Ocular | Optics Trade
 
Motorola mtm5400 197380
Motorola mtm5400 197380Motorola mtm5400 197380
Motorola mtm5400 197380
 
Motorola MTM5400 Inst. manual.pdf
Motorola MTM5400 Inst. manual.pdfMotorola MTM5400 Inst. manual.pdf
Motorola MTM5400 Inst. manual.pdf
 
Eb1304%20 Net%20 En
Eb1304%20 Net%20 EnEb1304%20 Net%20 En
Eb1304%20 Net%20 En
 
advancing-the-automotive-industry-by-collaboration-and-modularity
advancing-the-automotive-industry-by-collaboration-and-modularityadvancing-the-automotive-industry-by-collaboration-and-modularity
advancing-the-automotive-industry-by-collaboration-and-modularity
 
Gigaset S820A Digital Cordless Telephone User Guide
Gigaset S820A Digital Cordless Telephone User GuideGigaset S820A Digital Cordless Telephone User Guide
Gigaset S820A Digital Cordless Telephone User Guide
 
Gigaset R630H Pro Digital Cordless Phone
Gigaset R630H Pro Digital Cordless PhoneGigaset R630H Pro Digital Cordless Phone
Gigaset R630H Pro Digital Cordless Phone
 
Gigaset QV830 Tablet User Guide
Gigaset QV830 Tablet User GuideGigaset QV830 Tablet User Guide
Gigaset QV830 Tablet User Guide
 
Rapport veille salon-mobile IT & bigdata
Rapport veille salon-mobile IT & bigdataRapport veille salon-mobile IT & bigdata
Rapport veille salon-mobile IT & bigdata
 
White Paper: Indoor Positioning in Industry & Logistics
White Paper: Indoor Positioning in Industry & LogisticsWhite Paper: Indoor Positioning in Industry & Logistics
White Paper: Indoor Positioning in Industry & Logistics
 
alcatel Pop 4S Manual / User Guide
alcatel Pop 4S Manual / User Guidealcatel Pop 4S Manual / User Guide
alcatel Pop 4S Manual / User Guide
 

ELG4913 Final Report

  • 1. ! ! CELLULAR PHONE DETECTOR (PHONE SPOTTER) FINAL CAPSTONE PROJECT REPORT ! ! ! ! ! ! Prof. Abdulmotaleb El Saddik, P.Eng. University of Ottawa School of Electrical Engineering and Computer Science Team Members Nabila Fairuz Rahman 5129121 Nourhan Eid 6164009 Tilly Ndjiapanda 5800573 Vladimir François 5760018
  • 2. ! 20 December 2013 ABSTRACT Currently there is a great deal of news spreading around regarding the misuse of cell phones. They are being used in restricted areas disregarding the rules and regulations of such places. Many such scenarios exist where people abuse their rights of using mobile phones. Keeping all these examples in mind, it is our intention to build a cell phone detection unit that will help users find out if cell phones are being used in a restricted area. It will also be useful for detecting the use of a mobile phone for spying and unauthorized video transmission. ! It is our intention to make our unit reliable and inexpensive, as well as lightweight so the device can be portable. This device will detect precisely cellphones as well as smartphones using 2G, 3G, LTE and Wi-Fi within 110 feet. Also, our product will have a microcontroller which will make it possible to give a higher level of detection of cellphones in use in prohibited environ- ment. ! We want to create a device that can be depended on to work accurately. It is expected that this device will have a good market, with potential clients such as airlines, government and military facilities, hospitals, educational institutions etc. Since there is an increasing trend of companies and institutions taking drastic measures to secure their facilities and property information, this team is hopeful that the market for our product will increase. In addition, we claim that the cost of developing the product will allow our unit to be cheaper than its competitors. ! This report will also discuss the technical aspects of the device, detailing all the features it is supposed to be implemented with and the proposed design for the device. In addition, we demonstrated in this report that we have successfully build prototype for such device that works
  • 3. according to the set requirements. Lastly, we have presented a business case that we will use to move forward with our device for commercialization. ! ! ! ! TABLE OF CONTENTS Abstract 2............................................................................................................................................ Table of Figures 6.............................................................................................................................. Introduction 7..................................................................................................................................... Design Objectives: Features 9............................................................................................................ Product Design 11............................................................................................................................... Transition to a newer design 12...................................................................................................... Detailed Design 15........................................................................................................................ Antenna 15................................................................................................................................. Logartihmic Amplifier 16........................................................................................................... Signal Conditioning Circuit 18................................................................................................... Micro-controller 20.................................................................................................................... Design Methodology 25..................................................................................................................... Design Constraints 27......................................................................................................................... Experimental Results: Simulation and Testing 27.............................................................................. Component Simulation 27..............................................................................................................
  • 4. Instrumentation Amplifier 28.................................................................................................... Log Amplifier 28....................................................................................................................... Component Testing 29.................................................................................................................... Antenna 30................................................................................................................................. Log Amplifier 33........................................................................................................................ Signal conditioning testing 36.................................................................................................... Integration System Testing 37........................................................................................................ Testing for phone detection 37................................................................................................... Part 2: Connecting to Signal Conditioning Circuit 38............................................................... Part 3: Connecting the microcontroller 39............................................................................... Testing for distance of phone 40................................................................................................. Physical Implementation and Prototype 42........................................................................................ Device Output 46........................................................................................................................... Precautionary measure 49........................................................................................................... Detection for text Messages and data 50.................................................................................... Project Work Distribution 50.............................................................................................................. Business Proposal 53.......................................................................................................................... Business Description 53................................................................................................................. Traits and features for our successful product 54........................................................................... The commercialization process 54................................................................................................. Launch method 56...................................................................................................................... Marketing Strategy 56................................................................................................................ Targeted Market and Customers 56............................................................................................... Main Customers 56.....................................................................................................................
  • 5. ! ! ! ! ! ! Targeted Market: North and south America, Europe, Asia and africa 57................................. (SPECIALLY- Example for customers in north america) 57..................................................... Growth Trends in this Business, Pricing Power, Mean Time between Failures 58........................ Project Cost Estimate and Cash Flow Analysis 59......................................................................... Project Cost Estimate 59............................................................................................................. Description 61................................................................................................................................. Project Risks and Assumptions 62................................................................................................. Description 62............................................................................................................................. Conclusion 63..................................................................................................................................... References 64..................................................................................................................................... Appendix A 65.................................................................................................................................... Cell Phone Detector Circuit 65................................................................................................... Appendix B 65.................................................................................................................................... Flowchart of PIC24F (MCU) Program 66.................................................................................. C CODE of PIC24F (MCU) Program 66................................................................................... Appendix C 78.................................................................................................................................... Gantt chart and project schedule 78.........................................................................................
  • 6. ! ! ! ! ! ! TABLE OF FIGURES Figure 1: Cellbusters Zone Protector 8............................................................................................... Figure 2: Block Diagram Of Old Proposed Design 11....................................................................... Figure 3: Cell Phone Detector System Block Diagram Of The New Proposed Design 13................ Figure 4: ANT-ELE-S01-006 Antenna (Left) And Its Magnetic Base (Right) 15.............................. Figure 5: Basic Connections For The RSSI Mode As Suggested By The Datasheet 16.................... Figure 6: AD8313 Output Voltage Versus Power Level In Dbm (Taken From Datasheet [6]) 17..... Figure 7: Cell Phone Detector Signal Conditioning Circuit 17.......................................................... Figure 8: Test Setup For ADC And LCD Libraries Using The Explorer 16 Board 21....................... Figure 9: Instrumentation Amplifier Circuit In Multisim 27.............................................................. Figure 10: Log Amplifier Multisim Simulation 28............................................................................ Figure 11: Log Amplifiera Simulation Output 28.............................................................................. Figure 12: Spectrum Analyzer Capture Of Signal Detected From Cell Phone 1 30.......................... Figure 13: SPECTRUM ANALYZER CAPTURE OF SIGNAL DETECTED FROM CELL PHONE 2 31....................................................................................................................................... Figure 14: Spectrum Analyzer Capture Of Signal Detected From Cell Phone 3 31.......................... Figure 15:Log Amplifier Circuit On Breadboard 32.......................................................................... Figure 16: Results Of Log Amplifier Testing 34................................................................................ Figure 17: Signal Conditioning Prototype On The Breadboard 35.................................................... Figure 18: Voltmeter Results Of Antenna And Log Amplifier Testing 36.........................................
  • 7. Figure 19: Voltmeter Results From Signal Conditioning Circuit 37.................................................. Figure 20: Microcontroller Output At Phone Detection 38................................................................ Figure 21: Variation Of Voltage With Distance 39............................................................................. Figure 22: Circuit Soldered On Veraboard 41.................................................................................... Figure 23: Prototype Circuit Connected To MCU 42......................................................................... Figure 24: Circuit In The Metal Enclosure 43.................................................................................... Figure 25: Physical Appearance Of Final Prototype 43..................................................................... Figure 26: Device Output When Battery Is Off 44............................................................................. Figure 27: Places Where Cell Phone Detectors Are Sold Worlwide 53............................................. ! INTRODUCTION Cell phones have been a significant scientific leap, helping people remain connected to each oth- er more profoundly than before. Nowadays, everyone has a cell phone and as with every tech- nology, the misuse of cell phone is also becoming more and more emergent. Recently there is a growing number of information leakage, security breach and examination cheating cases linked to the use of cell phones. Even if there are signs asking people to not use their cell phones, it is often ignored and people use their mobile phones in restricted areas. Some scenarios include: take-off and landing period in airplanes where, despite warnings, people still use their phones; exam halls, where students smuggle in their smart phones and use internet to get answers; jails and correctional facilities, where inmates can smuggle in phones and plan mutiny or prison breaks to escape. It is shown that 65% teens use cell-phones in school building despite school policy, and 35% use phones in tests [1]. The use of cell-phones while driving can also be dangerous as it leads to the increase of road accidents [9]. Also, the signal emitted from cell phones can be harmful in the sense that it can cause electro- magnetic interference (EMI) with devices in the hospitals. This can be dangerous to patients. A Dutch research carried out showed that, out of 63 hospital devices, 26 were disrupted due to EMI
  • 8. [10]. That’s almost 43% of hospital devices. The same research showed that out of all the inter- ference, 75% were considered “hazardous”. ! As a result of scenarios such as the ones discussed above, this team proposes to build a cell phone detector that can detect RF (radio frequency) signals made by cellular phones, especially when they are making calls. The detector can alert the user of any cell phone being used in the vicinity, thus limiting the use of the phones in restricting areas. This device can be used in air- planes, military facilities, prisons, hospitals as well as examination halls in schools, universities and other educational institutions. The concept our project is not a very new invention. Similar sophisticated products exist. Com- panies such as Cell Busters, whose produce zone protector shown in Figure 1, as well as Wolfhound have similar cell phone detectors [2] [3]. But their components are either not portable or doesn’t use a microcontroller and thus not flexible and are unreliable . More importantly, both companies produce very expensive devices. Compared to that, we are looking to produce a de- vice that is portable and less expensive, but still work just as efficient. These were our main in- tentions when thinking of doing this project. ! FIGURE 1: CELLBUSTERS ZONE PROTECTOR
  • 9. DESIGN OBJECTIVES: FEATURES At the beginning of the design phase, we compiled a list of requirements or features that we wanted our final product to posses and which will make it better than the other products in the market. The following lists a number of features that was intended to be incorporated in the final product. 1. Dimensions The design will be portable, light weight and if possible, pocket sized. Hence, the ideal dimen- sions that were thought of are given as follows: • Dimensions: Height – 20 cm, Width – 19 cm, Depth – 6 cm • Weight: 900 grams without directional antenna 2. Power Supply To make the device effectively portable, the device is made to be battery operated rather than us- ing an adapter to power it. A 3.7 volts lithium-ion battery with 1100 – 1500 mA is to be used. This battery is chosen because it is rechargeable and it has an expected life time of 12 hours. 3. Frequency Bands Cell phones use radio frequency (RF) signals to communicate with the outside world. Most phones nowadays also use Wi-Fi besides the traditional RF signals assigned for cellular commu- nication. Therefore, it is necessary to expand the design of the product to detect Wi-Fi signals as well. This lead to making the RF design to be wideband, since the range of the frequencies will expand up to 5 GHz. The primary goal is to detect following range of frequencies: • GSM/EDGE (850, 1900 MHz) • UMTS/HSPA+ (850, 1700, 1900, 2600 MHz) • W-CDMA/CDMA/CDMA2000 (800, 1900 MHz) • LTE (700, 1700, 2100, 2600 MHz) (Band 2, 3, 4, 5, 13, 17, 25) • Wi-Fi 802.11a/b/g/n (2.4, 3.7, 5 GHz)
  • 10. 4. Detection range The detector should detect signal as farthest as possible in large rooms such as the end of an air- plane when standing at the other end. This is made possible through the use of high gain antenna. Using directional antenna can be useful because they boost the range of detection due to their higher gain as compared to an omnidirectional antenna. However, the device will incorporate a build-in omnidirectional antenna and the directional antenna will be optional to connect external- ly to the device. The following are the range this device should be able to detect: • 0 - 110 feet under typical conditions • 0 - 150 feet when using directional antenna under typical conditions 5. Alert option The user is alerted that a cell phone has been detected via three possible options, which form part of the user interaction. The options that are available in the device are: • Buzzer: Which sounds an alarm once a cell-phone is detected and the sound stops once the detected device is switched off. • Two multi-color LED indicators: a. “detect” LED: Phone detection indicators which have two states: LED lights green when a phone is detected and the detector is moving away from the phone, as well as, LED lights orange when phone is detected and the detector is getting closer to it. b. “fail” LED: LED lights red when a error or fail occurs. • Vibration alarm: Is an optional feature that produces a vibration instead of a buzzer sound. When switched on the buzzer is automatically switched off. 6. Display The final design is intended to have a 16 x 4 LCD to display the following: • Error messages • Battery level
  • 11. • Message when a phone is detected PRODUCT DESIGN The idea behind phone detection is that when a cell phone call is being made then the cellar sig- nal in the area will demonstrate an increase in their power level. Therefore, we need to introduce a design that continuously scans for cellular signals and evaluates their power levels, and accord- ingly detects a sudden increase in power which indicates a detected phone. Using this method and in light of previously mentioned goals , the team proposed a system design last semester for the cell phone detector which is shown in Figure 2. In summary, the device was proposed to function by receiving cell phone signals in the surrounding environment via an antenna and a receiving unit, and then feed the detected signals to a microprocessor, namely, a Digital Signal Processor (DSP). The DSP will analyze the signals and decide if it belongs to an active phone transmission and alarm the user accordingly. The aim of this device is to preserve the RF signals to be processed in the DSP which will give our device the uniqueness of having most of the in- formation about the signal. ! FIGURE 2: BLOCK DIAGRAM OF OLD PROPOSED DESIGN In more details of design Figure 2, the antenna picks-up cellular RF signals propagating around the device. The received cellular signals are then passed through a band-pass filter that blocks signals with frequencies outside the cellular frequency bands, such as, 824-849 MHz for
  • 12. GSM-850. Following the filter, signals are passed through a RF module which consists of a low- noise amplifier (LNA), down-converter and local oscillator. The low-noise amplifier amplifies the received signal while reducing its noise level; this is important because the received signal has a significantly low power and any level of noise will distort the signal power. The signals are then fed to a down-converter where the signal frequencies are changed from high radio frequen- cies to lower frequencies in the intermediate range (less than 1MHz). For the down-converter to operate, it is connected to a local oscillator that produces a signal at a pre-defined frequency. The last stage is the digital signal processor (DSP) which is the core unit of the device. The de- sign intends to preserve the signal for the DSP to make all the decisions and analyses of the de- tection. The DSP will receive the signal at every time instance, scan it to determine the power level of the signal, compare the data to a stored threshold (for example, from a lookup table of the expected range of power levels of the signal) and give out a final result on the Liquid Crystal Display (LCD) of the device. ! ! ! TRANSITION TO A NEWER DESIGN While working on this design, theoretically it sounded right to us and seemed executable. How- ever throughout the implementation phase, we faced numerous technical challenges, especially with the RF module. The main problem faced was from the RF down converter, in which all down-converter chips sold in the market produces an output signal much larger in frequency than what the ADC in the microprocessor was capable of handling. As a result, we found a work- around for the problem faced, but this solution involved adding other stages to our design which increased its complexity. Thus, while trying to make this work-around work we were shifting more toward designing and implementing a receiver unit because of its sophisticated and de- manding design. More importantly, this lead to gradually shift our scope from implementing a
  • 13. cell phone detector, which should simply detect cellular transmission within vicinity of the de- vice, to a receiving unit, and as a consequence, more effort was focused on implementing the RF module although it formed a small peripheral unit of our overall system. Therefore, we realized that this excessive focus on the complex RF module will eventually lead to a negative impact on the implementation of our overall product. In addition, designing the RF module required immense microwave circuit design experience and resources that we lacked. Some of the components that theoretically sounded perfect ended up being more complicated to apply in reality. In the light of that, we sought to find a better yet simpler design that will achieve our goal without the need to implement the complex RF module. Fundamentally, the device is expected to detect cellular signals; this is comprised of detecting the presence of signal power from the antenna. This is in an essence a RF power meter but instead of measuring power and displaying it, the device uses the power level to alert the user of the pres- ence of cell phone in the area. In the previous design we were trying to accomplish this by using a more advanced yet complex approach by down-converting the signal to be analyzed in the DSP for power calculation. Whereas, a simpler method would be to replace the RF module with a component that will act as an envelope detector or a power detector, which has the function to measure RF power of the received signal. This replacement will make our design simpler with- out compromising the functions to be performed by our original design as well as maintain the same level efficiency that was claimed by our product. As a result, the team decided to make changes to the original proposed design. In our new design, we replaced the RF module with a log amplifier. The log amplifier is an amplifier that converts the input signal to its power level in decibels (dB) by producing an almost DC voltage output that is proportional to that power level.
  • 14. ! FIGURE 3: CELL PHONE DETECTOR SYSTEM BLOCK DIAGRAM OF THE NEW PROPOSED DESIGN The new proposed design that uses the log amplifier is shown in Figure 3. Similar to the old de- sign, the cellular signals are received by an antenna and passed through a band-pass filter to re- move any stray signals not belonging to cell phones [5]. These two components are the same components that were to be used by the old design which is to our advantage since it allowed us to progress with implementing this stage. The next stage is the log amplifier which is new to this design; the amplifier outputs a voltage level that is an indication of the power level in dB of the received signal. The output voltage is applied to an amplifier and a low-pass filter which re- moves the noise and amplifies the signal. This is done in order to increase the resolution and pre- cision of the voltage that will be read by the microcontroller. Since this circuit is prone to noise, there is future proposal to add a LNA after the BPF which will help to amplify the signal while eliminating noise. However, such a component was not incorporated as part of the prototype. The microcontroller used is a Microchip PIC24F that has an integrated a 10-bit Analog to Digital Converter. From Figure 3 we notice that we replaced the DSP used previously with a micro-con- troller. This is because the function of the DSP of performing signal processing to calculate the power level has moved from the microprocessor to the log amplifier. In other words, the previous design required the microprocessor to perform digital filtering and other complex calculations rapidly which can only be performed by the DSP, but these operations are not done in the micro-
  • 15. processor of the new design. Therefore, the goal of the microprocessor to perform complex cal- culations has been eliminated, and for this reason we used a normal micro-controller instead. This change has not caused complication to the team since the development board originally used with the DSP, Explorer 16 development board, had the option of changing the processor to a PIC24F, through plug-in module technology. Thus, the team was capable of retaining their origi- nal board and this saved the effort needed to adapt the code to another processor. DETAILED DESIGN We will discuss each of the components of the new design in details; refer to Appendix A for complete circuit design of the system in Figure 3. ANTENNA For this device an antenna that can operate at cellular frequencies was needed. To get such an antenna there was two options, either to build our own antenna or buy off-the shelf antenna. However, it was preferred to buy an antenna which will reduce the risk of building an antenna that doesn’t meet the specification. An omni-directional monopole antenna (ANT-ELE-S01-006 ) was found which operated at two frequency bands: 824-960MHz and 1710-1880MHz. The an- tenna requires a magnetic base to connect to which will provide a 50Ω matching to the antenna. The magnetic base will allow the antenna to be attached to a ground plane through it magnetic properties.
  • 16. ! ! FIGURE 4: ANT-ELE-S01-006 ANTENNA (LEFT) AND ITS MAGNETIC BASE (RIGHT) In addition, the voltage standing wave ratio (VSWR) is known which enable us to determine the power reflected and power transmitted to the antenna. The parameter VSWR is a measure that numerically describes how well the antenna is impedance matched to the radio or transmission line it is connected to. From the datasheet we found out that the antenna is less than 1.5 VSWR, which is actually good, because it only reflect 4% of the power, which is -14dB power reflected, that means at least 96% of the power will be deliver. And typically antenna is matched to 50 ohms impedance, which is also in our case. LOGARTIHMIC AMPLIFIER In general, a logarithmic amplifier is a non-linear amplifier that received signal at radio frequen- cies and outputs a DC voltage level that is proportional to the log power level of the input signal and thus the log amplifier can be used a power detector or envelope detector. The log amplifier to be used in this design is intended to operate at radio frequencies; namely, it should operate at cel-
  • 17. lular frequencies which are 850 MHz, 1700MHz and 1900MHz. For this reason we choose a log amplifier from Analog Devices, AD8313. AD8313 operates between 0.1GHz and 2.7 GHz as well as it can detect signals with power levels as low as -70 dBm; this specification is very suit- able for our design because the received signal by the antenna has an extremely low power from attenuation. In addition, AD8313 requires a low supply voltage of around 2.7 V to 5.5V which reduces power consumption in the circuit. However, the amplifier chip only comes in surface mount packages (8-lead MSOP), but there is a way around it by buying a surface mount to through hole adapter (8 MSOP to DIP adapter) for prototyping and given that the chip has only 8 pins it is not as cumbersome to solder it. AD8313 needs biasing and connections around it to op- erate; the connections shown in Figure 5 are suggested by the datasheet [6] which was used for our design after setting RPROT to 500Ω; refer to Appendix A for the detailed circuit of the log am- plifier as part of the complete product circuit. ! FIGURE 5: BASIC CONNECTIONS FOR THE RSSI MODE AS SUGGESTED BY THE DATASHEET The AD8313 is expected to produce an output voltage that varies with the input power level lin- early via the following equation: ! Where Slope is the line slope in V/dBm and intercept is the y interecept in dBm. The response in Figure 6 obeys this equation. This equation will later be used by the micro-con- troller to deduce the received signal power level from voltage level read by the micro-controller.
  • 18. ! FIGURE 6: AD8313 OUTPUT VOLTAGE VERSUS POWER LEVEL IN DBM (TAKEN FROM DATASHEET [6]) SIGNAL CONDITIONING CIRCUIT The purpose of signal conditioning circuit is to remove any noise imposed on the voltage from the log amplifier, as well as amplify the voltage to around 3.3V (maximum input level to the mi- cro-controller) to increase precision at the micro-controller. The signal conditioning circuit is de- signed by the team as in Figure 7. ! FIGURE 7: CELL PHONE DETECTOR SIGNAL CONDITIONING CIRCUIT The circuit consists of two stages: an instrumentation amplifier and a second-order Butterworth low pass filter. The instrumentation amplifier has two non-inverting amplifiers at the first stage
  • 19. followed by a differential amplifier. The gain of such a 3 op-amp instrumentation amplifier is given as ! From the graph in Figure 6 we observe that the maximum voltage level will reach around 1.7V. Although in our application the voltage level will range from 0.7V to 1V, we choose our input voltage of 1.7V, to protect the micro-controller from over-driving in case the voltage surged to 1.7V. Using the above equation, R1 and R2 were designed to be 1.2 kΩ, and R3 was designed to be 2.4 kΩ. A variable resistor, Rgain is used to control the overall gain of the circuit. The higher the value of Rgain the better the output voltage becomes i.e. the closer the output voltage becomes to be- coming perfect for the ADC, where it will go next. For example, when Rgain = 56 kΩ, the output voltage is approximately 3.2 V, giving an approximate gain of 2.096, and thus this is the resistor value that we will use. In the design, we have used an operational amplifier manufactured by Microchip (MCP602) in- stead of the traditional 741 amplifiers. This is because MCP602 amplifiers require single low DC supply (+5V) as opposed to the dual DC supply (VCC+ and VCC-) required by other amplifiers, as well as, there were numerous technical issues experienced by 741 amplifiers especially when used in specialized applications such as in our case. Furthermore, MCP602 packages contain two amplifiers in their packages, and hence they will significantly save space, and they come in through hole as well as surface mount packages so can be utilized in both prototyping and prod- uct manufacturing using PCB. There are high frequency components that might affect the accuracy of our measurements for the power level. Therefore, we designed a Low-Pass filter as our last stage with cut-off frequency of 50Hz. It will be implemented after the instrumentation amplifiers. The equation for a low-pass filter is !
  • 20. Since Fc (cut-off frequency) is 50 Hz, we designed R4 to be 33KΩ and C1 to be 100 nF. For the low-pass filter we choose a passive filter as opposed to an active filter because this application doesn’t require an efficient filter and thus using an operational amplifier for the filter will in- crease cost, power consumption and component count unnecessarily. MICRO-CONTROLLER The last stage of the design is the micro-controller. As mentioned earlier the antenna receives cel- lular signals which are then converted by the log amplifier to a DC voltage level. Lastly the DC voltage is then amplified and filtered to be fed to the micro-controller via the analog input port. The intention of the microcontroller is to advance the detection capabilities of the device; in oth- er words to add flexibly and accuracy to detection and thus making the device smarter. The mi- crocontroller achieves this by reading input voltage levels via a built-in Analog to Digital Con- verter (ADC) and the processor scans and analyzes the data to make decision regarding cell phone detection, and accordingly inform the user through the appropriate output ports. The out- put port will include: LED, buzzer and LCD screen. The algorithm used by the micro-controller for accurate detection will be discussed in further details in ‘Algorithm’ section. Besides detecting active cell-phone signals in the area, the micro-controller is capable of calcu- lating the power of the received signal in dBm and displaying the power level to the user on the LCD screen. The micro-controller calculates power. Furthermore, the micro-controller will be- come more useful in future proposed features to be added to the device. These features include phone positioning in which the position of the detected phone can be identified using wireless network sensor (WNS) approach [8], as well as computer communication in which the device will be able to send the results to a remote computer. The microcontroller used is a PIC24F (PIC24FJ128GA010) manufactured by Microchip Tech- nology. A PIC microcontroller is used because it is proven to have higher analog to digital con- version speeds and accuracy than other microcontrollers in the market. This is important since phone detection relies on reading a series of voltage levels and analyzing them, and hence a fast and accurate ADC will reflect directly on the quality of detection. In addition, the PIC is cheaper
  • 21. than other microcontrollers in the market with the same specifications. For the prototype, an Ex- plorer 16 development board is used; this board houses the PIC24FJ128GA010 and has built-in 4*16 LCD screen, 8 LEDs as well as In-circuit debugger connector for the programmer. ! ALGORITHM The microcontroller has one input from the analog input pin that is connected directly to the ADC. The output is then send via 2 digital output pins one connected to the LED and the other to the buzzer, as well as output ports that are connected to the LCD screen controller. Before im- plementing the program, an algorithm is developed for the microcontroller. The idea behind the phone detection is that when the input voltage level exceeds a certain threshold a phone is being detected. In addition, the microcontroller can determine if a detected phone is close when the voltage level suddenly rises to a higher threshold than the first one. The algorithm developed is illustrated in the flowchart in Appendix B. As illustrated in the flowchart, the input voltage is first read by the ADC which is used to calculate the input power level in dBm using the follow- ing equation. The calculated power level is displayed on the first row of the LCD screen. ! Where Vin is the voltage read by the ADC Gain is the gain of the signal conditioning circuit Slope: is the slope of the log amp yintercept: is the y intercept of the log amp response Simultaneously, the input voltage is compared against a predefined threshold voltage; the pro- gram has two thresholds one when the detected phone is close to the device (V2) and the other when the detected phone is away from the device (V1) . If the voltage exceeds the threshold V1 for a certain time (number of samples) then a phone is detected with 90% confidence. As a re- sponse to this the LED will turn on, buzzer will sound and a message will be displayed on the second row of the LCD screen saying “Cell Phone Detected!”. However, if the voltage exceeded the threshold for a very short time which is one or two time samples, then there is only a 50%
  • 22. chance that a phone is detected. As a result only the LED will turn on which means that it is just a warning to the user that a phone might be detected. If the voltage exceeds both thresholds V1 and V2 for a significant time, then a phone is detected and within a close distance to the device. Consequently, the buzzer will sound and LED will turn on, but “Cell Phone Close!” message will be displayed on the second row of the LCD screen. Lastly, if the voltage is below both thresholds then no phone is detected, and thus no LED will be turned on, buzzer won’t sound and nothing will be displayed on the second row of the LCD screen. From the flowchart, it can be observed that for a phone to be considered as detected it should ex- ceed the threshold for a considerable time, in order to prevent false alarms due to rapid fluctua- tions from noise. In addition, the device is capable of differentiating whether the detected phone is close or distant besides detecting a cellular signal. It can be noted that this feature has been added at the end of the implementation phase after the device was established; the testing per- formed to arrive to the algorithm regarding this feature is explained in details in the Testing sec- tion. SOFTWARE The algorithm is then implemented in C code for the PIC microcontroller. The MPLABX C30 compiler was used to create a hex file which is then loaded to the microcontroller using PICKIT2 programmer. Two library files were created for this project: LCD and ADC. The LCD library is used to provide interface to the LCD screen, namely, to initializes the registers and prints a string on the screen. The ADC library is used to initialize and read from ADC-specific registers. The libraries were then tested by varying the input voltage from an external circuit and observe the voltage level on the LCD screen, shown in Figure 8 is the setup for the testing done on the li- braries
  • 23. ! FIGURE 8: TEST SETUP FOR ADC AND LCD LIBRARIES USING THE EXPLORER 16 BOARD Apart from the LCD and ADC files, the main file is implemented where the code is run by the microcontroller indefinitely. The main code implements the algorithm discussed in the flowchart; Appendix B shows the c code for the LCD, ADC and main files. The first step in the code is to initialize the I/O pins as shown below. The I/O pins include digital output pins A where A1 to A8 are connected to the built in LED and A15 is connected to the buzzer, and analog input pin 8. AD1PCFG = 0xFFFF; // all ANs are digital I/O PORTB =0; AD1PCFGbits.PCFG8 = 0; //AN8 is analog TRISA = 0; The ADC and LCD are then initialized; initialization involves setting the appropriate registers with the right settings. InitADC(); InitLCD(); clrLCD(); ! In the indefinite loop, the voltage is read via the ADC; the ADC reads levels instead of voltage, and thus the levels are converted to voltage in mV knowing that the highest attainable voltage is 3300 mV and the numbers of levels are 1024. //Read input voltage by ADC adc_val = ReadADC (); __delay_ms (2); //Convert the ADC level to voltage in mV volt_in =(adc_val*3300)/1024; ! The voltage is then used to calculate power in dBm and display it on the first row of the LCD screen.
  • 24. //Calculate Power in dBm // Map voltage to input of signal conditioning Vin = volt_in / Gain; // Change the voltage to power in dBm via log amp Pin = (Vin / slope ) + y_intercept ; ! The voltage then goes through a series of comparisons with both of the thresholds, and if the voltage exceed threshold V1 for prolonged time then a phone is detected, but if the voltage ex- ceed threshold V2 for a prolonged time then a phone is detected and close. if (volt_in>V1 ) { // When voltage is more than threshold V1 turn LED on and increase // the count it exceeded threshold V1 volt_count++; LATA = 0xFF; if (volt_in>V2) { // When voltage is more than threshold V2 increase the count it // exceeded V2 volt_count2++; if (volt_count2 > maxCount ) { // If the voltage exceeded threshold V2 for more than max_count2 // then phone detected and close // Display Phone Close on second row of LCD putsLCD(1,1,"Phone Close!"); // Sound the buzzer (connected to pin A15) _LATA15 = 1; } else { // If the voltage exceeded threshold V2 but not for prolonged time // then phone is only detected putsLCD(1,1,"Phone Detected!"); _LATA15 = 1; } } else { volt_count2 =0; if (volt_count > maxCount ) { // If the voltage exceeded threshold V1 for more than max_count // then phone detected and away putsLCD(1,1,"Phone Detected!"); _LATA15 = 1; } } !} else { // If voltage didnt exceed neither thresholds then no phone detected
  • 25. // Turn LED and buzzer off LATA= 0x0000; // Clear second row of LCD screen putsLCD(1,1," "); // Reset the counts volt_count =0; volt_count2=0; } !! In summary, the device will pass through four statuses with the following responses shown in Table 1. ! TABLE 1: STATUS AND OUTPUT OF THE DEVICE DESIGN METHODOLOGY Status LED Buzzer LCD (2 LCD (1 Phone detected for very short time (50% chance of detection) ON OFF “Power = xx dBm” Phone detected for long time and far away (90% chance of detection) ON ON "Phone Detected!” “Power = xx dBm” Phone detected with 90% confidence and close ON ON "Phone Close!” “Power = xx dBm” Phone not detected OFF OFF “Power = xx dBm”
  • 26. When we first chose the project, our main question was: how do we detect the desired signal? To that end, we decided to follow the theories that we have learnt in our classes, as well as search for similar projects where people have worked with signal detection. The first stage in our project was to find a way to capture the cell phone signal. The answer was of course to use an antenna. Then depending on our need, we had to decide the specifications of the antenna. Our antenna is a monopole whip antenna which will detect certain bands for our de- vice. In the last stage we had to find a way to analyze the detected signal, decide whether it is in the intended band and alert the user that a cell phone has been detected nearby. This kind of analysis is best done using a microcontroller. So we went ahead and found a microcontroller with an LCD attached that will help to show the alert on display. The middle stage is crucial in the sense that we had to decide in which way we are going to do the detection. There are several ways to detect signal, such as detecting the power level of the coming signal, transforming the coming RF signal into IF and processing that IF signal to use for detection etc. We opted to go for power level detection. In this method, the frequency of the com- ing signal from the antenna is transformed into power level according to the each frequency. We decided to choose this method as it is less complex and therefore easier to implement than other methods of detection. We had some help from various research papers that helped us understand how the method works. We found a logarithmic amplifier which does this job best, so it was cho- sen for our project. Since to use the microcontroller we had to change the coming analog signal to digital, we real- ized that we needed an Analog to Digital Converter (ADC) to do the conversion. We have learnt in our classes that to do so, the coming input signal had to be conditioned so that the ADC could work on it. So we needed to do some signal conditioning prior to the signal going in the ADC. Based on our theories from Electronics III (ELG4139) course, we decided to go for an instru- mentation amplifier followed by a low pass filter to do the signal conditioning, as the instrumen-
  • 27. tation amplifier has a high CMRR (common mode rejection ratio) which would help us more to keep away unwanted frequencies. These were the train of thoughts that led us to have our present design for the project. Last, we are working toward implementing a prototype that we will be demonstrating. We expect to proof that with our current design, our device will be capable to correctly detect and alert the user when a phone call is being made with a phone operating in either 1700 MHz or 19000 MHz DESIGN CONSTRAINTS The product is built on the assumption that it will be used in cell phones restricted area, which means it will work in an environment where a maximum of five cell-phones signals are in use. In addition, all the device tests will be performed on the ground and thus there will be no tests per- formed on an airplane like environment before the deployment and shipment of the device, but we claim that it can function in an airplane within an acceptable range of accuracy. Detecting a wide range frequency is more useful and more needed in the market, but designing our circuit to work with frequencies that operate at 5 GHz will be challenging, as the higher the frequency goes, the more complicated the RF circuitry becomes, thus making it more difficult to implement. Also, most components do not work properly at very high frequencies. Therefore, we are planning to design our device to operate at the traditional cell-phone RF transmission fre- quency and Wi-Fi in the 2.4 GHz band. EXPERIMENTAL RESULTS: SIMULATION AND TEST- ING COMPONENT SIMULATION Within the last two months we have also went upon testing some of the components that we or- dered. This step was very important to verify the response of the components especially after the
  • 28. changes in the design that we did. We needed simulation models that we can go back to incase we experienced any technical problem during physical implementation. INSTRUMENTATION AMPLIFIER We have modeled the instrumentation amplifier circuit suggested in Figure 7 of “Detailed De- sign” section. The aim of the model to easily go back to it to change resistor in case we wanted to tune the gain. Figure 9 below is the simulation in Multisim of the instrumentation amplifier part of our conditioning circuit used in our product. We calculate precisely the gain needed in order to increase our output voltage going into the ADC to around 3.3V. ! FIGURE 9: INSTRUMENTATION AMPLIFIER CIRCUIT IN MULTISIM LOG AMPLIFIER Besides the instrumentation amplifier simulation, we wanted to verify the response of the AD8313 amplifier. In particular, the aim is to prove that the amplifier will produce a DC voltage that follows the slope response in Figure 6. Unfortunately, it was difficult to simulate AD8313 because it doesn’t have a component in Multisim and the PSPICE model fails to simulate on Ca-
  • 29. dence OrCAD. Thus, we decided to simulate a similar log amplifier, which is AD8310, that has the same connections but operate at lower frequencies. Figure 10 shows the Multisim model of AD8310 log amplifier circuit in RSSI mode simulated on Multisim Component Evaluator 13.0. From Figure 11, we observe that at an output of DC volt- age level of 2.012V was produced which was the same value interpolated from the AD8310 re- sponse curve in its datasheet [7]. From the result, we verified that the log amplifier will in fact produce a DC voltage proportional to the input power level. ! FIGURE 10: LOG AMPLIFIER MULTISIM SIMULATION ! FIGURE 11: LOG AMPLIFIERA SIMULATION OUTPUT COMPONENT TESTING
  • 30. In this step, the aim was to make sure that the log amplifier and signal conditioning circuit re- spond to our criteria, which most importantly being able to detect our cell phone signals, as ex- plained below, in a certain frequency range. For the log amplifier we ordered samples for two amplifiers: AD8307 and AD8313. AD8307 has a range frequency of up to 500MHz, but we wanted to be able to reach at least ~849MHz, which was our initial goal. ! ! ANTENNA We built an antenna for last semester in order to test cellular signal that will be detected, but de- cided to buy an antenna for this semester due to problems we had with the previous antenna. The previous antenna was only able to detect one cell phone, and from that result we made all our calculations according to 849MHz However, for this session we used three cell phones and none of them were around that frequen- cy range. They used a higher frequency. Because of the changes in frequency, we could not use AD8307 as our log amplifier. So we had to use the other log amplifier (AD8313), which re- sponds to our criteria. From the new log amplifier we are able to detect frequencies from 0.1 GHz to 2.7GHz. Accord- ingly, we built a circuit and made our calculation in order to have the desired voltage at the out- put of the AD8313 log amplifier. As shown in the Figure 6, we expect a signal between 0.7<V<1.0 at the output of our AD8313 log amplifier. We will use the output value of our log amplifier and inject it at the input of our signal conditioning. Moreover, from the beginning we were going to detect a frequency range of 824-849MHz from our monopole antenna that we built last session and it was fixed on the uplink (which means only catching signals being sent to a source). In fact, that was only from one cell phone that we tested. But for this session, we bought an antenna which has 2 bands:
  • 31. a. Band1: 824-960MHz, gain 0dbi b. Band2: 1710-1880MHz, gain 4dbi From the datasheet we knew that the new antenna will be more efficient than the first one, so we first gathered information about the antenna, to make sure that we will be able to detect within our ranges. So from that entire information gather we decided to confirm with our measurement, by testing three different cell phones. TEST SETUP The test setup involves connecting the antenna directly to a spectrum analyzer. The spectrum an- alyzer used in this experiment is ‘Rohde and Schwartz HMS3010’ that can operate at frequencies up to 3 GHz which made it beneficial to the experiment since we are dealing with radio frequen- cies. The spectrum analyzer input port is a SMA female which was the same as the one of the antenna connector, and thus we bought an SMA male to male adapter for this experiment. RESULTS Connecting the antenna and spectrum analyzer as the test setup, calls were being made and the results observed on the analyzer. Since we have three different phones with three different carri- ers each operating at a band that is of interest to us, we used each of the phones for the experi- ment. The results of conducting the experiment with each of the three phones: i. Cell phone1: Wind mobile as its carrier and operates at 1700MHz ASM; result is shown in Figure 12 !
  • 32. ! FIGURE 12: SPECTRUM ANALYZER CAPTURE OF SIGNAL DETECTED FROM CELL PHONE 1 Once a cell is being made a spike is observe on the analyzrer as shown in Figure 12, which signi- fies that the spike belong to the call we made and thus concluded to us that a phone call leads to a power spike. In addition, we were able to observe from the spectrum analyzer that the cell phone signal frequency of operation is at around 1.73520GHz as shown in Figure 12. Thus, we confirmed that the signal is detected because it is in the frequency range of the antenna. ii. Cell phone 2: Fido as its carrier and operates at 850/1900MHz GSM ! ! FIGURE 13: SPECTRUM ANALYZER CAPTURE OF SIGNAL DETECTED FROM CELL PHONE 2
  • 33. It can be observed from the spectrum analyzer a cell phone signal being detect at around 1.90600GHz as shown in Figure 13. From the result, it can be deduced that the signal is slightly out of the antenna range, and hence from the spectrum analyzer the power level of the signal is lower than cell phone 1 while making a call. Therefore, there is weak signal appearing, which is normal due to that the signal is out of range. iii. Cell phone 3: Chatr as its carrier and operates at 850/1900MHz GSM ! ! FIGURE 14: SPECTRUM ANALYZER CAPTURE OF SIGNAL DETECTED FROM CELL PHONE 3 It can be observed from the spectrum analyzer results in Figure 14, a cell phone signal is detected at around 1.90600GHz. For this case, it is the same as the cell phone2, and so the frequency of operation is the same for both cases. It can be concluded that a strong we signal level is observed in cellphone1 compared to cellphone2 and cellphone3, which have a weak signal level received by the antenna. As a result, the antenna main band of operation is around 1700 MHz with the ability to pick up signal at 1900 MHz the power level at the output of the antenna is of weaker strength. LOG AMPLIFIER
  • 34. Besides simulating the AD8310, we wanted to ensure our log amplifier circuit works. Thus using the circuit proposed in Figure 5, a log amplifier circuit was implemented on a breadboard as shown in Figure 15. It is known that the breadboard is not the best choice when testing mi- crowave circuit since it introduces noise due to parasitic; however, the breadboard was a better option for preliminary testing that soldering the components on a Veraboard.. ! FIGURE 15:LOG AMPLIFIER CIRCUIT ON BREADBOARD TEST SETUP To test the log amplifier AD8313 circuit, a signal frequency from a function generator was in- jected. The function generator used is a microwave function generator operating up to 1.1GHz of frequency which we borrowed from Prof. Yao graduate lab. This experiment enabled us to read the output signal of the log amplifier which is a DC voltage measured with the voltmeter. It was were expecting to get an output from the log amplifier of a noise floor of around 0.6V, which from that we had to differentiate with our input signal injected. Thus, the test setup involved connecting a microwave function generator operating in the range 100MHz to 1.1GHz to the in- put of the log amplifier circuit whose output is connected to the voltmeter. RESULTS We inject a frequency of 900 MHz within different input signal from -60 dBm to 10 dBm, and read the variation in voltage from the output while changing the input and then we plot it to compare from the plot of the datasheet. The input power level is read from the function genera-
  • 35. tor and the output voltage is read from the voltmeter. The data is measured and collected at the table below which is then plotted in the graph in Figure 16 . ! ! ! FIGURE 16: RESULTS OF LOG AMPLIFIER TESTING As we can see from the graph in Figure 16 and the table above, we have some similarity with values gather from the datasheet in Figure 6, except in our case, because we were using a bread- Input (dBm) Output (Volts) -60 0.850 -50 0.821 -40 0.828 -30 0.865 -20 1.009 -10 1.189 0 1.377 10 1.567
  • 36. board we automatically have noises added to our circuit. This is why we have some differences of values comparing to the one from the datasheet. In general, the result in Figure 16 verifies that the log amplifier circuit works as per specifications. SIGNAL CONDITIONING TESTING Based on the design described previously in the ‘Detailed Design’ section, the signal condition- ing circuit was built in a prototype. Shown below in Figure 17 is its physical implementation. ! FIGURE 17: SIGNAL CONDITIONING PROTOTYPE ON THE BREADBOARD For our testing, we wanted to confirm that the circuit worked similarly to the simulation. The main goal of the testing was to make sure that the output voltage of the circuit stays well below 3.3V. This is because the output of this circuit goes to the input of the micro controller, and our microcontroller was unable to take in voltage above the limit of 3.3V. Keeping that in mind, we first tested the circuit by measuring the output voltage. We had some initial trouble with our gain (it was close to 4) which gave us a higher output voltage than de- sired. So we recalculated and chose 56kΩ as our Rgain. This gave us a gain of approximately 2.1 which in turn produced an output voltage that was below the 3.3V limit. Once we were
  • 37. INTEGRATION SYSTEM TESTING During this testing phase we combined all the components of the circuit that has been tested in- dividually and tested when they are integrated together to form a complete device. The system testing was divided to two main parts; testing for phone detection where the capabilities of the system to detect cell phone signal is tested, and testing for distance measurement where the ca- pability of the system to distinguish between close and far phones is tested. Through this testing phase all prototypes are carried out on a breadboard, and the power is supplied via a lab power supply. TESTING FOR PHONE DETECTION The plan to test our device was simple. Since we were dealing with voltage levels to detect cell phones, our prediction regarding detection was that, when a cell phone is being used to make a call, send a text or use data, the voltage level would increase significantly, thus showing the user that there is a phone in the area. Also, we tested each component one after the other to ensure that the device worked impeccably at each stage, and we only moved on to the next part after making sure the present one is work- ing accurately. Presented below is an in depth description of our testing procedures. It will be shown that the outcome of the tests followed our predictions perfectly. PART 1: ANTENNA AND LOG AMPLIFIER We next connect the monopole antenna ANT-ELE-S01-006 to first stage of the circuit, the log amplifier AD8313. Then we used voltmeters to measure the voltages at the input and output nodes, i.e. the input and output of the log amplifier. Finally we took measurements for a period of time to see the changes on the voltmeters
  • 38. ! FIGURE 18: VOLTMETER RESULTS OF ANTENNA AND LOG AMPLIFIER TESTING Figure 18 shows the voltmeter results at the output of the log amplifier; these are two of the many measurements that were taken to make sure that the two components were working as ex- pected. We first made a test without making a call and we were expecting a noise output voltage of around 0.6V as the datasheet explained which is what we obtained as shown on the left of Figure 18. Then we made a test making a call, we observe the voltage increasing once a call made as shown on the right of Figure 18. The test was repeated with different cell phones to compare signal output of difference from different company providers. As expected the output voltage was not we the same value at each call made because each company has different fre- quency band and the signal strength varies according to the environment and obstacle. Thus, it can be explained why we were getting different values and also why they weren`t stable. So we concluded that the log amplifier connected with antenna works as per our intentions. PART 2: CONNECTING TO SIGNAL CONDITIONING CIRCUIT The next step in the testing process is to connect the setup from previous testing to the signal conditioning circuit where the output of the log amplifier goes to the input of the signal condi- tioning. The same testing procedure as in the last testing has been following with the expectation to observe a similar response as with the log amplifier.
  • 39. ! FIGURE 19: VOLTMETER RESULTS FROM SIGNAL CONDITIONING CIRCUIT In Figure 19, the pictures on the left column show the voltage results before a call being made and the ones on the right columns shows the voltage results after a call is made. The top voltages are from the output of the signal conditioning circuit, the bottom ones are from the output of the log amplifier circuit. The results at the bottom of Figure 19, that shows the output of the log am- plifier, are the same as the testing is part 1. In addition, the results at the output of the signal conditioning demonstrates the same response in which a there is significant voltage increase when a call is being made. However, the values out of the conditioning circuit are higher due to the amplification undergone by the instrumentation amplifier. Therefore, the results matched our expectations and that verifies that the signal conditioning circuit works correctly. ! ! PART 3: CONNECTING THE MICROCONTROLLER As per this step, it was proved that the circuit implementation works as expected, however we want to verify that the microcontroller works as part of the system. The microcontroller is con- nected to the rest of the circuit where the signal conditioning circuit output (from LPF) goes into the input of the microcontroller, which is analog input pin AN15. As discussed in ‘Detailed Design’, the microcontroller detects if a phone call is being made by comparing the incoming input to a threshold level of voltage. If the incoming signal is higher than the threshold, then the micro controller “detects” a phone nearby.
  • 40. The value of the threshold was found through experimentation. By making a large amount of calls, we checked how high the voltage level rises for each call. Then, an average of these values was chosen, above which if the voltage level rose then it guaranteed that the level was high enough to be sure that a call was being made. That value was used as a threshold in the micro- controller; this value was chosen around 1.6 V. However, the value was continuously tweaked to improve performance. After determining the correct threshold value and editing the code to match such improvement, the output was observed on the microcontroller as shown in Figure 20. ! FIGURE 20: MICROCONTROLLER OUTPUT AT PHONE DETECTION The microcontroller displays the message “Phone Detected!” on the LCD screen and the LEDs light up. Also, a buzzer is attached to the device which sounds whenever a phone has been de- tected. In addition, the power level of the input signal is shown on the first row of the LCD screen. TESTING FOR DISTANCE OF PHONE
  • 41. Following testing the system, we wanted to add a feature such that the device can differentiate if the phone detected is close to the device. To add such a feature an experiment was carried out using three different phones, and numerous calls were made from them with the experiment re- peated at two distances 0m from the device and 1.25m from the devie. The output was recorded via a voltmeter connected to the output of the circuit that is fed to the microcontroller. During each of the experiments the variation of the voltage level at two different distances were noted and recorded. ! FIGURE 21: VARIATION OF VOLTAGE WITH DISTANCE The data was then plotted in graphs for comparison, shown in Figure 21 above is the result from one of the phones. The blue line shows the voltage level when the phone is right near to the an- tenna (i.e. 0 meters away) and the red line shows the voltage level when it’s approximately 1.25 meters away from the antenna of our device. As it can be seen, there is a clear difference between the two levels. From this experiment, we observed that our device can detect if a phone is next to the device or some distance away. Consequently using the data plotted, we extracted a second threshold than can be used for distance differentiation (V2) which from the result is apparent to be 2.2 V. The microcontroller code was then edited to add the distance detection feature. Another observation from the results is that the probability that a phone is detected when a call is made
  • 42. decrease beyond a certain distance, after that distance the quality of detection decrease and con- tinues to decrease as we move further away until the capability of detection vanishes. From the result, it can be concluded that the device best operation between 0m and 1.25 meters, and the device can detect up to 11m. PHYSICAL IMPLEMENTATION AND PROTOTYPE From the experimentation and testing, it have been verified that the complete system works as expected. Thus, the next step was to import this circuit to a prototype. For prototyping, we had two options: a PCB and a Veraboard; the PCB seemed like the best choice but since it was the first time to do a layout the risk was higher. Although, the PCB layout development was executed and started already we opted for soldering the components on a Veraboard because it will give us extra time to add another feature which is the distance detection in our case. For the Veraboard we found a type of board that is connected from the back horizontally and thus will reduce the need to connect components with wires making it as close as possible to a PCB. The signal con- ditioning and log amplifier circuits were soldered on the Veraboard and the board is shown in Figure 22. !
  • 43. ! FIGURE 22: CIRCUIT SOLDERED ON VERABOARD During testing the power supply was used as a voltage source, but in thus phase the power supply was replaced with battery in a battery holder with a switch to make it portable. The antenna is connected to the circuit through an SMA connector soldered to the circuit. Before connecting the circuit to the microcontroller, the output voltage and all pins in the circuit were measure to make sure they correspond to our expected values observed during system and component testing.
  • 44. After testing the soldered circuit, it was connected to the microcontroller input pin AN15. The connection to the microcontroller is done through a breadboard that can be hooked to the exten- sion board and has header pins for each of the I/O pins. Figure 23 shows the prototype after con- necting the soldered circuit to the microcontroller. ! FIGURE 23: PROTOTYPE CIRCUIT CONNECTED TO MCU The system in Figure 23was then tested by connecting the output to a voltmeter, making numer- ous calls, and observing the output on the microcontroller and voltmeter. Unfortunately, the out- put from the system was not stable and it was deduced that it is due to interference affecting mi- crowave part of the circuit. In order, to shield the circuit we suggested to put the circuit in a met- al enclosure, as shown in Figure 24, which will prevent interference and can act as a ground plane to the antenna. Following this step, the prototype of the device which will be used for demonstration and proof of concept is shown in Figure 25.
  • 45. ! FIGURE 24: CIRCUIT IN THE METAL ENCLOSURE
  • 46. ! FIGURE 25: PHYSICAL APPEARANCE OF FINAL PROTOTYPE DEVICE OUTPUT The device passes through four different situations as shown in Table 1; our aim is to recreate these 4 statuses and verify that the output is within the expected responses. Before turning the battery on the LCD will show “Turn Battery On”, which is a precaution for us to remind us when a battery is on or off. This situation and its output is shown in Figure 26.
  • 47. ! FIGURE 26: DEVICE OUTPUT WHEN BATTERY IS OFF Once the battery is turned on, the device will display received power strength in dBm on the LCD as shown below !
  • 48. When a phone call is made and is placed beside the device, the device shows the following mes- sage on the LCD: “Phone close!” as shown below. In addition to that, the LED (shown at the bot- tom of the picture) will turn on and the buzzer will sound. ! As the phone making the call moves farther from the device to around a distance of 1.25 meters away from the antenna, then the LCD displays: “Phone detected” instead of “Phone Close” as shown below, thereby showing that a phone is being detected but it is not right near to the device. In this case, the LED will also be turned on and the buzzer will sound.
  • 49. ! PRECAUTIONARY MEASURE As an extra feature against errors, the device has a warning sign. To make sure that the device is actually detecting a phone and not just some random signal, the micro-controller of the device samples the incoming signals three times. If the micro controller samples two inputs one after the other, it is taken as a sign that there may or may not be a phone nearby. At this point, the buzzer doesn’t ring and the LCD doesn’t display anything. Only the LEDs light up as a warning to the user as shown below
  • 50. ! However, if right after the two inputs the microcontroller samples a third input, then it is taken as a sure sign of detection, in which case the LCD displays one of the aforementioned messages and the buzzer rings. DETECTION FOR TEXT MESSAGES AND DATA When sending a text, the device detects the phone while the text is being sent. As it doesn’t take too long to send a text, the device can detect it for only a couple of seconds. In addition, the de- vice can detect if a phone is using the internet via a phone data network. PROJECT WORK DISTRIBUTION Work has been divided upon team members based on their knowledge and academic background. The design of this product requires knowledge in mostly RF circuitry, electronic components such as microprocessor, and experience in antenna design. Apart from engineering expertise, some knowledge in business studies is also helpful to understand the business prospect of the project. The members of this project have various backgrounds that accommodate the division of
  • 51. responsibility agreeably, not to mention that they are all currently studying their Bachelor of Sci- ence in Electrical Engineering. ! Because of her knowledge in RF and C programming, Nourhan Eid was in charge of designing the device system and suggesting how the main blocks of the circuits should work. In addition, she was responsible for implementing the microcontroller software. ! Since they both had taken a course on antenna design, Tilly Ndjiapanda, worked on designing and testing the antenna part. This required coming up with a basic design for the antenna to con- duct the experiment with. In addition, she build and tested the log amplifier circuit. ! Nabila Fairuz Rahman being the team leader of the project, was also responsible for organization of duties and workloads. She had to keep an eye out for deadlines and regularly update the team about how the work is going. Moreover, due to her electronics discipline she worked along with Vladimir Francois on designing and simulating the signal conditioning circuit. ! Vladimir Francois was in charge of the business aspect of the project. He was responsible for coming up with a well prepared business proposal that specifies the reasons behind doing this project and why it will be a worthy project financially. He created a budget with price assump- tions that gave an idea of how much the design would cost. Apart from that, he was also in charge of overall formatting of the reports and presentations. Apart from working with Nabila on the signal conditioning circuit, he soldered the circuit on the Veraboard. !
  • 52. All other tasks were divided between team members; the following table, Table 2, shows the de- tailed work distribution between team members. ! ! ! ! ! ! Tasks Nabila Rahman (Team Lead) Nourhan Eid Vladimir Francois Tilly Ndjiapanda Overall research 30% 30% 10% 30% Main system design 0% 100% 0% 0% Antenna testing 0% 0% 0% 100% Log amplifier design, implementation, verification 0% 0% 0% 100% Signal conditioning research and design 60% 0% 40% 0% Signal conditioning implementation and verification 60% 0% 40% 0%
  • 53. ! ! TABLE 2: WORK DISTRIBUTION ! ! BUSINESS PROPOSAL BUSINESS DESCRIPTION Micro-controller coding and verification (for detection) and distance measurement) 0% 100% 0% 0% Micro-controller coding and verification (for distance measurement) 0% 100% 0% 0% Business case 0% 0% 100% 0% Team management and organization 100% 0% 0% 0% Circuit soldering 0% 0% 65% 35% Various testing (testing for detection, distance, accuracy etc) 25% 25% 25% 25%
  • 54. Our product is a cell phone detector that can detect any device operating within a range from 1.7 GHz to 1.9 GHz. Specially; it allows users to detect precisely within a diameter of 11 meters any cell phones receiving a call, making a call, receiving a text message or sending texts messages, as well as being able to display information on whether the phone is close or far away from our device. Our Cell phone detector is portable, reliable and less expensive compared to other similar products in the market. TRAITS AND FEATURES FOR OUR SUCCESSFUL PRODUCT In the industry, there are traits which are used as guidelines on whether a product will be success- ful in the market or not. And, after extensive research and investigation, we have come to the conclusion that our device is an engineering innovation which meets the three main requirements of a successful product. • Novelty: Our cell phone detector has a specific and original design system compare to the other similar devices in the market which are not flexible or portable and three to four times more expensive than ours. • Usefulness: Our device can help fighting industrial Espionage, counterterrorism, inap- propriate transmission in casino, workers in hazardous areas distracted and student who are cheating during tests and exams by using cell phones. • Profitability: We have built for our product a cash flow analysis which present the detail strategy on how we are going to make a name for our product in the market and as well as an exponential business model progression. We assume, we can find an investment or borrow $ 100, 000 dollars to start a company with 6 people. And, by the end of 15 years, the company can have a net present value of cash flow of over $ 6,000,000 dollars, while paid off all debt. THE COMMERCIALIZATION PROCESS Commercialization of a product requires fulfilling the following criteria:
  • 55. 1. Launching time Factors such as market conditions, more time for improvement of product, or potential eclipsing of sales of other products are important to when it comes to determining the time of launch. Keeping this in mind, it can be seen that the present time is perfect to launch our device, or at least a basic version of it. With different types of organizations trying to secure their buildings from spying eyes, now is a ripe time to introduce our device. Cell phones are the most common way of disregarding privacy, and our device works to help prevent cell phone usage. 2. Potential customer Research and marketing are used to identify primary consumer groups. The ideal primary con- sumer group should consist of innovators, early adopters etc. This ensures adoption by other buyers in the market during the product-growth period. Based on this, we came up with a list of potential primary customers: • Government offices: Many offices contain places that have sensitive data and facts that should not be leaked out. A device that can detect cell phones would come pretty handy in these places to detect if cell phones are being used to compromise these data. • Airlines: Passengers on a plane are not allowed to use cell phones, but often people don’t pay attention to this rule. With our device, the cabin crew can find out if anyone is using phones and stop them from doing so. • Educational Institutions: Exams halls and classrooms are supposed to be free from call phone usage. Our device can make sure students are not using cell phones to cheat in ex- ams. A whole list of potential customer will be stated in next section. Apart from applied use of our product, we believe it can also be used in various research and ex- periments. Our device shows the power of the incoming call. And by knowing the power of a
  • 56. signal, much information can be gathered from it. So we believe that this can help in different researches. LAUNCH METHOD An action plan should be proposed by addressing the issues talked above. A marketing strategy has to be developed to launch the product. MARKETING STRATEGY The following are the steps that will be adopted to market our product 1. Concentrate our resources on optimal opportunities to increase sales and achieve a sustain- able competitive advantage 2. Initially low price to rapidly capture sales and market share 3. Retail channels and direct sales 4. Media Campaign TARGETED MARKET AND CUSTOMERS In order to justify that our product will make a successful business model, we have carried out a market research. In this section we are presenting our market and customers that we have con- cluded from our research. MAIN CUSTOMERS The following is the list of the main customers that we are expecting to sell our product to: • Government’s institutions • Military bases • Casinos
  • 57. • Airlines • Education institutions • Pharmaceutical companies • Hobby enthusiasts • Private wireless security companies that are in need of enforcing their cell-phones usage policies TARGETED MARKET: NORTH AND SOUTH AMERICA, EUROPE, ASIAAND AFRICA ! FIGURE 27: PLACES WHERE CELL PHONE DETECTORS ARE SOLD WORLWIDE (SPECIALLY- EXAMPLE FOR CUSTOMERS IN NORTH AMERICA) Given the list of customer we mentioned earlier, we present below the number of our customers in groups. This helped us to determine the market share that our product may have in North America: ! ● Hobby enthusiast person 100 000 ● Total Number of colleges and universities in North America 3000
  • 58. ● Total Number of Military Bases 400 ● Total Government institutions with restricted areas 500 ● Total pharmaceutical companies 100 ● Private Businesses 1000 According to the Association of American Colleges and Universities there are two thousand six hundred eighteen accredited four-year colleges and universities in the Unites States. GROWTH TRENDS IN THIS BUSINESS, PRICING POWER, MEAN TIME BETWEEN FAILURES Governments, educational institutions and private businesses are in need for a reliable product which can allow them to enforce their cell phones restricted areas policies. We have identified this market and implemented a cell phone detector which is very efficient in detecting any cell phone being used in unauthorized areas. The growth in our business will base on the fundamental economics’ theory which is: Decreasing the price or keeping it stable; the demand will increase. Also, we will keep improving our device, so we can keep selling more quantity to our customers and make new customers at the same time. The mean time between failures (MTBF) for our device is the estimated elapsed time between inherent failures of our product during operation. We calculated it to be 4 years based on the components we are intended to use to build our device. Below is a graph of how to calculate the MTBF. !
  • 59. ! PROJECT COST ESTIMATE AND CASH FLOW ANALYSIS Our project cost estimate is determined based on the components that we have used to build our device. ! PROJECT COST ESTIMATE The following includes the quantity and the price of essential the components for our project: Product Quantity = 1 Cost ($) ! Log-amplifier (AD8313) (Sample / Free) Monopole antenna (ANT-ELE-S01-006) $ 4.17 Magnetic base for the antenna $7.63 Micro-controller (PIC24F) (Borrowed from Lab) Antenna adapter $1.79 BPS StripBoard-3U (Prototype Board) $13.99 Operational Amplifiers (x5) (MCP602) $3.80 ($0.76/ea) Buzzer $2.00 Total = $33.38
  • 60. ! Now, we are going to present in details the economic feasibility of our project. We use an excel spreadsheet to elaborate a cash flow analysis table with a loan of $100,000 and payback period is 15 years.Each column of the resulting table corresponds to one year of operation, and each row accounts for a contributing factor to analyze our business. This technique is one of the most flexible and powerful ways to analyze an investment and study the economic feasibility of a business. It takes into account some complicating factors such as tax-deductible interest 8%, salaries $ 300,000 available, rent 3,000, number of units sold 1000 units first year and 1,500 for each year during the next 14 years, the price per unit $ 400, the net income, the cash flow and the most important the total profit we can make in the end of the 15 years of operation. On the table 1 above, we assumed for the first year we will sell 1000 units, and unit cost $120 to be made and the unit price is $ 400. We can see clearly, our total revenue for that first year will be $ 400,000; our direct costs $ 120,000 and our gross margin $280, 000 which result in a lost in the net income of - $27,000 the first year. However, during the subsequent years, we assumed our units sold will pass from 1000 to 1500 units and that we will result in an average net income of $79,000 and an average cash flow of approximately $73,000 after salaries, rent and opera- tional costs deducted. And, by year 3, we can see our revenue is approximately $ 1,800,00 dol- lars and by year 8, our revenue is over $ 2,000, 000 dollars Finally, we assume that we will be able to sell 22, 000 units during 15 years and open an account with an interest rate of 4% to put the cash flow of each year; the total future value is expected to be over $ 6,000,000 as a present value of our cash flow and our initial loan balance will be $ 0. !
  • 62. Identify all business risks that may compromise our success. A risk is a factor or event that may jeopardize our company from achieving the anticipated benefits or increase the cost production. The following are the examples of our business risks: • Legislative changes • Insufficient training • Inadequate communication • Conflicting priorities • Lack of Experience: Due to the inexperience in management and entrepreneurship • Inability to free-up critical business resources ! Taking into account all these risks and other possible undesired situations which may come up, we feel confident in our product and our business model will be able to grow. PROJECT RISKS AND ASSUMPTIONS The reason for writing the Project Risk Assessment is to provide an understanding of the risks that are related to the project and how these risks may vary. DESCRIPTION Identify all project risks that may relate to the project. A risk is a factor or event that may jeop- ardize the project from achieving the anticipated benefits or increase the cost of the project. The following are the examples of the project risks: • Programming: Most of the project designers have little to none experience in program- ming microcontrollers and hence, Schedule may be affected by this. • Lack of Experience: Due to the inexperience in using and operating electrical compo- nents we might cause some damage to the components and might have to reorder compo- nents which may affect our schedule. • Inability to free-up critical business resources
  • 63. Lastly we will create our proposed product based on the assumptions that the implementation part will be completed on time, and we will maintain the level of commitment that we have now. CONCLUSION Different scenarios prove how people misuse their mobile phones. It is clear that the need for a good cell phone detector is essential in many places to protect privacy and security. But when enquires were carried out, it seemed that cell-phone detectors are expensive to obtain. Also, they have other problems that could cause hindrance, such as lack of portability, and use of more dis- crete components in the circuitry that was harder to debug. We felt there was a need to come up with a better alternative, thereby coming up with the idea of this project. The proposition was to design and build a cell-phone detector that will have the de- sirable features of both of the previously mentioned products, but also make it less expensive and more flexible to user needs. In light of these requirements we proposed a design that is based on the idea of using a sudden increase in the power level of received cellular signal as an indication of a phone detected. In ad- dition, our proposed design incorporated a microcontroller to add a accuracy and novelty to our product. The circuit was then tested on the component and system scale. From the results, we were able to verify that our device meets the set requirements. Moreover, we were able to add a feature such that the device can tell when a the detected phone is close. Lastly, as per that date we were able to implement the device physically and demonstrate it. Therefore, we have confidence that we are able to create a cell phone detector that is a better option than other competitors in the mar- ket. Given the milestone that we have reached to that date, we are planning to take our device to the next step and commercialize it. This included finding the potential market for our device and building a strong business case as well as a financial plan.
  • 64. ! REFERENCES [1] C. Paslay, “Teens and Cell-phones: Some Startling Statistics”. Internet: http://chalkandtalk.- wordpress.com/2009/11/27/teens-and-cellphones-some-startling-statistics-2/ [November 2007] [2] “The Zone Protector Cellular, WiFi and Mobile Device Detection.” Internet: http://www.- cellbusters.com/zone-detector-the-ultimate-in-cell-phone-detection/ [September 2013] [3] “Wolfhound Pro Cell phone detector.” Internet: http://www. bvsystems.com/Products/Securi- ty/Wolfhound-Pro/wolfhound-pro.htm#specs [September 2013] [4] Analog Devices Inc, “Log Amp Basic” “Internet: http://www.analog.com/static/imported- files/tutorials/MT-077.pdf”, 2007 MT-077 Tutorial. [5] ARPN Journal of Science and Technology [Online], Vol. 2, No. 1, January 2012, ISSN 2225- 7217 [6] Analog Devices Inc, “0.1 GHz to 2.5 GHz 70 dB Logarithmic Detector/Controller”, AD8313 datasheet, 2004 [Rev D] [7] Analog Devices Inc, “Fast, Voltage-Out, DC to 440 MHz, 95 dB Logarithmic Amplifier” AD8310 datasheet, 2005-2010 [Rev F] [8] F. Viani, L. Lizzi, P. Rocca, M. Benedetti, M. Donelli and A. Massa, “Object tracking through RSSI measurements in wireless sensor networks”, IEEE Xplore, Vol. 44, No. 10, 8th May 2008 [9] J.T. Cohen et al, “Cellular Phone Use While Driving: Risks and Benefits”, Harvard Center for Risk Analysis, Harvard School of Public Health, Boston, Massachusetts [10 ] C. Masters, “Cell-Phones in Hospitals: Bad Prescription” Internet: http://www.time.com/ time/health/article/0,8599,1659417,00.html [September 2007]
  • 65. APPENDIX A CELL PHONE DETECTOR CIRCUIT ! ! ! ! ! ! ! APPENDIX B
  • 66. FLOWCHART OF PIC24F (MCU) PROGRAM ! ! ! ! ! ! ! ! ! C CODE OF PIC24F (MCU) PROGRAM The following is the C code implemented to be used with the microcontroller.
  • 67. MAIN.C / ***************************************************************************** */ /* Main FUNCTION FOR PIC24FJ128GA010 * Author: Nourhan Eid * Date: 10 November 2013 */ / ***************************************************************************** */ / ***************************************************************************** */ /* Files to Include */ / ***************************************************************************** */ //#include <stdint.h> /* Includes uint16_t definition */ //#include <stdbool.h> /* Includes true/false definition */ #include <stdio.h> #include <stdlib.h> ! #include "system.h" /* System funct/params, like osc/peripheral config */ #include "user.h" /* User funct/params, such as InitApp */ #include "LCD.h" #include "ADC.h" ! / ***************************************************************************** */ /* CONFIG */
  • 68. / ***************************************************************************** */ _CONFIG1( JTAGEN_OFF & GCP_OFF & GWRP_OFF & COE_OFF & FWDTEN_OFF & ICS_PGx2) _CONFIG2( FCKSM_CSDCMD & OSCIOFNC_OFF & POSCMOD_XT & FNOSC_PRI) ! / ***************************************************************************** */ /* Global Variable Declaration */ / ***************************************************************************** */ const unsigned int ADC_channel = ADC_CHANNEL; const unsigned int REF_volt = REF_VOLT; const unsigned int maxCount =3; const unsigned long V1 = 1470; //mV threshold voltage for far phone const unsigned long V2 = 2200; //mV threshold voltage for close phone const double Gain = 2.096; //linear gain const double y_intercept = -100; //Y interecept of log amp (-100) dBm const double slope = 17.5 ; //slope of log amp 17.5 mV/dBm unsigned long adc_val; long volt_in; long volt_count; long volt_count2; char msg[16] = "Power: dBm"; char msg2[15]; ! / ***************************************************************************** */ /* Main Program */ / ***************************************************************************** */ ! int main(void)
  • 69. { int inum; double Vin,Pin ; volt_count = 0; volt_count2 = 0; /* * I/O Pin Configurations */ AD1PCFG = 0xFFFF; // all ANs are digital I/O PORTB =0; AD1PCFGbits.PCFG8 = 0; //AN8 is analog TRISA = 0; ! /* * Initialization */ InitADC(); InitLCD(); clrLCD(); __delay_ms(3); ! while(1) { //Read input voltage by ADC adc_val = ReadADC (); __delay_ms (2); //Convert the ADC level to voltage in mV volt_in =(adc_val*3300)/1024; clrLCD(); homeLCD(); ! //If Voltage is very low then circuit not operating and battery is Off if (volt_in<1000) { putsLCD(1,1,"Turn Battery on.."); } else {
  • 70. //Calculate Power in dBm // Map voltage to input of signal conditioning Vin = volt_in / Gain; // Change the voltage to power in dBm via log amp Pin = (Vin / slope ) + y_intercept ; ! //Change the value to a string to be displayed on LCD if (Pin<0) { msg[6] ='-'; Pin = Pin *-1; } ! inum = (int)(Pin /10); msg[7] = inum+48; inum = ((int)(Pin) %10); msg[8]= inum+48; msg [9] = '.'; inum = ((int)(Pin*10)%10); msg[10]= inum+48; inum = ((int)(Pin *100)%10); msg[11]= inum+48; __delay_ms(1); ! //Display on LCD putsLCD(1,1,msg); } __delay_ms (2); ! //Move LCD cursor to second row cmdLCD (0xC0); if (volt_in>V1 ) { // When voltage is more than threshold V1 turn LED on and in- crease // the count it exceeded threshold V1 volt_count++; LATA = 0xFF; if (volt_in>V2)
  • 71. { // When voltage is more than threshold V2 increase the count it // exceeded V2 volt_count2++; if (volt_count2 > maxCount ) { // If the voltage exceeded threshold V2 for more than max_count2 // then phone detected and close // Display Phone Close on second row of LCD putsLCD(1,1,"Phone Close!"); // Sound the buzzer (connected to pin A15) _LATA15 = 1; } else { // If the voltage exceeded threshold V2 but not for pre- longed time // then phone is only detected putsLCD(1,1,"Phone Detected!"); _LATA15 = 1; } } else { volt_count2 =0; if (volt_count > maxCount ) { // If the voltage exceeded threshold V1 for more than max_count // then phone detected and away putsLCD(1,1,"Phone Detected!"); _LATA15 = 1; } } ! } else
  • 72. { // If voltage didnt exceed neither thresholds then no phone de- tected // Turn LED and buzzer off LATA= 0x0000; // Clear second row of LCD screen putsLCD(1,1," "); // Reset the counts volt_count =0; volt_count2=0; } __delay_ms(1000); } ! return (EXIT_SUCCESS); } ! LCD LIBRARY /* ** LCD.h ** * Author: Eid * * Created on November 9, 2013, 2:48 AM */ ! #ifndef LCD_H #define LCD_H ! /* Device header file */ #include "user.h" ! #define HLCD 16 // LCD width = 16 characters #define VLCD 2 // LCD height = 2 rows ! #define LCDDATA 1 // address of data register #define LCDCMD 0 // address of command register !
  • 73. void InitLCD( void); void writeLCD( int addr, char c); char readLCD( int addr); ! #define putLCD( d) writeLCD( LCDDATA, (d)) #define cmdLCD( c) writeLCD( LCDCMD, (c)) ! #define clrLCD() writeLCD( LCDCMD, 1); __delay_ms(1) #define homeLCD() writeLCD( LCDCMD, 2) ! #define setLCDG( a) writeLCD( LCDCMD, (a & 0x3F) | 0x40) #define setLCDC( a) writeLCD( LCDCMD, (a & 0x7F) | 0x80) ! #define busyLCD() ( readLCD( LCDCMD) & 0x80) #define addrLCD() ( readLCD( LCDCMD) & 0x7F) #define getLCD() readLCD( LCDDATA) ! void putsLCD( int row,int col, char *s); ! #endif /* LCD_H */ ! / ***************************************************************************** */ /* LCD.c : LCD library * Author: Nourhan Eid * Date: 9 November 2013 */ / ***************************************************************************** */ //#include <p24fxxxx.h> #include "LCD.h" ! void InitLCD( void) { // PMP initialization PMCON = 0x83BF; // Enable the PMP, long waits PMMODE = 0x3FF; // Master Mode 1
  • 74. PMAEN = 0x0001; // PMA0 enabled // init TMR1 //T1CON = 0x8030; // Fosc/2, 1:256, 16us/tick ! // wait for >30ms __delay_ms (32); // 2000 x 16us = 32ms //initiate the HD44780 display 8-bit init sequence PMADDR = LCDCMD; // command register PMDIN1 = 0b00111000; // 8-bit interface, 2 lines,5x7 __delay_us (48); // 3 x 16us = 48us PMDIN1 = 0b00001100; // disp ON, cursor off, blink off __delay_us (48); // 3 x 16us = 48us PMDIN1 = 0b00000001; // clear display __delay_us(1600); // 100 x 16us = 1.6ms PMDIN1 = 0b00000110; // increment cursor, no shift __delay_us(1600); // 100 x 16us = 1.6ms } // InitLCD ! ! char readLCD( int addr) { int dummy; while( PMMODEbits.BUSY); // wait for PMP to be available PMADDR = addr; // select the command address dummy = PMDIN1; // initiate a dummy read cycle while( PMMODEbits.BUSY); // wait for PMP to be available return( PMDIN1); // read the status register ! } // ReadLCD ! ! void writeLCD( int addr, char c) { while( busyLCD());
  • 75. while( PMMODEbits.BUSY); // wait for PMP to be available PMADDR = addr; PMDIN1 = c; } // WriteLCD ! void putsLCD(int row,int col, char *s) { int i; cmdLCD(6); //Increment cursur __delay_ms(1); if (row<=2 && col<=16){ if (row==2){ cmdLCD (0xC0); __delay_ms(1); } i=1; while (i< col){ putLCD(32); __delay_ms(1); i++; } } while( *s) { putLCD( *s++); __delay_ms(1); } } //putsLCD ! ADC LIBRARY /* * File: ADC.h * Author: Eid * * Created on November 9, 2013, 2:48 AM */ ! #ifndef ADC_H
  • 76. #define ADC_H ! #include "user.h" ! #ifdef __cplusplus extern "C" { #endif ! ! ! ! #ifdef __cplusplus } #endif ! void InitADC (); //unsigned int ReadADC (unsigned int ch); unsigned long ReadADC (void); ! #endif /* ADC_H */ ! /* * File: ADC.c * Author: Eid * * Created on November 9, 2013 */ ! #include <stdio.h> #include <stdlib.h> ! #include "ADC.h" ! // initialize the ADC, select Analog input pins void InitADC( void) { /* AD1CON1 = 0x00E0; // auto convert after end of sampling AD1CSSL = 0; // no scanning required AD1CON3 = 0x1F3F; // max sample time = 31Tad, Tad = 2 x Tcy
  • 77. AD1CON2 = 0; // use MUXA, AVss and AVdd are used as Vref+/- AD1CON1bits.ADON = 1; // turn on the ADC*/ ! AD1CON1 = 0x80E4; //Turn on, auto sample start, auto- convert AD1CON2 = 0; //AVdd, AVss, int every conversion, MUXA only AD1CON3 = 0x1F05; //31 Tad auto-sample, Tad = 5*Tcy AD1CSSL = 0; // no scanning required AD1CHS = ADC_CHANNEL; ! _TRISB8 = 1; _LATB8=0; ! // Explorer 16 Development Board Errata (work around 2) // RB15 should always be a digital output _LATB15 = 0; _TRISB15 = 0; } // InitADC ! ! // sample/convert one analog input unsigned long ReadADC(void) { unsigned long Result; //AD1CHS = ADC_CHANNEL; // select analog input channel //AD1CON1bits.SAMP = 1; // start sampling, automatic conversion will follow while (!AD1CON1bits.DONE); // wait to complete the conversion Result = (long) ADC1BUF0; // read the conversion result return Result; } // readADC ! ! ! ! !
  • 78. APPENDIX C GANTT CHART AND PROJECT SCHEDULE Gantt chart for the implementations phase: ! Project Schedule (For the year 2013, during the months of September to December): TASKS Start Date Duration (Days) End Date Component Ordering and finishing last minute design details 03-Sep 22 24-Sep Setback - Transition to New design - Design Stage and New Component Ordering 25-Sep 21 15-Oct Circuit Implementation 16-Oct 11 26-Oct Component testing 27-Oct 10 05-Nov Partial System Testing 06-Nov 10 16-Nov Full System Testing 17-Nov 10 26-Nov Distance Measurement Testing 27-Nov 6 02-Dec
  • 79. ! ! The presentation and demonstration date was on December 3rd, 2013. The deadline to finish the work was December 2nd, 2013. As per the chart, it can be seen that despite a setback, the work was finished on time. Moreover, an important milestone was achieved by December 3rd ,2013 when we managed to demonstrate a working prototype for our device.

  • 80. !