0% found this document useful (0 votes)
75 views69 pages

Wireless Desktop Operation For PC

Wireless Desktop Operation for PC www.btechzone.com INDEX CONTENTS 1. Abbreviations 2. Figures locations 3. Abstract 4. Introduction 5. Block Diagram 6. Schematic 8. Schematic 9. Hardware components Power supply Max-232 PC's IR Transmitter and Receiver keypad 10.Software components 11. Source Code 12. Conclusion (or) Synopsis 13. Future Aspects Name Accumulator B register Program status word Stack pointer data pointer 2 bytes low byte high byte Port0 port

Uploaded by

sahumeenakshi17
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
75 views69 pages

Wireless Desktop Operation For PC

Wireless Desktop Operation for PC www.btechzone.com INDEX CONTENTS 1. Abbreviations 2. Figures locations 3. Abstract 4. Introduction 5. Block Diagram 6. Schematic 8. Schematic 9. Hardware components Power supply Max-232 PC's IR Transmitter and Receiver keypad 10.Software components 11. Source Code 12. Conclusion (or) Synopsis 13. Future Aspects Name Accumulator B register Program status word Stack pointer data pointer 2 bytes low byte high byte Port0 port

Uploaded by

sahumeenakshi17
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 69

www.btechzone.

com

Wireless Desktop
Operation for
PC
w w w. b t e c h z o n e . c o m
www.btechzone.com

INDEX

CONTENTS

1. Abbreviations
2. Figures locations
3. Abstract
4. Introduction
5. Block Diagram
6. Block Diagram Description
7. Schematic
8. Schematic Description
9. Hardware Components
 Microcontrollers
 Power supply
 Max-232
 PC’s
 IR Encoder & Decoder
 IR Transmitter & Receiver
 Keypad
10.Software components

a. About Kiel
w w w. b t e c h z o n e . c o m

b. Embedded ‘C’

11. Source Code

12.Conclusion (or) Synopsis

13. Future Aspects

14. Bibliography
www.btechzone.com

1. Abbreviations:

Symbol Name
ACC Accumulator
B B register
PSW Program status word
SP Stack pointer
DPTR Data pointer 2 bytes
DPL Low byte
DPH High byte
P0 Port0
P1 Port1
P2 Port2
P3 Port3
IP Interrupt priority control
IE Interrupt enable control
TMOD Timer/counter mode control
TCON Timer/counter control
T2CON Timer/counter 2 control
T2MOD Timer/counter mode2 control
TH0 Timer/counter 0high byte
TL0 Timer/counter 0 low byte
TH1 Timer/counter 1 high byte
TL1 Timer/counter 1 low byte
TH2 Timer/counter 2 high byte
TL2 Timer/counter 2 low byte
SCON Serial control
SBUF Serial data buffer
PCON Power control

2. Figure Locations:
w w w. b t e c h z o n e . c o m

Pg.No. Fig No Figure Name:


14 1 Architecture of uc
15 2 Oscillator Connection
15 3 External clock drive configuration
16 4 Memory structure of the 8051
www.btechzone.com

17 5 Program memory
18 6 Internal data memory
19 7 The lower 128 bytes of ram
22 8 Accumulator register
23 9 B register
23 10 Registers
25 11 RAM locations
26 13 PSW
28 14 DPTR register
29 15 SP register
29 16 I/O port register
30 17 Pin diagram
38 18 Timer register
40 19 TCON register
43 20 DB9 connector
44 21 8051 connection to RS232
45 22 SCON register
w w w. b t e c h z o n e . c o m
www.btechzone.com

3. Abstract:
In present days the use of computer is growing rapidly with the boom in IT
field. There is a great impact of IT field. And day by day, the need for computations
with great speed and accuracy also increased the usage of computers. Computer
became a basic amenity for students. Students are using computers for their academic
work. The other applications apart from above mentioned are to play audio and video
files etc. Even kids became regular users of computer due to their passion towards
games.

But sitting in front of monitor for hours and hours has a great impact
on our eyes as well as body. So here is an approach to do all these mouse operations
and some of the keypad operations remotely by using IR communication and
DOTNET.
w w w. b t e c h z o n e . c o m

The present project will do all the operations of the mouse as well as the some
functions of the Keyboard like Enter, Windows button and Direction keys as well.
Just use your computer as a TV with the help of this remote.

In this we are going to use IR communication and .NET as main platforms.


Here the signals of our remote are transmitted to the receiver section including
microcontroller, which is nearer to the PC, through IR. The signals from this
www.btechzone.com

controller are sent to the PC via serial communication through DB-9 connector. And
finally the operations are all done by the COM controls by the use of .NET.

The .NET is used for the front-end application development. Here we are
using the COM controls to interface the controller. The block diagram of the present
project including the transmitter and receiver section along with PC is shown below.

4. Introduction:

In this project our aim is to develop an automated system


to control all the operations of the key board and the mouse in order rescue
the eyes those who are sitting in front of the system hours together. So,
here we about to control all the functions of the mouse and some of the
functions of keyboard such as, a) directional keys (b) start windows (c)
Close windows (d) enter key.
To do all these operations firstly we need to install the
software which is done as a front end application in .Net.
Actually the project is combination of to sections divided
on the bases of wireless communication of IR. The first section consists
the monitoring part of controller which is serially interfaced to the PC
through RS232 and MAX232. The second section deals with Remote
keypad consisting of twelve keys with twelve different operations and is
w w w. b t e c h z o n e . c o m

operated with IR communication and acts as transmitter.


www.btechzone.com

5. BLOCK DIAGRAM:

Remote Section:

Power Supply

IR
IR transmitter
ENCODER
w w w. b t e c h z o n e . c o m

KEYPAD Section
www.btechzone.com

Receiver Section:

Power Supply

Microcontroller

IR IR
receiver decoder

DB-9 MAX-232
Connector
PC
w w w. b t e c h z o n e . c o m
www.btechzone.com

6. Block Diagram Explanation:

Microcontrollers:

In this project the micro-controller is playing a major role. Micro-


controllers were originally used as components in complicated process-control systems.
However, because of their small size and low price, Micro-controllers are now also being
used in regulators for individual control loops. In several areas Micro-controllers are
now outperforming their analog counterparts and are cheaper as well.

IR Sensor:

IR transmitter as IR LED used to transmit IR rays .

Since the IR rays are out of the visible range we cannot observe the rays
from the transmitter.

These are Infrared LEDs; the light output is not visible by our eyes. They can be
used as replacement LEDs for remote controls, night vision for camcorders, invisible
beam sensors, etc. Here this IR transmitter is used as remote keypad. Through these keys
we are giving instructions to the PC to perform the operations. Individual keys having
individual functionalities.

Tsop:
w w w. b t e c h z o n e . c o m

The TSOP17.. – Series are miniaturized receivers for infrared remote control
systems. PIN diode and preamplifier are assembled on lead frame, the epoxy package is
designed as IR filter. The demodulated output signal can directly be decoded by a
microprocessor. TSOP17.. is the standard IR remote control receiver series, supporting
all major transmission codes. It can be seen on the receiver side and rays emitted by
transmitter are taken by the TSOP and sends to the controller.
www.btechzone.com

IR Encoder:

Encoder is for encoding the data given by the keys and the respected encoded data
is emitted into the air. We use SM5021 IC for the encoder which as 14 pin with 8 data
pins, one data output (enable) pin, VCC, GND and OSC.

IR Decoder:

Decoder is used for decoding the data given by the encoder. We should maintain
the same address for the transmission and receiving of the data at the encoder and
decoder pins. For decoding also we aare using a 14 pin IC which as one data input pin, 8
data pins, VCC, GND and OSC.

MAX232:

To allow compatibility among data communication equipment made by various


manufactures, an interfacing standard called RS232 was set by the Electronic Industries
Association (EIA).This RS-232 standard is used in PCs and numerous types of equipment
.However, since the standard was set long before the advent of the TTL logic family, its
w w w. b t e c h z o n e . c o m

input and output voltage levels are not TTL compatible. In RS-232 ,a 1 is represented by
-3 to -25V,while a 0 bit is +3 to +25V,making -3 to +3 undefined. For this reason, to
connect any RS-232 to a microcontroller system we must use voltage converters such as
MAX232 to convert the TTL logic levels to the RS-232 voltage levels and vice versa.

POWER SUPPLY
www.btechzone.com

A variable regulated power supply, also called a variable bench power supply, is
one where you can continuously adjust the output voltage to your requirements. Varying
the output of the power supply is the recommended way to test a project after having
double checked parts placement against circuit drawings and the parts placement guide.
This type of regulation is ideal for having a simple variable bench power supply. Actually
this is quite important because one of the first projects a hobbyist should undertake is the
construction of a variable regulated power supply. While a dedicated supply is quite
handy e.g. 5V or 12V, it's much handier to have a variable supply on hand, especially for
testing. Most digital logic circuits and processors need a 5 volt power supply. To use
these parts we need to build a regulated 5 volt source. Usually you start with an
unregulated power supply ranging from 9 volts to 24 volts DC (A 12 volt power supply is
included with the Beginner Kit and the Microcontroller Beginner Kit.). To make a 5 volt
power supply, we use a LM7805 voltage regulator IC.

The LM7805 is simple to use. You simply connect the positive lead of your
unregulated DC power supply (anything from 9VDC to 24VDC) to the Input pin, connect
the negative lead to the Common pin and then when you turn on the power, you get a 5
volt supply from the Output pin.
w w w. b t e c h z o n e . c o m

7. Schematic:
TX
w w w. b t e c h z o n e . c o m

RX
www.btechzone.com
w w w. b t e c h z o n e . c o m www.btechzone.com
www.btechzone.com

8. Schematic Diagram:

IR Remote:

The one end of IR LED is connected to the supply of 9v with a resister and the
other end is connected to the transistor which is been switched with according to the pin
15 DOUT. 8 switches are connected to the 8 keys pins of the IC SM5021 (IR
encoder).namely 3, 4, 5, 6, 7, 9, 10, and 11th with diodes IN4007 in-between.

IR Receiver:
Here for the IR decoder we are using SM5032 which is a 14 pin IC. The 8 data
pins of the decoder SM5032 such as 3, 4, 5, 6, 7, 8, 9 and 10 are totally dedicated to the
complete PORT2 of the controller.
11th and 12 th of the decoder are been short to GND.
TSOP:
Two of the pins are connected to GND and the VCC respectively and the
remaining one is connected to the IR decoder with the pin number 2 and 14 which
includes a transistor for switching.

The RESET and the OSCILLATOR circuits are connected to 9 th and 18th, 19th pins
of the controllers.

MAX232:
The 11th and 12th pins of MAX are interfaced to 11th and 10th pins of controller
w w w. b t e c h z o n e . c o m

respectively.
The 13th and 14th pins of MAX are interfaced to 3rd and 2nd pins of DB9 connector
which is indirectly fitted to PC.
The 5th pin DB9 is GND.
www.btechzone.com

9. Hardware Components:

MICRO CONTROLLER (AT89S51)

Introduction
A Micro controller consists of a powerful CPU tightly coupled with memory,
various I/O interfaces such as serial port, parallel port timer or counter, interrupt
controller, data acquisition interfaces-Analog to Digital converter, Digital to Analog
converter, integrated on to a single silicon chip.
If a system is developed with a microprocessor, the designer has to go for external
memory such as RAM, ROM, EPROM and peripherals. But controller is provided all
these facilities on a single chip. Development of a Micro controller reduces PCB size and
cost of design.
One of the major differences between a Microprocessor and a Micro controller is
that a controller often deals with bits not bytes as in the real world application.
Intel has introduced a family of Micro controllers called the MCS-51.

Figure: micro controller


w w w. b t e c h z o n e . c o m

Features:
www.btechzone.com

• Compatible with MCS-51® Products


• 4K Bytes of In-System Programmable (ISP) Flash Memory
– Endurance: 1000 Write/Erase Cycles
• 4.0V to 5.5V Operating Range
• Fully Static Operation: 0 Hz to 33 MHz
• Three-level Program Memory Lock
• 128 x 8-bit Internal RAM
• 32 Programmable I/O Lines
• Two 16-bit Timer/Counters
• Six Interrupt Sources
• Full Duplex UART Serial Channel
• Low-power Idle and Power-down Modes

Description
The AT89S51 is a low-power, high-performance CMOS 8-bit microcontroller with 4K bytes of
in-system programmable Flash memory. The device is manufactured using Atmel’s high-
density nonvolatile memory technology and is compatible with the industry- standard 80C51
instruction set and pinout. The on-chip Flash allows the program memory to be reprogrammed
in-system or by a conventional nonvolatile memory programmer. By combining a versatile 8-
bit CPU with in-system programmable Flash on a monolithic chip, the Atmel AT89S51 is a
powerful microcontroller which provides a highly-flexible and cost-effective solution to many
embedded control applications.
w w w. b t e c h z o n e . c o m

Block diagram:
www.btechzone.com

Figure: Block diagram

Pin diagram:
w w w. b t e c h z o n e . c o m

Figure: pin diagram of micro controller


www.btechzone.com

Pin Description
VCC - Supply voltage.
GND - Ground.
Port 0:
Port 0 is an 8-bit open drain bidirectional I/O port. As an output port, each pin can sink
eight TTL inputs. When 1s are written to port 0 pins, the pins can be used as high-impedance
inputs. Port 0 can also be configured to be the multiplexed low-order address/data bus during
accesses to external program and data memory. In this mode, P0 has internal pull-ups. Port 0
also receives the code bytes during Flash programming and outputs the code bytes during
program verification. External pull-ups are required during program verification.

Port 1:
Port 1 is an 8-bit bidirectional I/O port with internal pull-ups. The Port 1 output buffers
can sink/source four TTL inputs. When 1s are written to Port 1 pins, they are pulled high by
the internal pull-ups and can be used as inputs. As inputs, Port 1 pins that are externally being
pulled low will source current (IIL) because of the internal pull-ups. Port 1 also receives the
low-order address bytes during Flash programming and verification.

Port 2:
w w w. b t e c h z o n e . c o m

Port 2 is an 8-bit bidirectional I/O port with internal pull-ups. The Port 2 output buffers
can sink/source four TTL inputs. When 1s are written to Port 2 pins, they are pulled high by
the internal pull-ups and can be used as inputs. As inputs, Port 2 pins that are externally being
pulled low will source current (IIL) because of the internal pull-ups. Port 2 also receives the
high-order address bits and some control signals during Flash programming and verification.
Port 3:
www.btechzone.com

Port 3 is an 8-bit bidirectional I/O port with internal pull-ups. The Port 3 output buffers
can sink/source four TTL inputs. When 1s are written to Port 3 pins, they are pulled high by
the internal pull-ups and can be used as inputs. As inputs, Port 3 pins that are externally being
pulled low will source current (IIL) because of the pull-ups. Port 3 receives some control
signals for Flash programming and verification. Port 3 also serves the functions of various
special features of the AT89S51, as shown in the following table.

RST:
Reset input. A high on this pin for two machine cycles while the oscillator is running
resets the device. This pin drives High for 98 oscillator periods after the Watchdog times out.
The DISRTO bit in SFR AUXR (address 8EH) can be used to disable this feature. In the
default state of bit DISRTO, the RESET HIGH out feature is enabled.
ALE/PROG:
w w w. b t e c h z o n e . c o m

Address Latch Enable (ALE) is an output pulse for latching the low byte of the address
during accesses to external memory. This pin is also the program pulse input (PROG) during
Flash programming. In normal operation, ALE is emitted at a constant rate of 1/6 the oscillator
frequency and may be used for external timing or clocking purposes. Note, however, that one
ALE pulse is skipped during each access to external data memory. If desired, ALE operation
can be disabled by setting bit 0 of SFR location 8EH. With the bit set, ALE is active only
www.btechzone.com

during a MOVX or MOVC instruction. Otherwise, the pin is weakly pulled high. Setting the
ALE-disable bit has no effect if the microcontroller is in external execution mode.

PSEN:
Program Store Enable (PSEN) is the read strobe to external program memory. When
the AT89S51 is executing code from external program memory, PSEN is activated twice each
machine cycle, except that two PSEN activations are skipped during each access to external
data memory.
EA/VPP:
External Access Enable. EA must be strapped to GND in order to enable the device to
fetch code from external program memory locations starting at 0000H up to FFFFH. Note,
however, that if lock bit 1 is programmed, EA will be internally latched on reset. EA should be
strapped to VCC for internal program executions. This pin also receives the 12-volt
programming enable voltage (VPP) during Flash programming.
XTAL1:
Input to the inverting oscillator amplifier and input to the internal clock operating
circuit.
XTAL2:
Output from the inverting oscillator amplifier.

Oscillator Characteristics:
XTAL1 and XTAL2 are the input and output, respectively, of an inverting
amplifier which can be configured for use as an on-chip oscillator, as shown in Figs
6.2.3. Either a quartz crystal or ceramic resonator may be used. To drive the device from
w w w. b t e c h z o n e . c o m

an external clock source, XTAL2 should be left unconnected while XTAL1 is driven as
shown in Figure 6.2.4.There are no requirements on the duty cycle of the external clock
signal, since the input to the internal clocking circuitry is through a divide-by-two flip-
flop, but minimum and maximum voltage high and low time specifications must be
observed.
www.btechzone.com

Fig 6.2.3 Oscillator Connections Fig 6.2.4 External Clock Drive Configuration

IR MODULE:

Infrared (IR) radiation is part of the electromagnetic spectrum,


which includes radio waves, microwaves, visible light, and
ultraviolet light, as well as gamma rays and X-rays.

The IR range falls between the visible portion of the spectrum


and radio waves. IR wavelengths are usually expressed in
microns, with the lR spectrum extending from 0.7 to 1000
microns.

Using advanced optic systems and detectors, non-contact IR


w w w. b t e c h z o n e . c o m

thermometers can focus on nearly any portion or portions


of the0.7-14 micron band. Because every object (with the
exception of a blackbody) emits an optimum amount of IR
energy at a specific point along the IR band, each process
may require unique sensor models with specific optics and
detector types.
www.btechzone.com

For example, a sensor with a narrow spectral range centered


at 3.43 microns is optimized for measuring the surface
temperature of polyethylene and related materials. A sensor
set up for 5 microns is used to measure glass surfaces. A 1
micron sensor is used for metals and foils. The broader
spectral ranges are used to measure lower temperature
surfaces, such as paper, board, poly, and foil composites.

An object
reflects,
transmits, and
emits
energy, as
shown in the
diagram.

TSOP:

IR sensor TSOP 1738


 Photo detector and preamplifier circuit in the same casing.
 Receives and amplifies the infrared signal without any external component.
 5 V output (active at level 0).
 38 kHz integrated oscillator.
 High sensitivity.
w w w. b t e c h z o n e . c o m

 High level of immunity to ambient light.


 Improved shielding against electrical field interference.
 TTL and CMOS compatibility.
 Applications: infrared remote control.
www.btechzone.com

Technical specification
Supply: 5 V
Power consumption: 0.4 to 1.0 mA
Min. Ee irradiation: 0.35 mW/m2 typ.
Angle of detection: 90
Dimensions of the casing (mm): 12.5 x 10 x Thickness 5.8
Temperature range: -25 C to +85 C

DECODING IR REMOTE CONTROLS:

The origin of this posting was the question what to do with an old TV. I suggested
to use the infrared remote control as an input keyboard for a micro controller board and
w w w. b t e c h z o n e . c o m

mentioned a piece of code I had written for the 89S51 micro controller. I was asked by
some people to share my information about remote controls, so here it is:

There are at least two international standards, which are used by remote controls
to encode the commands, the RC5 and RECS 80 code. The RECS 80 code uses pulse
length modulation. Each bit to be transmitted is encoded by a high level of the duration T
www.btechzone.com

followed by a low level of duration 2T representing a logical '0' or 3T representing a


logical '1'.   T 2T T 3T T 2T

_ _ _
|| || ||
_| |__| |___| |__
0 1 0

Notice that a '1' takes more time to be transmitted than a '0'. The RC 5 code instead has a
uniform duration of all bits. A transition in the middle of the time interval assigned to
each bit encodes the logical value. A '0' is encoded by a high to low transition and a '1' by
a low to high transition. Therefore we need additional transitions at the beginning of each
bit to set the proper start level if a series of equal bits is sent. We don't need this
additional transition if the next bit has a different value. This is also called a 'bi phase'
code.

|1.Bit|2.Bit|3.Bit|4.Bit|

__ __ __ __
| | | | | |
|__| |_____| |__|
0 0 1 1
Instead of being fed direct into the IR emitter, most remote controls modulate a 20-30
kHz carrier with this signal. Logic one is represented by a burst of oscillations.
w w w. b t e c h z o n e . c o m

______/\/\/\/\_______/\/\/\/\________
0 1 0 1 0

The reason is, that you can use a filter tuned to the carrier frequency to distinguish the
signal from noise in the ambient light. Fluorescent lamps are the main source of such
noise. Photodiodes behind an optical filter, which transmits infrared light but blocks
www.btechzone.com

visible light, are used as detectors. The signal from the photodiode is fed through a filter
tuned to the carrier frequency and then amplified. The amplified signal is demodulated
just like the carrier is demodulated in any AM radio receiver.

It can be a lot of pain to design a sensitive receiver that doesn’t start to oscillate. It is also
necessary to have some automatic gain control to avoid overload of the amplifier at close
distance to the emitter. It is easier to use some integrated circuit that does all of the job.
The best i have ever seen (and used) is the TSOP.

If you don't know which code your remote control is transmitting you can identify it by
viewing the output of your receiver with an oscilloscope. The RECS 80 code uses high
pulses of uniform length while the low pulses differ in length. If there are high and low
pulses of two different lengths it might be RC5 code. Note that your receiver may invert
the levels.

How commands like volume are control or channel selction encoded? In the case of the
RC5 code there is an international standard. Every command is encoded by 14 bits. The
first two bits S are startbits to allow the receiver to adjust the automatic gain control and
to synchronize. Next a bit T follows, that toggles with every new keystroke. Next is the
address A of the device which shall respond to the command. At last the command itself
follows.

| S | S | T | A4 | A3 | A2 | A1 | A0 | C5 | C4 | C3 | C2 | C1 | C0 |
w w w. b t e c h z o n e . c o m

IR RECEIVER (TSOP)

Description
www.btechzone.com

The TSOP17.. – Series are miniaturized receivers for infrared remote control
systems. PIN diode and preamplifier are assembled on lead frame, the epoxy package is
designed as IR filter. The demodulated output signal can directly be decoded by a
microprocessor. TSOP17.. is the standard IR remote control receiver series, supporting
all major transmission codes.
Features
Photo detector and preamplifier in one package
Internal filter for PCM frequency
Improved shielding against electrical field disturbance
TTL and CMOS compatibility
Output active low
Low power consumption
High immunity against ambient light
Continuous data transmission possible
(up to 2400 bps)
Suitable burst length .10 cycles/burst
w w w. b t e c h z o n e . c o m
www.btechzone.com

Suitable Data Format


The circuit of the TSOP17.. is designed in that way that unexpected output
pulses due to noise or disturbance signals are avoided. A bandpassfilter, an integrator
stage and an automatic gain control are used to suppress such disturbances. The
w w w. b t e c h z o n e . c o m

distinguishing mark between data signal and disturbance signal are carrier frequency,
burst length and duty cycle. The data signal should fulfill the following condition• Carrier
frequency should be close to center frequency of the band pass (e.g. 38 kHz). Burst
length should be 10 cycles/burst or longer. • After each burst which is between 10 cycles
and 70cycles a gap time of at least 14 cycles is necessary. For each burst, which is longer
than 1.8ms, a corresponding gap time is necessary at some time in
www.btechzone.com

the data stream. This gap time should have at least same length as the burst. • Up to 1400
short bursts per second can be received continuously. Some examples for suitable data
format are: NEC Code, Toshiba Micom Format, Sharp Code, RC5 Code, RC6 Code, R–
2000 Code, Sony Format (SIRCS).When a disturbance signal is applied to the TSOP17..
it can still receive the data signal. However the sensitivity is reduced to that level that no
unexpected pulses will occur. Some examples for such disturbance signals which
are suppressed by the TSOP17.. are: • DC light (e.g. from tungsten bulb or sunlight)
• Continuous signal at 38kHz or at any other frequency Signals from fluorescent lamps
with electronic ballast.

IR-SENSOR

Infrared (IR) radiation is part of the electromagnetic spectrum, which


includes radio waves, microwaves, visible light, and ultraviolet light, as well as
gamma rays and X-rays.

The IR range falls between the visible portion of the spectrum and radio waves.
w w w. b t e c h z o n e . c o m

IR wavelengths are usually expressed in microns, with the lR spectrum extending


from 0.7 to 1000microns.

Using advanced optic systems and detectors, non-contact IR thermometers


can focus on nearly any portion or portions of the0.7-14 micron band. Because
every object (with the exception of a blackbody) emits an optimum amount of IR
www.btechzone.com

energy at a specific point along the IR band, each process may require unique
sensor models with specific optics and detector types.

For example, a sensor with a narrow spectral range center data 3.43
microns is optimized for measuring the surface temperature of polyethylene and
related materials. A sensor set up for 5 microns is used to measure glass surfaces.
A micron sensor is used for metals and foils. The broader spectral ranges are used
to measure lower temperature surfaces, such as paper, board, poly, and foil
composites.

The intensity of an object's emitted IR energy increases or decreases in


proportion to its temperature. It is the emitted energy, measured as the target's
emissivity that indicates an object's temperature.

Emissivity is a term used to quantify the energy-emitting characteristics of


different materials and surfaces. IR sensors have adjustable emissivity settings,
usually from 0.1 to 1.0, which allow accurate temperature measurements of
several surface types.

The emitted energy comes from an object and reaches the IR sensor through its
optical system, which focuses the energy onto one or more photosensitive
detectors. The detector then converts the IR energy into an electrical signal, which
is in turn converted into a temperature value

Based on the sensor's calibration equation and the target's emissivity. This temperature
value can be displayed on the sensor or, in the case of the smart sensor, converted to a
w w w. b t e c h z o n e . c o m

digital output and displayed on a computer terminal.

IR remote controls use wavelengths between 850 - 950nm. At this short wavelength,
the light is invisible to the human eye, but a domestic camcorder can actually view this
portion of the electromagnetic spectrum. Viewed with a camcorder, an IR LED appears
to change brightness.
www.btechzone.com

All remote controls use an encoded series of pulses, of which there are thousands of
combinations. The light output intensity varies with each remote control, remotes
working at 4.5V dc generally will provide a stronger light output than a 3V dc control.
Also, as the photodiode in this project has a peak light response at 850nm, it will receive
a stronger signal from controls operating closer to this wavelength. The photodiode will
actually respond to IR wavelengths from 400nm to 1100nm,so all remote controls should
be compatible.

A sensor is a type of transducer, or mechanism, that responds to a type of


energy by producing another type of energy signal, usually electrical. They are either
direct indicating (an electrical meter) or are paired with an indicator (perhaps indirectly
through an analog to digital converter, a computer and a display) so that the value sensed
is translated for human understanding. Types of sensors include electromagnetic,
chemical, biological and acoustic. Aside from other applications, sensors are heavily used
in medicine, industry& robotics.

In order to act as an effectual sensor, the following guidelines must be met:


 the sensor should be sensitive to the measured property
 the sensor should be insensitive to any other property
 the sensor should not influence the measured property

In theory, when the sensor is working perfectly, the output signal of a sensor is exactly
w w w. b t e c h z o n e . c o m

proportional to the value of the property it is meant to measure. The gain is then defined
as the ratio between output signal and measured property. For example, if a sensor
measures temperature and has an actual voltage output, the gain is a constant with the
unit.

When the sensor is not perfect, various deviations can occur, including gain error, long
www.btechzone.com

term drift, and noise. These and other deviations can be classified as systematic, or
random, errors. Systematic deviations may be compensated for by means of some kind of
calibration strategy. Noise is an example of a random error that can be reduced by signal
processing, such as filtering, usually at the expense of the dynamic behavior of the
sensor.

A sensor network is a computer network of spatially distributed devices using sensors to


monitor conditions (such as temperature, sound, vibration, pressure, motion or pollutants)
at a variety of locations. Usually the devices are small and inexpensive, allowing them to
be produced and deployed in large numbers; this constrains their resources in terms of
energy, memory, and computational speed and bandwidth. Each device is equipped with
a radio transceiver, a small micro controller, and an energy source, most commonly a
battery. The devices work off each other to deliver data to the computer which has been
set up to monitor the information. Sensor networks involve three areas: sensing,
communications, and computation (hardware, software, algorithms). They are applied in
many areas, such as video surveillance, traffic monitoring, home monitoring and
manufacturing.

Here the IR transmitter is nothing but the IR LED.

It just looks like a normal LED but transmits the IR signals.

Since the IR rays are out of the visible range we cannot observe the rays from the

transmitter.
w w w. b t e c h z o n e . c o m

These are infrared LEDs; the light output is not visible by our eyes. They can be used as

replacement LEDs for remote controls, night vision for camcorders, invisible beam

sensors, etc.
www.btechzone.com

Advantages:

 Infrared LEDs are ideal light sources for use with night vision goggles,
surveillance cameras, medical imaging, recognition and calibration
systems.

 Due to their resistance to ambient-light impediments and electromagnetic


interference (EMI), Infrared LEDs enhance the performance of wireless
computer-to-PDA links, collision avoidance systems, automation
equipment, biomedical instrumentation, and telecommunications
equipment.

 Solid-state design renders Infrared LEDs impervious to electrical and


mechanical shock, vibration, frequent switching and environmental
extremes. With an average life span of 100,000-plus hours (11 years),
Infrared LEDs operate reliably year-after-year.
w w w. b t e c h z o n e . c o m
www.btechzone.com

ENCODER SM (5021):
w w w. b t e c h z o n e . c o m
w w w. b t e c h z o n e . c o m www.btechzone.com
w w w. b t e c h z o n e . c o m www.btechzone.com
w w w. b t e c h z o n e . c o m www.btechzone.com
w w w. b t e c h z o n e . c o m www.btechzone.com
w w w. b t e c h z o n e . c o m www.btechzone.com
w w w. b t e c h z o n e . c o m www.btechzone.com
w w w. b t e c h z o n e . c o m www.btechzone.com
w w w. b t e c h z o n e . c o m www.btechzone.com
www.btechzone.com

IR Decoder:

Block diagram
w w w. b t e c h z o n e . c o m
www.btechzone.com

Pin Description:
w w w. b t e c h z o n e . c o m
www.btechzone.com

Functional Description:
w w w. b t e c h z o n e . c o m
www.btechzone.com

Power supply

The power supplies are designed to convert high voltage AC


mains electricity to a suitable low voltage supply for electronics circuits and other
w w w. b t e c h z o n e . c o m

devices. A power supply can by broken down into a series of blocks, each of which
performs a particular function. A d.c power supply which maintains the output voltage
constant irrespective of a.c mains fluctuations or load variations is known as “Regulated
D.C Power Supply”.
www.btechzone.com

For example a 5V regulated power supply system as shown below:

Fig 12

Transformer:
w w w. b t e c h z o n e . c o m

A transformer is an electrical device which is used to convert electrical power


from one

Electrical circuit to another without change in frequency.

Transformers convert AC electricity from one voltage to another with little loss of
power. Transformers work only with AC and this is one of the reasons why mains
www.btechzone.com

electricity is AC. Step-up transformers increase in output voltage, step-down


transformers decrease in output voltage. Most power supplies use a step-down
transformer to reduce the dangerously high mains voltage to a safer low voltage. The
input coil is called the primary and the output coil is called the secondary. There is no
electrical connection between the two coils; instead they are linked by an alternating
magnetic field created in the soft-iron core of the transformer. The two lines in the middle
of the circuit symbol represent the core. Transformers waste very little power so the
power out is (almost) equal to the power in. Note that as voltage is stepped down current
is stepped up. The ratio of the number of turns on each coil, called the turn’s ratio,
determines the ratio of the voltages. A step-down transformer has a large number of turns
on its primary (input) coil which is connected to the high voltage mains supply, and a
small number of turns on its secondary (output) coil to give a low output voltage.

An Electrical Transformer

Turns ratio = Vp/ VS = Np/NS

Power Out= Power In


w w w. b t e c h z o n e . c o m

VS X IS=VP X IP
Vp = primary (input) voltage
Np = number of turns on primary coil
Ip  = primary (input) current    
www.btechzone.com

RECTIFIER:

A circuit which is used to convert a.c to dc is known as RECTIFIER. The process


of conversion a.c to d.c is called “rectification”

TYPES OF RECTIFIERS:
 Half wave Rectifier
 Full wave rectifier
1. Centre tap full wave rectifier.
2. Bridge type full bridge rectifier.

Comparison of rectifier circuits:

Type of Rectifier
Parameter
Half wave Full wave Bridge
Number of diodes
1 2 4
PIV of diodes
Vm 2Vm Vm

D.C output voltage Vm/ 2Vm/ 2Vm/

Vdc,at 0.318Vm 0.636Vm 0.636Vm


no-load

Ripple factor 1.21 0.482 0.482


Ripple
frequency f 2f 2f
Rectification
efficiency 0.406 0.812 0.812
Transformer
Utilization 0.287 0.693 0.812
w w w. b t e c h z o n e . c o m

Factor(TUF)
RMS voltage Vrms Vm/2 Vm/√2 Vm/√2

Full-wave Rectifier:

From the above comparision we came to know that full wave bridge rectifier as more
advantages than the other two rectifiers. So, in our project we are using full wave bridge
rectifier circuit.
www.btechzone.com

Bridge Rectifier: A bridge rectifier makes use of four diodes


in a bridge arrangement to achieve full-wave rectification.
This is a widely used configuration, both with individual
diodes wired as shown and with single component bridges
where the diode bridge is wired internally.

A bridge rectifier makes use of four diodes in a bridge arrangement as shown in


fig(a) to achieve full-wave rectification. This is a widely used configuration, both with
individual diodes wired as shown and with single component bridges where the diode
bridge is wired internally.

Fig 13 (A)

Operation:

During positive half cycle of secondary, the diodes D2 and D3 are in forward
w w w. b t e c h z o n e . c o m

biased while D1 and D4 are in reverse biased as shown in the fig(b). The current flow
direction is shown in the fig (b) with dotted arrows.
www.btechzone.com

Fig 14 (B)
During negative half cycle of secondary voltage, the diodes D1 and D4 are in forward
biased while D2 and D3 are in reverse biased as shown in the fig(c). The current flow
direction is shown in the fig (c) with dotted arrows.

Fig 15 (C)

Filter:
w w w. b t e c h z o n e . c o m

A Filter is a device which removes the a.c component of rectifier output

but allows the d.c component to reach the load

Capacitor Filter:
We have seen that the ripple content in the rectified output of half wave rectifier is
121% or that of full-wave or bridge rectifier or bridge rectifier is 48% such high
www.btechzone.com

percentages of ripples is not acceptable for most of the applications. Ripples can be
removed by one of the following methods of filtering.

(a) A capacitor, in parallel to the load, provides an easier by –pass for the ripples voltage
though it due to low impedance. At ripple frequency and leave the d.c.to appears the load.

(b) An inductor, in series with the load, prevents the passage of the ripple current (due to
high impedance at ripple frequency) while allowing the d.c (due to low resistance to d.c)

(c) various combinations of capacitor and inductor, such as L-section filter section
filter, multiple section filter etc. which make use of both the properties mentioned in (a)
and (b) above. Two cases of capacitor filter, one applied on half wave rectifier and
another with full wave rectifier.

Filtering is performed by a large value electrolytic capacitor connected across the


DC supply to act as a reservoir, supplying current to the output when the varying DC
voltage from the rectifier is falling. The capacitor charges quickly near the peak of the
varying DC, and then discharges as it supplies current to the output. Filtering
significantly increases the average DC voltage to almost the peak value (1.4 × RMS
value).

To calculate the value of capacitor(C),

C = ¼*√3*f*r*Rl

Where,
w w w. b t e c h z o n e . c o m

f = supply frequency,

r = ripple factor,

Rl = load resistance

Note: In our circuit we are using 1000µF Hence large value of capacitor is placed
to reduce ripples and to improve the DC component.
www.btechzone.com

Regulator:
Voltage regulator ICs is available with fixed (typically 5, 12 and 15V) or variable output
voltages. The maximum current they can pass also rates them. Negative voltage
regulators are available, mainly for use in dual supplies. Most regulators include some
automatic protection from excessive current ('overload protection') and overheating
('thermal protection'). Many of the fixed voltage regulator ICs have 3 leads and look like
power transistors, such as the 7805 +5V 1A regulator shown on the right. The LM7805 is
simple to use. You simply connect the positive lead of your unregulated DC power
supply (anything from 9VDC to 24VDC) to the Input pin, connect the negative lead to
the Common pin and then when you turn on the power, you get a 5 volt supply from the
output pin.

Fig. 15 A Three Terminal Voltage Regulator


78XX:
The Bay Linear LM78XX is integrated linear positive regulator with three
w w w. b t e c h z o n e . c o m

terminals. The LM78XX offer several fixed output voltages making them useful in wide
range of applications. When used as a zener diode/resistor combination replacement, the
LM78XX usually results in an effective output impedance improvement of two orders of
magnitude, lower quiescent current. The LM78XX is available in the TO-252, TO-220 &
TO-263packages,
www.btechzone.com

Features:

• Output Current of 1.5A


• Output Voltage Tolerance of 5%
• Internal thermal overload protection
• Internal Short-Circuit Limited
• No External Component
• Output Voltage 5.0V, 6V, 8V, 9V, 10V,12V, 15V, 18V, 24V
• Offer in plastic TO-252, TO-220 & TO-263
• Direct Replacement for LM78XX
w w w. b t e c h z o n e . c o m
www.btechzone.com

10. Circuit Description:

In the above project discussed as far, we are not sure about actually the idea
regarding the project because , till now we had discussed about the different components
used in the project and their specifications, characteristics etc. but now we come across
the flow of data or the sequence of the connections regarding these components with the
microcontroller.

In this flow the place goes to the power supply circuit and which is also used any
application where ever the controller is necessary. That means power supply plays a
major role in any project. It is easy and simple either to built or learn. When the question
comes, “what are the major components used in the circuit ……?” Immediately the
answer is “It consists of four important components such as
- A transformer which is step down
- A rectifier bridge.
- A Electrolytic Capacitor and
- The voltage regulator”
The total operation and the action of the power supply circuit as already discussed
earlier.
Firstly when the key is pressed that is identified by the encoder which is again
encoded and forwards the respective signal to the LED which is also called as the IR TX
Then the IR is transmitted and was received by the IR Rx or the TSOP by which the same
w w w. b t e c h z o n e . c o m

signal is being amplified and sends to the decoder for the decoding purpose and then the
is forwarded to the controller. Their controller analysis the signal works according to the
program and the same signal is then send to the PC for the controlling with a mechanism
of serial communication. For this data to be communicate we have to under go a big
process called a serial communication. For the serial com to be a successful process we
need two mediators in between such as MAX232 and the RS232. MAX is a 16 pin IC
which is also called as a level converter, which means the voltage levels of the controller
www.btechzone.com

are converted to the PC voltage levels and vise versa. RS232 is a recommended standard
cable used for the wire connection between the max and the PC.
In this way we can operate our PC with out the KEY board and the mouse with
the help of a front end application which is done in .NET.

11 Software Components:

a. About Keil

1. Click on the Keil u Vision Icon on Desktop

2. The following fig will appear


w w w. b t e c h z o n e . c o m
www.btechzone.com

3. Click on the Project menu from the title bar

4. Then Click on New Project


w w w. b t e c h z o n e . c o m

5. Save the Project by typing suitable project name with no extension in u r own
folder sited in either C:\ or D:\
www.btechzone.com

6. Then Click on Save button above.

7. Select the component for u r project. i.e. Atmel……

8. Click on the + Symbol beside of Atmel


w w w. b t e c h z o n e . c o m

9. Select AT89C51 as shown below


www.btechzone.com

10. Then Click on “OK”

11. The Following fig will appear


w w w. b t e c h z o n e . c o m

12. Then Click either YES or NO………mostly “NO”


www.btechzone.com

13. Now your project is ready to USE

14. Now double click on the Target1, you would get another option “Source
group 1” as shown in next page.

15. Click on the file option from menu bar and select “new”
w w w. b t e c h z o n e . c o m
www.btechzone.com

16. The next screen will be as shown in next page, and just maximize it by double
clicking on its blue boarder.

17. Now start writing program in either in “C” or “ASM”

18. For a program written in Assembly, then save it with extension “. asm” and
for “C” based program save it with extension “ .C”
w w w. b t e c h z o n e . c o m
www.btechzone.com

19. Now right click on Source group 1 and click on “Add files to Group Source”

20. Now you will get another window, on which by default “C” files will appear.
w w w. b t e c h z o n e . c o m

21. Now select as per your file extension given while saving the file
www.btechzone.com

22. Click only one time on option “ADD”

23. Now Press function key F7 to compile. Any error will appear if so happen.

24. If the file contains no error, then press Control+F5 simultaneously.

25. The new window is as follows


w w w. b t e c h z o n e . c o m

26. Then Click “OK”


www.btechzone.com

27. Now Click on the Peripherals from menu bar, and check your required port as
shown in fig below

28. Drag the port a side and click in the program file.
w w w. b t e c h z o n e . c o m

29. Now keep Pressing function key “F11” slowly and observe.

30. You are running your program successfully


www.btechzone.com

b. Embedded C:
Data Types:

U people have already come across the word “Data types” in C- Language. Here
also the functionality and the meaning of the word is same except a small change in the
prefix of their labels. Now we will discuss some of the widely used data types for
embedded C- programming.

Data Types Size in Bits Data Range/Usage


unsigned char 8-bit 0-255
signed char 8-bit -128 to +127
unsigned int 16-bit 0 to 65535
signed int 16-bit -32,768 to +32,767
sbit 1-bit SFR bit addressable only
Bit 1-bit RAM bit addressable only
Sfr 8-bit RAM addresses 80-FFH
only

Unsigned char:

The unsigned char is an 8-bit data type that takes a value in the range of 0-255(00-
FFH). It is used in many situations, such as setting a counter value, where there is no
need for signed data we should use the unsigned char instead of the signed char.
w w w. b t e c h z o n e . c o m

Remember that C compilers use the signed char as the default if we do not put the key
word
www.btechzone.com

Signed char:

The signed char is an 8-bit data type that uses the most significant bit (D7 of D7-
D0) to represent the – or + values. As a result, we have only 7 bits for the magnitude of
the signed number, giving us values from -128 to +127. In situations where + and – are
needed to represent a given quantity such as temperature, the use of the signed char data
type is a must.

Unsigned int:

The unsigned int is a 16-bit data type that takes a value in the range of 0 to 65535
(0000-FFFFH). It is also used to set counter values of more than 256. We must use the int
data type unless we have to. Since registers and memory are in 8-bit chunks, the misuse
of int variables will result in a larger hex file. To overcome this we can use the unsigned
char in place of unsigned int.

Signed int:

Signed int is a 16-bit data type that uses the most significant bit (D15 of D15-D0)
to represent the – or + value. As a result we have only 15 bits for the magnitude of the
number or values from -32,768 to +32,767.
w w w. b t e c h z o n e . c o m

Sbit (single bit):

The sbit data type is widely used and designed specifically to access single bit
addressable registers. It allows access to the single bits of the SFR registers.
www.btechzone.com

11. Source Code:

12. Conclusion:

The project “Wireless Desktop Operation for PC” has been successfully designed and
tested.
Integrating features of all the hardware components used have
developed it. Presence of every module has been reasoned out and placed carefully thus
contributing to the best working of the unit.
w w w. b t e c h z o n e . c o m

Secondly, using highly advanced IC’s and with the help of growing technology the
project has been successfully implemented.
Data communication is blossoming at a great pace. As communication
systems evolve, service quality and capacity are of primary importance. To ensure
reliable communication over a mobile radio channel, a system must overcome multi path
fading, polarization mismatch, and interference. The trend towards low power hand held
transceivers increases all of these challenges. Keeping all the above parameters in view
www.btechzone.com

we have designed a low cost integrated system for transferring data between two Sections
of transmitter and the receiver.
Finally we conclude that IR Technology is an emerging field and there is a
huge scope for research and development.

13. Future Aspects:

The project “Wireless Desktop Operation for PC” as been developed to reach
w w w. b t e c h z o n e . c o m

its respective needs. With IR technology the project as been down very smoothly and
easily we can also enhance this project by replacing the IR with either the RF technology
or the GSM. By this, the distance of communication is further been increased and can be
advanced. If we use the GSM technology here we can operate our PC from any where in
the globe. Apart from this, we can also enhance this project by increasing the number of
keys and their functional operations so that we can do more applications on the PC
without the use of keyboard.
www.btechzone.com

14. Bibliography:

The 8051 Micro controller and Embedded


Systems

-Muhammad Ali Mazidi


Janice Gillispie Mazidi

The 8051 Micro controller Architecture,


Programming & Applications
w w w. b t e c h z o n e . c o m

-Kenneth J.Ayala

Fundamentals Of Micro processors and


Micro computers

-B.Ram

Micro processor Architecture, Programming


& Applications
www.btechzone.com

-Ramesh S.Gaonkar

Electronic Components

-D.V.Prasad

Wireless Communications
- Theodore S. Rappaport

Mobile Tele Communications


- William C.Y. Lee

References on the Web:


www.national.com
www.atmel.com
www.microsoftsearch.com
www.geocities.com
w w w. b t e c h z o n e . c o m

You might also like