1 Introduction
When doing PCB reverse design, you need to first detect the circuit board to find out the connection relationship between all component pins; then use the corresponding software to analyze and process the detection results, and finally restore the PCB schematic.
Since there are many device pins on large-scale PCBs, manual detection is not only inefficient but also prone to errors.
In order to improve the efficiency and accuracy of PCB detection, this paper proposes a design and implementation scheme of a PCB detection system based on the EZ-USB 2100 series microcontroller. The system has a detection head, which is connected to the device pins of the circuit board. Under the control of the microcontroller, the system automatically detects the connection relationship between the pins; then, the system selects the next group of pins for detection based on the detection selection algorithm, and repeats this cycle until all device pins are detected. Using the EZ-USB 2100 series microcontroller for development not only makes it easy to realize high-speed communication between the detection device and the host, but also brings great convenience to the functional expansion of the detection device. The following will first analyze the characteristics and technical advantages of the EZ-USB 2100 series microcontroller, and then give the design and implementation scheme of the PCB detection system based on this type of microcontroller.
2 Features of EZ-USB 2100 Series MCU
The EZ-USB 2100 series microcontrollers are developed by Cypress. They integrate a USB controller that complies with the USB 1.1 specification and an enhanced 8051 core. The enhanced 8051 core runs at 24MHz, and a bus cycle contains 4 clock cycles, while the standard 8051 contains 12 clock cycles. In addition to the enhanced 8051 core, the EZ-USB 2100 series microcontrollers have two major advantages over traditional 8051 microcontrollers: 1) high-speed data transmission with the host through the USB bus; 2) firmware reconfiguration function. These two technologies provide great convenience and flexibility for application development. The following will specifically analyze how to use these two technologies in the actual development process.
2.1 Communication between EZ-USB 2100 series MCU and host
The USB controller integrated in the EZ-USB 2100 series microcontroller complies with the USB 1.1 specification and supports 12Mbps high-speed data transmission. The application on the host communicates with the EZ-USB microcontroller through the EZ-USB device driver. Cypress provides a universal device driver that users can directly use to communicate with the EZ-USB microcontroller.
First, the host needs to load the universal device driver. When using a USB device for the first time, you may need to manually install its driver; after that, Windows will save the relevant information in the registry and automatically locate the device driver.
After loading the generic device driver, the application first obtains a handle to access the device driver by calling the Win32 API function CreateFile():
HANDLE DeviceHandle;
DeviceHandle = CreateFile (“\\.\ezusb-0”, GENERIC_WRITE, FILE_SHARE_WRITE, NULL, OPEN_EXISTING, 0, NULL );
Then, the application sets up the I/O buffer for the device handle returned by the CreateFile() function and completes the device read and write operations by calling the Win32 API function DeviceIoControl():
PVOID pvBuffer = NULL;
DWORD nBytes = 0;
PvBuffer = malloc (sizeof (Usb_Device_Descriptor ));
BResult = DeviceIoControl (DeviceHandle, //Opened device handle
IOCTL_EZUSB_GET_DEVICE_DESCRIPTOR, //IO control code
NULL, 0, pvBuffer, sizeof (Usb_Device_Descriptor),
&nBytes, NULL);
The operation of EZ-USB peripherals is achieved by passing the corresponding control code to the DeviceIoControl function. For example, to complete the bulk read and bulk write operations of data, you can pass the IOCTL_EZUSB_BULK_READ and IOCTL_EZUSB_BULK_WRITE control codes to the function respectively.
2.2 Firmware Reconfiguration Function of EZ-USB 2100 Series MCU
After the hardware circuit design of a single-chip microcomputer system is completed, the characteristics and functions of the single-chip microcomputer system can also be changed by changing the software program (i.e., firmware) of the single-chip microcomputer. Using ROM to store firmware cannot be changed; using EPROM to store firmware will be limited by the number of erase and write times and cost. The external RAM integrated in the EZ-USB series single-chip microcomputer can be used to load firmware. When the device is connected to the host, the firmware is loaded from the host to the RAM for execution. Devices loaded with different firmware will show different characteristics, thereby achieving the purpose of soft configuration.
3 Application of EZ-USB 2100 Series Microcontrollers in PCB Detection System Development
The hardware circuit structure of the system is shown in Figure 1. k detector heads are connected to an analog switch composed of multiple analog switches.
3.2 System Function Expansion
As described in Section 2.2 of this article, the reconfiguration function of EZ-USB can be used to modify the firmware program to enable the system to obtain new functions. In the process of developing the PCB detection system, we found that it was necessary to measure the values of two-pin devices such as resistors, capacitors, and inductors on the circuit board. Due to the large number of such devices on large-scale circuit boards, it is a very tedious task to measure them manually using a multimeter or logic analyzer. The reconfiguration function of EZ-USB can solve this problem. Using the same hardware circuit as Section 3.1, the author also designed a set of firmware programs for type identification and value determination of resistors, capacitors, and inductors on circuit boards.
4 Conclusion
The detection system greatly improves the efficiency of PCB reverse design. The results of practical application show that the detection system has good detection completeness and accuracy.
Previous article:Single chip microcomputer realizes multi-gas detection system
Next article:C51 MCU interrupt number and interrupt vector
Recommended ReadingLatest update time:2024-11-17 01:34
- Popular Resources
- Popular amplifiers
- Wireless Sensor Network Technology and Applications (Edited by Mou Si, Yin Hong, and Su Xing)
- Modern Electronic Technology Training Course (Edited by Yao Youfeng)
- Modern arc welding power supply and its control
- Small AC Servo Motor Control Circuit Design (by Masaru Ishijima; translated by Xue Liang and Zhu Jianjun, by Masaru Ishijima, Xue Liang, and Zhu Jianjun)
- High signal-to-noise ratio MEMS microphone drives artificial intelligence interaction
- Advantages of using a differential-to-single-ended RF amplifier in a transmit signal chain design
- ON Semiconductor CEO Appears at Munich Electronica Show and Launches Treo Platform
- ON Semiconductor Launches Industry-Leading Analog and Mixed-Signal Platform
- Analog Devices ADAQ7767-1 μModule DAQ Solution for Rapid Development of Precision Data Acquisition Systems Now Available at Mouser
- Domestic high-precision, high-speed ADC chips are on the rise
- Microcontrollers that combine Hi-Fi, intelligence and USB multi-channel features – ushering in a new era of digital audio
- Using capacitive PGA, Naxin Micro launches high-precision multi-channel 24/16-bit Δ-Σ ADC
- Fully Differential Amplifier Provides High Voltage, Low Noise Signals for Precision Data Acquisition Signal Chain
- 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!
- Rambus Launches Industry's First HBM 4 Controller IP: What Are the Technical Details Behind It?
- 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
- Multisim op amp output is greater than the power supply problem
- How to choose between DT4215 and 15B for multimeter selection
- The world's first single-chip microcomputer was produced by TI
- EEWORLD University ---- Digital Integrated Circuit Analysis and Design
- The contradiction between insulation withstand voltage and ESD
- Buck Circuit
- [Silicon Labs BG22-EK4108A Bluetooth Development Evaluation] Schematic diagram + Building development environment + Debugging lights
- How to adapt Allwinner V853 development board to binocular GC2053
- CC2640R2F Bluetooth debugging - change device name
- High pass filter gain problem