Available online at www.sciencedirect.com
ScienceDirect Energy Procedia 39 (2013) 428 – 433
Asian Nuclear Prospects 2012 (ANUP2012)
The Design of Digital Multi-channel Analyzer Based on FPGA ZENG Weihua * China University of Geosciences, BeiJing, China
Abstract
A Digital Multi-Channel Analyzer (DMCA) based on FPGA(Field Programmable Gate Array) is introduced. The nuclear signals are processed by EP3C40Q240. It uses digital signals acquired by ADC to do calculus,seek the peaks,discriminate the threshold,and then form the energy spectrum. DMCA communicates with energy spectrum processing terminal(for example: PC) by high-speed RS485 bus interface. The software on PC can control DMCA and display energy spectrum. And the energy spectrum of 137Cs is given ,which is obtained from NaI( Tl) detector and processed by DMCA. © 20xx The Authors. Published by Elsevier Ltd.
© 2013 The Authors. Published by Elsevier Ltd. Selectionand and/or peer-review under responsibility of Nuclear Institute Nuclear and New Energy Technology, Selection peer-review under responsibility of Institute of andofNew Energy Technology, Tsinghua University
Tsinghua University
Keywords: Digital Multi-Channel Analyzer ; FPGA ; Digital Integration ; RS485
1. Introduction Digital Multi-Channel Analyzer (DMCA) is a key component of nuclear radiation measurement and analysis instruments. It is capable of realizing rapid A/D conversion of random and fast analog nuclear signals and thus obtaining digital nuclear signals. DMCA will obtain the nuclear spectrum after digital integration, peak-seeking and threshold discrimination on the digital nuclear signal. Compared with * Corresponding author. Tel.: +86-010-82321795; fax: +86-010-82323290. E-mail address:
[email protected]
1876-6102 © 2013 The Authors. Published by Elsevier Ltd.
Selection and peer-review under responsibility of Institute of Nuclear and New Energy Technology, Tsinghua University doi:10.1016/j.egypro.2013.07.233
429
Zeng Weihua / Energy Procedia 39 (2013) 428 – 433
analog multi-channel analyzer, DMCA has the following advantages: rapid analysis speed, high pulse through rate, more abundant pulse information, using programmable device to implement a flexible data processing algorithm , which make DMCA can be widely used in nuclear spectral analysis, nuclear radiation measurement, industrial CT, medical CT and many other fields. 2. Principles of DMCA Fully-digital technology aims to take sample of the original waveform of the nuclear signals as early as possible and preserve the original information of nuclear cases as much as possible, and then extract from the sampling signals by digital processing in accordance with the purpose of signal analysis[1]. By obtaining the waveform, time and energy information simultaneously of nuclear pulse signals, it can realize functions that analog technology is unable to achieve: both of its analysis accuracy and flexibility are better than the analog analysis. Therefore, DMCA is able to effectively improve the performance of the spectrometer, and further promote the application of nuclear spectrometer as well as the level of measurement and analysis [2,3]. Lots of integrated chips and hardware& software programs may be used to develop and manufacture DMCA[4]. A design and implementation of digital multi-channel analyzer base on single FPGA main chip will be introduced. 3. Overall Design of DMCA System As shown in figure 1, the digital multi-channel analyzer is composed of the A/D,FPGA(Field Programmable Gate Array),SRAM(Static RAM), communication interface, power supply unit etc.. The analog signal of nuclear pulse is transferred to the high-speed ADC for analog-to-digital conversion after front-end processing, and ADC will transfer the converted digital signal into FIFO(First-in First-Out) within FPGA under the control of the FPGA internal logic. After filtering preprocessing, pole-zero cancellation, digital integration and peak detection processing of the digital nuclear pulse signal within FPGA, the peak value of nuclear pulse signal will be obtained. Nuclear spectrum data formed by peak signals of nuclear pulse will be stored at the SRAM outside of FPGA, and then be transferred to personal computer by high-speed RS485 interface for subsequent nuclear spectral analysis, or be connected with other nuclear spectral processing terminals via 16-bit parallel bus interface. CLK+
VIN+ VIN-
SRAM
CLK-
AD9649-65
EP3C40Q240C8N
ADC
FPGA
RS485 bus interface 16-bit bus interface
1V8
3V3
1V2
2V5
3V3
Power Supply Fig. 1. Block diagram of DMCA system
430
Zeng Weihua / Energy Procedia 39 (2013) 428 – 433
4. Hardware Circuit Design 4.1. Design of preprocessing front-end and data acquisition circuit The signal that output from the detector will be transferred to the analog front-end and data acquisition circuit after preliminary amplification processing. Figure 2 shows the analog front-end and data acquisition circuit schematic diagram. Single-ended analog signal is converted into differential signal with better anti-jamming capacity through ADA4937, and then transferred to A/D chip--AD9649 for analog-to-digital conversion under the control of FPGA internal logic. The FPGA used here is EP3C40Q240C8N provided by Altera Company, which, by adopting SOPC(System On a Programmable Chip) technology, integrates high-density logic element (FPGA), static storage (SRAM) and embedded processor (ARM) in programmable logic devices, realizing a perfect combination of speed and programmability. FPGA performs the following functions in the system: data acquisition of nuclear spectrum, digital filter processing, data buffering (realizing FIFO through FPGA), digital integration, peak-seeking and serial data communication with personal computer. Data acquisition and digital signal processing achieved by a single FPGA chip have brought into the fullest play the parallel processing capabilities of the FPGA chip and reduced the dead time of the multi-channel analyzer[5,6], while simplify the hardware circuit design of multi-channel analyzer, reducing its power consumption. 1V8
1
FB-
SIG_P
SIG_C_P
AD_IN_P
2
IN+
+
OUT-
SIG_N
SIG_C_N
AD_IN_N
3
IN-
-
OUT+
R28 50
C22 10uF
C23 10uF
R25 200
R29 76.8
R27 200
4
0.1uF
VOCM
FB+ 3V3
C24 E3
12 AMP_PD
E2
AD_OUT_E_N R22
10uF/16V
11 AD_OUT_N
200
10 AD_OUT_P 9 VCM
R24
33
VCM
R26 E5
200 AD_OUT_E_P
10uF/16V
ADC_VIN_N
R30
C10 10pF ADC_VIN_P
ADC_CLK_P ADC_CLK_N
1 2
SPI_nCS SPI_CLK SPI_DIO
4 5 6
ADC_VIN_P ADC_VIN_N VCM
31 30 27
33 U2 AD9649BCPZ-65
0.1uF 10uF/16V
GND
CLK+ CLK-
CSB SCLK/DFS SDIO/PDWN VIN+ VINVCM
GND
MODE/OR DCO D13 D12 D11 D10 D9 D8
23 22 21 20 19 18 17 16
AD_OR AD_DCO AD_D13 AD_D12 AD_D11 AD_D10 AD_D9 AD_D8
D7 15 D6 14 D5 12 D4 11 D3 10 D2 9 D1 8 D0 7 RBIAS 28 SENSE 26
200 GND
PD
VS+ 8 VS+ 7 VS+ 6 VS+ 5
R32
GND
10uF/16V
C7
AD_D0 AD_D1 AD_D2 AD_D3 AD_D4 AD_D5 AD_D6 AD_D7
U3 ADA4937-1YCPZ-R2
VREF DRVDD AVDD AVDD AVDD AVDD AGND
BNC
200
R23 76.8
VSVSVSVSVS-
2 1
13 14 15 16 17
J1
E1
25 13 3 24 29 32 33
R21 GND
GND
GND
GND
3V3
Int Vref R20 10K(1%) GND
Fig .2. Scheme of analog front-end and data acquisition
4.2. A/D converter A/D converter is a key component of the digital multi-channel analyzer, which can directly affect performance of DMCA. In this design, AD9649-65 is used as its AD converter, which has the following characteristics: Conversion bit: 14-bit Sampling rate: 3-65Msps Low power consumption: 75mW at operating mode; 34mW at suspend mode Input mode: differential mode Output mode: 14-bit parallel bus Differential nonlinearity: ±0.3LSB Integral nonlinearity: ±0.5LSB
431
Zeng Weihua / Energy Procedia 39 (2013) 428 – 433
With high resolution, fast conversion rate, user-friendly control, low power consumption and other advantages, AD9649-65 is particularly suitable for rapid data acquisition, image processing, communications and other fields. 4.3. FPGA EP3C40Q240, the digital signal processor in the system, is responsible for A/D conversion control, digital signal processing, RS485 communication control and other function in the system. Integrated resources within the EP3C40Q240 chip include: 39,600 logic elements, 1134Kbit RAM, 126 multipliers and 4 phase-locked loops. In FPGA, the A/D conversion control module runs in parallel with the digital signal processing module of nuclear pulse, connected with each other by FIFO, which is realized by RAM within the FPGA. Compare to the digital multi-channel composed of single DSP system, digital multichannel composed of FPGA chip with parallel processing capabilities can effectively reduce the dead time of the multi-channel analysis. DMCA composed of a single FPGA chip is able to simplify the PCB layout design and thus effectively reduce the power consumption of DMCA. 4.4. RS485 interface Spectroscopy data of DMCA is transferred to the spectral processing system of personal computer via bus interface. In this design of DMCA, a high-speed half-duplex RS485 differential bus is used as the communication interface for the digital multi-channel. As a high-speed RS485 transceiver for power supply within a wide voltage range, SN65HVD08D can provide a communication speed of 0-10Mbps with power supply voltage of 3.3V or 5V. Figure 3 shows the block diagram of RS485 interface circuit. Build a USART communication module in FPGA so that FPGA is able to record the spectroscopy data in SRAM into this USART module, which will be converted into RS485 data and then transferred to personal computer. Compared to USB interfaces, high-speed RS485 interface circuit is simple, as only one RS485 converter with a high-speed USB interface is needed to be connected with the personal computer while without designing the complex USB driver on PC, further simplifying the design of the spectral data processing software. GND
5V
U11 485_RXD 485_nRE 485_DE 485_TXD
1 2 3 4
RO VCC /RE B DE A DI GND SN65HVD08D
8 7 6 5
R48 4.7K(OPEN)
5V
1 2 3 4
R53 4.7K(OPEN)
GND
GND 5V
Fig .3. Scheme of high-speed RS485 bus interface
J5
RS485
432
Zeng Weihua / Energy Procedia 39 (2013) 428 – 433
5. Software Design 5.1. Digital integration and peak-detection Detector output signal will be transferred to high-speed A/D conversion circuit after the pretreatments such as preamplifier and so on to obtain charge integration signal by digital integration. A/D converter is liable for continuous high-speed sampling while FPGA will perform the functions such as digital integration of nuclear signal, peak detection and threshold discrimination. Set integral width as T, integrated output signal as U o (t ) , input signal as Ui(t ) , integrate Ui(t ) as: t U o (t ) t T Ui( )d 1 Where Ui(t ) meets the following conditions: if -T< t < 0, then Ui(t ) 0 . Formula (1) can be converted into: Uo(t ) [Ui ( ) Ui ( T )]d 2 U o (t ) will have an extremum when the first derivative of U o (t ) is 0, i.e. when dUo(t ) dt 0 , Ui( ) Ui( T ) 0(0 t ) , U o (t ) is an extremum. When dUo(t ) d (t ) turns to negative from positive, Ui( ) Ui( T ) 0(0 t ) will turn to negative from positive correspondingly and U o (t ) will be the maximum value, and conversely the minimum value. Therefore, each nuclear pulse peak can be found in the continuous input signals. To obtain Ui(n T ) , discrete signals obtained from A/D conversion will be shifted at T time intervals by FPGA. In the process when Ui(n) Ui(n T ) gradually turns to negative from positive, Ui(n) Ui(n T ) 0 will be the peak value of Uo(n) . Therefore, the peak can be recorded into the corresponding address (channel) in SRAM. To improve the efficiency of peak-seeking, it is necessary to judge the threshold of discrete pulse signals prior to peak-detection. As peak-detection of signals with amplitude lower than the preset threshold is omitted, discrete nuclear pulse signals involved in peak-detection module are significantly reduced. 5.2. Software design for personal computer Software of personal computer is developed under Borland C++ integrated development environment, achieving lots of functions including RS485 serial communication, system parameter settings, spectrum display and spectroscopy data management, etc. 6. Performance Parameters This DMCA is capable of taking sample of nuclear pulses and obtaining energy spectrum. Figure 4 shows the energy spectra of 137Cs rays on 75*75mm NaI(Tl) detector measured by this DMCA. The basic performance parameters of this DMCA are as follows: Number of channels: 1024 (512-8192 channels may be set) Energy resolution: 8.6 Integral nonlinearity: 0.8% Differential nonlinearity: 1.4% Pulses through rate: >200k CPS
Zeng Weihua / Energy Procedia 39 (2013) 428 – 433
Fig.4. A
-ray spectrum of 137Cs collected by DMCA
7. Conclusions A kind of DMCA is designed based on FPGA used to complete data acquisition, digital integration of nuclear signals, peak-detection, RS485 high-speed data transmission. spectrum display program on personal computer was developed . 137Cs nuclear signals detected by NaI (Tl) detector are processed by DMCA to obtain 1024-channel energy spectrum with energy resolution approximate to 8 while logic resources utilization within FPGA is less than 30 . The basic functions of DMCA have been realized and further research will focus on realizing other functions on this hardware platform, such as digital filtering, waveform shaping of nuclear pulses, baseline elimination, pile-up rejection and other digital processing algorithms of nuclear pulses. By future work, DMCA will have more perfect functions and better performance. Acknowledgements Research for this paper was partially supported by “the fundamental research funds for the central universities”. References [1] Wang Lei, Tuo Xianguo, Cheng Yi, etc. Design of DMCA based on DSP[J]. Nuclear Electronics & Detection Technology, 2009, 29(4):880-882. [2] Xiao Wuyun, Wei Yixiang, Ai Xianyun, etc. Research on Digital Multi-Channel Pulse Height Analysis Techniques[J]. Nuclear Technology, 2005, 28(10):787-788. [3] Ge Liangquan, Zeng Guoqiang, Lai Wancheng, etc, Development of Measurement System of Aviation Digital Gamma Energy Spectrum[J]. Progress Report on China Nuclear Science & Technology, 2009, 1(Vol: Uranium Geology): 19-23. [4] Ao Qi, Wei Yixiang, Wen Xiangyang, Design of DMCA based on DSP[J]. Nuclear Technology, 2007, 30(6):532-534. [5] M. Grey , J. Goldsten, R. Maurer, D. Roth , C. Zeitlin. Data acquisition for the Combined Ion and Neutron Spectrometer (CINS) . Nuclear Instruments and Methods in Physics Research B,2009,267(1):139-143. [6] Ju Hahn Lee, Hyo Soon Jung, Hwa Youn Cho, Young Kwan Kwon, and Chun Sik Lee. A Novel Digital Pulse-Shape Analysis for High-Resolution Position-Sensitive Gamma-Ray Spectroscopy. NUCLEAR SCIENCE, 2010,57(5):2631-2637.
433