Single-chip microcomputer is one of the compulsory courses for electronic technology majors in domestic colleges and universities. Many students are engaged in single-chip microcomputer hardware and software design after graduation. The development of single-chip microcomputer requires designers to have a certain hardware design foundation and assembly or C language programming ability. At present, most domestic colleges and universities adopt the teaching steps of teaching first and then experimenting. Students lack a perceptual understanding in the learning process, and cannot connect with the knowledge in the textbook during the experiment, which results in a double waste of time and teaching resources.
l Introduction of Proteus
With the rapid development of computer software and hardware technology, various simulation systems have emerged in various fields, providing accurate and reliable guarantees for the development of various practical systems, while saving a lot of manpower and material resources. The emergence and development of simulation technology is the inevitable result of the development of science and technology, one of the key technologies of modern science and technology, and has gradually become a necessary technology for scientific and technological personnel. Proteus is a simulation system that came into being and developed rapidly under this situation. Proteus is a design and simulation platform for analog circuits, digital circuits, and analog/digital mixed circuits; it is also an advanced design and simulation platform for single-chip microcomputer systems. It truly realizes the complete design and simulation process from schematic diagram and circuit design, circuit analysis and simulation, single-chip microcomputer code-level debugging and simulation, system testing and functional verification to the formation of PCB on the computer. It has been favored by teachers, engineering and technical personnel engaged in single-chip microcomputer business, as well as many college students and single-chip microcomputer technology enthusiasts.
The single-chip microcomputer virtual development environment based on Proteus effectively links theory with experiment. In this development environment, demonstration, hardware circuit design and software design can be well combined. Applying this development environment in teaching and specific engineering projects not only helps to improve efficiency, but also reduces development costs and risks. At present, the fields of electronic technology, mechanical design and manufacturing, and software development tend to adopt virtual simulation development environment. On the one hand, the adoption of virtual environment helps the parallel development of projects to improve the product development cycle, and can advance some of the later work in traditional development steps; on the other hand, the virtual development environment can show the prototype of the product and expose some practical problems of the experimental product in the virtual design stage. For example, the combination of mechanical design software SoliWorks and LabView can complete the simulation of design work with high risks such as three-dimensional motion control, control logic analysis, and component collision analysis of machine moving parts. For enterprises, reducing risk investment and accelerating product launch are key factors in winning the market. Therefore, the virtual development environment described here can well adapt to the needs of future scientific research and product development, and cultivating the virtual development awareness of developers is an important knowledge asset for enterprises and society.
2. Proteus simulation system
Proteus is a circuit analysis and physical simulation software from Labcenter, a British company. It can simulate and analyze (Spice) various analog devices and integrated circuits. The features of this software are:
(1) It realizes the combination of single-chip microcomputer simulation and Spice circuit simulation. It has the functions of analog circuit simulation, digital circuit simulation, simulation of systems composed of single-chip microcomputers and their peripheral circuits, RS 232 dynamic simulation, I2C debugger, SPI debugger, keyboard and LCD system simulation; it has various virtual instruments such as oscilloscopes, logic analyzers, signal generators, etc.
(2) It supports the simulation of mainstream single-chip microcomputer systems. The types of single-chip microcomputers currently supported are: 68000 series, 8051 series, AVR series, PIC12 series, PIC16 series, PIC18 series, Z80 series, HC11 series and various peripheral chips. (
3) It provides software debugging functions. In the hardware simulation system, it has debugging functions such as full speed, single step, and setting breakpoints. At the same time, it can observe the current status of various variables, registers, etc., so these functions must also be available in the software simulation system; it also supports third-party software compilation and debugging environments, such as Keil C51 μVision 2 and other software.
(4) It has powerful schematic drawing functions. After starting Proteus, the ISIS design window will appear, as shown in Figure 1. It includes: title bar, main menu, standard toolbar, drawing toolbar, status bar, object selection button, preview object orientation control button, simulation process control button (bottom row), preview window, object selector window, and graphic editing window.
[page]
The software also has a circuit board demonstration function. Taking temperature display as an example, its demonstration effect is shown in Figure 2. This demonstration diagram is not only helpful for teaching work, but also can help enterprises reduce product design risks.
3 Program Development
Here, the AVR MCU ATmega16 and DS18B20 are used as examples to demonstrate the MCU program development process for temperature measurement and display. The AVR MCU is a high-performance MCU launched by Atmel. Some of this series of MCUs use a 16-bit structure. All IO ports can set the data direction individually and have programmable internal pull-up resistors, which improves the overall performance and application range. In terms of MCU program design, ICCAVR provides a good programming interface, and the initialization program can be generated by selecting the visualization option box, as shown in Figure 3.
When developing a project program, you only need to select the CPU used, the initial direction of the I/O port, the use of the timer, the UART and other peripheral function modules to make settings to generate a corresponding C language initialization program. After completing the initialization, the programmer only needs to write a functional program for his specific application. DS18B20 supports the "one-line bus" interface, and the measurement temperature range is -55~+125℃. In the range of -10~+85℃, the accuracy is ±0.5℃. The accuracy of DS1822 is poor, which is ±2℃. The field temperature is directly transmitted in a digital way of "one-line bus", which greatly improves the anti-interference ability of the system. It is suitable for field temperature measurement in harsh environments, such as: environmental control, equipment or process control, temperature measurement consumer electronics products, etc. Unlike the previous generation of products, the new product supports a voltage range of 3.0~5.5 V, making the system design more flexible and convenient. Moreover, the new generation of products is cheaper and smaller in size. The interface between DS18B20 and microcontroller is only one line, and the single bus feature of DS18B20 only needs one microcontroller I/O pin to support multiple DS18B20, which greatly reduces the hardware cost. Of course, the small hardware cost needs relatively complex software to compensate. Since serial data transmission is used between DS1820 and microprocessor, the read and write timing must be strictly guaranteed when reading and writing programming of DS1820, otherwise the temperature measurement result will not be read. The specific flow chart is shown in Figure 4.
[page]
After programming according to the design requirements, double-click the ATmega16 microcontroller in the ISIS Professional window, an editing window will pop up, select the .hex file generated by ICCAVR in the program file, and click "OK". Click the simulation process control button in the ISIS window, and the simulation results shown in Figure 5 will appear. Change the temperature of DS18B20, and the display will show accordingly.
4 Conclusion
Single-chip microcomputer technology is an indispensable technology in the modern electronic industry. Mastering single-chip microcomputer technology is a basic condition for the employment of students majoring in electronic information. Here, through the example of single-chip microcomputer product development, the status and role of Proteus in single-chip microcomputer teaching and single-chip microcomputer application product development are discussed. Proteus is an efficient, economical and reliable single-chip microcomputer system design and simulation platform for single-chip microcomputer teaching and application product development. Students can boldly carry out circuit design, program design, measurement, debugging and modification in the Proteus ISIS window. Not only will it not damage components and instruments, but the results can be seen before installing the physical work. The students' independent operation ability, initiative, enthusiasm and creativity are all brought into play. In short, the single-chip microcomputer virtual development environment based on Proteus is conducive to promoting curriculum and teaching reforms, and is more conducive to the cultivation of talents; the use of simulation systems can not only save development time and development costs, but also has great flexibility and scalability; it is also a beneficial attempt for colleges and universities to improve the level of laboratory construction.
Previous article:Design of fast position servo system based on single chip microcomputer
Next article:Design of camera motion control system based on single chip microcomputer
Recommended ReadingLatest update time:2024-11-16 22:25
- Popular Resources
- Popular amplifiers
- MCU C language programming and Proteus simulation technology (Xu Aijun)
- Single-chip microcomputer C language programming and simulation
- 100 Examples of Microcontroller C Language Applications (with CD-ROM, 3rd Edition) (Wang Huiliang, Wang Dongfeng, Dong Guanqiang)
- 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
- Positive and negative 12V power supply, MC340463, simulation is OK, but the actual limit is about -5V
- [NUCLEO-WL55JC2 Review 4] STM32WL sub-GHZ RF (LoRa\FSK..)
- AVRDUDE released version 6.4 and moved to github
- Several issues on hysteresis compensation
- I wish you all good health and a safe family and a happy new year!!!
- MSP430FR2311 microcontroller infrared reflective sensing
- Does anyone have the BAP protocol in Volkswagen's CAN protocol?
- [RVB2601 Creative Application Development] 8 If more than a certain number of letters are not shot down, the game will be displayed as over.
- NRF51822 production capacity is urgent, what should be used as a replacement?
- [Construction Monitoring and Security System] 9. Kaluga loads project configuration from SD card