Showing posts with label keil code. Show all posts
Showing posts with label keil code. Show all posts

Monday, 17 June 2013

8051 interfacing with the buzzer

8051 interfacing with the buzzer

 components:  1) AT89C51 microcontroller

                       2) crystal oscillator

                       3) k1 buzzer

                       4) 4.7k resistor

                      5) 2 pcs 0.01uf capacitor

                      6) 5v power supply

                      7) inverter

Description: this is the post about interfacing microcontroller with a k1 buzzer.

                    pin 40 and 31 is connected to vcc(5v). port 1.5 is connected with

                    a inverter and then to the buzzer.pin 18 and 19 are connected to a crystal oscillator with    ceramic 0.01uf capacitor.

  The buzzer gets turned on when port 2.3 is high.

For resetting the buzzer pin 31 and 3 are connected together with 1uf capacitor and and then connected to ground through 8.2k resistor.

 CODE: 

org 00H

HERE: JNB P2.3,HERE                        ;keep monitoring for high

            SET B P1.5                                 ;set bit P1.5

            CLR P1.5                                    ;make P1.5 low

           SJMP HERE                               ; keep repeating

          END

the code is compiled in keil uvision software.

For any assistance or problem or query comment below.

happy innovention...................................

 

password: circuitsandprogram

download link of complete project: http://d01.megashares.com/dl/zIlpiG7/1

 

 

About the author

Scholar Ratan pal singh is a Google scholar, a man with innovative ideas and a nothing is impossible attitude, is a tech-lover.
He works as a independent researcher and freelance website and software developer.
Member of IEEE comsoc society, Green technology society and has published research paper and codes in many international journals and opensource.

"Failure is the pillar of success and Honesty with oneself is the only true way of achieving self-confidence."

Translate

Pageviews