contactless tachometer - 8085...

14
1 CONTACTLESS TACHOMETER Jasmeet Singh 67/EC/13 Jatin Singh - 69/EC/13

Upload: ngotu

Post on 19-Apr-2018

218 views

Category:

Documents


4 download

TRANSCRIPT

Page 1: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

1

CONTACTLESS

TACHOMETER

Jasmeet Singh 67/EC/13

Jatin Singh - 69/EC/13

Page 2: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

2

Contents

S. NO. TOPIC PAGE NO.

1. Acknowledgement 3

2. Abstract 3

3. Components Used 4

4. Schematic Details 5

5. Block Diagram 7

6. Schematic(s) 8

7. Board Layout 10

10. Code 11

11. Conclusion 13

12. Bibliography

14

Page 3: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

3

Acknowledgement

This is to acknowledge the invaluable contributions made by Prof.

Dhananjay Gadre for helping us at each stage of the project.

Furthermore we thank you for providing the necessary components and

access necessary to the facilities which enabled us to work comfortably

on our project.

We would also like to express our gratitude to the members of the

Microprocessors lab for their patience.

Abstract

The main aim of the project is to develop a contactless tachometer using

8085 Microprocessor.

The project has a LCD which displays the speed of the motor in rpm.

The blade of the motor is detected using phototransistor. The output of

comparator is fed at RST7.5 and the 555 timer generates a 1.1 second

pulse which is fed at RST6.5. Thus using 8085 microprocessor we can

calculate the number of pulses of RST 7.5 when RST 6.5 is high which

gives us the speed in revolutions per second.

The number of pulses are observed and after some calculations the

speed(in rpm) is displayed on the LCD.

Page 4: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

4

Components Used

Component Name Quantity Model No.

8085 Microprocessor 1 8085AHC

NAND Gate IC 1 74HC00N

RAM 32K 1 62256

EEPROM 32K 1 28C256

Latches 1 74HCT573N

Decoder 1 74HCT138N

8255 1 82C55AC

555 timer 1 10k

Comparator 1 LM311

Crystal 4MHz 1

Resistors - 1k,10k,2.2k,3.3k,100k

Capacitors - 0.1uF, 22uF, 10uF,100uf

Page 5: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

5

Schematic Details

8085 Microprocessor

Page 6: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

6

Data Bus Latch

8085 has a multiplexed data bus which must be de-multiplexed so that

general purpose memory devices can be used. The lower order data bus

is de-multiplexed using the ALE signal and the latch 74HCT573N.As

ALE goes low, the address on the bus AD7-AD0 is latched and the 8

output lines of the latch serve as lower order address lines. The address

on the latch remains the same until the next ALE signal.

Memory

32K of EEPROM is used. The memory addresses are from the range

0000H to 7FFFH. 32K of RAM is used. The memory addresses range is

from 8000H to FFFFH.

Page 7: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

7

Block Diagram

LCD

8255 8085

Micro

Processor

RAM

ROM

Motor

Phototransistor

Comparator

Page 8: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

8

Schematic(s)

Page 9: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

9

Page 10: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

10

Board Layout

Page 11: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

11

Code

.ORG 0000H

LXI SP,0FFFFH ; initialize stack pointer

JMP start

.org 02000h

.DB 057h,065h,06Ch,063h,06Fh,06Dh,065h,020h ;Welcome to

.DB 074h,06fh,054h,061h,063h,068h,06Fh,06Dh ;Tachometer

.DB 065h,074h,065h,072h,020h

.ORG 0034H

JMP six_serv

.ORG 003CH

JMP seven_serv

six_serv: RIM ;service routine for rst6.5

ANI 40H ;check if rst7.5 is present

JNZ increment

JMP main ;if rst7.5 is not present JMP to main

increment: INR E ;increment register E for every rst7.5

RET

seven_serv: CALL six_serv ;service routine for rst7.5

JMP main

hex_to_bcd: MOV A,E

MOV B,E

ANI 0FH

MOV C,A

MOV A,B

ANI F0H

ADD C

show_speed: MOV E,A ;E now holds speed in bcd

MVI A,98H

OUT 03H

mvi a,038h ;lcd initialzation command

out 01h

call cmd

mvi a,00fh

out 01h

call cmd

mvi a,006h

out 01h

call cmd

mvi a,001h

out 01h

call cmd

Page 12: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

12

mvi a,093h ;set location in lcd

out 01h

call cmd

lxi d,02000h

mvi b,00Ah

wel: ldax d

out 01h

call data

inx d

dcr b

jnz wel

mvi a,d0h

out 01h

call cmd

mvi b,011h

cmd: push psw

push d

mvi a,02h

out 03h

mvi a,00h

out 03h

mvi d,0ffh

data: push psw

mvi a,03h

out 02h

mvi a,01h

out 02h

pop psw

ret

start: MVI E,00H

main: EI

no_intr: DI ;if no interrupt is present it means first cycle is completed now disable the interrupt

CALL hex_to_bcd ;convert speed from hex to bcd

CALL show_speed ;show the speed on lcd

Page 13: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

13

Conclusion Overall working experience on this project was a great. This practical project not only strengthened our concepts but also showed us how to apply theoretical knowledge to build something useful. It made us aware of the advances that the electronics industry has made. It also helped us understand the integration of hardware and software.

Page 14: CONTACTLESS TACHOMETER - 8085 Projects8085projects.in/wp-content/uploads/2016/11/67EC13-69EC13-Report.pdf · 3 Acknowledgement This is to acknowledge the invaluable contributions

14

BIBLIOGRAPHY

Ramesh Gaonkar, Microprocessor Architecture, Programming and Applications with the 8085, Sixth edition.

http://www.alldatasheet.com/

http://www.circuitstoday.com/digital-tachometer-using-8051