Microcontroller (MCU for microcontroller unit) is a single-chip microcomputer that integrates the main part of a microcomputer on a chip, appropriately reduces the frequency and specifications of the central processing unit, and integrates memory, counter, USB, A/D Peripheral interfaces such as conversion, UART, PLC, and DMA, and even LCD driver circuits are integrated on a single chip to form a chip-level computer, which performs different combination controls for different applications.
The microcontroller was born in the mid-1970s. After more than 20 years of development, its cost has become lower and lower, and its performance has become more and more powerful, which has made the use of microcontrollers in various fields.
Microcontrollers are used for automatic control of products and equipment, such as automotive engine control systems, implanted medical devices, remote controls, office machines, PC peripherals, industrial stepping motors, control of robotic arms, electrical appliances, power tools and other embedded systems, etc.
How Does Microcontrollers Work?
A microcontroller is embedded inside the system to control a single function in the device. It does this by using the CPU to interpret data received from I/O peripherals. Temporary information received by the microcontroller is stored in its data memory, where the processor accesses it and uses instructions stored in its program memory to decrypt and apply incoming data. It then uses its I/O peripherals to communicate and perform appropriate actions.
Microcontrollers are used in a wide variety of systems and devices. Devices often use multiple microcontrollers that work together within the device to handle their respective tasks.
For example, a car may have many microcontrollers to control various independent systems inside, such as anti-lock brakes, traction control, fuel injection, or suspension control. All microcontrollers communicate with each other to inform proper operation. Some may communicate with a more complex central computer in the car, while others may only communicate with other microcontrollers. They use I/O peripherals to send and receive data and process that data to perform specified tasks.
Components Of Microcontroller
The main components of a microcontroller include:
(1) CPU
The CPU can be thought of as the brain of the device, similar to the processor in a computer. It processes and responds to various instructions directing the functions of the microcontroller. This involves performing basic arithmetic, logic, and I/O operations. It also performs data transfer operations, communicating commands to other components in the larger embedded system.
The CPU mainly consists of an arithmetic logic unit (ALU), a control unit, and a register array. As the name suggests, the ALU performs all arithmetic and logic operations on data received from input devices or memory.
A register array consists of a series of registers, such as accumulator (A), B, C, D, etc., which act as temporary fast-access memory locations for processing data. It can be seen that the control unit controls the flow of instructions and data throughout the system.
(2) memory
RAM stands for Random Access Memory. Similar to a computer, the role of RAM is to dynamically store data when the microcontroller executes instructions. It is a volatile memory and all data disappears when the power is turned off.
ROM stands for Read Only Memory. In older microcontrollers, the flash memory was one-time programmable, that's why it's called ROM. In the latest microcontrollers though, it is reprogrammable, known as Electrically Erasable Programmable Read-Only Memory (EEPROM). The role of ROM is to store programs or instructions that need to be executed.
(3) I/O peripherals
Input and output devices are the interface between the processor and the outside world. The input port receives information and sends it to the processor in the form of binary data. The processor receives this data and sends the necessary instructions to output devices that perform tasks external to the microcontroller.
While the processor, memory, and I/O peripherals are the defining elements of a microprocessor, other elements are often included.
Classification Of Microcontrollers
Microcontrollers can be classified from different aspects: according to the data bus width can be divided into 8Bit, 16Bit and 32Bit; according to the memory structure can be divided into Harvard structure and Von Neumann structure; according to the type of embedded program memory can be divided into OTP, mask Membrane, EPROM/EEPROM and flash memory; according to the instruction structure, it can be divided into CISC (Complex Instruction Set Computer) and RISC (Reduced Instruction Set Computer) microcontrollers.
8Bit microcontroller
8Bit microcontrollers can transmit and process 8-bit data in one cycle. Its ALU (Arithmetic Logic Unit) is also 8-bit, and when larger data needs to be processed, such as 16-bit, it uses multiple cycles to complete a simple math function. This can lead to poor performance of the entire logic circuit.
Some common 8-bit microcontrollers are the Intel 8031/8051, PIC1x, and Motorola MC68HC11 families.
16Bit microcontroller
16-bit data can be transferred and processed in a single cycle. Its ALU is more efficient in performance than 8-bit microcontrollers, offering a wide range from 0x0000 (0) to 0xFFFF (65535), providing the best precision per unit cost for any application or project requiring timer functionality.
Common examples of 16-bit microcontrollers are the 8051XA, PIC2x, Intel 8096, and Motorola MC68HC12 families.
32Bit microcontroller
It has higher performance and precision than 16-bit microcontrollers, but it is also more expensive and consumes a lot of power. 32-bit microcontrollers have a higher processing speed, which makes them the best choice for complex tasks such as audio and video signal processing, image processing, etc.
It can also support multiple peripherals such as Ethernet, Universal Serial Bus (USB), Universal Asynchronous Transceiver Devices (UARTS), and Control Area Network (CAN) buses required by any embedded system project or application.
Common 32-bit microcontrollers are the Intel/Atmel 251 series, PIC3x.
Microcontroller Application
Microcontrollers are used in many fields, including home and business, building automation, manufacturing, robotics, automotive, lighting, smart energy, industrial automation, communications, and Internet of Things (IoT) deployments.
The simplest microcontrollers help operate electromechanical systems found in everyday convenience items such as ovens, refrigerators, toasters, microwave ovens, washing machines, air conditioners, and other home appliances. Also includes office equipment such as copiers, scanners, fax machines and printers as well as smart meters, ATMs and security systems.
More complex microcontrollers are used to perform critical functions in aircraft, spacecraft, ocean-going vessels, vehicles, medical and life support systems, and robotics.
In medical scenarios, microcontrollers can regulate the operation of artificial hearts, kidneys, or other organs. They also aid in the function of prosthetic devices.
In automotive applications, microcontrollers (MCUs) drive critical performance. In recent years, with the development of automotive electronics and intelligence, the application development of automotive-grade microcontrollers (MCUs) has also been driven, and automotive-grade microcontrollers (MCUs) have also become a hot spot in the industry.
According to the application of microcontroller (MCU) products in automobiles, it mainly focuses on lights, windows, seats, BMS, air conditioners, motors, sensors, T-Box, doors, OBC, ETC, TPMS, instruments, entertainment, charging guns , EPS, reversing sensor, ADAS, domain control, airbag, 360 surround view, ABS, OBD, rearview mirror, PM2.5, HUD, brake, gearbox, pedal, steering wheel, wireless charging, shifter, exhaust, alarm device, PTC, etc. The concentration of microcontroller (MCU) product applications is not high, and most applications are lights, windows, seats, BMS, and air conditioners.