Preface
From aerospace to children's toys, everything that has a little bit of intelligence is inseparable from the presence of microcontrollers... In this article, we will learn about the STC89C52 microcontroller, which belongs to the 8051 series of microcontrollers. As an entry-level microcontroller, the 51 microcontroller is not only widely used in teaching experiments, but also in actual projects.
1. Basic knowledge
1. What is a microcontroller?
A single-chip microcomputer is a single-chip microcomputer that consists of a central processing unit CPU, data storage RAM, program storage ROM, input/output devices (keyboard, display, etc.) integrated into a single chip.
2. What can a microcontroller do?
The functions of the microcontroller are well explained at the beginning of the preface. Anything that has a touch of intelligence is inseparable from the microcontroller, especially now that the Internet of Things is developing in full swing, and the microcontroller has ushered in a new spring. Currently, the most commonly used smart meters and smart small appliances are the 51 microcontroller + wireless module connected to the Internet of Things platform, and then the smart devices can be monitored through the front end.
3.Why should we learn microcontrollers?
Learning about microcontrollers can help you make some interesting small creations by yourself, improve your hands-on and practical abilities, and participate in electronic competitions. It is very helpful for job hunting after graduation, and you may even change the world accidentally.
4. Development Board Introduction
The 51 single-chip Internet of Things development board used in this experiment is shown in the figure below:
The corresponding names of the modules marked in the above figure are as follows:
2. Development Environment Construction
Download information from Baidu Cloud Disk:
Link: https://pan.baidu.com/s/1WVuun7PWWMfWLcbZ4-MWhw
Extraction code: h4iv
After downloading and decompressing, the directory is as follows:
1. Install CH340 driver
Open A-08 related software/must-install software/CH340_CH341
Double-click to install:
The following box pops up to indicate that the installation is successful, click OK
2. Install Keil 4
Open A-08 related software/must-install software/keil4
Click mdk473 to start installation
Click the Next button in the picture above to proceed to the next step
Check I agree to all the terms of the preceding License Agreement, then click Next
Select the default path C:Keil and click Next
Fill in the First Name, Last Name, Company Name, and E-mail content casually, click Next, and enter the installation page
Wait for the installation to complete
Continue to click Next
Click Finish, a pop-up box will pop up prompting you to install the driver software, click Install
After clicking Install in the above picture, the installation of Keil4 is completed, the web page opens the content in the picture below, and an icon is generated on the desktop, and the installation is complete.
3. Install C51 plug-in
Click A-08 related software/must-install software/keil4/c51v901.exe
Click Next
After checking the Agree tab, click Next
Select the same path as the Keil4 installation path, then click Next
Continue to click Next
If it appears during the process:
Click Replace All
4. Activate Keil 4
Open the Keil4 icon generated on the desktop as an administrator
Click License Management
Open the A-08 related software/must-install software/keil4 folder
Unzip keygen2032, copy the CID in keil LicenseMangement,
Click Generate
Copy the generated ID, paste it into Keil License Management, and click Add LIC
The above picture shows that the activation is successful and the validity period ends in 2032
3. Download and run
1. Compile
First, unzip the A-08 reference program.rar, and then open the first program: 1. Light up an LED
Click the compile icon, the system has 0 errors and 0 warnings
The generated hex file is as follows
2. Download
(1) Open the download software
Unzip A-08 related software/Required software/STC-ISP download/stc-isp-15xx-v6.87M.zip, then double-click to open stc-isp-15xx-v6.87M.exe
(2) Connecting Hardware
(3) Download the program
Set up the STC-ISP tool and select the burning file
Then click the Download/Program button
Then click the hexagonal self-locking switch twice in succession to reset and power on, complete the cold start, and download the program successfully
(4) Equipment operating status
After the program is downloaded successfully, the device LED0 is always on, indicating that the program is downloaded successfully
Previous article:51 MCU Playing with the Basics of the Internet of Things 02-Light up the LED lights to achieve a marquee effect
Next article:The principle of sending and receiving of 8051 asynchronous serial port
Recommended ReadingLatest update time:2024-11-16 11:24
- Popular Resources
- Popular amplifiers
- MCU C language programming and Proteus simulation technology (Xu Aijun)
- 100 Examples of Microcontroller C Language Applications (with CD-ROM, 3rd Edition) (Wang Huiliang, Wang Dongfeng, Dong Guanqiang)
- Fundamentals and Applications of Single Chip Microcomputers (Edited by Zhang Liguang and Chen Zhongxiao)
- Single chip microcomputer control technology (Li Shuping, Wang Yan, Zhu Yu, Zhang Xiaoyun)
Professor at Beihang University, dedicated to promoting microcontrollers and embedded systems for over 20 years.
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- New real-time microcontroller system from Texas Instruments enables smarter processing in automotive and industrial applications
- [RISC-V MCU CH32V103 Review] First impression of CH32V103C8T6 chip
- 100 check items for PCB design to ensure you have no problems with your design!
- How to write the corresponding program process according to the timing diagram
- Differences and similarities between detection circuits, filter circuits, frequency selection circuits, threshold comparison circuits, and bandpass circuits
- When designing PCB, how to consider electromagnetic compatibility EMC/EMI, specifically...
- How to measure the PWM generated by msp430f149 with an oscilloscope
- EEWORLD University ---- Signal Processing on MSP430 16-bit MCU
- What should I do if the segment code LCD screen has too many segments and the pins cannot be placed?
- Qorvo PAC chip application in cordless vacuum cleaner
- Application example of serial-input-parallel-output chip 74HC595