You are on page 1of 5

U8 VCC U6 33 PF U1 31 18 19 9 EA/VPP RST XTAL2 XTAL1 P1.7 P1.6 P1.5 P1.4 P1.3 P1.2 P1.1 P1.0 P0.7/AD7 P0.

6/AD6 P0.5/AD5 P0.4/AD4 P0.3/AD3 P0.2/AD2 P0.1/AD1 P0.0/AD0 AT89C51 ALE/PROG PSEN P3.7/RD P3.6/WR P3.5/T1 P3.4/TO P3.3/INT1 P3.2/INTO P3.1/TXD P3.0/RXD P2.7/A15 P2.6/A14 P2.5/A13 P2.4/A12 P2.3/A11 P2.2/A10 P2.1/A9 P2.0/A8 30 29 17 16 15 14 13 12 11 10 28 27 26 25 24 23 22 21

LPT PIN-2

IF_IN

6 5

VCC

C2 12 MHz xTAL

Y1

33 PF VCC

C3

C1 10 UP

U6 32 33 34 35 36 37 38 39

8 7 6 5 4 3 2 1

LPT PIN-25

IF_IN

2 470 e R2 U8

4 MCT2E 10 K

2k2 R2

R2

IF_OUT

P1.0

LPT PIN-3

IF_IN

6 5

VCC

IF_IN

Card Reader
2k2 R2 R2
IF_IN IF_OUT

R1 47 K

LPT PIN-25

IF_IN

2 470 e R2 U8

4 MCT2E 10 K

P1.1

LPT PIN-4

IF_IN

6 5

VCC

LPT PIN-25

IF_IN

2 470 e R2

4 MCT2E 10 K R2

2k2

R2

IF_OUT

P1.2

U8

LPT PIN-5

IF_IN

6 5

VCC

LPT PIN-25

IF_IN

2 470 e R2 U8

4 MCT2E 10 K R2

2k2

R2

IF_OUT

P1.3

LPT PIN-6

IF_IN

6 5

VCC

LPT PIN-25

IF_IN

2 470 e R2

4 MCT2E 10 K

2k2 R2

R2

IF_OUT

P0.4

MICROCANTROLAR AND LPT PORT INTERFACING CIRCUIT

CONECTOR

TRANSFORMER STEPDOWN SW1 1 2 8 T1 4 4 1 5 3 IN 4007 + 2 C5 470 UF ADJ 1 1 U11 VIN IC1 7812 VOUT 3 +12v U6

ON / OFF SWITCH 230 V AC 50 HZ


CONECTOR

-9v

vcc

U11 VIN

IC1 7909 VOUT ADJ

U11 VIN ADJ

IC1 7905 VOUT

POWER SUPPLY CIRCUIT

U8 1 VCC U6 6 5 4 2 470 e R2 10 K 1 U7 6 5 4 2k2 2 470 e R2 U8 1 VCC U6 6 5 4 2 470 e R2 10 K 1 U7 6 5 4 2k2 2 470 e R2 MCT2E 10 K R2 2 R2 R2


+12v

IF_IN

+12v

4 2k2 R2 2 R2
+12v

K1 3
IF_IN

U8 1 VCC U6 6 5 4 2 470 e R2 10 K 1 U7 6 5 4 2k2 2 470 e R2 MCT2E 10 K R2 2 1 RELAY Q2 3BC547 R2 1 2 R2


+12v +12v

P2.0
MCT2E

1 2 1 RELAY Q1 3BC547 K2 3

4 2k2 R2 2 1 2

K1 3

P2.4
MCT2E

0
IF_IN

4 R2 2 10 K R2 1 2

1 RELAY Q1 3BC547 K2 3

P2.1

0
IF_IN

MCT2E

1 RELAY Q2 3BC547

P2.5

IF_IN

+12v

P2.2

4 2k2 R2 2 1 2

K1 3

MCT2E

1 RELAY Q1 3BC547 K2 3

0
IF_IN

P2.3

1 2 1 RELAY Q2 3BC547

RELAY INTERFACE CIRCUIT

CIRCUIT DESCRIPTION

This one is a simple timing control project that executes many times-based tasks. An Atmel Micro controller has become our target micro controller. Micro controller kit is interface with our PC. The circuit diagram shows the interfacing the micro controller with our PCs LPT port pin 2,3,4,5,6 & 25. LPT port pin 2 to pin 9 are output pin and 25 pin is ground pin. LPT port pin 2 is connected to pin no 1 MCT2E through resistor 270 ohms and MCT2E pin 2 is connected to LPT port pin 25. Simultaneously all MCT2E is connected to all LPT port pin 3 to 6 and pin 25 (MCT2E is a optocoupler IC) to protect the PC and micro controller kit) All pin 5 of MCT2E is connected to Vcc of power supply and all pin 4 of MCT2E is connected to its micro controller port P 1. P 1.0,P 1.1, P 1.2, P1.3, P1.4 respectively through resistor 1k. Capacitor 10 micro Farad 50V is connected to pin 9 through resistor 10K ohms and crystal 12 MHz and 33 pico Farad is connected is connected to pin 18 and pin 19 of micro controller. The micro controller port 2 of pin 21. 22, 23, 24 and 25 (P2.3, P2.4, P2.5, P2.6, P2,7) is connected to all MCT2E pin 2, of all through resistor 270 ohm and pin 1 is connected to board. Pin 4 is connected the box of transistor BC 457 through resistor 10K and collector of transistor is connected to 12V through resistor 270 ohm and R1Y5 (12V).

The data from the PC is given to micro controller. The micro controller then calculates the bit and proceeds further. The control will be transferred to the relay unit. As per the data fetched from the PC the micro controller operates on it. Then the power board controls all the room power supply.

The circuit is given the power supply, using the Transformer. It is given 230 V AC supply. Four diodes are connected to the transformer. Voltage Regulators are used to regulate the voltage. The following voltage regulators are used to generate various outputs : 7812 regulator generates a +12V supply. 7912 regulator generates a 12V supply. 7809 regulator generates +9V supply. 7805 regulator generates +5V vcc supply. - 12V is given to the relay. - +5V, vcc are given to the Pin No. 31,40 of the Micro Controller 89C51.

You might also like