1 Chip Selection
1.1 S3C2410 Processor
The S3C2410 processor is a 32-bit microcontroller based on the ARM920T processor core of ARM Corporation and manufactured using a 0.18μm process. The processor has: independent 16 KB instruction cache and 16 KB data cache, MMU, LCD controller supporting TFT, NAND flash controller, 3-way UART, 4-way DMA, 4-way Timer with PWM, I/O port, RTC, 8-way 10-bit ADC, Touch Screen interface, I2C-BUS interface, IIS-BUS interface, 2 USB hosts, 1 USB device, SD host and MMC interface, 2-way SPI. The S3C2410 is a 16/32-bit RISC architecture processor that uses the powerful instruction set of the ARM920T CPU core. The processor can run at up to 203 MHz.
1.2 AD9283 High-Speed Analog-to-Digital Converter
In ultrasonic nondestructive testing systems, the frequency of ultrasonic probes is generally 2 to 10 MHz. The probe frequency is 5 MHz. According to the sampling theorem, the sampling frequency is preferably 5 to 8 times the probe frequency. Therefore, the A/D chip uses AD9283 from AD Company, which has a maximum sampling rate of 100 MHz and can meet the system requirements.
1.3 FIFO memory CY7C4261
FIFO memory is a bridge between A/D and ARM. Its parameter indicators directly affect the data acquisition speed. First, the read/write speed of the FIFO memory should be fast enough. For the convenience of debugging, it is best to be consistent with the maximum speed of the A/D device; secondly, the storage capacity of the FIFO memory should be appropriate. If the capacity is too large, it will cause resource waste. If the capacity is too small, it will cause overflow or the data acquisition speed will be too slow.
The thickness of the object under test is usually 10 mm. When the signal length is the first 8 peaks and the entire system works at the limit frequency of 100 MHz, the following calculation is made:
Number of sampling times = sampling rate × time
= sampling rate × (2 × thickness × 8 / ultrasonic speed)
= 100 × 2 × 0.01 × 8 / 5 900
= 2 712 times
That is, nearly 3 KB of cache is required. The ultrasonic thickness measurement system needs to measure objects with a maximum thickness of 50 mm, so a FIFO with a capacity of 15 K × 8 B is required. Therefore, the depth of the FIFO must be greater than 15 KB; the width must be greater than the number of bits of A/D, that is, greater than 8 bits; the maximum operating rate is 100 MHz, which is consistent with the A/D sampling rate. This design uses CY's FIFO memory CY7C4261, which has a maximum sampling rate of 100 MHz, the same as the maximum sampling rate of AD9283; the capacity is 16 KB × 9 B, which can meet the data volume requirements.
2 Interface Design
AD9283 is an 8-bit analog/digital converter, CY7C4261 is a 9-bit FIFO, and the data bus of S3C2410 is 32 bits. CY7C4261 only needs to connect to the lower 8 bits DO~D7 of S3C2410. Due to the first-in first-out structure of FIFO, no address line is required in the system, which greatly simplifies the circuit. The data sampled by A/D must be sent to FIFO in real time. The write clock frequency of the two must be the same, and the minimum clock input of AD9283 and CY7C4261 is 10 ns, which is unified and convenient to operate. 74ALS08 is a four-two input AND gate. TOUTl (GPBl) and TOUT2 (GPB2) in the pulse width modulation wave output port of ARM are configured as general output ports to control the on and off of 74ALS08, thereby controlling the write clock of A/D and FIFO. The CLKOUTO of S3C2410 is connected to the RCLK of CY7C4261 to provide the read clock for FIFO. The full flag of CY7C4261 is connected to the external interrupt EINT1 of S3C2410 to trigger the external interrupt. The nRSTOUT1 of S3C2410 is connected to the CY7C4261 to reset the FIFO. The interface block diagram is shown in Figure 1.
3 Timing Design
The write clocks of A/D and FIFO are controlled by two AND gates. Because it takes 4 clock cycles for AD9283 to start analog input and the data of the conversion appears on the output port, and the delay effect of the wire will be very obvious when sampling at high speed, if the clocks of A/D and FIFO are connected together, it is likely that too much invalid data will be sampled. After separate control, the clocks of A/D and FIFO can be easily controlled by software delay. It is quite convenient to debug, and try to reduce the number of bits of invalid data to a minimum. The working timing of AD9283 is shown in Figure 2, and the write timing diagram of CY7C4621 is shown in Figure 3. [page]
When sampling. TOUT1 and TOUT2 are enabled by the program and output as 1. At this time, the sampling clock pulse is ANDed with TOUT1 and TOUT2 and then sent to the clock input ENCODE of AD9283 and the write clock input WCLK of CY7C4621 respectively. At this time, A/D starts to work and sends the converted data to its own output ports D0~D7. When the write enable
is low and WEN2 is high, the data on the A/D output port is written into FIFO in sequence on the rising edge of WCLK. Each time a pulse comes from A/D and FIFO, an analog/digital conversion is completed and the data is stored in FIFO in sequence. The maximum data storage capacity of CY7C4261 is 16 KB. After completing 16 KB conversions, CY7C4261 will no longer be able to store new data. At this time, the memory full flag
outputs a low level (outputs a high level when not full). Connect this signal to the external interrupt EINT1 of S3C2410, and use its change from high to low to generate an interrupt to indicate that a set of data collection is completed.
In the interrupt, ARM first quickly turns off the sampling pulse signal (making the output of TOUT1 and TOUT2 0), stopping the operation of A/D and FIFO. The ARM external clock signal CLKOUTO is connected to the read input RCLK of FIFO. Every time ARM performs an I/O read operation, cLKOUT0 sends a pulse to RCLK. Set FIFO read enable
and WEN2 to low, and perform 16K I/O read operations continuously. The data is sent from CY7C4261 to the S3C2410 system in turn, and the entire data collection work is completed. Before each data collection, reset CY7C4261, configure nRSTOUTl of S3C24-10 as a general output port, input a low pulse of not less than 10 ns to the RS pin of CY7C4261, that is, output a low pulse at the nRSTOUTl pin of ARM. This can more fully ensure the stability of the read and write pointers of FIFO.
4 Data collection process The
data collection process of the ultrasonic thickness measurement system mainly includes ARM initialization, input excitation pulse, enable external interrupt, clock input to A/D, FIFO, and wait for interrupt. Stop A/D and FIFO, ARM reads data, and resets FIFO. The flow chart is shown in Figure 4.
5 Conclusion
Through the actual design in the ARM-based ultrasonic nondestructive testing system, the use of FIFO can make the high-speed A/D and ARM processor seamlessly connected, solving the mismatch problem between the two. Through software settings, the operation timing of A/D, FIFO and ARM can be flexibly adjusted, and the debugging is simple, ensuring the safety and reliability of data acquisition. The interface circuit is simple, flexible and efficient, and has high application value.
Previous article:Design of energy harvesting charger based on EasyARM1138
Next article:ISP Design of ARM Embedded System
Recommended ReadingLatest update time:2024-11-17 00:08
- Popular Resources
- Popular amplifiers
- USB Development Encyclopedia 4th Edition
- Teach you to learn DSP step by step - based on TMS320X281x 3rd edition (Gu Weigang)
- Xilinx FPGA Advanced Applications - General IP Core Detailed Explanation and Design and Development (Huang Wanwei)
- Teach you how to design FPGA step by step: the simplest design method based on the principle of simplicity (Pan Wenming)
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
- Four methods of STM32 delay function
- [New version of Zhongke Bluexun AB32VG1 RISC-V development board] - 2: Key points of Downloader usage
- [ESP32-Korvo Review] (4) Playing PCM audio from an SD card
- What is the purpose of these three assignment statements?
- AMIC110 SoC makes industrial communications simple
- 【GD32E503 Review】08 Comprehensive Review of Digital Photo Album (Part 1)
- Machine Learning Interface Reference Design for Embedded Applications
- STM32F446 NUCLEO 3.5 inch TFT LCD driver
- Problems with remote upgrade of STM32F103
- A PhD student was rejected for a job application with a monthly salary of 5,000 yuan and went to the United States to develop cold nuclear fusion with an annual salary of 800 million yuan