Nothing Special   »   [go: up one dir, main page]

CN100587504C - Digital synchronous sampling method - Google Patents

Digital synchronous sampling method Download PDF

Info

Publication number
CN100587504C
CN100587504C CN200810056423A CN200810056423A CN100587504C CN 100587504 C CN100587504 C CN 100587504C CN 200810056423 A CN200810056423 A CN 200810056423A CN 200810056423 A CN200810056423 A CN 200810056423A CN 100587504 C CN100587504 C CN 100587504C
Authority
CN
China
Prior art keywords
frequency
sampling
input signal
extraction
signal
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN200810056423A
Other languages
Chinese (zh)
Other versions
CN101216511A (en
Inventor
王荣华
门长有
杨昆
谭年熊
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Hangzhou hi tech Limited by Share Ltd
Original Assignee
Wangao (hangzhou) Technology Co Ltd
Wangong Sci & Tech Co Ltd Beijing
Hangzhou Vango Science & Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Wangao (hangzhou) Technology Co Ltd, Wangong Sci & Tech Co Ltd Beijing, Hangzhou Vango Science & Technology Co Ltd filed Critical Wangao (hangzhou) Technology Co Ltd
Priority to CN200810056423A priority Critical patent/CN100587504C/en
Publication of CN101216511A publication Critical patent/CN101216511A/en
Application granted granted Critical
Publication of CN100587504C publication Critical patent/CN100587504C/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Measuring Frequencies, Analyzing Spectra (AREA)
  • Synchronisation In Digital Transmission Systems (AREA)

Abstract

The invention relates to a digital synchronous sampling method, which belongs to the field of D/A mixed signal processing. The method comprises the following steps of: setting a sampling frequency fsto M*N*f0, sampling an input signal with a frequency fi according to the sampling frequency fs, wherein f0 is the frequency theoretical value of the input signal; measuring the frequency of the inputsignal; and subjecting the sampled signal to lower decimation filtering at a decimation position p and a decimation rate M' by a cascade comb decimation filter manner according to the frequency measurement result to an input signal with a sampling frequency and a frequency of fi after decimation satisfying the synchronous sampling relationship. The invention has the advantages of less calculationamount, easy implementation, accuracy synchronization and good practicality.

Description

A kind of digital synchronous sampling method
Technical field
The invention belongs to the digital-to-analogue mixed signal process field, particularly digital synchronous sampling method.
Background technology
Synchronized sampling is exactly complete cycle, uniform sampling uniformly-spaced, requires sample frequency f sWith the measured signal frequency f iRatio be the integral multiple of sampling number N in the week.According to sampled signal mode difference is provided, synchronized sampling is divided into synchronous sampling by software and hardware synchronization is sampled two kinds.
The hardware synchronization sampling is to produce the sampling pulse that is synchronized with measured signal by special hardware circuit.Traditional way is to utilize the frequency of phase locking following principle to realize synchronous equal interval sampling, and its circuit as shown in Figure 1.The interior Fractional-N frequency device that adds of phaselocked loop (hereinafter to be referred as PLL) that this circuit is made of phase comparator (hereinafter to be referred as PD), low-pass filter (hereinafter to be referred as LP), voltage controlled oscillator (hereinafter to be referred as VCO), input f iBe the frequency of measured signal, as the reference frequency of phaselocked loop, output f sBe sample frequency.f sBehind Fractional-N frequency with f iCompare; According to the phase-locked loop operation principle, f during locking s=N * f iBecause the real-time follow-up of PLL is when the measured signal frequency f iDuring variation, circuit can be followed the tracks of and lock automatically fast, satisfies the integral multiple that sample frequency is the measured signal frequency all the time, thereby realizes equal interval sampling N point in the week.This hard-wired synchronous sampling method needs mimic channel to realize, the design more complicated, and take bigger hardware area; When divider ratio N is big, the sample frequency f of output sThere is shake, equal interval sampling in the week that can not realize ideal.
The synchronous sampling method that adopts software to realize has two kinds: method one is dynamically to adjust sampling time interval in sampling process, i.e. sample frequency f is adjusted in equivalence s, make actual samples approach desirable evenly synchronized sampling constantly to greatest extent constantly; Method two be after sampling with linear interpolation method correction sampled value, make the actual samples sequence approach ideal uniform synchronized sampling sequence.But synchronous sampling by software needs the participation of microprocessor, for improving real-time, must adopt high performance microprocessor just can finish the needed computing of algorithm, so cost of development is also very high.
The synchronous sampling by software method need detect the measured signal fundamental frequency.2003 by Zhang Shiping, Zhao Yongping, Zhang Shaoqing, Li Desheng etc. are published in " electrical engineering journal " " a kind of grid frequency measurement new method based on adaptive notch filter ", it adopts the two poles of the earth adaptive notch filter structure: first order trapper filtering harmonic wave and the first-harmonic composition that is strengthened, widen the first-harmonic frequency spectrum thick through down-sampled processing again; Estimate fundamental frequency by second level trapper.It is little that this algorithm has calculated amount, and the fireballing advantage of frequency detecting is fit to business development and uses.
Summary of the invention
The objective of the invention is to have proposed a kind of digital synchronous sampling method for overcoming the weak point of prior art, have calculated amount little, be easy to realize, synchronously accurately, advantage that practicality is good.
A kind of digital synchronous sampling method that the present invention proposes is characterized in that, may further comprise the steps:
1) establishes sample frequency f sBe M * N * f 0, use f sTo frequency is f iInput signal sampling, f wherein 0Be the theoretical value of frequency input signal, M, N are positive integer, (are f sTo behind the signal sampling with analog signal digital, in the Digital Discrete territory to f 0Sampling be synchronous);
2) use based on the grid frequency measurement method of adaptive notch filter input signal is carried out frequency measurement;
3) according to the result of frequency measurement, it is that p, extraction yield are the following filtering extraction of M ' that the resulting sampled signal of step 1) is extracted the position with cascade comb filtering (hereinafter to be referred as CIC) extraction mode; Sample frequency after obtaining extracting and frequency are f iInput signal satisfy synchronized sampling relation.
The cascade comb filtering extraction mode of described step 3) adopts the cascade comb filter to realize that the transport function of this wave filter is:
H ( z ) = ( 1 - z - M ′ 1 - z - 1 ) r . . . ( 1 )
In the formula: r represents cascade exponent number, z -1Representation unit postpones, and M ' with the relation of M is
Figure C20081005642300042
(characteristics of this wave filter are that all filter factors are 1, do not need multiplier when therefore realizing).A kind of implementation of the wave filter that the present invention adopts is to be constituted integral unit and connected r by d type flip flop and totalizer, doing after the individual integral operation of every M ' once differentiates realizes extracting down, differentiation element is made of d type flip flop, subtracter and connects r, thus the transport function of realization formula (1);
(for incoming frequency be f iSignal keep the relation of synchronized sampling) extract the post-sampling frequency f down SdNeed to satisfy:
f sd = f s M ′ = N × f i . . . ( 2 )
Promptly descend extraction yield M ' to be:
M ′ = f s N × f i = M × f 0 f i . . . ( 3 )
If M ' fractional value is realized under the mark that extraction can utilize to extract the change of position in the CIC extraction process and realize; That is: be located at f sUnder the sampling rate k constantly the extraction position of CIC be p (k), and establish that next to extract constantly be k+x, extracting the position so can be expressed as:
p(k+x)=p(k)+x…………………………………(4)
Wherein x is the nonnegative integer that satisfies formula (5):
f i×(k+x)-round(f i×k)≥M×f 0…………………(5)
Wherein round represents the rounding operation that rounds up; f iIt is the frequency of input signal; f 0It is the theoretical value of frequency input signal; M is following extraction yield.
(all multiplyings in the formula (5) can by add up and mode realize, do not take hardware multiplier.) can be used for similar fast fourier transform (hereinafter to be referred as FFT) like this to the very sensitive computing of synchronized sampling through the signal after the above-mentioned processing digital synchronous sampling, and then obtain the required various data of practical application.
Characteristics of the present invention and effect:
The inventive method is at sample frequency f sUnder the constant condition, according to the measuring-signal frequency f iThe result dynamically adjust the extraction position of filtering extraction in the digital signal processing, make sample frequency f after extracting SdAlways follow frequency input signal f iVariation and change, therefore the actual sampled value that obtains is approached desirable uniform sampling value to greatest extent, has reached the purpose of synchronized sampling.Entire method can both be finished with digital circuit, and hardwareization need not the participation of software fully.
The present invention compares existing method, and to have calculated amount little, be easy to realize, synchronously accurately, the advantage that practicality is good.
Description of drawings
Fig. 1 is the structural representation of existing a kind of hard-wired synchronized sampling.
Fig. 2 is the theory diagram of the inventive method.
Fig. 3 is the embodiment block diagram of the inventive method.
Fig. 4 is the CIC structural representation that extracts position-controllable in the inventive method.
Fig. 5 is the signal FFT frequency spectrum of the inventive method embodiment after extracting.
Embodiment
Introduce its embodiment in detail below in conjunction with the application of the inventive method in the harmonic electric energy metering.
In the harmonic electric energy metering, need obtain first-harmonic and definite amplitude and the phase place of harmonic wave in the electrical network exactly, method commonly used is exactly fast fourier transform (hereinafter to be referred as FFT).And FFT calculating can cause serious frequency to leak and then make first-harmonic and harmonic wave electric energy metrical precision to reduce under the condition of non-synchronous sampling, so synchronized sampling is the key of harmonic wave metering.
The present invention be applied to harmonic wave metering synchronous sampling method embodiment structural drawing as shown in Figure 3, wherein, the theoretical value f of mains frequency 0Be 50Hz, suppose sample frequency f sBe 50 * 131072Hz=6.5536MHz, the actual frequency f of electrical network iBe 52Hz, this method may further comprise the steps:
1) to the simulating signal of the input analog to digital converter (hereinafter to be referred as ADC) that is 50 * 128 * 1024Hz=6.5536MHz through a sample frequency, it to signal sampling after with analog signal digital;
2) use the frequency f of measuring input signal based on the grid frequency measurement method of adaptive notch filter i=52Hz;
3) signal of ADC output is M=128 through a theoretical down-sampling rate, the CIC filtering extraction process of cascade exponent number r=3, its inner structure as shown in Figure 4, it constitutes integral unit (shown in left side among Fig. 4) by 3 d type flip flops and 3 totalizers; And push over formula (5) according to k extraction position constantly and realize that mark extracts down
Figure C20081005642300051
Constitute differentiation element (shown in right side among Fig. 4) by 3 d type flip flops and 3 subtracters, system's extraction yield is reduced to the most at last
If the k=0 extraction position of CIC constantly is p (0)=0, by recursion formula p (k+x)=p (k)+x and 52 * (k+x)-round (52 * k) 〉=128 * 50, can obtain each time successively and extract corresponding extraction position, for example the 1st, 2,3 time extraction position is respectively: 123,118,113.
Signal after CIC extracts the Digital Discrete territory and down-sampled after sample frequency satisfy the relation of synchronized sampling, promptly a signal cycle has 1024 point sampling values.
In the middle of practical application, in order to reduce the complexity that FFT calculates, present embodiment can be M=16 by a down-sampling rate with signal, and the cic filter of cascade exponent number r=3 drops to 3.328KHz with system frequency, and promptly a signal cycle has 64 point sampling values.
Above-mentioned synchronous sampling signal is done the FFT spectrum analysis, its spectral line as shown in Figure 5, wherein transverse axis is represented frequency (unit be hertz), the longitudinal axis is represented amplitude (unit is a decibel); The phenomenon of the spectrum leakage when as can be seen from Figure 5, there has not been non-synchronous sampling in frequency spectrum.The result of FFT is processed the relevant information that just can obtain measuring needed first-harmonic and harmonic wave, and wherein the active power error of first-harmonic is less than 0.0001%.

Claims (1)

1, a kind of digital synchronous sampling method is characterized in that, may further comprise the steps:
1) establishes sample frequency f sBe M * N * f 0, use f sTo frequency is f iInput signal sampling, f wherein 0Be the frequency theory value of input signal, M, N are positive integer;
2) input signal is carried out frequency measurement;
3) according to step 2) frequency measurement that obtains, it is that p, extraction yield are the following filtering extraction of M ' that the sampled signal of step 1) is extracted the position with cascade comb filtering extraction mode; Sample frequency after obtaining extracting and frequency are f iInput signal satisfy synchronized sampling relation;
The cascade comb filtering extraction mode of described step 3) adopts the cascade comb filter to realize that the transport function of this wave filter is:
H ( z ) = ( 1 - z - M ′ 1 - z - 1 ) r · · · ( 1 )
In the formula: r represents cascade exponent number, z -1Representation unit postpones, and M ' with the relation of M is M = 2 round ( log 2 ( M ′ ) ) ;
If described M ' is a fractional value, then be located at f sUnder the sampling rate k constantly the extraction position of cascade comb filtering be p (k), and establish and nextly extract constantly to be k+x, to extract the position so and try to achieve with following derivation formula:
p(k+x)=p(k)+x…………………………………(2)
Wherein x is the nonnegative integer that satisfies formula (3):
f i×(k+x)-round(f i×k)≥M×f 0…………………(3)
Wherein round represents the rounding operation that rounds up; f iIt is the frequency of input signal; f 0It is the theoretical value of frequency input signal; M is theoretical extraction yield down.
CN200810056423A 2008-01-18 2008-01-18 Digital synchronous sampling method Active CN100587504C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN200810056423A CN100587504C (en) 2008-01-18 2008-01-18 Digital synchronous sampling method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN200810056423A CN100587504C (en) 2008-01-18 2008-01-18 Digital synchronous sampling method

Publications (2)

Publication Number Publication Date
CN101216511A CN101216511A (en) 2008-07-09
CN100587504C true CN100587504C (en) 2010-02-03

Family

ID=39622989

Family Applications (1)

Application Number Title Priority Date Filing Date
CN200810056423A Active CN100587504C (en) 2008-01-18 2008-01-18 Digital synchronous sampling method

Country Status (1)

Country Link
CN (1) CN100587504C (en)

Families Citing this family (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102809679A (en) * 2012-08-08 2012-12-05 航天科工深圳(集团)有限公司 Method and device for sampling electric monitoring signal
CN102901853A (en) * 2012-09-19 2013-01-30 四川大学 Nuclear signal frequency conversion digitization sampling method
CN103634006A (en) * 2013-04-28 2014-03-12 中国科学院电子学研究所 Rapid mixed sampling method for ultra wide band signal
CN104459318B (en) * 2014-11-13 2017-06-16 广东电网有限责任公司电力科学研究院 The measuring method and system of electric harmonic
CN104483545B (en) * 2014-11-27 2017-05-31 广东电网有限责任公司电力科学研究院 The harmonic measuring method and system of power system
CN104483563B (en) * 2014-11-27 2017-03-08 广东电网有限责任公司电力科学研究院 The synchronous sampling method of electric power signal and system
CN106209031A (en) * 2016-07-18 2016-12-07 珠海格力电器股份有限公司 Clock circuit, clock signal generating method, and control chip including the clock circuit
CN106291096A (en) * 2016-07-20 2017-01-04 中国电力科学研究院 A kind of multistage method for resampling for nonlinear load electric energy meter
CN107085144B (en) * 2017-04-28 2019-08-20 珠海泰芯半导体有限公司 A kind of method of rapid survey Harmonious Waves in Power Systems
CN107800441B (en) * 2017-10-26 2021-05-28 慧众行知科技(北京)有限公司 Signal processing method and system
CN108121396B (en) * 2017-12-19 2020-12-01 电子科技大学 Selection method of variable fractional sampling rate
CN109633266B (en) * 2019-02-26 2020-12-01 重庆新世杰电气股份有限公司 Frequency measurement method, system, device and computer readable storage medium

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
时域同步平均原理与应用. 罗德扬.振动、测试与诊断,第19卷第3期. 1999
时域同步平均原理与应用. 罗德扬.振动、测试与诊断,第19卷第3期. 1999 *

Also Published As

Publication number Publication date
CN101216511A (en) 2008-07-09

Similar Documents

Publication Publication Date Title
CN100587504C (en) Digital synchronous sampling method
CN106932642B (en) Electric Power Harmonic Analysis method
CN103558436B (en) Based on the method for the detection of grid voltage magnitude of single-phase phase-locked loop algorithm, frequency and phase angle
CN102236048B (en) Method for measuring phasor frequency of electric system
CN105871371B (en) A kind of three-stage time-to-digital conversion circuit based on phaselocked loop
Yao et al. A novel method for phasor measurement unit sampling time error compensation
CN103257271A (en) Device and method for detecting micro grid harmonic wave and inter-harmonics based on STM32F107VCT6
CN101833603B (en) Sigma-delta fraction N frequency comprehensive device behavior level modeling method
CN104181374B (en) Method for detecting and separating positive and negative sequence components of grid voltage of three-phase neutral-line-free system
CN102045062A (en) Digital phase-locked loop based on Cordic algorithm
CN203287435U (en) A micro electrical network harmonic wave and inter-harmonic wave test apparatus based on an STM32F107VCT6
CN109495169A (en) Wide-range high-precision time delay measuring device and method for optical fiber link
US20120084035A1 (en) System and method for frequency measurement based on quadratic forms
CN109510619A (en) Enhanced phaselocked loop for the detection of single-phase mains voltage synchronizing information
CN104391464B (en) A kind of hardware equivalent synchronized sampling unit based on FPGA
CN103487648A (en) Sigma-delta PLL frequency measuring circuit and method
CN104410408A (en) Single phase locking method and device
CN103412209B (en) A kind of off resonance degree detection method of tuned filter
CN101789601B (en) Real time digital system (RTDS) phase-locking synchronous element
CN106199184A (en) A kind of spectrum analyzer with quick phase-locked function
CN204517793U (en) A kind of device improving crystal oscillator long-term stability
CN201985842U (en) Local frequency generation circuit for microwave bandwidth folding receiver
CN101060330B (en) A broken number frequency division synthesizer
RU2625557C1 (en) Method for determining borders of operating range of impulse generator of phase synchronisation systems and device for its implementation
CN109120260A (en) A kind of clock module high-precision phase demodulation system and method based on ASIC-TDC

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
C41 Transfer of patent application or patent right or utility model
TR01 Transfer of patent right

Effective date of registration: 20110603

Address after: Hangzhou City, Zhejiang province 310012 Xihu District Huaxing Road No. 99 Neusoft building A408 room

Co-patentee after: Wangong Sci. & Tech. Co., Ltd., Beijing

Patentee after: Hangzhou Vango Science & Technology Co., Ltd.

Address before: Hangzhou City, Zhejiang province 310012 Xihu District Huaxing Road No. 99 Neusoft building A408 room

Co-patentee before: Wangao (Hangzhou) Technology Co., Ltd.

Patentee before: Hangzhou Vango Science & Technology Co., Ltd.

Co-patentee before: Wangong Sci. & Tech. Co., Ltd., Beijing

ASS Succession or assignment of patent right

Owner name: WANGAO (HANGZHOU) TECHNOLOGY CO., LTD.

Free format text: FORMER OWNER: HANGZHOU VANGO SCIENCE + TECHNOLOGY CO., LTD.

Effective date: 20130410

Free format text: FORMER OWNER: WANGONG SCI. + TECH. CO., LTD., BEIJING

Effective date: 20130410

C41 Transfer of patent application or patent right or utility model
TR01 Transfer of patent right

Effective date of registration: 20130410

Address after: Hangzhou City, Zhejiang province 310012 Binjiang District Dangfeng Road No. 788, building 901, 902 sea

Patentee after: Wangao (Hangzhou) Technology Co., Ltd.

Address before: Hangzhou City, Zhejiang province 310012 Xihu District Huaxing Road No. 99 Neusoft building A408 room

Patentee before: Hangzhou Vango Science & Technology Co., Ltd.

Patentee before: Wangong Sci. & Tech. Co., Ltd., Beijing

C56 Change in the name or address of the patentee
CP03 Change of name, title or address

Address after: Hangzhou City, Binjiang District province six and 310053 Zhejiang Road No. 368 building B4004 North Sea Base

Patentee after: Hangzhou hi tech Limited by Share Ltd

Address before: Hangzhou City, Zhejiang province 310012 Binjiang District Dangfeng Road No. 788, building 901, 902 sea

Patentee before: Wangao (Hangzhou) Technology Co.Ltd