1 Introduction 3 Circuit Analysis U2 (74LS139) is a 2-4 line decoder. Its functions are shown in Table 1. Its input terminals B and A are connected to P3.4 and P3.5 respectively. The output terminals Y0-Y3 depend on the combination of input terminals. Each combination Only one output terminal (Y0-Y3) outputs an active low level. U3-U6 are D latches. The relationship between pins 5 and 6 determines their working status. According to the information, when the logic potential of pins 5 and 6 is the same, the chip can output D3-D0 data. to Q3-Q0; when the logic potential of pins 5 and 6 is different, the chip is in a state of latching the original data and will not "read in" the current D3-D0 data. Pin 6 of U3-U6 is fixed in the circuit Connect to low potential, and pin 5 is controlled by the output signal of U2 (74LS139). It is not difficult to realize that "the setting of each BCD code can be realized independently". 4511 is a decoding driver. It is connected to a common cathode digital tube to display the decimal number corresponding to the current BCD code of each bit. It is convenient for observation. The display part is very simple and will not be described in detail here. At the same time, the display part is not necessary in the circuit and can be omitted. , the BCD code is derived through J3 and J2. The reason why two linkers are used is for more flexibility and ease of use. Simply put, the task of the keyboard scanner is: first confirm whether a key is pressed, then use scanning to determine which row the key is on, and finally find and calculate the specific key by comparing it with the preset 4-line table, thereby converting to the corresponding functional program. (4) In the KEYCALCU subroutine, the multiplication by 3 operation is used for the scattered rotation instruction JMP. Note that LJMP is a 3-byte instruction. The function programs corresponding to each button are arranged together to string LJMP, so the multiplication by 3 operation can be correctly mapped to each button. Execute the target function program. The corresponding processing functions of each key are relatively simple. Just input the corresponding control command corresponding to different keys. For S0-S9, the different states of P3.3-P3.0 are controlled to obtain the corresponding BCD code. For S10-S13 It is to control the status of P3.4 and P3.5 to control U3-U6. Due to space limitations, please refer to the program for details. When the program starts to be executed, it controls the 4-digit BCD code output one by one, and the corresponding digital tubes display in sequence. The initial state is 0001, 0000, 0000, 0000. The 4-digit BCD codes are derived from J3 and J2 respectively, and the digital tube displays 1, 0, 0, 0. | |||||
Previous article:Testing and analysis of 8051, ARM and DSP instruction cycles
Next article:Design of four-bit BCD encoder circuit based on microcontroller
Recommended ReadingLatest update time:2024-11-16 23:53
- Popular Resources
- Popular amplifiers
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
- Banknote number recognition system based on ARM
- 【TI recommended course】#Battery test solution#
- 【IoT Graduation Project】Raspberry Pi Development Board + Gizwits IoT + Monitoring Robot
- TI has new products: ISO224 isolation amplifier and ISO1042 CAN transceiver.
- [Repost] Learn these eight circuit design skills and your professional quality will be greatly improved
- [STM32WB55 Review] +ST's Attack
- In the TTL inverter circuit, there is no power supply on the collector of VT4. How does VT4 saturate?
- MSP430 ADC conversion + mean filter
- EEWORLD University ---- Linux Kernel Design
- TI eSMO library Fsmopos and Gsmopos parameter analysis