1、B876214单片机Guangdong University of EducationBTEC CenterProgram: Electrical/Electronic Engineering (Electronic) Unit Title: Microprocessor Systems Unit No: 10 Assignment Title: Design Two Applications based on a MicrocontrollerAssignment No.: 1001 Issue Date: March 1,2011 Submission Deadline: Part 1:
2、May 1, 2011 Assessor/Tutor: Sunny Yao Internal Verifier: Ricky Zhang Student: Jianfeng Wu Students Reg. No: B876214 NOTES TO STUDENTS Check carefully the submission date and the instructions given with the assignment. Late assignments will not be accepted. Ensure that you give yourself enough time t
3、o complete the assignment by the due date. Do not leave things such as printing to the last minute excuses of this nature will not be accepted for failure to hand-in the work on time. You must take responsibility for managing your own time effectively. If you are unable to hand in your assignment on
4、 time and have valid reasons such as illness, you may apply (in writing) for an extension. When you refer to the work of other authors in your assignment, you must practice citation by following Harvard System for Referencing. If you are caught plagiarizing, you could have your grade reduced to zero
5、, or at worst, you could be excluded from the course.STUDENTS DECLARATION:I confirm that this is all my own work.Students Signature: Jianfeng Wu ASSESSMENT for Part 1GradeCriteria/DescriptorsEvidenceFeedbackAssessPass Assessment 2. Produce software for a microprocessor-based system2.1 Design softwar
6、e to a given specification using a structured design techniqueAn algorithm block flow diagram is presented.2.2 Write programs to implement designs using an appropriate computer languageAn executable program that meets the basic requirements is edited.2.3 Test software to ensure it meets the given sp
7、ecificationRunning result meets the given specification Grading AssessmentM1 identify and apply strategies to find appropriate solutionsAn effective approach to study and research has been applied Can use proper application software correctly.M2 select and apply appropriate methods/techniquesThe des
8、ign of methods/techniques has been justifiedA structured design technique is used very well.M3 present and communicate appropriate findingsThe communication is appropriate for familiar andunfamiliar audiences and appropriate media have been usedMake a lecture for your application design in class thr
9、ough media and have done it very clearly.D1 use critical reflection to evaluate own work and justify valid conclusionsThe validity of results has been evaluated using defined criteria and self criticism of approach has taken place The result has met requirement given and there is evaluation in your
10、assignment that explains programs advantages and disadvantages.D2 take responsibility for managing and organizing activitiesThe importance of interdependence has been recognized andachievedDo your assignment without other persons help.D3 demonstrate convergent/lateral/ creative thinkingInnovation an
11、d creative thought have been appliedProposed a creative thinking in your assignment.Assessors additional comments Assessors signature: Students Feedback Students signature:Notes:Assignment DescriptionScenarioRecently Atmel Company has successfully developed a new more powerful microcontroller (AT89S
12、51). 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 Atmels high-density nonvolatile memory technology and is compatible with the industry-standard 80C51 instruction set and pin out. The on
13、-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-
14、effective solution to many embedded control applications. In order to increase the new product market promotion, the company decides to organize a news conference for it. You are assigned to design an advertising demo system to display the convenient and powerful application development function of
15、this new product. The system you design must be able to demonstrate at least two applications based on this type of microcontroller. Part 1 (This part must be accomplished before May 1, 2011):Directly use the input/output ports of this microcontroller to do an application system. Please provide your
16、 design reports which must contain the following points: Task:1. (Pass Criterion 2.1) Design software to a given specification using a structured design technique. Design an algorithm block flow diagram using a structured design technique for your development.2. (Pass Criterion 2.2) Write programs t
17、o implement designs using an appropriate computer language. Please write the program in assembler or c language according to the algorithm block flow diagram above.3. (Pass Criterion 2.3) Test software to ensure it meets the given specification. Test the program until it meets the given specificatio
18、n. Please provide the schematic circuit of your design and a detailed description of the implementation phenomenon of your program in text and graphics or tables. My Report 1 Summarize1.1 Background The AT89S51 is a low-power, high-performance CMOS 8-bit microcontroller with 4K bytes of In-system Pr
19、ogrammable Flash memory. So this design is based on it. This design is a study on rotating lights and alarm. 1.2 Design methodThe design is a buzzer alarm with LED lights to achieve water on. Its hardware mainly consists of four components, a AT89C51 microcontroller chip, a switch button, a buzzer,
20、and LED lights.Eight LED lights through the P2 port is connected with the AT89C51. The SOUNDER through the P3.0 port is connected with the AT89C51. Switch control of the circuit through P1.7.When the switch is opened, the circuit will be powered. LED lights and the buzzer rang.2 Overall system progr
21、am and hardware designIn the recent research 梁炳东,2006 found these information. 2.1 C51 MCU tube feet and characteristics Integrated on a single chip CPU, memory, RAM, ROM and input and output interface circuit, the chip used to be known as the chip micro-computer, referred to as microcontrollers. IN
22、TEL MCS-51 microcontroller is introduced in 1980, high-end 8-bit microcontroller. Its typical products: 8051,8031,8751,80 C51, 80C31, 87C51. AT89C51 pin diagram2.2 Buzzer Buzzer is an integrated structure of an electronic sounder, DC voltage power supply. Buzzer mainly divides into the piezoelectric
23、 buzzer and solenoid buzzer style two kinds. Buzzer schemes2.3 Hardware connection diagram Original requirements: 1AT89C51, 8LED-RED, 9RES,1SOUNDER,1SW-SPDTHardware connection diagram as follow: Fig2.3 3 Software DesignIn the recent research 李学礼,2008 found these information.3.1 flow diagramBlock flo
24、w diagram as follow: In the recent research 梁炳东,2009 found these information.3.2 The main program software ORG 00HMAIN: MOV P2,#00H MOV P3,#00H JB P1.7, MAIN /* Determine whether the alarm */ MOV R2, #100 MOV A,#01HB1000: /*Have low/high rate*/ CLR P3.0 LCALL DL0D5ms /*Delay*/ SETB P3.0 /*Buzzer ran
25、g*/ LCALL DL0D5ms DJNZ R2, B1000 /* Determine R2=100*/B500: /*Have low/high rate*/ CLR P3.0 LCALL DL0D5ms /*Delay*/ LCALL DL0D5ms SETB P3.0 /*Buzzer rang*/ LCALL DL0D5ms LCALL DL0D5ms JB P1.7, MAIN DJNZ R2, B500 MOV P2,A /*LED light*/ RL A /*other LED light*/ SJMP B1000 DL0D5ms: /*Delay*/ MOV R7, #2
26、50DL: DJNZ R7, DL RET END4 Proteus software simulationsThe implementation phenomenon4.1 Switch is high: 4.2 Switch is low When P1.7 is high, P2 and P3 port is low. When P1.7 is low, P2 and P3 is high, the LED light and the Buzzer rang. 5 Summarize5.1 My program advantages and disadvantages Advantages: My program is simple, should understand. Disadvantages: LED and buzzer program can not achieve synchronization. Actual results and the desired outcome have a little different.Reference templates:Books:李学礼,2008.基于Proteus的8051单片机实例教程.第二版.北京:电子工业出版社梁炳东,2009.单片机原理与应用.第一版.北京:人民邮电出版社
copyright@ 2008-2022 冰豆网网站版权所有
经营许可证编号:鄂ICP备2022015515号-1