CN102128656A - Slightly bent Koch mass flow meter digital signal processing method and system - Google Patents

Slightly bent Koch mass flow meter digital signal processing method and system Download PDF

Info

Publication number
CN102128656A
CN102128656A CN 201110046129 CN201110046129A CN102128656A CN 102128656 A CN102128656 A CN 102128656A CN 201110046129 CN201110046129 CN 201110046129 CN 201110046129 A CN201110046129 A CN 201110046129A CN 102128656 A CN102128656 A CN 102128656A
Authority
CN
China
Prior art keywords
digital signal
dsp
analog
signal processing
processing method
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.)
Granted
Application number
CN 201110046129
Other languages
Chinese (zh)
Other versions
CN102128656B (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.)
Anhui Tianwei Instrument Co ltd
Original Assignee
Hefei University of Technology
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 Hefei University of Technology filed Critical Hefei University of Technology
Priority to CN 201110046129 priority Critical patent/CN102128656B/en
Publication of CN102128656A publication Critical patent/CN102128656A/en
Application granted granted Critical
Publication of CN102128656B publication Critical patent/CN102128656B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention relates to a slightly bent Koch mass flow meter digital signal processing method and system. The slightly bent Koch mass flow meter digital signal processing system comprises an amplifying and filtering circuit, an ADC (A/D converter) 1, an ADC (A/D converter) 2, a voltage reference source, a voltage follower, a current source, a difference amplifier, an ADC (A/D converter) 3, an analog driver module, a DSP (digital signal processor), an expended SRAM (static random access memory), an expended EEPROM (electrically erasable programmable read-only memory), 4-20 mA output, pulse output, a power module and software. The analog driver module stimulates an exciter in a Koch mass flow sensor to make a flow pipe vibrate at the natural frequency. After being amplified and filtered by two regulating circuits with same parameters, two sensor signals are respectively transformed into digital values by the ADC 1 and the ADC 2, and then are transported to the DSP by the multichannel MCBSP of the DSP. The DSP carries out digital filtering noise elimination on the collected signals, the frequency and the phase difference of the signal are calculated by adopting a zero-crossing detection method based on the lagrange's interpotation so that the parameters of the density, the mass flow, and the like of the fluid are obtained, and compensation is carried out by combining the temperature.

Description

A kind of little curved Ke's mass flowmeter digital signal processing method and system
Technical field
The present invention relates to field of flow detection, be a kind of Ke's mass flowmeter digital signal processing method and system, particularly higher at little curved coriolis mass flow sensor natural frequency, phase differential is less and the IIR bandpass filter of a kind of passband width, the depth-adjustment of design, based on the signal processing method and the system of the zero passage detection of Lagrange's interpolation.
Background technology
Coriolis mass flowmeters (abbreviation Coriolis mass flowmeter) can directly be measured mass rate, is one of current flowmeter with the fastest developing speed, has broad application prospects.Coriolis mass flowmeter is made up of primary instrument and secondary instrument, and primary instrument comprises measuring tube (or claiming flowtube), magnetoelectric velocity transducer (perhaps optical displacement sensor), vibrator and temperature sensor; Secondary instrument is called transmitter again, mainly comprises signal condition, processing and driving circuit.Measuring tube has U-shaped cast (being designated hereinafter simply as the U type), straight pipe type and little bent tube type (being designated hereinafter simply as little curved) etc., wherein, U type highly sensitive, promptly the torsional deformation that coriolis force produced that is caused by flow is big, and natural frequency (resonance frequency) is generally between 70Hz to 150Hz; The sensitivity of straight pipe type is low, and natural frequency is generally more than 1kHz; Little curved remolding sensitivity U type low, natural frequency is generally between 300Hz to 900Hz.The effect of transmitter is mistiming or frequency and the phase differential of measuring between the two-way magnetoelectric velocity transducer output signal.For computational accuracy and the antijamming capability that improves Coriolis mass flowmeter, Digital Signal Processing is used for the processing of coriolis mass flow sensor output signal both at home and abroad, development is based on the Coriolis mass flow transmitter of DSP (digital signal processor), for example, HeFei University of Technology combines lattice type adaptive notch filter and the DTFT algorithm of taking into account negative frequency, handle the output signal of coriolis mass flow sensor, and adopt the TMS320F28335 dsp chip to develop Coriolis mass flow transmitter (Xu Kejun, Zhu Yong is strong etc., a kind of Coriolis mass flow transmitter based on DSP, patent of invention, application number: 200910185560.8, application publication number: CN 101706299 A, Shen Qing Publication day: 2010.05.12).Sensor output signal carries out pre-service through digital filter earlier, adopts lattice type adaptive notch filter tracking signal frequency afterwards, adopts the phase differential of the DTFT algorithm computation signal of taking into account negative frequency.A whole set of algorithm has stronger antijamming capability, speed of convergence, higher computational accuracy faster, the transmitter of being developed matches with U type Coriolis mass flowmeter primary instrument, carries out discharge and demarcates, and measuring accuracy reaches 0.1 grade, more than the range ratio 20:1, effect is fine.But this transmitter is mainly at the U type.When being used to handle little curved coriolis mass flow sensor output signal,,, just must improve the sample frequency of transmitter in order to obtain computational accuracy preferably because the natural frequency of little bend pipe is higher; In order to reflect the variation of flow in real time, must between the sampling interval of adjacent two data, finish the processor active task of algorithm; And present dsp chip is because the restriction of resource can't be finished this task in real time.If simplify present algorithm, reduce calculated amount, certainly will reduce computational accuracy.And the phase differential of little curved coriolis mass flow sensor output little than U type, for example, the phase differential of the U type Coriolis mass flowmeter maximum flow correspondence of domestic certain Coriolis flowmeter manufacturer production is about 2 0, and the phase differential of little curved Coriolis mass flowmeter maximum flow correspondence is about 0.5 0So, must propose new, not only satisfy computational accuracy require, but also can be on DSP the algorithm of real-time implementation, the handling problem that solves little curved coriolis mass flow sensor output signal.
Summary of the invention
The present invention is for addressing the above problem, by the following technical solutions: little curved Ke's mass flowmeter digital signal processing method and system comprise amplification filtering circuit, analog to digital converter (ADC1), analog to digital converter (ADC2), voltage-reference, voltage follower, current source, differential amplifier, analog to digital converter (ADC3), analog-driven module, digital signal processor DSP, extend out SRAM, extend out EEPROM, man-machine interface, the output of 4~20mA electric current, pulse output, power module and software.The vibrator of analog-driven module excitation coriolis mass flow sensor inside makes flowtube with natural frequency vibration; Be positioned at two magnetoelectric sensor output two-way sinusoidal signals of flowtube both sides, two paths of signals is after the identical modulate circuit amplification of two-way parameter, filtering, by two identical ADC1 and analog to digital converter ADC2 sample conversion of model is digital quantity, and the multichannel buffered serial port McBSP by digital signal processor DSP sends into digital signal processor DSP; Digital signal processor DSP is eliminated noise effect to the filtering of the advanced line number word of sampled signal, adopts frequency, mistiming based on the zero passage detection method signal calculated of Lagrange (Lagrange) interpolation again, and then obtains the mass rate and the fluid density of fluid; Steady current is through coriolis mass flow sensor temperature inside sensor (RTD), the RTD output voltage is behind differential amplifier, by analog to digital converter ADC3 sample conversion is that digital quantity is sent into digital signal processor DSP, and digital signal processor DSP compensates according to the temperature convection amount; The measurement result of digital signal processor DSP shows on liquid crystal, and exports measurement result by output of 4~20mA electric current and pulse output module.
The advantage of patent of the present invention is: adopt a kind of simply and effectively signal processing algorithm to handle the Ke Shi sensor signal, reduce the operand of algorithm greatly, be easy to realize, be fit to very much the higher Ke Shi sensor signal of the little curved equifrequent of processing; Take corresponding measure to overcome that single-chip microcomputer computing number of significant digit is limited, there is biasing problem in hardware circuit, guaranteed the realization precision of algorithm; Based on DSP in real time, implementation algorithm accurately, develop the system that industry member can be accepted and use.
Description of drawings
Fig. 1 is the hardware The general frame of system of the present invention.
Fig. 2 is the master monitor process flow diagram of system of the present invention.
Fig. 3 is the signal acquisition process synoptic diagram of system of the present invention.
Fig. 4 is the ADC break in service process flow diagram of system of the present invention.
Fig. 5 is the DMA break in service process flow diagram of system of the present invention.
Fig. 6 is the zero passage detection schematic diagram of system of the present invention.
Fig. 7 is the zero passage detection algorithm block diagram of system of the present invention.
Fig. 8 finds the solution the process flow diagram at zero point for system of the present invention.
Fig. 9 is the influence of the circuit bias of system of the present invention to algorithm.
Figure 10 is the pulse output synoptic diagram of system of the present invention.
Figure 11 is the PWM divide ratio allocation scheme of system of the present invention.
Embodiment
Hardware block diagram of the present invention as shown in Figure 1, by amplification filtering circuit, analog to digital converter (ADC1), analog to digital converter (ADC2), voltage-reference, voltage follower, current source, differential amplifier, analog to digital converter (ADC3), analog drive circuit, digital signal processor (DSP), extend out SRAM, extend out EEPROM, man-machine interface, the output of 4~20mA electric current and pulse output, power module form.
The course of work of the present invention as shown in Figure 2.After system powered on, on the one hand, the vibrator of analog drive system excitation Coriolis mass flowmeter primary instrument made flowtube with natural frequency vibration; On the other hand, digital signal processor DSP is finished the initialization of each module of system and the initialization of algorithmic variable.Be positioned at two magnetoelectric sensor output two-way sinusoidal signals of flowtube both sides, after the modulate circuit amplification that this two paths of signals process two-way parameter is identical, the filtering, by two analog to digital converter ADC1, analog to digital converter ADC2 samplings that model is identical, sampled result is sent in the digital signal processor DSP by the multichannel buffered serial port McBSP of digital signal processor DSP; Digital signal processor DSP adopts frequency and phase differential based on the zero passage detection method signal calculated of Lagrange's interpolation again to the filtering of the advanced line number word of sampled data, obtains mass rate; Digital signal processor DSP reads the numerical value of analog to digital converter ADC3, is converted into temperature, and flow is carried out temperature compensation; Finally, flow measurement is the result be presented on the LCD, and by 4~20mA and pulse output module, exports corresponding electric current and pulse signal.
After system powers on, mimic channel produces the vibration of drive signal excitation Coriolis flowmeter on the one hand, digital signal processor DSP is finished the initialization of system's various piece on the other hand, starts also the sample conversion of two-way analog to digital converter ADC1 and analog to digital converter ADC2 synchronously then.After analog to digital converter ADC1 data-switching is good, trigger interruption to digital signal processor DSP by GPIO.Consider that analog to digital converter ADC1, analog to digital converter ADC2 open synchronously, data-switching is finished in theory simultaneously, therefore, does not open analog to digital converter ADC2 and interrupts, by the state of inquiry analog to digital converter ADC2 in ADC1 interrupts, judge whether analog to digital converter ADC2 converts.After converting, digital signal processor DSP provides clock by McBSP-A, McBSP-B to analog to digital converter ADC1, analog to digital converter ADC2, transformation result is moved to the receiving register (DRR) of McBSP; It then is to finish by direct memory access (DMA) (DMA) module that data in the McBSP receiving register are specified the transfer in random-access memory (ram) space to the user.During initialization DMA, the passage 1 of DMA, the source address pointer of passage 2 are respectively the receiving register of McBSP-A and McBSP-B, the purpose pointer is interim array bufferL, the bufferR of directed towards user definition then, and then DMA automatically stores the ADC transformation result into bufferL and bufferR from DRR.When interim array deposit full after, produce DMA and interrupt, in the interrupt service routine, DMA changes the purpose pointer earlier, prepares for transmitting next time, the content in the ephemeral data is copied in two circulation arrays in the external SRAM again, waits for calling of algorithm.Like this, leaving alone under the situation of CPU, finishing reading of ADC sampled result.Whole signals collecting, transport process as shown in Figure 3, ADC break in service flow process as shown in Figure 4, DMA break in service flow process is as shown in Figure 5.
As shown in Figure 2, after having produced 500 new point data, promptly begin to call algorithm.Detection signal amplitude size at first if signal amplitude, represents then that sensor does not open fully less than setting value and shake, continues to wait for; After signal amplitude is greater than setting value, allow 500 point data pass through the IIR bandpass filter of a passband width and depth-adjustment earlier, carry out pre-service, adopt afterwards based on glug and allow frequency, mistiming of zero passage detection method signal calculated of day interpolation, draw instantaneous mass flow in conjunction with instrument coefficient; Read temperature, flow is carried out temperature compensation.The whether set of inquiry keyboard zone bit is if set is then called keyboard and handled subroutine.By regularly 1s interruption of cputimer0, in interrupt service routine, the instantaneous delivery that adds up obtains integrated flow; In addition, according to the instantaneous delivery value, by DA or outwards output 4~20mA electric current and the pulse of ePWM module.Refresh LCD, show each measurement result.
There is multiple noise in the actual industrial scene, disturb as a certain fixed frequency that random noise, power frequency interference, motor and pipe vibration etc. cause, the frequency band of these noise distributes very wide, for this reason, the present invention adopts a kind of IIR bandpass filter with trapper structure that sensor signal is carried out filtering.Filter transfer function is:
Figure 2011100461292100002DEST_PATH_IMAGE002
(1)
In the formula,
Figure 2011100461292100002DEST_PATH_IMAGE003
,
Figure 2011100461292100002DEST_PATH_IMAGE004
Be the trap frequency, ,
Figure 2011100461292100002DEST_PATH_IMAGE006
Will
Figure 2011100461292100002DEST_PATH_IMAGE007
With
Figure 591290DEST_PATH_IMAGE003
Substitution formula (1) can get its gain at trap frequency place and is:
Figure 2011100461292100002DEST_PATH_IMAGE008
(2)
When
Figure 2011100461292100002DEST_PATH_IMAGE009
,
Figure 2011100461292100002DEST_PATH_IMAGE010
Be in close proximity to 1, and
Figure 757698DEST_PATH_IMAGE004
During not 0, near π, 2 π, formula (2) can be reduced to:
Figure 2011100461292100002DEST_PATH_IMAGE011
(3)
As seen, when
Figure 2011100461292100002DEST_PATH_IMAGE012
The time, the trap place is decay; When
Figure 2011100461292100002DEST_PATH_IMAGE013
The time, the trap place is for amplifying.Trap depth by
Figure 2011100461292100002DEST_PATH_IMAGE014
Figure 2011100461292100002DEST_PATH_IMAGE015
Decision, and be subjected to
Figure 160604DEST_PATH_IMAGE004
Influence very little.During designing filter, can fix earlier
Figure 618130DEST_PATH_IMAGE009
, by regulating
Figure 245552DEST_PATH_IMAGE010
Change the trap width of trapper, its value approaches 1 more, and the trap width is narrow more; Regulate again
Figure 130331DEST_PATH_IMAGE009
, change trap depth.This bandpass filter passband is narrower, and in working in the reality, when fluid media (medium) was full of flowtube, the natural frequency basic fixed of Coriolis mass flowmeter was feasible so with this wave filter the Coriolis mass flowmeter output signal is carried out pre-service.
Zero passage detection obtained the time interval between zero crossing, and then asks for signal frequency, phase differential, as shown in Figure 6 by the moment of tracer signal zero crossing.As seen, signal frequency is , the two paths of signals mistiming is
Figure 2011100461292100002DEST_PATH_IMAGE017
, phase differential is
Figure 2011100461292100002DEST_PATH_IMAGE018
In the actual operation, DSP handles is discrete signal after the sampling.Because ADC can not sample cycle signal zero-cross point just, this just need carry out curve fitting to sampled data, obtains signal zero crossing, as shown in Figure 7.The present invention adopts Lagrangian quadratic interpolation match.If sample sequence
Figure 2011100461292100002DEST_PATH_IMAGE019
, work as appearance
Figure 2011100461292100002DEST_PATH_IMAGE020
The time, promptly show at [n-1, n] to have a zero point constantly.Generate the quadratic interpolation polynomial expression
Figure 2011100461292100002DEST_PATH_IMAGE021
, by Lagrangian computing formula:
Simplify:
(4)
Figure 2011100461292100002DEST_PATH_IMAGE024
?(5)
Figure 2011100461292100002DEST_PATH_IMAGE025
(6)
Therefore, can obtain by solving an equation
Figure 2011100461292100002DEST_PATH_IMAGE026
The time moment corresponding t, i.e. zero crossing.To give up that root outside [n-1, n] in the equation in actual applications.
Finding in implementation procedure, is that situations between [n-1, n] not of two roots that the match quadratic equation obtains all can appear in 3 matches of Lagrange's interpolation or 5 matches of least square method.When this situation occurring, find the solution null position again with approach based on linear interpolation, find the solution flow process as shown in Figure 8.
After 500 signal datas find zero point, just can the signal calculated parameter.Ask phase differential to need the zero point of two paths of signals, this takes place to misplace to subtract each other easily, as shown in Figure 6, if 500 do not comprise just
Figure 2011100461292100002DEST_PATH_IMAGE027
, will produce
Figure 2011100461292100002DEST_PATH_IMAGE028
Therefore such dislocation, need be judged.Suppose that two paths of signals respectively calculates
Figure 2011100461292100002DEST_PATH_IMAGE029
,
Figure 2011100461292100002DEST_PATH_IMAGE030
Individual zero point is because the phase range of little curved Coriolis mass flowmeter is no more than
Figure 2011100461292100002DEST_PATH_IMAGE031
10 °, so do as judging:
(1) if , L road signal lag then is described and dislocation can take place and subtract each other modification method: should be
Figure 2011100461292100002DEST_PATH_IMAGE033
To zero point, the mistiming by
Figure 2011100461292100002DEST_PATH_IMAGE034
Try to achieve;
(2) if
Figure 2011100461292100002DEST_PATH_IMAGE035
, R road signal lag then is described and dislocation can take place and subtract each other modification method: should be
Figure 2011100461292100002DEST_PATH_IMAGE036
To zero point, the mistiming by
Figure 2011100461292100002DEST_PATH_IMAGE037
Try to achieve;
(3) if
Figure 2011100461292100002DEST_PATH_IMAGE038
No matter illustrate to be LStill RDislocation can not take place road signal lag subtracts each other, and has
Figure 2011100461292100002DEST_PATH_IMAGE039
To zero point, the mistiming directly by
Figure 2011100461292100002DEST_PATH_IMAGE040
Try to achieve.
The zero passage detection method is simple, and calculated amount is little, but when realizing on DSP, is subjected to the influence that DSP computing number of significant digit is limited, there is biasing in hardware circuit easily.So, must take corresponding measure to guarantee the realization precision of algorithm.
The float categorical variable that uses 32 is when carrying out interpolation arithmetic, and the coefficient number of significant digit that is obtained by formula (4)~(6) is few, and the error of calculation is big.For this reason, intermediate variable must use 64 double types of variables when interpolation arithmetic.
Algorithm is transplanted to when DSP goes up test and is found, when the used sampled value of Lagrange's interpolation
Figure 352625DEST_PATH_IMAGE019
Very near 0 o'clock, the resultant error of calculating can be very big, and when separating the quadratic polynomial equation, along with nIncrease, increasing by the equation root error that formula (4)~(6) solve, these all are the limited and truncation errors that cause of DSP computing number of significant digit.The method that solves is that the sampled value that Lagrange's interpolation is used is amplified 100 times earlier, and subscript unification is constantly carried out interpolation calculation by (n-2), (n-1), n normalizing to 0,1,2 again, and formula (4)~(6) become:
Figure 2011100461292100002DEST_PATH_IMAGE041
(7)
Figure 2011100461292100002DEST_PATH_IMAGE042
(8)
(9)
Through after the above-mentioned processing, the number of significant digit of result of calculation is improved, and has guaranteed the realization precision of algorithm.
Because the hardware circuit parameter can not accomplish to mate fully, the modulate circuit of two-way sensor signal is symmetry fully, and this just causes the signal after the two-way conditioning to have biasing, is not strict with 0 symmetry, and the biasing difference of two paths of signals.And algorithm detects is cycle signal zero-cross point, and therefore, must take measures on customs clearance overcomes the influence of circuit bias to algorithm.
Suppose that left road sensor signal just is biased to, the right wing sensor signal is biased to negative, the zero crossing of algorithm detection signal, as shown in Figure 9.
During calculated rate, be example with left road, [L 1, L 2] between the time interval less than the half period of signal, and [L 2, L 3] between the half period interval greater than signal, so, if only with L 1 , L 2 Or L 2 , L 3 The signal calculated frequency must be introduced than the computation error.For the influence that reduces to setover to frequency computation part, should use L 1, L 3Ask for signal frequency, the zero point that promptly guarantees to ask for frequency and be employed zero point a signal period is right.
When calculating phase differential,, make from L because the two paths of signals biasing is different 1 , R 1 , L road signal lag is from L 2 , R 2 , L road signal is leading.In the reality, biasing may not can so obviously (allows one road signal in negative edge hysteresis at zero point, leading zero point at rising edge) to the influence of algorithm, allows one road signal in negative edge hysteresis at zero point, in rising edge leading trend at zero point, if only with L but can produce one 1 , R 1 Or L 2 , R 2 For primitive calculates phase differential, calculating the result will inevitably fluctuate.For this reason, should be with L 1 , R 1 And L 2 , R 2 Be primitive, two groups of zero points that promptly comprise rising edge and negative edge are to calculating phase differential.When adopting said method calculated rate and phase differential, the fluctuation of result of calculation obviously reduces.
After calculating signal frequency, phase differential, result of calculation is sorted, and abandon maximum, smallest point, get rid of singular point, after intermediate point is averaged, again the result is sent into second level running mean.The numerical values recited of macro definition average group length MeanN in the software, and open up a TimeDiffAarry[MeanN] array, then each running mean is calculated as:
TimeDiffMean=TimeDiffMean+(TimeDiff-TimeDiffAarry[mean_cur])/MeanN;
TimeDiffAarry[mean_cur]=TimeDiff;
mean_cur++;
if(mean_cur>=?MeanN)
{mean_cur=0;}
As seen,, can change the length of running mean array, take into account algorithm response speed and response accuracy, and do not need to change the internal algorithm program only by the size of macro definition MeanN.
In cputimer0 interrupts, flow need be converted to electric current output.Send 12 bit serial data with GPIO simulation SPI sequential to DA7513, finish the conversion of digital quantity by D/A to analog voltage amount, again by a V/I translation circuit, with voltage transitions is 4~20mA, be that DSP needs earlier instantaneous delivery to be converted to electric current, be voltage with current conversion again, write the corresponding digital quantity of voltage therewith to D/A at last.
It then is to finish by the ePWM module that instantaneous delivery is converted to pulse, and the present invention has designed a kind of software and realized the quantitatively method of output pulse.In the 1s that cputimer0 produces interrupts, the flow rate conversion that is accumulated in this 1s is become will export the number of pulse, and stipulate these pulses output when cputimer0 interrupts next time finish (in 1s, export and finish).The flow value out_flow that exports gets the integral part of integrated flow in this 1s, and fraction part left_flow is added to next time and calculates.If pulse equivalency is the 1g/ pulse, then in 1s, export N=out_flow pulse, the frequency of pulse is f PwmSo=N is the periodic quantity PRD=f of general purpose timer TBCLK/ f Pwm, base when TBCLK is the input of timer, its frequency is f TBCLK=HSPCLK/DIV, HSPCLK=75MHz is the high-frequency clock of DSP, and DIV is a divide ratio, and value is 1,2,4,8,16,32,64,128.Because of (f TBCLK/ f Pwm) the possibility of result be decimal, and PRD only gets result's integral part, maximum error is-1.Therefore, pwm pulse of every output, timer can be counted a TBCLK pulse at most more, so in 1s, timer at most can many meter f PwmIndividual TBCLK pulse, but as long as guarantee CMP〉fpwm, the part of many meters just can not produce new pwm pulse.In cputimer0 interrupts next time, can be earlier with timer count value CNT zero clearing, the part of many meters can not add up, as shown in figure 10.
As seen, a certain number of pulses switch of output becomes the PWM ripple of output certain frequency in 1s.The main task of upgrading the PWM output valve promptly is according to different f Pwm, select corresponding divide ratio DIV, guaranteeing PRD between 0~65535, and CMP f PwmAt HSPCLK=75MHz, under the CMP=PRD/2 situation, the frequency range that DSP can export is 8.94~6123Hz, at the sensor of different bores, can revise pulse equivalency, cooperates pulse output.At this, Figure 11 provides the concrete allocation scheme of a kind of DIV.
It is unusual to occur some in the measuring process, the situation that for example external device initialization error, transmitter do not have that input signal, measurement result go beyond the scope, Array Bound, data cover or the like, for the ease of monitoring these mistakes, also debugging for convenience simultaneously, in system software, add error module, be used for the abnormal conditions that produce in mark and the logging program implementation.Definition ERROR structure and global variable cmf_error:
typedef?struct
{ int16?ad_error;
int16?no_signal_error;
int16?array_overflow_error;
int16?zero_cross_error;
int16?eeprom_error;
int16?ad_temp_error;
int16?error_flag;?}
ERROR;
ERROR?cmf_error;
When the configuration peripheral hardware, to peripheral hardware operate, when algorithm process is made mistakes, the number of times that corresponding module will be made mistakes at corresponding program segment adds 1, and the error_flag of set simultaneously, inquiry cmf_error variable state, and take corresponding error handling processing measure.

Claims (10)

1. little curved Ke's mass flowmeter digital signal processing method and system, comprise the amplification filtering circuit, analog to digital converter (ADC1), analog to digital converter (ADC2), voltage-reference, voltage follower, differential amplifier, analog to digital converter (ADC3), the analog-driven module, digital signal processor (DSP), extend out SRAM, extend out EEPROM, man-machine interface, output of 4~20mA electric current and pulse output, power module and software, it is characterized in that: the vibrator of analog-driven module excitation Ke Shi sensor internal makes flowtube with natural frequency vibration; Be positioned at two magnetoelectric sensor output two-way sinusoidal signals of flowtube both sides, two paths of signals is after the identical modulate circuit amplification of two-way parameter, filtering, by two identical analog to digital converter (ADC1) and analog to digital converter (ADC2) sample conversion of model is digital quantity, and the multichannel buffered serial port McBSP by digital signal processor (DSP) sends into digital signal processor (DSP); Digital signal processor (DSP) is eliminated noise effect to the filtering of the advanced line number word of sampled signal, adopts frequency, mistiming based on the zero passage detection method signal calculated of Lagrange's interpolation again, and then obtains the mass rate and the fluid density of fluid; Steady current is through coriolis mass flow sensor temperature inside sensor (RTD), temperature sensor (RTD) output voltage is behind differential amplifier, by analog to digital converter (ADC3) sample conversion is that digital quantity is sent into digital signal processor (DSP), and digital signal processor (DSP) compensates according to the temperature convection amount; The measurement result of digital signal processor (DSP) shows on liquid crystal, and exports measurement result by output of 4~20mA electric current and pulse output module.
2. a kind of little curved Ke's mass flowmeter digital signal processing method as claimed in claim 1 and system, it is characterized in that: after system powers on, analog-driven produces the vibration that drive signal is kept sensor on the one hand, on the other hand, the initialization of the initialization of each module of system and algorithm, variable is finished in digital signal processor (DSP) inside, opens then and the sample conversion of synchronized AD converter (ADC1) and analog to digital converter (ADC2) two-way AD; After data-switching is good, produce interruption by GPIO; Interrupt service routine is sent to the receiving register of McBSP with the AD transformation result, by direct memory access (DMA) (DMA) module, the data of McBSP receiving register is sent in the interim array in user-defined random-access memory (ram) space; After interim array is deposited and expired, produce DMA and interrupt, in the interrupt service routine, the new data in the interim array is stored in the user-defined external SRAM circulation array, be used for algorithm and transfer data; Whenever producing 500 new point data, promptly begin to call algoritic module data are handled.
3. a kind of little curved Ke's mass flowmeter digital signal processing method as claimed in claim 1 and system is characterized in that: after producing 500 new point data, algorithm is transferred 500 point data from the circulation array, carry out algorithm process; At first be to judge the signal amplitude size, if signal amplitude is very little, showing that sensor does not also open fully shakes, and at this moment should continue to wait for; If signal amplitude is greater than the reference value that sets, showing that sensor has opened shakes, at this moment, earlier two paths of signals is carried out pre-service by the IIR bandpass filter of a passband width, depth-adjustment, eliminate noise, call zero passage detection method then, calculate frequency, the mistiming of two paths of signals based on Lagrange's interpolation; Result of calculation is sorted, get rid of singular value, and, obtain measuring average,, calculate mass rate in conjunction with instrument coefficient through after the running mean; Read temperature value, flow is carried out temperature compensation.
4. a kind of little curved Ke's mass flowmeter digital signal processing method as claimed in claim 1 and system, it is characterized in that: digital signal processor (DSP) is handled is discrete signal after the sampling, can not be zero crossing just, this just need carry out curve fitting to sampled data, obtains signal zero crossing; Adopt Lagrangian quadratic interpolation match; If sample sequence
Figure 2011100461292100001DEST_PATH_IMAGE001
, work as appearance
Figure 2011100461292100001DEST_PATH_IMAGE002
The time, promptly show at [n-1, n] to have a zero point constantly; Generate the quadratic interpolation polynomial expression
Figure 2011100461292100001DEST_PATH_IMAGE003
,
Figure 2011100461292100001DEST_PATH_IMAGE004
Figure 2011100461292100001DEST_PATH_IMAGE005
Can obtain by solving an equation The time moment corresponding t, i.e. zero crossing; To give up that root outside [n-1, n] in the equation in actual applications.
5. a kind of little curved Ke's mass flowmeter digital signal processing method as claimed in claim 1 and system, it is characterized in that: be that situations between [n-1, n] not of two roots that the match quadratic equation obtains all can appear in 3 matches of Lagrange's interpolation or 5 matches of least square method; When this situation occurring, find the solution null position again with approach based on linear interpolation.
6. a kind of little curved Ke's mass flowmeter digital signal processing method as claimed in claim 1 and system is characterized in that: after 500 signal datas find zero point, with regard to the signal calculated parameter; When asking phase differential, need the zero point of two paths of signals, dislocation takes place and subtracts each other in easily; If 500 do not comprise just
Figure 2011100461292100001DEST_PATH_IMAGE008
, will produce
Figure 2011100461292100001DEST_PATH_IMAGE009
Therefore such dislocation, need be judged; Suppose that two paths of signals respectively calculates
Figure 2011100461292100001DEST_PATH_IMAGE010
,
Figure 2011100461292100001DEST_PATH_IMAGE011
Individual zero point is because the phase range of little curved Coriolis mass flowmeter is no more than
Figure 2011100461292100001DEST_PATH_IMAGE012
10 °, so:
(1) if
Figure 2011100461292100001DEST_PATH_IMAGE013
, L road signal lag then is described and dislocation can take place and subtract each other modification method: should be
Figure 2011100461292100001DEST_PATH_IMAGE014
To zero point, the mistiming by
Figure 2011100461292100001DEST_PATH_IMAGE015
Try to achieve;
(2) if
Figure 2011100461292100001DEST_PATH_IMAGE016
, R road signal lag then is described and dislocation can take place and subtract each other modification method: should be
Figure 2011100461292100001DEST_PATH_IMAGE017
To zero point, the mistiming by
Figure 2011100461292100001DEST_PATH_IMAGE018
Try to achieve;
(3) if
Figure 2011100461292100001DEST_PATH_IMAGE019
No matter illustrate to be LStill RDislocation can not take place road signal lag subtracts each other, and has
Figure 2011100461292100001DEST_PATH_IMAGE020
To zero point, the mistiming directly by
Figure 2011100461292100001DEST_PATH_IMAGE021
Try to achieve.
7. a kind of little curved Ke's mass flowmeter digital signal processing method as claimed in claim 1 and system is characterized in that: intermediate variable uses 64 double types of variables when interpolation arithmetic; When the used sampled value of Lagrange's interpolation Very near 0 o'clock, the sampled value that Lagrange's interpolation is used is amplified 100 times earlier, subscript unification is constantly carried out interpolation calculation by (n-2), (n-1), n normalizing to 0,1,2 again, to improve the number of significant digit of result of calculation, guarantees the realization precision of algorithm.
8. a kind of little curved Ke's mass flowmeter digital signal processing method as claimed in claim 1 and system is characterized in that: be the influence that reduces to setover to frequency computation part, use L 1, L 3Ask for signal frequency, the zero point that promptly guarantees to ask for frequency and be employed zero point a signal period is right; When calculating phase differential, with L 1 , R 1 And L 2 , R 2 Be primitive, two groups of zero points that promptly comprise rising edge and negative edge are to calculating phase differential.
9. a kind of little curved Ke's mass flowmeter digital signal processing method as claimed in claim 1 and system, it is characterized in that: after calculating each parameter such as signal frequency, phase differential, fluid flow, digital signal processor (DSP) is gone up measurement result and is shown in LCD on the one hand, on the other hand, digital signal processor (DSP) produces 1s by a CPU timer and interrupts, in interrupt service routine, instantaneous delivery is added up, obtain integrated flow, and, export corresponding electric current and pulse number by 4~20mA output and pulse output module.
10. a kind of little curved Ke's mass flowmeter digital signal processing method as claimed in claim 1 and system, it is characterized in that: instantaneous delivery is converted to the output pulse by the ePWM module, in the 1s that cputimer0 produces interrupts, the flow rate conversion that is accumulated in this 1s is become will export the number of pulse, and stipulate that these pulses output when cputimer0 interruption next time finishes; The flow value out_flow that exports gets the integral part of integrated flow in this 1s, and fraction part left_flow is added to next time and calculates.
CN 201110046129 2011-02-25 2011-02-25 Slightly bent Koch mass flow meter digital signal processing method and system Active CN102128656B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN 201110046129 CN102128656B (en) 2011-02-25 2011-02-25 Slightly bent Koch mass flow meter digital signal processing method and system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN 201110046129 CN102128656B (en) 2011-02-25 2011-02-25 Slightly bent Koch mass flow meter digital signal processing method and system

Publications (2)

Publication Number Publication Date
CN102128656A true CN102128656A (en) 2011-07-20
CN102128656B CN102128656B (en) 2013-09-04

Family

ID=44266833

Family Applications (1)

Application Number Title Priority Date Filing Date
CN 201110046129 Active CN102128656B (en) 2011-02-25 2011-02-25 Slightly bent Koch mass flow meter digital signal processing method and system

Country Status (1)

Country Link
CN (1) CN102128656B (en)

Cited By (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103353320A (en) * 2013-07-03 2013-10-16 太原太航科技有限公司 Coriolis mass flowmeter signal processing method based on frequency mixing algorithm
CN103528634A (en) * 2013-10-23 2014-01-22 山东大学 Coriolis mass flow meter cloud transmission digital signal processing device and method
CN103984228A (en) * 2014-05-31 2014-08-13 福州大学 Method for designing Coriolis mass flow meter digital drive system
CN104236651A (en) * 2014-07-19 2014-12-24 中国人民解放军后勤工程学院 Humanoid intelligent control method for vibration amplitude of Coriolis mass flowmeter
CN104300768A (en) * 2014-11-03 2015-01-21 深圳晶福源科技股份有限公司 Generation method of driving waveform of thyristor rectifier and drive circuit of thyristor rectifier
CN104572076A (en) * 2014-12-12 2015-04-29 烟台智慧云谷云计算有限公司 Soft filter algorithm for analog acquisition and filter system
CN105547709A (en) * 2015-12-10 2016-05-04 中国船舶工业系统工程研究院 Marine diesel engine torsional vibration signal processing method and device
CN105784036A (en) * 2016-04-06 2016-07-20 合肥工业大学 Differential type power amplifying circuit in Coriolis mass flowmeter driving system
CN112511156A (en) * 2020-11-18 2021-03-16 河南卓正电子科技有限公司 Pulse metering and storing method
CN112729441A (en) * 2020-12-21 2021-04-30 唐山学院 High-precision flow measuring method based on pulse type flow sensor
CN113340369A (en) * 2021-04-16 2021-09-03 中国民用航空适航审定中心 Signal processing method and device for turbine fuel mass flowmeter
CN113988144A (en) * 2021-12-27 2022-01-28 中国空气动力研究与发展中心设备设计与测试技术研究所 Coriolis flowmeter natural frequency obtaining method
CN115270893A (en) * 2022-09-26 2022-11-01 中国空气动力研究与发展中心设备设计与测试技术研究所 High-precision Coriolis flowmeter digital signal processing method

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4934196A (en) * 1989-06-02 1990-06-19 Micro Motion, Inc. Coriolis mass flow rate meter having a substantially increased noise immunity
US5555190A (en) * 1995-07-12 1996-09-10 Micro Motion, Inc. Method and apparatus for adaptive line enhancement in Coriolis mass flow meter measurement
US6311136B1 (en) * 1997-11-26 2001-10-30 Invensys Systems, Inc. Digital flowmeter
CN1095538C (en) * 2000-04-30 2002-12-04 合肥工业大学 Ke's mass flowmeter digital signal processing system
CN101393046A (en) * 2008-10-31 2009-03-25 重庆耐德工业股份有限公司 Software processing method of coriolis mass flowmeter suitable for gas medium

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4934196A (en) * 1989-06-02 1990-06-19 Micro Motion, Inc. Coriolis mass flow rate meter having a substantially increased noise immunity
US5555190A (en) * 1995-07-12 1996-09-10 Micro Motion, Inc. Method and apparatus for adaptive line enhancement in Coriolis mass flow meter measurement
US6311136B1 (en) * 1997-11-26 2001-10-30 Invensys Systems, Inc. Digital flowmeter
CN1095538C (en) * 2000-04-30 2002-12-04 合肥工业大学 Ke's mass flowmeter digital signal processing system
CN101393046A (en) * 2008-10-31 2009-03-25 重庆耐德工业股份有限公司 Software processing method of coriolis mass flowmeter suitable for gas medium

Cited By (23)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103353320A (en) * 2013-07-03 2013-10-16 太原太航科技有限公司 Coriolis mass flowmeter signal processing method based on frequency mixing algorithm
CN103528634A (en) * 2013-10-23 2014-01-22 山东大学 Coriolis mass flow meter cloud transmission digital signal processing device and method
CN103528634B (en) * 2013-10-23 2017-11-28 山东大学 A kind of coriolis mass flowmeters cloud transmission digital signal processing device and method
CN103984228A (en) * 2014-05-31 2014-08-13 福州大学 Method for designing Coriolis mass flow meter digital drive system
CN103984228B (en) * 2014-05-31 2017-02-01 福州大学 Method for designing Coriolis mass flow meter digital drive system
CN104236651A (en) * 2014-07-19 2014-12-24 中国人民解放军后勤工程学院 Humanoid intelligent control method for vibration amplitude of Coriolis mass flowmeter
CN104236651B (en) * 2014-07-19 2017-06-16 中国人民解放军后勤工程学院 A kind of apery intelligent control method of Coriolis flowmeter vibration amplitude
CN104300768B (en) * 2014-11-03 2017-05-03 深圳晶福源科技股份有限公司 Generation method of driving waveform of thyristor rectifier and drive circuit of thyristor rectifier
CN104300768A (en) * 2014-11-03 2015-01-21 深圳晶福源科技股份有限公司 Generation method of driving waveform of thyristor rectifier and drive circuit of thyristor rectifier
CN104572076A (en) * 2014-12-12 2015-04-29 烟台智慧云谷云计算有限公司 Soft filter algorithm for analog acquisition and filter system
CN104572076B (en) * 2014-12-12 2018-04-17 烟台智慧云谷云计算有限公司 The soft filtering algorithm and filtering system of a kind of analog acquisition
CN105547709A (en) * 2015-12-10 2016-05-04 中国船舶工业系统工程研究院 Marine diesel engine torsional vibration signal processing method and device
CN105784036B (en) * 2016-04-06 2018-10-02 合肥工业大学 A kind of differential type power amplification circuit in Coriolis mass flowmeter drive system
CN105784036A (en) * 2016-04-06 2016-07-20 合肥工业大学 Differential type power amplifying circuit in Coriolis mass flowmeter driving system
CN112511156A (en) * 2020-11-18 2021-03-16 河南卓正电子科技有限公司 Pulse metering and storing method
CN112511156B (en) * 2020-11-18 2024-03-22 河南卓正电子科技有限公司 Pulse metering and storing method
CN112729441B (en) * 2020-12-21 2022-03-22 唐山学院 High-precision flow measuring method based on pulse type flow sensor
CN112729441A (en) * 2020-12-21 2021-04-30 唐山学院 High-precision flow measuring method based on pulse type flow sensor
CN113340369A (en) * 2021-04-16 2021-09-03 中国民用航空适航审定中心 Signal processing method and device for turbine fuel mass flowmeter
CN113340369B (en) * 2021-04-16 2022-05-03 中国民用航空适航审定中心 Signal processing method and device for turbine fuel mass flowmeter
CN113988144A (en) * 2021-12-27 2022-01-28 中国空气动力研究与发展中心设备设计与测试技术研究所 Coriolis flowmeter natural frequency obtaining method
CN115270893A (en) * 2022-09-26 2022-11-01 中国空气动力研究与发展中心设备设计与测试技术研究所 High-precision Coriolis flowmeter digital signal processing method
CN115270893B (en) * 2022-09-26 2022-12-06 中国空气动力研究与发展中心设备设计与测试技术研究所 High-precision Coriolis flowmeter digital signal processing method

Also Published As

Publication number Publication date
CN102128656B (en) 2013-09-04

Similar Documents

Publication Publication Date Title
CN102128656B (en) Slightly bent Koch mass flow meter digital signal processing method and system
CN102506951B (en) Method and system of digital driving following for Coriolis mass flowmeter
CN101706299B (en) Coriolis mass flow transmitter based on DSP
CN108020282B (en) Coriolis mass flowmeter signal processing method based on complex coefficient filtering
AU2003286596B2 (en) Diagnostic apparatus and methods for a Coriolis flow meter
CA2622976C (en) Meter electronics and methods for verification diagnostics for a flow meter
CN103528634B (en) A kind of coriolis mass flowmeters cloud transmission digital signal processing device and method
JP2930430B2 (en) Method and apparatus for adaptive line enhancement in Coriolis mass flow meter measurements
CN106679741B (en) Processing method and system based on vortex-shedding meter anti-jamming signal
KR100472994B1 (en) Multi-rate digital signal processor and processing method for vibrating conduit sensor signals
CN1163731C (en) Technology for basically eliminating measured error led by temp. in Coriolis table
CN104501890B (en) A kind of control method for the Coriolis mass flow pipe for becoming sensor signal setting value
JPH04505506A (en) Virtually noise-insensitive Coriolis mass flowmeter
CA2623191C (en) Meter electronics and methods for determining one or more of a stiffness coefficient or a mass coefficient
CN203534650U (en) Cloud transmission digital signal processing device with Coriolis mass flow meter
JP2000505895A (en) Method and apparatus for pressure measurement in Coriolis mass flow meters
JPH0778440B2 (en) Coriolis mass flow meter
CN1095538C (en) Ke's mass flowmeter digital signal processing system
CN107167196B (en) A kind of Ke's mass flowmeter digital drive system based on FPGA
CN100385207C (en) Low cost intelligent vortex shedding flowmeter signal processing system based on DSP
CN102538914A (en) Electronic water meter with correction function
CN104748810A (en) Fluid flow accumulating system
Tu et al. Method for CMF signal processing based on the recursive DTFT algorithm with negative frequency contribution
CN106123973B (en) Vortex-shedding meter based on cross-correlation analysis measurement low reynolds number flow
CN100359293C (en) Digital signal resolving device and method for Coriolis mass flowmeter based on harmonious decomposition

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
TR01 Transfer of patent right

Effective date of registration: 20220729

Address after: 230041 No. 32 Hetang Road, industrial park, Luyang District, Hefei City, Anhui Province

Patentee after: ANHUI TIANWEI INSTRUMENT CO.,LTD.

Address before: Tunxi road in Baohe District of Hefei city of Anhui Province, No. 193 230009

Patentee before: Hefei University of Technology

TR01 Transfer of patent right