Professional Documents
Culture Documents
INTRODUCTION
Todays era is electronics era. In our daily life we deal with number of
electronics goods and item. Technology is becoming a major part of our life.
So I am going to discuss a very common and adaptable project. Now a day
rush is growing very rapidly specially in public places. My project is visitor
Counter. Its very common in mall and offices. Where a smart device counts
the number of persons entered or exited from a cabin or some hall. To
demonstrate this model I am using the concept of IR along with
microcontroller and LCD. IR sensors are used to detect the persons entered
and exited. A microcontroller is used for counting. No of persons counted by
the microcontroller is show on LCD, Which is basically an output device. LCD
is a display device. LCD is passive device it needs some commands to
display something on it. Microcontroller is also responsible for the commands
of LCD. A power supply unit is used to Power up the Microcontroller, LCD and
sensors.
We are using this idea in our project to build a system which number of
students in the classroom.
Also we are building a attendance system in which every student is assigned
with a particular button for his attendance student has to press his button for
marking his attendance teacher in class also has his control with that he can
check the attendance of the students.
Basic Electronics
TRANSFORMER
Transformer works on the principle of mutual inductance. We know that if two
coils or windings are placed on the core of iron, and if we pass alternating
current in one winding, back emf or induced voltage is produced in the
second winding. We know that alternating current always changes with the
time. So if we apply AC voltage across one winding, a voltage will be induced
in the other winding. Transformer works on this same principle. It is made of
two windings wound around the same core of iron. The winding to which AC
voltage is applied is called primary winding. The other winding is called as
secondary winding. Transformers are of two types Step Up transformer and
Step Down transformer.
the load current. All transformer comes with different current rating e.g. 6 V
transformer is available in 500m A, 750mA, 1A, 2A so on. One thing should
be kept in mind as the ampear increases cost of transformer also increases.
We have to choose best one according to our circuit requirements.
RESISTORS
The flow of charge (or current) through any material, encounters an opposing
force similar in many respect to mechanical friction. This opposing force is
called resistance of the material. It is measured in ohms. In some electric
circuits resistance is deliberately introduced in the form of the resistor.
Resistors are of following types:
1. Wire wound resistors.
2. Carbon resistors.
3. Metal film resistors.
Carbon Resistors:
Carbon resistors are divided into three types:
a.
c.
Cement film resistors are made of thin carbon coating fired onto a
solid ceramic substrate. The main purpose is to have more precise
resistance values and greater stability with heat. They are made in a
small square with leads.
Variable Resistors:
Potentiometer is a resistor where values can be set depending on the
requirement. Potentiometer is widely used in electronics systems. Examples
are volume control, tons control, brightness and contrast control of radio or
T.V. sets.
2nd
3rd
band
band
(multiplier)
Black 0
100
Brown 1
101
Color
band 4th
band Temp.
(tolerance)
Coefficient
1% (F)
100 ppm
102
103
15 ppm
Yellow 4
104
25 ppm
Green 5
105
0.5% (D)
Blue
106
0.25% (C)
Violet 7
107
0.1% (B)
Gray
108
0.05% (A)
White 9
109
Red
Orang
e
2% (G)
Gold
101
5% (J)
Silver
102
10% (K)
None
Example:
Band1
20% (M)
1k or 1000 ohms
50 ppm
Band 2
Band 3
Band 4
CAPACITORS
A capacitor can store charge, and its capacity to store charge is called
capacitance. Capacitors consist of two conducting plates, separated by an
insulating material (known as dielectric). The two plates are joined with two
leads. The dielectric could be air, mica, paper, ceramic, polyester,
polystyrene, etc.
Non Polar Capacitor:- Those capacitor have no polarity are known as NONpolar capacitor. Ceramic capacitor are the example of non polar capacitors
dielectric disc, which acts as capacitor plates. Leads are attached to each
sides of the
proof coating. Disc type capacitors have very high value up to 0.001uf. Their
working voltages range from 3V to 60000V. These capacitors have very low
leakage current. Breakdown voltage is very high.
circuits. There are also diodes which emit "light", of course these are known
as light-emitting-diodes or LED's.
a rectifying diode of the 1N4001-07 ( 1A) type or even one of the high power,
high current stud mounting types. You will notice the straight bar end has the
letter "k", this denotes the "cathode" while the "a" denotes anode. Current
can only flow from anode to cathode and not in the reverse direction, hence
the "arrow" appearance. This is one very important property of diodes.
The principal early application of diodes was in rectifying 50 / 60 Hz AC
mains to raw DC which was later smoothed by choke transformers and / or
capacitors. This procedure is still carried out today and a number of
rectifying schemes for diodes have evolved, half wave, full wave and bridge,
full wave and bridge rectifiers.
As examples in these applications the half wave rectifier passes only the
positive half of successive cycles to the output filter through D1. During the
negative part of the cycle D1 does not conduct and no current flows to the
load. In the full wave application it essentially is two half wave rectifiers
combined and because the transformer secondary is centre tapped, D1
conducts on the positive half of the cycle while D2 conducts on the negative
part of the cycle. Both add together. This is more efficient. The full wave
bridge rectifier operates essentially the same as the full wave rectifier but
does not require a cetre tapped transformer. Further discussion may be seen
on the topic power supplies
1N4148 Diode
The 1N4148 and 1N4448 are high-speed switching diodes fabricated in
planar technology, and encapsulated in hermetically sealed leaded glass
SOD27 (DO-35) packages.
FEATURES
Hermetically sealed leaded glass SOD27 (DO-35) package
High switching speed: max. 4 ns
General application
APPLICATIONS
High-speed switching
IC
IC (Integrated Circuit) means that all the components of the circuit are
fabricated on same chip. Digital ICs are a collection of resistors, diodes, and
transistors fabricated on a single piece of semiconductor, usually silicon
called a substrate, which is commonly referred to as wafer. The chip is
enclosed in a protective plastic or ceramic package from which pins extend
out connecting the IC to other device. Suffix N or P stands for dual-in-line
(plastic package (DIP) while suffix J or I stands for dual-in-lime ceramic
package. Also the suffix for W stands for flat ceramic package.
The pins are numbered counter clockwise when viewed from the top of the
package with respect to an identity notch or dot at one end of the chip.The
manufacturers name can usually be guessed from its logo that is printed on
the IC. The IC type number also indicates the manufacturers code. For e.g.
DM 408 N SN 7404 indicates National Semiconductor and Texas Instruments.
: UA, UAF
National Semiconductor
Motorola
: MC, MFC.
Sprague
Signetic
Burr-Brown
: BB.
Texas Instruments
: SN.
The middle portion i.e. the IC type number tells about the IC function and
also the family, which the particular IC belongs to.ICs that belongs to
standard TTL series have an identification number that starts with 74; for e.g.
7402, 74LS04, 74S04 etc. ICs that belongs to standard CMOS family their
number starts with 4, like 4000, 451B, 4724B, 1400. The 74C, 74HC, 74AC &
74ACT series are newer CMOS series.
Various series with TTL logic family are:Standard TTL 74.
Schottky TTL 74s.
Low power Schottky 74LS.
Advance Schottky 74AS.
Advanced Low Power Schottky 74ALs.
Also there are various series with CMOS logic family as metal state CMOS 40
or 140.
RELAYS
A relay is an electrically operated switch. The relay contacts can be made to
operate in the pre-arranged fashion. For instance, normally open contacts
STRIP
OUT N/C
OUT N/O
SPRING
230V
P
MAGNET
USE OF RELAY
The reason behind using relay for switching loads is to provide complete
electrical isolation. It means that there is no electrical connection between
the driving circuits and the driven circuits. The driving circuit may be low
voltage operated low power circuits that control several kilowatts of power. In
our circuit where a high fan could be switched on or off depending upon the
output from the telephone.
Since the relay circuit operated on a low voltage, the controlling circuit is
quite safe. In an electromagnetic relay the armature is pulled by a magnetic
force only. There is no electrical connection between the coil of a relay and
the switching contacts of the relay. If there are more than one contact they
all are electrically isolated from each other by mounting them on insulating
plates and washers. Hence they can be wired to control different circuits
independently.
Some of the popular contacts forms are described below:
1. Electromagnetic relay
2. Power Relay.
3. Time Delay Relay.
4. Latching Relay.
5. Crystal Can Relay.
6. Co-axial Relay
1. Electromagnetic relay:
An electromagnetic relay in its simplest form consists of a coil, a DC current
passing through which produces a magnetic field. This magnetic field
2. Power relays:
Power relays are multi-pole heavy duty lapper type relays that are capable of
switching resistive loads of upto 25amp.. These relays are widely used for a
variety of industrial application like control of fractional horse power motors,
solenoids, heating elements and so on. These relays usually have button like
silver alloy contacts and the contact welding due to heavy in rush current is
avoided by wiping action of the contacts to quench the arc during high
voltage DC switching thus avoiding the contact welding.
4. Latching Relay:
In a Latching Relay, the relay contacts remain in the last energized position
even after removal of signal in the relay control circuit. The contacts are held
in the last relay-energized position after removal of energisation either
electrically or magnetically. The contacts can be released to the normal
position electrically or mechanically.
Transistor:-
DC
transistors with the same part number. The gain also varies with the collector
current and temperature.
The pull down resistor in the first circuit forces Vout to become LOW except
when the push button switch is operated. This circuit delivers a HIGH voltage
when the switch is pressed. A resistor value of 10
is often used.
In the second circuit, the pull up resistor forces Vout to become HIGH except
when the switch is operated. Pressing the switch connects Vout directly to 0 V.
In other words, this circuit delivers a LOW voltage when the switch is
pressed.
In circuits which process logic signals, a LOW voltage is called 'logic 0' or just
'0', while a HIGH voltage is called 'logic1' or '1'. These voltage divider circuits
are perfect for providing input signals for logic systems.
What kinds of switches could you use. One variety of push button switch is
called a miniature tactile switch. These are small switches which work
well with prototype board:
LED:- LED means light emitting diode. Its function is similar to the diode.
But these are not made up from silicon or germanium. These are generally
used as a indicating device. There are variety of LEDs are available in market
depending upon their size and colour.
Polarity of LED:- LED have polarity. We can judge its polarity by watching
flags in its structure. Bigger flag is known as cathode and smaller flag is
known as anode as shown below.
Voltage Regulator
employ
internal
current-limiting,
thermal
shutdown
and
safe-area
Features
Output current up to 1 A
Output voltages of 5; 6; 8; 9; 12; 15; 18; 24 V
Thermal overload protection
Short circuit protection
MICROCONTROLLERS (MCU)
Figure shows the block diagram of a typical microcontroller, which is a
true computer on a chip. The design incorporates all of the features found
in micro-processor CPU, ALU, PC, SP, and registers. It also added the other
features needed to make a
counters,and clock circuit.
complete
4.1
8051 MICROCONTROLLER
VCC:
Pin 40 provides supply voltage to the chip. The voltage source is +5 Volts.
GND:
Pin 20 is the ground.
RST:
Pin 9 is the RESET pin. It is an input and is active high. Upon applying a
high pulse to this pin the microcontroller well reset and terminate all
activities. This is often referred to as a power on reset .Activating a power on
reset will cause all values the registers to be lost. It will set program counter
to all 0s.
In order for the RESET input to be effective it must have a minimum duration
of two machine cycles. In other words the high pulse must be high for a
minimum of two machine cycles before it is allowed to go low.
EA:
The 8051 family members such as the 8751/52, 89C51/52 or
DS89C4*0 all come with on chip ROM to store programs. In such cases the
EA pin is connected to Vcc. For family members such as the 8031 and 8032
in which there is no on chip ROM, code is stored on an external ROM and is
fetched by 8031/32. Therefore for the 8031 the EA pin must be connected to
GND to indicate that the code is stored externally. EA which stands for
external access is pin number 31 in the DIP packages. It is an input pin and
must be connected to either Vcc or GND. In other words it can not be
unconnected.
PSEN:
This is an output pin. PSEN stands for program store enable. In an
8031 based system in which an external ROM holds the program code, this
pin is connected to the OE pin of the ROM.
ALE: ALE stands for address latch enable. It is an output pin and is active
high. When connecting an 8031 to external memory, port 0 provides both
address and data. In other words the 8031 multiplexes address and data
through port 0 to save pins. The ALE pin is used for de-multiplexing the
address and data by connecting to G pin of the 74LS373 chip.
PORTS 0,1,2,3:
All the ports upon RESET are configured as input, since P0-P3 have
value FFH on them. The following is a summary of features of P0-P3.
PORT 0:
Port 0 is also designated as AD0-AD7 allowing it to be used for both
address and data. When connecting an 8051/31 to an external memory, port
0 provides both address and data. The 8051 multiplexes address and data
through port 0 to save pins. ALE indicates if p0 has address A0-A7.in the
8051 based systems where there is no external memory connection the pins
of P0 must be connected externally to 10k-ohm pull-up resistor. This is due to
the fact that P0 is an open drain, unlike P1, P2 and P3. Open drain is a term
used for MOS chips in the same way that open collector is used for TTL chips.
In many systems using the 8751, 89c51 or DS89c4*0 chips we normally
connect P0 to pull up resistors.
PORT 1, PORT 2:
In 8051 based systems with no external memory connection both P1
and P2 are used as simple I/O. however in 8031/51 based systems with
external memory connections P2 must be used along with P0 to provide the
16-bit address for the external memory.
memory P2 is used for the upper 8 bits of the 16 bit address and it cannot be
used for I/O.
PORT 3:
Port 3 occupies a total of 8 pins 10 through 17. It can be used as input
or output. P3 does not need any pull-up resistors the same as P1 and P2 did
not. Although port 3 is configured as input port upon reset this is not the way
it is most commonly used. Port 3 has the additional function of providing
some extremely important signals such as interrupts.
Port 3 Alternate functions:
P3 Bit
Function
Pin
P3.0
RxD
10
P3.1
TxD
11
P3.2
INT0
12
P3.3
INT1
13
P3.4
T0
14
P3.5
T1
15
P3.6
WR
16
P3.7
RD
17
b) B REGISTER:
B register is same as that of accumulator of. It is also an 8 bit register and
every bit of this is accessible. This is also a mathematical register B which is
used mostly for multiplication and division.
c) PSW (PROGRAM STATUS WORD) Register:
Program status word register is an 8 bit register. It is also referred to as the
flag register. Although the PSW register is 8 bits wide, only 6 bits of it are
used by the 8051. The unused bits are user-definable flags. Four of the flags
are called conditional flags, meaning that they indicate some conditions that
result after an instruction is executed. These four are CY (carry), AC (auxiliary
carry), P (parity) and OV (overflow).
CY
PSW.7
Carry Flag
AC
PSW.6
Auxiliary
Carry Flag
F0
PSW.5
Available
to the user
for
General
Purpose
RS1
PSW.4
Register
Bank
Selector
Bit 1
RS0
PSW.3
Register
Bank
Selector
Bit 0
OV
PSW.2
Overflow
Flag
--
PSW.1
User
Definable
Bit
PSW.0
Parity
Flag.
\The stack, such as PUSH, POP, LCALL, RET, RETI, and whenever interrupts are provoked by
the microcontroller.
d) DPL/DPH (DATA POINTER LOW/HIGH, ADDRESSES 82H/83H):
The SFRs DPL and DPH work together to represent a 16-bit value called
the Data Pointer. The data pointer is used in operations regarding external
RAM and some instructions involving code memory. Since it is an unsigned
two-byte integer value, it can represent values from 0000h to FFFFh (0
through 65,535 decimal).
BLOCK DIAGRAM
Working
It
is
very
useful
system,
In
this
system
an
intelligent
system
MATERIAL USED
1. Transformer
2. Diodes 1N4007
3. Capacitor (470uF,1000uf,22pf)
4. Voltage Regulator (7805 & 7812)
5. Resistors
6. LED
7. Microcontroller
8. IC bases
9. Crystal
10.
Switches
11.
IR sensors
12.
IC bases
13.
Relay
14.
BC 557
15.
BC 547
16.
Ribbon wire
17.
Jumper wire
18.
Soldering Iron
19.
Soldering Wire
20.
Multimeter
21.
PCB
22.
Cutter
SCHEMATIC
WORKING
Power supply: - Power supply is the essential part of any device or project.
We are using microcontroller and LED. These components needs +5V DC
supply. So we need a power supply circuit of +5V DC. Power supply circuit
includes step down transformer, rectifier circuit, filter circuit and regulator
circuit. An indicating component is also attached with the power supply to
indicate the power ON condition of power supply unit.
Most of LED operates at 1.5 to 2.5V voltage range with 8-10 mA. LED used
here is of 5mm size. We consider that LED operating at 1.6V with 8mA
current. We can calculate the value of resistor using the KVC law.
Total Voltage= Voltage across resistor+ Voltage across LED
LED and resistor are connected in series so same current will flow.
Means 8mA current will flow through the resistor.
Now Total Voltage is =5V
Voltage across resistor is =1.6v
Current is = 8mV
So our equation will be
5V= (10mA * resistance) + 1.6V
3.4V=10mA * resistance
Resistance =3.4/10mA
= 450 ohm
Thus we can calculate the any series resistor for any input voltage and LED.
CRYSTAL DISPLAY
A liquid crystal display (LCD) is a thin, flat electronic visual display that
uses the light modulating properties of liquid crystals (LCs). LCs does not
emit light directly. LCDs therefore need a light source and are classified as
"passive" displays. Some types can use ambient light such as sunlight or
room lighting. There are many types of LCDs that are designed for both
special and general uses.
LCDs are more energy efficient, and offer safer disposal, than CRTs. Its low
electrical power consumption enables it to be used in battery-powered
electronic equipment.
The LCD Module can easily be used with an 8051 microcontroller such as the
162A. The LCD Module comes with a 16 pin connector. This can be plugged
into connector 16 pin.
Most common LCDs connected to the 8051 are 16x2 and 20x2 displays. This
means 16 characters per line by 2 lines and 20 characters per line by 2 lines,
respectively.
PIN
Name
Function
VSS
Ground voltage
VCC
+5V
VEE
Contrast voltage
Register
RS
Select
Instruction
Register
1 = Data Register
Read/
5
R/W
Write,
to
choose
write
or
read
write
mode
mode
1 = read mode
Enable
6
start
to
1= disable
7
DB0
LSB
DB1
DB2
10
DB3
11
DB4
12
DB5
13
DB6
14
DB7
MSB
15
BPL
16
GND
Ground voltage
latch
data
to
LCD
character
The user may select whether the LCD is to operate with a 4-bit data bus or
an 8-bit data bus. If a 4-bit data bus is used, the LCD The 44780 standard
requires 3 control lines as well as either 4 or 8 I/O lines for the data bus. The
user may select whether the LCD is to operate with a 4-bit data bus or an 8bit data bus. If a 4-bit data bus is used, the LCD will require a total of 7 data
lines (3 control lines plus the 4 lines for the data bus). If an 8-bit data bus is
used, the LCD will require a total of 11 data lines (3 control lines plus the 8
lines for the data bus).
The three control lines are referred to as EN, RS, and RW.
Enable:-The EN line is called "Enable." This control line is used to tell the
LCD that you are sending it data. To send data to the LCD, your program
should first set this line high (1) and then set the other two control lines
and/or put data on the data bus. When the other lines are completely ready,
bring EN low (0) again. The 1-0 transition tells the 44780 to take the data
currently found on the other control lines and on the data bus and to treat it
as a command.
Register Select:-The RS line is the "Register Select" line. When RS is low
(0), the data is to be treated as a command or special instruction (such as
clear screen, position cursor, etc.). When RS is high (1), the data being sent
is text data which should be displayed on the screen. For example, to display
the letter "T" on the screen you would set RS high.
Read Write:-The RW line is the "Read/Write" control line. When RW is low
(0), the information on the data bus is being written to the LCD. When RW is
high (1), the program is effectively querying (or reading) the LCD. Only one
instruction ("Get LCD status") is a read command. All others are write
commands--so RW will almost always be low.
another feature of IR sensors is that these ray reflected back by the objects.
This assembly is used in the robots.
RELAY CIRCUIT
relay the coil allows the contacts at the other side to work. Relays are used
where it is necessary to control a circuit by a low-power signal (with
complete electrical isolation between control and controlled circuits), or
where several circuits must be controlled by one signal. Like relays,
transistors can be used as an electrically operated switch. For switching
small DC currents at low voltage they are usually a better choice than a
relay. However, transistors cannot switch AC (such as mains electricity) and
in simple circuits they are not usually a good choice for switching large
currents (> 5A). In these cases a relay will be needed.
A low power transistor may still be needed to switch the current for the
relay's coil. Here in circuit Q1 and Q2 transistors are used to switch the relay.
First transistor is PNP transistor so it will be switch on when it get low
pulse at its base. When it get a low its base then +5V is available at the base
of second transistor. Second transistor is NPN. It switched on when it get high
pulse at the base. When a low is available at the base of first transistor then
+5V is available at the base of transistor which results in switch ON of relay.
Advantages of relays:
Relays can switch AC and DC, transistors can only switch DC.
Relays are often a better choice for switching large currents (> 5A).
PROGRAM
;********
******************Student
**********************************
ORG 00H
MOV A,#38H
;2*16 MATRIX
MOV A,#01h
ACALL COMMAND
MOV A,#0CH
ACALL COMMAND
MOV A,#06H
ACALL COMMAND
mov a,#80h
acall command
Counting
mov dptr,#tabelhh
acall display
check:
jb p1.0,visitorin
jb p1.1,visitorout
jmp check
visitorin:
inc r1
mov a,r1
acall write
visitorout:
dec r1
mov a,r1
acall write
jmp check
LCDCLR:
MOV A,#01H
ACALL COMMAND
RET ; DISPLAY DATA ON LCD
DISPLAY:
CLR A
MOVC A,@A+DPTR
ACALL WRITE
INC DPTR
JMP DISPLAY
NEXT:
RET
WRITE:
ACALL CHKBUSY
MOV LCD,A
SETB RS
CLR RW
SETB E
acall delay
CLR E
RET
COMMAND:
ACALL CHKBUSY
MOV LCD,A
CLR RS ; instruction
CLR RW
SETB E
CLR E
RET
CHKBUSY:
SETB FL
SETB RW
CLR RS
CHECK4:
CLR E
SETB E
JNB FL,CHECK4
RET
delay1:
MOV R4,#50
AGAIN22: MOV R5,#150
BACK22: DJNZ R5, AGAIN22
DJNZ R4, BACK22
RET
DELAY:
MOV R6,#255
AGAIN: MOV R7,#255
BACK: DJNZ R7,BACK
DJNZ R6,AGAIN
RET
tabelhh: DB 'Visitors ',0
end
;********
******************
Attendance**********************************
ORG 00H
MOV A,#38H
ACALL COMMAND
MOV A,#38H
ACALL COMMAND
MOV A,#38H
ACALL COMMAND
MOV A,#01h
ACALL COMMAND
MOV A,#0CH
ACALL COMMAND
MOV A,#06H
ACALL COMMAND
check:
;2*16 MATRIX
;2*16 MATRIX
;2*16 MATRIX
;CLEAR DISPLAY SCREEN
;DISPLAY ON CURSOR OFF
;DISPLAY ON CURSOR OFF
JNB p1.0,ACC1
JNB p1.1,ACC2
JNB p1.2,ACC3
JNB p1.3,ACC4
Student
JNB
JNB
JNB
JNB
p1.4,DIP1
p1.5,DIP2
p1.6,DIP3
p1.7,DIP4
jmp check
ACC1:
MOV CAR1,#00H
CLR P3.0
mov dptr,#tabel22
acall display
CLR BUZZER
jmp check
ACC2:
MOV CAR2,#00H
CLR P3.1
mov dptr,#tabel33
acall display
CLR BUZZER
acall delay1
SETB BUZZEr
jmp check
ACC3:
MOV CAR3,#00H
mov dptr,#tabel44
acall display
CLR BUZZER
jmp check
ACC4:
MOV CAR4,#00H
CLR P3.3
mov dptr,#tabel55
acall display
CLR BUZZER
jmp check
DIP1:
MOV A,CAR1
CJNE A,#00H,DIP42
mov dptr,#tabel22
acall display
acall delay1
acall clrscr
jmp check
DIP2:
MOV A,CAR2
CJNE A,#00H,DIP42
mov dptr,#tabel33
acall display
acall delay1
acall clrscr
jmp check
DIP3:
MOV A,CAR3
CJNE A,#00H,DIP42
mov dptr,#tabel44
acall display
acall delay1
acall clrscr
jmp check
DIP4:
MOV A,CAR4
CJNE A,#00H,DIP42
mov dptr,#tabel55
acall display
acall delay1
acall clrscr
jmp check
DIP42:
mov dptr,#tabel55
acall display
acall clrscr
jmp check
delay1: acall delay
call delay
call delay
ret
clrscr: mov a,#01h
acall command
ret
DISPLAY:
CLR A
MOVC A,@A+DPTR
JZ NEXT
NEXT:
WRITE: CALL DELAY
MOV LCD,A
SETB RS
CLR RW
SETB E
CALL DELAY
CLR E
RET
COMMAND: CALL DELAY
MOV p1,A
CLR rs
CLR RW
SETB E
CALL DELAY
CLR E
RET
delay_lcd:
mov r7,#15h
jjk: mov r6,#200
djnz r7,jjk
ret
delay: mov r7,0ffh
aa:
mov r6,0ffh
bb:
nop
djnz r7,bb
djnz r6,aa
ret
tabelhh:
tabel22:
tabel33:
tabel44:
tabel55:
end
DB ATTENDANCE SYS',
db '1101',
db ' 1102',
db ' 1103',
db '1104',