CN108134635A - Measurement control method and device based on multithreading - Google Patents

Measurement control method and device based on multithreading Download PDF

Info

Publication number
CN108134635A
CN108134635A CN201711408398.2A CN201711408398A CN108134635A CN 108134635 A CN108134635 A CN 108134635A CN 201711408398 A CN201711408398 A CN 201711408398A CN 108134635 A CN108134635 A CN 108134635A
Authority
CN
China
Prior art keywords
measurement
thread
data
primitive
upload
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
CN201711408398.2A
Other languages
Chinese (zh)
Other versions
CN108134635B (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.)
China United Network Communications Group Co Ltd
Original Assignee
China United Network Communications Group 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 China United Network Communications Group Co Ltd filed Critical China United Network Communications Group Co Ltd
Priority to CN201711408398.2A priority Critical patent/CN108134635B/en
Publication of CN108134635A publication Critical patent/CN108134635A/en
Application granted granted Critical
Publication of CN108134635B publication Critical patent/CN108134635B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B17/00Monitoring; Testing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/46Multiprogramming arrangements
    • G06F9/48Program initiating; Program switching, e.g. by interrupt
    • G06F9/4806Task transfer initiation or dispatching
    • G06F9/4843Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Electromagnetism (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Memory System Of A Hierarchy Structure (AREA)
  • Medical Treatment And Welfare Office Work (AREA)

Abstract

The embodiment of the present invention provides a kind of measurement control method and device based on multithreading.This method includes:It creates and measures control thread, primitive parsing thread, data buffer storage thread, data upload thread and state control line journey;Thread and state control line journey are uploaded by dispatching control thread, primitive parsing thread, data buffer storage thread, the data of measuring, control concurrently is measured to the test process of at least two measurement items.The embodiment of the present invention is divided into multiple function modules by that will measure control module, it creates and measures control thread, primitive parsing thread, data buffer storage thread, data upload thread and state control line journey, can control concurrently be measured to the test process of at least two measurement items by dispatching each thread, the integrated testability efficiency at least two measurement items is improved, so as to improve the efficiency of the uniformity test of terminal comprehensive tester.

Description

Measurement control method and device based on multithreading
Technical field
The present embodiments relate to field of communication technology more particularly to a kind of measurement control methods and dress based on multithreading It puts.
Background technology
In mobile communication terminal authentication test, RF consistency test is one of most crucial test.Terminal synthesis is surveyed Examination instrument is the core equipment of RF consistency test, not only can also complete RF consistency with the function of analog core net The test of index.
Terminal comprehensive tester completes the test of RF consistency index by Survey Software.Survey Software, which includes measuring, to be calculated Method module and measurement control module, Measurement Algorithm module are operated in Windows systems, realize the survey of preset each RF index Amount method;Measurement control module, which operates in, can realize Digital Signal Processing (Digital Signal Process, abbreviation DSP on dsp chip), control is measured according to the order of Measurement Algorithm module, and complete the upload of measurement data.In order to Cover the test of various RF indexes, many measurement items of Measurement Algorithm module design, if peak power output is tested, EVM Test, channel occupancy bandwidth test, Lin Dao leakages are surveyed than test, transmitter unlatching/shut-in time template test, power control Examination, receiver sensitivity test etc..The beginning of each measurement item is interrupted, switching, exits and test pattern switches (single Measure or repeatedly measure) etc. the control of flows, read in measurement data to caching, measurement data uploaded into terminal to be measured etc. It is required for measuring control module completion.
Measure control module needs to complete multiple test assignments, such as receive in a test process for realizing measurement item It measures primitive message, parsing measurement primitive, caching measurement data, upload measurement data etc., to realize the control tested measurement item System and scheduling.But the measurement control module of terminal comprehensive tester is mostly realized by the way of single thread at present, that is, is needed It could start new test assignment after the completion of a upper test assignment, be completed one by one in multiple test assignments of a upper measurement item Later, the test of new measurement item could be started, the delay of any one test assignment is longer, can all influence integrated testability effect Rate, the efficiency for leading to the uniformity test of terminal comprehensive tester are low.
Invention content
The embodiment of the present invention provides a kind of measurement control method and device based on multithreading, is integrated with solving current terminal The measurement control module of tester is mostly realized by the way of single thread, that is, needs just open after the completion of a upper test assignment Begin new test assignment, after multiple test assignments of a upper measurement item are completed one by one, could start new measurement item Test, the delay of any one test assignment is longer, can all influence integrated testability efficiency, leads to the consistent of terminal comprehensive tester Property test efficiency it is low the problem of.
The one side of the embodiment of the present invention is to provide a kind of measurement control method based on multithreading, including:
It creates and measures control thread, primitive parsing thread, data buffer storage thread, data upload thread and state control line Journey;
Thread and state are uploaded by dispatching control thread, primitive parsing thread, data buffer storage thread, the data of measuring Thread is controlled, control concurrently is measured to the test process of at least two measurement items.
The other side of the embodiment of the present invention is to provide a kind of measuring and controlling based on multithreading, including:
Thread creation module measures control thread, primitive parsing thread, data buffer storage thread, data upload for creating Thread and state control line journey;
Processing module dispatches the measurement control thread, primitive parsing thread, data buffer storage thread, data for passing through Thread and state control line journey are uploaded, control concurrently is measured to the test process of at least two measurement items.
Measurement control method and device provided in an embodiment of the present invention based on multithreading are drawn by that will measure control module It is divided into multiple function modules, creates and measure control thread, primitive parsing thread, data buffer storage thread, data upload thread and shape State controls thread, concurrently can measure control to the test process of at least two measurement items by dispatching each thread, carry The high integrated testability efficiency at least two measurement items, so as to improve the effect of the uniformity test of terminal comprehensive tester Rate.
Description of the drawings
Fig. 1 is the flow chart of the measurement control method based on multithreading that the embodiment of the present invention one provides;
Fig. 2 is the flow chart of the measurement control method provided by Embodiment 2 of the present invention based on multithreading;
Fig. 3 is the flow chart of the measurement control method based on multithreading that the embodiment of the present invention three provides;
Fig. 4 is the flow chart of the measurement control method based on multithreading that the embodiment of the present invention four provides;
Fig. 5 is the structure diagram of the measuring and controlling based on multithreading that the embodiment of the present invention five provides;
Fig. 6 is the structure diagram of the measuring and controlling based on multithreading that the embodiment of the present invention six provides.
Specific embodiment
It is right below in conjunction with the attached drawing in the embodiment of the present invention to make technical scheme of the present invention and advantage clearer Technical scheme of the present invention is clearly and completely described, it is clear that and described embodiment is part of the embodiment of the present invention, Instead of all the embodiments.Based on the embodiments of the present invention, those of ordinary skill in the art are not making creative labor All other embodiments obtained under the premise of dynamic, shall fall within the protection scope of the present invention.
DSP/BIOS is an easy real-time embedded operating system, is mainly directed towards Real-Time Scheduling and synchronous, host/mesh Mark system communicates and the applications such as monitoring in real time, has the various functions of real time operating system, and management and running such as task are appointed Synchronization and communication, memory management, real time clock management, interruption service management, device Drivers management between business etc..Existing Measurement control module in, be real there are currently no on the DSP core of operating system mostly, and with the development of DSP technologies, trip Operate in the real time operating system DSP/BIOS on dsp chip.DSP/BIOS supports multithreading, by using multithreading Technology can improve the efficiency for performing algorithm.
Embodiment one
Fig. 1 is the flow chart of the measurement control method based on multithreading that the embodiment of the present invention one provides.The present invention is implemented Example is mostly realized for the measurement control module of current terminal comprehensive tester by the way of single thread, that is, is needed in upper one survey It could start new test assignment after the completion of trial business, after multiple test assignments of a upper measurement item are completed one by one, It can start the test of new measurement item, the delay of any one test assignment is longer, can all influence integrated testability efficiency, lead to end The problem of holding the efficiency of the uniformity test of comprehensive tester low, provides the measurement control method based on multithreading.Such as Fig. 1 institutes Show, this method is as follows:
Step S101, it creates and measures control thread, primitive parsing thread, data buffer storage thread, data upload thread and shape State controls thread;
In the embodiment of the present invention, control module will be measured and be divided into following function module:Measure control submodule, original Language analyzing sub-module, data buffer storage submodule, data upload submodule and mode control word module.
Wherein, it measures control submodule to be mainly used for completing to measure preparation, primitive analyzing sub-module is mainly used for connecing The primitive message of Measurement Algorithm module transmission is received and parses, to determine subsequent measurement control flow;Data buffer storage submodule master It is used to from default storage region read in the measurement data of measurement item to be measured in buffer zone;Data upload submodule and mainly use In the measurement data of measurement item to be measured is uploaded to terminal to be measured from buffer zone;Measuring state control module is mainly used for recording The state of each measurement item.
During controlling the measurement of any measurement item to be measured, measurement item to be measured is needed successively by primitive parsing Module, data buffer storage submodule, data upload the processing of submodule, wherein, after the completion of previous submodule processing, it will not join again With the processing procedure of follow-up submodule, previous submodule can continue with next measurement item to be measured;Son is parsed in primitive After the completion of any submodule is to the processing of measurement item in module, data buffer storage submodule, data upload submodule, it can all notify to survey Measure the state that status control module changes measurement item.
In order to realize that primitive analyzing sub-module, data buffer storage submodule, data upload submodule parallel to two surveys of instruction Quantifier measures control, distributes a thread for each submodule, per thread is used to complete the place of its corresponding submodule Function is managed, following manner specifically may be used to realize:
It creates and measures control thread, and control thread will be measured and distribute to measurement control submodule;Create primitive parsing line Journey, and primitive parsing thread is distributed into primitive analyzing sub-module;Data buffer storage thread is created, and data buffer storage thread is distributed Give data buffer storage submodule;It creates data and uploads thread, and data upload thread is distributed into data and uploads submodule;Create shape State controls thread, and state control line journey is distributed to mode control word module.
Step S102, thread, primitive is controlled to parse thread, data buffer storage thread, data by scheduling measurement and uploads thread With state control line journey, control concurrently is measured to the test process of at least two measurement items.
In the present embodiment, during controlling the measurement of any measurement item to be measured, measurement item to be measured needs successively to pass through The processing that primitive analyzing sub-module, data buffer storage submodule, data upload submodule is crossed, wherein, previous submodule processing is completed Afterwards, the processing procedure of follow-up submodule will not be participated in again, previous submodule can continue with next measurement item to be measured, Therefore, control thread is measured after the processing for completing a measurement item, which is continued with by data buffer storage thread, this Shi Yuanyu parsing threads can continue with next measurement item;After data buffer storage thread completes the processing to the measurement item, Thread is uploaded by data and continues with the measurement item, and data buffer storage thread can continue with primitive parsing thread and locate at this time The next measurement item managed;After data, which upload thread, completes the processing to the measurement item, all measurement items are completed Processing, data upload thread can continue with the processed next measurement item of data buffer storage thread;It can realize Control by each thread parallel is measured to the test process of at least two measurement items.
The embodiment of the present invention is divided into multiple function modules by that will measure control module, creates and measures control thread, original Language parsing thread, data buffer storage thread, data upload thread and state control line journey, can be concurrently right by dispatching each thread The test process of at least two measurement items measures control, improves the integrated testability efficiency at least two measurement items, from And improve the efficiency of the uniformity test of terminal comprehensive tester.
Embodiment two
Fig. 2 is the flow chart of the measurement control method provided by Embodiment 2 of the present invention based on multithreading.In above-mentioned implementation On the basis of example one, in the present embodiment, thread, primitive is controlled to parse thread, data buffer storage thread, data by scheduling measurement Thread and state control line journey are uploaded, control concurrently is measured to the test process of at least two measurement items, including:Pass through Scheduling measurement control thread receives the measurement preparation message that Measurement Algorithm module is sent, and preparing message according to measurement completes to measure standard Standby work sends measurement to Measurement Algorithm module and is ready to complete message, so that Measurement Algorithm module is ready to complete according to measurement and disappears The measurement primitive message that at least two measurement items are sent to primitive parsing thread is ceased, to start the test at least two measurement items Process;It wherein measures primitive message and includes at least measurement item primitive message;Thread, data buffer storage line are parsed by dispatcher primitive Journey, data upload thread, state control line journey, according to the measurement primitive message of at least two measurement items, concurrently at least two The test process of a measurement item measures control.As shown in Fig. 2, this method is as follows:
Step S201, thread is controlled to receive the measurement preparation message that Measurement Algorithm module is sent by scheduling measurement, according to It measures and prepares message completion measurement preparation, measured to the transmission of Measurement Algorithm module and be ready to complete message, so that Measurement Algorithm Module is according to the measurement primitive message for being ready to complete message to primitive parsing thread at least two measurement items of transmission is measured, to start To the test process of at least two measurement items.
In this implementation, before measuring control module and not having started measurement control, measure control thread and receive survey in real time The measurement that quantity algorithm module is sent prepares message, measures control thread upon receipt, completes before carrying out uniformity test Preparation is measured, for example, initialization is locally located, empties hardware flags position etc..It measures control thread and completes test preparation It after work, sends measurement to Measurement Algorithm module and is ready to complete message, represent that measure control module prepares to carry out test, to lead to Know that Measurement Algorithm module can parse the measurement primitive message that thread sends at least two measurement items to primitive, to start at least The test process of two measurement items.
Wherein, it measures primitive message and includes at least measurement item primitive message.Measurement item primitive message is identified including measurement item, Measurement item primitive message starts for representing that Measurement Algorithm module request measures control module to the corresponding survey of measurement item mark Quantifier measures control process.The present embodiment measures control to the measurement item primitive message that Measurement Algorithm module is sent Process is described in detail.
Optionally, it measures control thread and receives the measurement preparation message that Measurement Algorithm module is sent, prepare to disappear according to measuring Breath is completed after measuring preparation, measures the state that control thread can also notify that state control line journey will measure control module Ready state is updated to, represents that measuring control module has completed to measure preparation.
Optionally, the message write-in shared drive region that control thread can will update ready state, state control are measured Thread can periodically read the message of the update ready state in shared drive region, and read update ready state Message when, the state for measuring control module is updated to ready state.
It completes to measure preparation and may be used to appoint in the prior art according to preparation message is measured in addition, measuring control thread Anticipate it is a kind of measure control module according to Measurement Algorithm module sends measurement prepare message complete measurement preparation method come It realizes, details are not described herein again for the present embodiment.
Step S202, the measurement primitive message of thread reception Measurement Algorithm module transmission is parsed by dispatcher primitive;Successively Primitive message will each be measured as target measurement primitive message, if target measurement primitive message is measurement item primitive message, Thread is parsed by dispatcher primitive and measurement item mark and measurement data parameter are parsed according to target measurement primitive message, and to number Caching notice is issued according to caching thread.
Wherein, caching notice includes measurement item mark and measurement data parameter, and measurement data parameter includes storage location, surveys Measure the information such as size of data.
In the present embodiment, measurement item corresponding with target measurement primitive message is denoted as first object measurement item.This implementation In example, primitive parses thread after the measurement primitive message of measurement item of Measurement Algorithm module transmission is received, and can identify Going out to measure primitive message is measurement item primitive message or measures exit message, and how primitive parsing thread identifies measurement item original Language message and measurement exit message may be used measurement control module in the prior art and identify measurement item primitive message and measurement The method of exit message realizes that details are not described herein again the present embodiment.
Optionally, primitive parses thread and caches notice to data buffer storage thread issues, specifically may be used following any one Kind mode is realized:
(1) primitive parsing thread, which will cache, notifies in write-in shared drive region, and data buffer storage thread is periodically shared from this Caching notice is obtained in region of memory;(2) primitive parsing thread notice state control line journey updates the state of target measurement item For can buffer status, data buffer storage thread can regularly obtain the state of each measurement item, however, it is determined that target measurement item, which is in, to be delayed Deposit state, then it is assumed that the caching got corresponding to the target measurement item notifies.
Optionally, primitive parsing thread parses measurement item mark and measurement data parameter according to target measurement primitive message Later, it further includes:
The state that measurement item is identified corresponding measurement item by primitive parsing thread notice state control line journey is updated to test In, so that technical staff inquires the test mode of each test item.
Step S203, the caching notice issued by the way that data buffer storage thread is dispatched to obtain to it;It will each cache successively logical Know and notified as target cache, the measurement item in being notified according to target cache by dispatching data buffer storage thread identifies and measure number According to parameter, the measurement item during target cache is notified identifies measurement data corresponding with measurement data parameter and is cached to buffer area Domain, and thread issues upload notifications are uploaded to data, upload notifications include the measurement item mark in target cache notice.
In the present embodiment, data buffer storage thread obtains realization method and the above-mentioned steps S202 that the caching issued to it notifies The realization method that middle primitive parses thread to data buffer storage thread issues caching notice is corresponding.
In the present embodiment, corresponding measurement item will be notified to be denoted as the second target measurement item with target cache, that is to say second Target measurement item identifies corresponding measurement item for the measurement item in target cache notice, to carry out area with first object measurement item Point.
In the step, after data buffer storage thread obtains each caching notice issued to it, according to each caching notice publication Time will each cache notice and be notified as target cache successively, measurement item mark and measurement in being notified according to target cache The measurement data of second target measurement item is cached to buffer zone, and complete to the second target measurement item by data parameters After the caching of measurement data, thread issues upload notifications are uploaded to data, so that data upload thread by the second mesh of caching The measurement data of mapping quantifier uploads to terminal to be measured.
Preferably, when the measurement data of the second target measurement item is cached to buffer zone by data buffer storage thread, with data Frame is unit, every time by a data frame buffer memory in the measurement data of the second target measurement item to buffer zone, when data are delayed After the upload for depositing first data frame that thread completes the second target measurement item, thread issues upload notifications are uploaded to data, with Data is enable to upload thread, the data frame of the measurement data of the second buffered target measurement item is uploaded into terminal to be measured, So as to realize the parallel progress of data buffer storage and data upload, the efficiency of data buffer storage and data upload can be improved.
Optionally, data buffer storage thread uploads thread issues upload notifications to data, specifically may be used following any one Kind mode is realized:
(1) for data buffer storage thread by upload notifications write-in shared drive region, it is periodically shared from this that data upload thread Upload notifications are obtained in region of memory;(2) data buffer storage thread notice state control line journey updates the state of target measurement item For that can upload state, data, which upload thread, can regularly obtain the state of each measurement item, however, it is determined that target measurement item be in can on Biography state, then it is assumed that got the upload notifications corresponding to the target measurement item.
Step S204, the upload notifications for uploading thread by dispatching data and obtaining data buffer storage thread issues;It successively will be every A upload notifications upload measurement item mark of the thread in target upload notifications as target upload notifications by dispatching data Know, the measurement item in target upload notifications is identified measurement data of the corresponding measurement item in buffer zone uploads to end to be measured End.
In the step, data upload the realization method of the upload notifications of thread acquisition data buffer storage thread issues and above-mentioned step The realization method of data buffer storage thread to data upload thread issues upload notifications is corresponding in rapid S203.
In the present embodiment, measurement item corresponding with target upload notifications is denoted as third target measurement item, that is to say third Target measurement item is that the measurement item in target upload notifications identifies corresponding measurement item, with first object measurement item and the second mesh Mapping quantifier distinguishes.
Optionally, in the present embodiment, data upload thread as unit of data frame, every time by the measurement number of target measurement item Buffered data frame uploads to terminal to be measured in.
Optionally, data upload measurement item mark of the thread in target upload notifications, by third target measurement item Measurement data in buffer zone is uploaded to after terminal to be measured, and data upload thread notice state control line journey by third mesh The state of mapping quantifier is updated to test and completes, so that technical staff inquires the test mode of each test item.
Step S205, message is measured to the transmission of Measurement Algorithm module by dispatching data upload thread, be measured Message includes the measurement item mark in target upload notifications.
Optionally, data upload thread after the transmission of Measurement Algorithm module is measured message, and data upload thread and lead to Know that the state of third target measurement item is updated to test and completed by state control line journey.
Above-mentioned steps S202-S204 is to parse thread, data buffer storage thread, data by dispatcher primitive to upload thread, shape State controls thread, according to the measurement primitive message of at least two measurement items, concurrently to the test process of at least two measurement items Measure the process of control.
It should be noted that in above-mentioned steps S202-S204, primitive parsing thread, data buffer storage thread, data upload line Journey can handle different test items in synchronization, and above-mentioned steps S203-S204 can be carried out, be that is to say and pass through scheduling parallel Primitive parsing thread, data buffer storage thread, data upload thread, state control line journey, can concurrently measure at least two The test process of item measures control.For same target measurement item, the processing procedure of the target measurement item is needed It is performed according to the sequencing of S202, S203, S204.
The embodiment of the present invention parses thread after a test item has been handled by primitive, without waiting for the test item Data buffer storage and upload complete, can the next test item of horse back start to process;Data buffer storage thread to a test item at After having managed, completed without waiting for uploading the data of the test item, can the next test item of horse back start to process, realize Thread, data buffer storage thread, data are parsed by dispatcher primitive and upload thread, state control line journey, concurrently at least two The test process of a measurement item measures control, the integrated testability efficiency at least two measurement items is improved, so as to improve The efficiency of the uniformity test of terminal comprehensive tester.
Embodiment three
Fig. 3 is the flow chart of the measurement control method based on multithreading that the embodiment of the present invention three provides.In above-mentioned implementation On the basis of example two, in the present embodiment, if taken multiple measurements to test item, thread is uploaded according to mesh by dispatching data The measurement item mark in upload notifications is marked, the measurement item in target upload notifications is identified into corresponding measurement item in buffer zone Measurement data upload to after terminal to be measured, further include:Thread record is uploaded in target upload notifications by dispatching data Measurement item identify corresponding measurement item measurement data upload process completion number;If completing number is less than predetermined threshold value, Thread then is uploaded to data buffer storage thread issues caching notice by dispatching data, and caching notice is included in target upload notifications Measurement item identifies and measurement data parameter;If completing number is more than or equal to predetermined threshold value, line is uploaded by dispatching data Journey is measured message to the transmission of Measurement Algorithm module, is measured the measurement item that message is included in target upload notifications and identifies. As shown in figure 3, this method is as follows:
Step S301, thread is controlled to receive the measurement preparation message that Measurement Algorithm module is sent by scheduling measurement, according to It measures and prepares message completion measurement preparation, measured to the transmission of Measurement Algorithm module and be ready to complete message, so that Measurement Algorithm Module is according to the measurement primitive message for being ready to complete message to primitive parsing thread at least two measurement items of transmission is measured, to start To the test process of at least two measurement items.
Step S302, the measurement primitive message of thread reception Measurement Algorithm module transmission is parsed by dispatcher primitive;Successively Primitive message will each be measured as target measurement primitive message, if target measurement primitive message is measurement item primitive message, Thread is parsed by dispatcher primitive and measurement item mark and measurement data parameter are parsed according to target measurement primitive message, and to number Caching notice is issued according to caching thread.
Step S303, the caching notice issued by the way that data buffer storage thread is dispatched to obtain to it;It will each cache successively logical Know and notified as target cache, the measurement item in being notified according to target cache by dispatching data buffer storage thread identifies and measure number According to parameter, the measurement item during target cache is notified identifies measurement data corresponding with measurement data parameter and is cached to buffer area Domain, and thread issues upload notifications are uploaded to data, upload notifications include the measurement item mark in target cache notice.
Step S304, the upload notifications for uploading thread by dispatching data and obtaining data buffer storage thread issues;It successively will be every A upload notifications upload measurement item mark of the thread in target upload notifications as target upload notifications by dispatching data Know, the measurement item in target upload notifications is identified measurement data of the corresponding measurement item in buffer zone uploads to end to be measured End.
Above-mentioned steps S301-S304 is identical with the realization method of the step S201-S204 in embodiment two, the present embodiment this Place repeats no more.
In the present embodiment, measurement item corresponding with target upload notifications is denoted as third target measurement item, that is to say third Measurement item in target measurement Xiang Weiyu target upload notifications identifies corresponding measurement item, with first object measurement item and second Target measurement item distinguishes.
Step S305, thread record is uploaded to the corresponding survey of measurement item mark in target upload notifications by dispatching data The completion number of the upload process of quantifier measurement data.
In the present embodiment, due to be taken multiple measurements to third target detection item, it that is to say and measure control module needs It completes to the caching repeatedly recycled of measurement data of third target detection item and the process of upload, thread is uploaded to the in data After the completion of the test data of three target detection items uploads, the completion of the upload process to third target measurement item measurement data is recorded Number.
If step S306, completing number is less than predetermined threshold value, thread is uploaded to data buffer storage thread by dispatching data Publication caching notice, caching notice include measurement item mark and measurement data parameter in target upload notifications.
Wherein, predetermined threshold value identifies the survey of corresponding measurement item for the measurement item in the preset upload notifications to target Try number.
In the step, if being less than predetermined threshold value to the completion number of the upload process of third target measurement item measurement data, Data upload thread and cache notice to data buffer storage thread issues, to run above-mentioned steps again to third target measurement item again The process of S303-S305.
Optionally, data upload thread and cache notice to data buffer storage thread issues, specifically may be used following any one Kind mode is realized:
(1) data upload thread and will cache in notice write-in shared drive region, and data buffer storage thread is periodically shared from this Caching notice is obtained in region of memory;(2) data upload thread notice state control line journey by the state of third target measurement item Be updated to can buffer status, data buffer storage thread can regularly obtain the state of each measurement item, however, it is determined that third target measurement item In can buffer status, then it is assumed that the caching got corresponding to the third target measurement item notifies.
If step S307, completing number is more than or equal to predetermined threshold value, thread is uploaded to measurement by dispatching data Algoritic module transmission is measured message, is measured the measurement item that message is included in target upload notifications and identifies.
In the step, if being more than or equal to the completion number of the upload process of third target measurement item measurement data pre- If threshold value, then illustrate to have completed the test to third target measurement item, data upload thread and send survey to Measurement Algorithm module Amount completes message.
Optionally, data upload thread after the transmission of Measurement Algorithm module is measured message, and data upload thread and lead to Know that the state of third target measurement item is updated to test and completed by state control line journey.
The embodiment of the present invention uploads thread by the measurement data in buffer zone of target measurement item by dispatching data It uploads to after terminal to be measured, records the completion number for the upload process that corresponding measurement item measurement data is identified to measurement item, If complete number be less than predetermined threshold value, by dispatch data upload thread to data buffer storage thread issues cache notify, with after It is continuous that the test process of corresponding measurement item progress next time is identified to measurement item;If completing number is more than or equal to default threshold Value is then measured message by dispatching data upload thread to the transmission of Measurement Algorithm module, more to the progress of same test item During secondary test, it can also realize that parsing thread, data buffer storage thread, data by dispatcher primitive uploads thread, state control line journey, Control concurrently is measured to the test process of at least two measurement items, improves the integrated testability at least two measurement items Efficiency, so as to improve the efficiency of the uniformity test of terminal comprehensive tester.
Example IV
Fig. 4 is the flow chart of the measurement control method based on multithreading that the embodiment of the present invention four provides.In above-mentioned implementation On the basis of example two or three, in the present embodiment, it is former that the measurement primitive message that Measurement Algorithm module is sent includes at least measurement item Language message and measurement exit message;After measuring control thread and completing preparation, as shown in figure 4, being parsed by dispatcher primitive Thread, data buffer storage thread, data upload thread, state control line journey, according to the measurement primitive message of at least two measurement items, Control concurrently is measured to the test process of at least two measurement items, is as follows:
Step S401, the measurement primitive message of thread reception Measurement Algorithm module transmission is parsed by dispatcher primitive;Successively Primitive message will each be measured as target measurement primitive message, if target measurement primitive message leads to measure exit message Cross the mark that dispatcher primitive parsing thread parses measurement item to be retired according to target measurement primitive message.
Wherein, primitive message is measured to include at least measurement item primitive message and measure exit message.Measure primitive message extremely Include measurement item primitive message less and measure two kinds of exit message.Measurement item primitive message is identified including measurement item, and measurement item is former Language message starts the corresponding measurement item progress to measurement item mark for representing that Measurement Algorithm module request measures control module Measure control process.It measures exit message to identify including measurement item, measures exit message for representing Measurement Algorithm module request It measures control module and exits the measurement control process that corresponding measurement item is identified to the measurement item.The present embodiment is to Measurement Algorithm mould The process that the measurement item primitive message that block is sent measures control is described in detail.
In the present embodiment, if measurement primitive message be measurement item primitive message, primitive parsing thread, data buffer storage thread, Above-described embodiment may be used in the process that data upload thread, state control line journey measures control to the measurement primitive message Two or embodiment three in mode realize that details are not described herein again the present embodiment.
Optionally, after primitive parsing thread parses the mark of measurement item to be retired according to target measurement primitive message, Parsing thread by dispatcher primitive notifies state control line journey that the state of measurement item to be retired is updated to test and is interrupted, so as to skill The test mode of each test item of art personnel inquiry.
Step S402, thread is parsed by dispatcher primitive and caches expiry notification to data buffer storage thread issues, caching stops Notice includes the mark of measurement item to be retired.
After primitive parsing thread parses the mark of measurement item to be retired according to target measurement primitive message, primitive solution The caching expiry notification that thread includes the mark of the measurement item to be retired to data buffer storage thread issues is analysed, to notify data buffer storage Thread stops the measurement data of measurement item to be retired being cached to buffer zone.
Optionally, primitive parses thread and caches expiry notification to data buffer storage thread issues, specifically may be used such as lower section Any one in formula is realized:
(1) primitive parsing thread will be cached in expiry notification write-in shared drive region, and data buffer storage thread is periodically from this Caching expiry notification is obtained in shared drive region;(2) primitive parsing thread notifies state control line journey by measurement item to be retired State be updated to caching halted state, data buffer storage thread can regularly obtain the state of each measurement item, however, it is determined that be retired Measurement item is in caching halted state, then it is assumed that has got the caching expiry notification corresponding to the measurement item to be retired.
Step S403, thread is parsed by dispatcher primitive and uploads thread issues upload expiry notification to data, uploaded and stop Notice includes the mark of measurement item to be retired.
After primitive parsing thread parses the mark of measurement item to be retired according to target measurement primitive message, primitive solution The upload expiry notification that thread uploads mark of the thread issues including measurement item to be retired to data is analysed, data to be notified to upload line Journey stops the measurement data of measurement item to be retired uploading to terminal to be measured.
Optionally, primitive parses thread and uploads thread issues upload expiry notification to data, specifically may be used such as lower section Any one in formula is realized:
(1) primitive parsing thread will be uploaded in expiry notification write-in shared drive region, and data buffer storage thread is periodically from this It is obtained in shared drive region and uploads expiry notification;(2) primitive parsing thread notifies state control line journey by measurement item to be retired State be updated to upload halted state, data buffer storage thread can regularly obtain the state of each measurement item, however, it is determined that be retired Measurement item, which is in, uploads halted state, then it is assumed that has got the upload expiry notification corresponding to the measurement item to be retired.
Above-mentioned steps S403 can be performed before step S402, the two steps can also be performed simultaneously, the present embodiment The sequencing of above-mentioned steps S402 and S403 are not specifically limited.
Preferably, primitive parsing thread according to target measurement primitive message parse measurement item to be retired mark it Afterwards, it while primitive parses thread to data buffer storage thread issues caching expiry notification, uploads thread issues upload to data and stops Only notify.
Step S404, the caching expiry notification issued to it is obtained by dispatching data buffer storage thread, and is stopped according to caching The mark of measurement item to be retired in only notifying stops the measurement data of measurement item to be retired being cached to buffer zone, and to It measures control thread and sends out caching interrupt notification.
Specifically, data buffer storage thread can periodically obtain the caching expiry notification issued to it, then according to slow The mark for depositing the measurement item to be retired in expiry notification stops the measurement data of measurement item to be retired being cached to buffer zone, and And caching interrupt notification is sent out to control thread is measured, so as to measure control thread in the caching for receiving the measurement item to be retired After interrupt notification and upload interrupt notification, determine that the test of the measurement item to be retired has logged out.
Optionally, data buffer storage thread sends out caching interrupt notification to control thread is measured, and specifically may be used following A kind of mode of anticipating is realized:
(1) data buffer storage thread will be cached in interrupt notification write-in shared drive region, measure control thread regularly from Caching interrupt notification is obtained in the shared drive region;(2) data buffer storage thread notifies state control line journey by measurement to be retired The state of item is updated to caching interrupt status, and the state of each measurement item can regularly be obtained by measuring control thread, however, it is determined that wait to move back Go out measurement item and be in caching interrupt status, then it is assumed that get the caching interrupt notification corresponding to the measurement item to be retired.
Step S405, the upload expiry notification issued to it is obtained, and stop according to upload by dispatching data upload thread The mark of measurement item to be retired in only notifying stops the measurement data of measurement item to be retired uploading to terminal to be measured, and to It measures control thread and sends out upload interrupt notification.
Specifically, data, which upload thread, can periodically obtain the upload expiry notification issued to it, be stopped according to upload The mark of measurement item to be retired in only notifying stops the measurement data of measurement item to be retired uploading to terminal to be measured, and to survey Amount control thread sends out upload interrupt notification, so that it is open close in the caching for receiving the measurement item to be retired to measure control thread After knowing and uploading interrupt notification, determine that the test of the measurement item to be retired has logged out.
Optionally, data upload thread and send out upload interrupt notification to control thread is measured, and specifically may be used following A kind of mode of anticipating is realized:
(1) data upload thread and will upload in interrupt notification write-in shared drive region, measure control thread regularly from It is obtained in the shared drive region and uploads interrupt notification;(2) data upload thread notice state control line journey by measurement to be retired The state of item is updated to upload interrupt status, and the state of each measurement item can regularly be obtained by measuring control thread, however, it is determined that wait to move back Go out measurement item and be in upload interrupt status, then it is assumed that get the upload interrupt notification corresponding to the measurement item to be retired.
Step S406, it is obtained by scheduling measurement control thread open close into the caching interrupt notification of its publication and upload Know, if getting the caching interrupt notification of same measurement item and uploading interrupt notification, thread is controlled to measurement by scheduling measurement Algoritic module, which is sent, measures exit message, measures open close during exit message includes the caching interrupt notification of same measurement item and uploads Measurement item to be retired mark in knowing.
It should be noted that in the present embodiment, primitive parsing thread, data buffer storage thread, data upload thread same Moment can handle different test items, that is to say that primitive parsing thread, data buffer storage thread, data upload thread, state control Control is measured to thread parallel processed to the test process of at least two measurement items.
An embodiment of the present invention provides the concrete processing procedures to measuring exit message, parse thread by primitive and are handling After a complete test item to be retired, the stopping of data buffer storage and upload without waiting for the test item to be retired can be at once The next test item of start to process;After data buffer storage thread has handled a test item to be retired, treated without this is waited for Exit test item data upload stopping, can the next test item of horse back start to process, realize primitive parsing thread, number According to caching thread, data upload thread, state control line journey concurrently measures the test process of at least two measurement items Control, improves the integrated testability efficiency at least two measurement items, is surveyed so as to improve the consistency of terminal comprehensive tester The efficiency of examination.
Embodiment five
Fig. 5 is the structure diagram of the measuring and controlling based on multithreading that the embodiment of the present invention five provides.The present invention The measuring and controlling based on multithreading that embodiment provides can perform the measurement control method embodiment based on multithreading and carry The process flow of confession, as shown in figure 5, the device 50 includes:501 and processing module 502.
Specifically, thread creation module 501 for create measure control thread, primitive parsing thread, data buffer storage thread, Data upload thread and state control line journey;
Processing module 502 is used to thread, primitive be controlled to parse thread, data buffer storage thread, data by scheduling measurement Thread and state control line journey are passed, control concurrently is measured to the test process of at least two measurement items.
Device provided in an embodiment of the present invention can be specifically used for performing the embodiment of the method that above-described embodiment one is provided, Details are not described herein again for concrete function.
The embodiment of the present invention is divided into multiple function modules by that will measure control module, creates and measures control thread, original Language parsing thread, data buffer storage thread, data upload thread and state control line journey, can be concurrently right by dispatching each thread The test process of at least two measurement items measures control, improves the integrated testability efficiency at least two measurement items, from And improve the efficiency of the uniformity test of terminal comprehensive tester.
Embodiment six
Fig. 6 is the structure diagram of the measuring and controlling based on multithreading that the embodiment of the present invention six provides.Above-mentioned On the basis of embodiment five, in the present embodiment, as shown in fig. 6, processing module 502 includes:Measure control submodule 5021, primitive Analyzing sub-module 5022, data buffer storage submodule 5023, data upload submodule 5024 and mode control word module 5025.
Wherein, control submodule 5021 is measured to be used to thread be controlled to receive what Measurement Algorithm module was sent by scheduling measurement It measures and prepares message, preparing message according to measurement completes to measure preparation, and sending measurement to Measurement Algorithm module is ready to complete Message, so that Measurement Algorithm module is ready to complete survey of the message to primitive parsing thread at least two measurement items of transmission according to measurement Primitive message is measured, to start the test process at least two measurement items;It wherein measures primitive message and includes at least measurement item original Language message.
Primitive analyzing sub-module 5022, data buffer storage submodule 5023, data upload submodule 5024 and mode control word The cooperation of module 5025 is used to parse thread, data buffer storage thread, data upload thread, state control line journey by dispatcher primitive, Control is concurrently measured to the test process of at least two measurement items according to the measurement primitive message of at least two measurement items.
Specifically, primitive analyzing sub-module 5022 is used to parse thread reception Measurement Algorithm module transmission by dispatcher primitive Measurement primitive message;Primitive message will be each measured successively as target measurement primitive message, if target measurement primitive message For measurement item primitive message, then by dispatcher primitive parse thread according to target measurement primitive message parse measurement item mark and Measurement data parameter, and cache and notify to data buffer storage thread issues, caching notice includes measurement item mark and measurement data ginseng Number.
Data buffer storage submodule 5023 is used for the caching notice issued by the way that data buffer storage thread is dispatched to obtain to it;Successively Notice will each be cached to notify as target cache, the measurement item in being notified according to target cache by dispatching data buffer storage thread Mark and measurement data parameter, the measurement item during target cache is notified identify measurement data corresponding with measurement data parameter and delay Buffer zone is stored to, and thread issues upload notifications are uploaded to data, upload notifications include the measurement item in target cache notice Mark.
Data upload submodule 5024 and are used for the upload for uploading thread by dispatching data and obtaining data buffer storage thread issues Notice;Successively using each upload notifications as target upload notifications, thread is uploaded according to target upload notifications by dispatching data In measurement item mark, the measurement item in target upload notifications is identified into the measurement data of corresponding measurement item in buffer zone Upload to terminal to be measured.
Data upload submodule 5024 and are additionally operable to:
Message is measured to the transmission of Measurement Algorithm module by dispatching data upload thread, message is measured and includes mesh Mark the measurement item mark in upload notifications.
Optionally, primitive analyzing sub-module is additionally operable to:Parsing thread by dispatcher primitive notifies state control line journey that will solve The state that the measurement item of precipitation identifies corresponding measurement item is updated in test.
Optionally, data upload submodule and are additionally operable to:Thread notice state control line journey is uploaded by mesh by dispatching data The state that measurement item in mark upload notifications identifies corresponding measurement item is updated to test completion.
Device provided in an embodiment of the present invention can be specifically used for performing the embodiment of the method that upper embodiment two is provided, tool Details are not described herein again for body function.
The embodiment of the present invention parses thread after a test item has been handled by primitive, without waiting for the test item Data buffer storage and upload complete, can the next test item of horse back start to process;Data buffer storage thread to a test item at After having managed, completed without waiting for uploading the data of the test item, can the next test item of horse back start to process, realize Thread, data buffer storage thread, data are parsed by dispatcher primitive and upload thread, state control line journey, concurrently at least two The test process of a measurement item measures control, the integrated testability efficiency at least two measurement items is improved, so as to improve The efficiency of the uniformity test of terminal comprehensive tester.
Embodiment seven
On the basis of above-described embodiment six, in the present embodiment, if taken multiple measurements to test item, data upload son Module is additionally operable to:
Thread record is uploaded to the corresponding measurement item measurement of measurement item mark in target upload notifications by dispatching data The completion number of the upload process of data;If completing number is less than predetermined threshold value, thread is uploaded to data by dispatching data Caching thread publication caching notice, caching notice include measurement item mark and measurement data parameter in target upload notifications;If It completes number and is more than or equal to predetermined threshold value, be then measured by dispatching data upload thread to the transmission of Measurement Algorithm module Message is measured the measurement item that message is included in target upload notifications and identifies.
Device provided in an embodiment of the present invention can be specifically used for performing the embodiment of the method that upper embodiment three is provided, tool Details are not described herein again for body function.
The embodiment of the present invention uploads thread by the measurement data in buffer zone of target measurement item by dispatching data It uploads to after terminal to be measured, records the completion number for the upload process that corresponding measurement item measurement data is identified to measurement item, If complete number be less than predetermined threshold value, by dispatch data upload thread to data buffer storage thread issues cache notify, with after It is continuous that the test process of corresponding measurement item progress next time is identified to measurement item;If completing number is more than or equal to default threshold Value is then measured message by dispatching data upload thread to the transmission of Measurement Algorithm module, more to the progress of same test item During secondary test, it can also realize that parsing thread, data buffer storage thread, data by dispatcher primitive uploads thread, state control line journey, Control concurrently is measured to the test process of at least two measurement items, improves the integrated testability at least two measurement items Efficiency, so as to improve the efficiency of the uniformity test of terminal comprehensive tester.
Embodiment eight
On the basis of above-described embodiment six or embodiment seven, in the present embodiment, the measurement that Measurement Algorithm module is sent is former Language message includes at least measurement item primitive message and measures exit message.
Primitive analyzing sub-module is additionally operable to:The measurement that thread reception Measurement Algorithm module transmission is parsed by dispatcher primitive is former Language message;Primitive message will be each measured successively as target measurement primitive message, if target measurement primitive message is moved back to measure Outbound message then parses the mark of measurement item to be retired by dispatcher primitive parsing thread according to target measurement primitive message.
Primitive analyzing sub-module is additionally operable to:Thread is parsed by dispatcher primitive to stop leading to data buffer storage thread issues caching Know, caching expiry notification includes the mark of measurement item to be retired.
Primitive analyzing sub-module is additionally operable to:It parses thread by dispatcher primitive and uploads thread issues to data and upload and stop leading to Know, upload the mark that expiry notification includes measurement item to be retired.
Data buffer storage submodule is additionally operable to:The caching expiry notification issued to it is obtained by dispatching data buffer storage thread, And the mark of the measurement item to be retired in caching expiry notification, stop the measurement data of measurement item to be retired being cached to slow Region is deposited, and caching interrupt notification is sent out to control thread is measured.
Data upload submodule and are additionally operable to:The upload expiry notification issued to it is obtained by dispatching data upload thread, And according to the mark for uploading the measurement item to be retired in expiry notification, stop uploading to the measurement data of measurement item to be retired and treat Terminal is surveyed, and upload interrupt notification is sent out to control thread is measured.
Control submodule is measured to be additionally operable to:By scheduling measurement control thread obtain to its issue caching interrupt notification and Interrupt notification is uploaded, if getting the caching interrupt notification of same measurement item and uploading interrupt notification, passes through scheduling measurement control Thread processed sends to Measurement Algorithm module and measures exit message, measures the caching interruption that exit message includes shown same measurement item Notice and the measurement item to be retired uploaded in interrupt notification identify.
Optionally, primitive analyzing sub-module is additionally operable to:
Parsing thread by dispatcher primitive notifies state control line journey that the state of measurement item to be retired is updated in test It is disconnected.
Device provided in an embodiment of the present invention can be specifically used for performing the embodiment of the method that upper example IV is provided, tool Details are not described herein again for body function.
An embodiment of the present invention provides the concrete processing procedures to measuring exit message, parse thread by primitive and are handling After a complete test item to be retired, the stopping of data buffer storage and upload without waiting for the test item to be retired can be at once The next test item of start to process;After data buffer storage thread has handled a test item to be retired, treated without this is waited for Exit test item data upload stopping, can the next test item of horse back start to process, realize primitive parsing thread, number According to caching thread, data upload thread, state control line journey concurrently measures the test process of at least two measurement items Control, improves the integrated testability efficiency at least two measurement items, is surveyed so as to improve the consistency of terminal comprehensive tester The efficiency of examination.
In several embodiments provided by the present invention, it should be understood that disclosed device and method can pass through it Its mode is realized.For example, the apparatus embodiments described above are merely exemplary, for example, the division of unit, only A kind of division of logic function, can there is an other dividing mode in actual implementation, for example, multiple units or component can combine or Person is desirably integrated into another system or some features can be ignored or does not perform.Another point, shown or discussed is mutual Between coupling, direct-coupling or communication connection can be INDIRECT COUPLING or communication link by some interfaces, device or unit It connects, can be electrical, machinery or other forms.
The unit illustrated as separating component may or may not be physically separate, be shown as unit Component may or may not be physical unit, you can be located at a place or can also be distributed to multiple networks On unit.Some or all of unit therein can be selected according to the actual needs to realize the purpose of this embodiment scheme.
In addition, each functional unit in each embodiment of the present invention can be integrated in a processing unit, it can also That each unit is individually physically present, can also two or more units integrate in a unit.Above-mentioned integrated list The form that hardware had both may be used in member is realized, can also be realized in the form of hardware adds SFU software functional unit.
The above-mentioned integrated unit realized in the form of SFU software functional unit, can be stored in one and computer-readable deposit In storage media.Above-mentioned SFU software functional unit is stored in a storage medium, is used including some instructions so that a computer It is each that equipment (can be personal computer, server or the network equipment etc.) or processor (processor) perform the present invention The part steps of embodiment method.And aforementioned storage medium includes:USB flash disk, mobile hard disk, read-only memory (Read-Only Memory, ROM), random access memory (Random Access Memory, RAM), magnetic disc or CD etc. are various to deposit Store up the medium of program code.
Those skilled in the art can be understood that, for convenience and simplicity of description, only with above-mentioned each function module Division progress for example, in practical application, can be complete by different function modules by above-mentioned function distribution as needed Into the internal structure of device being divided into different function modules, to complete all or part of function described above.On The specific work process of the device of description is stated, the corresponding process in preceding method embodiment can be referred to, details are not described herein.
Finally it should be noted that:The above embodiments are only used to illustrate the technical solution of the present invention., rather than its limitations;To the greatest extent Pipe is described in detail the present invention with reference to foregoing embodiments, it will be understood by those of ordinary skill in the art that:Its according to Can so modify to the technical solution recorded in foregoing embodiments either to which part or all technical features into Row equivalent replacement;And these modifications or replacement, various embodiments of the present invention technology that it does not separate the essence of the corresponding technical solution The range of scheme.

Claims (16)

1. a kind of measurement control method based on multithreading, which is characterized in that including:
It creates and measures control thread, primitive parsing thread, data buffer storage thread, data upload thread and state control line journey;
Thread and state control are uploaded by dispatching control thread, primitive parsing thread, data buffer storage thread, the data of measuring Thread concurrently measures control to the test process of at least two measurement items.
2. according to the method described in claim 1, it is characterized in that, described control thread, primitive solution by dispatching described measure It analyses thread, data buffer storage thread, data and uploads thread and state control line journey, concurrently to the test of at least two measurement items Journey measures control, including:
Thread is controlled to receive the measurement preparation message that Measurement Algorithm module is sent by dispatching described measure, standard is measured according to described Standby message is completed to measure preparation, and sending measurement to the Measurement Algorithm module is ready to complete message, so that described measure is calculated Method module is ready to complete measurement of the message to primitive parsing thread transmission at least two measurement item according to the measurement Primitive message, to start the test process at least two measurement item;Wherein described measurement primitive message, which includes at least, to be surveyed Quantifier primitive message;
Thread, data buffer storage thread, data upload thread, state control line journey are parsed by dispatching the primitive, according to described The measurement primitive message of at least two measurement items concurrently measures control to the test process of at least two measurement item System.
3. according to the method described in claim 2, it is characterized in that, described by dispatching, the primitive parses thread, data are delayed Deposit thread, data upload thread, state control line journey, according to the measurement primitive message of at least two measurement item, concurrently Control is measured to the test process of at least two measurement item, including:
The measurement primitive message for parsing thread by dispatching the primitive and receiving the Measurement Algorithm module and sending;
Primitive message will be each measured successively as target measurement primitive message, if the target measurement primitive message is measurement item Primitive message, then by dispatch the primitive parse thread according to the target measurement primitive message parse measurement item mark and Measurement data parameter, and cache and notify to the data buffer storage thread issues, the caching notice includes the measurement item mark With measurement data parameter;
The caching notice issued by the way that the data buffer storage thread is dispatched to obtain to it;
Notice will be each cached successively to notify as target cache, be delayed by dispatching the data buffer storage thread according to the target Measurement item mark and the measurement data parameter in notice are deposited, measurement item mark and measurement data during the target cache is notified The corresponding measurement data of parameter is cached to buffer zone, and uploads thread issues upload notifications to the data, and described upload is led to Know the measurement item mark in being notified including the target cache;
The upload notifications for uploading thread by dispatching the data and obtaining the data buffer storage thread issues;
Successively using each upload notifications as target upload notifications, thread is uploaded according in the target by dispatching the data The measurement item mark in notice is passed, the measurement item in the target upload notifications is identified into corresponding measurement item in the buffer area Measurement data in domain uploads to terminal to be measured.
4. according to the method described in claim 3, it is characterized in that, described upload thread according to by dispatching the data Measurement item in the target upload notifications is identified corresponding measurement item described by the measurement item mark in target upload notifications Measurement data in buffer zone is uploaded to after terminal to be measured, is further included:
Message is measured to Measurement Algorithm module transmission by dispatching the data upload thread, described be measured disappears Breath includes the measurement item mark in the target upload notifications.
5. according to the method described in claim 3, it is characterized in that, described upload thread according to by dispatching the data Measurement item in the target upload notifications is identified corresponding measurement item described by the measurement item mark in target upload notifications Measurement data in buffer zone is uploaded to after terminal to be measured, is further included:
Thread record is uploaded to the corresponding measurement item of measurement item mark in the target upload notifications by dispatching the data The completion number of the upload process of measurement data;
If the completion number is less than predetermined threshold value, sent out by dispatching the data upload thread to the data buffer storage thread Cloth caching notice, the caching notice include measurement item mark and measurement data parameter in the target upload notifications;
If the completion number is more than or equal to the predetermined threshold value, thread is uploaded to the survey by dispatching the data The transmission of quantity algorithm module is measured message, and the message that is measured includes the measurement item mark in the target upload notifications Know.
6. method according to claim 4 or 5, which is characterized in that it is described by dispatch the primitive parse thread according to After the target measurement primitive message parses measurement item mark and measurement data parameter, further include:
Notify the state control line journey identifies the measurement item parsed to correspond to by dispatching the primitive parsing thread The state of measurement item be updated in test;
Correspondingly, it is described by dispatch the data upload thread to Measurement Algorithm module transmission be measured message it Afterwards, it further includes:
Notify the state control line journey by the measurement item in the target upload notifications by dispatching the data upload thread The state for identifying corresponding measurement item is updated to test completion.
7. method according to claim 4 or 5, which is characterized in that described to parse thread, data by dispatching the primitive Caching thread, data upload thread, state control line journey, according to the measurement primitive message of at least two measurement item, parallel Ground measures control to the test process of at least two measurement item, further includes:
The measurement primitive message for parsing thread by dispatching the primitive and receiving the Measurement Algorithm module and sending;
Primitive message will be each measured successively as target measurement primitive message, if the target measurement primitive message is moved back to measure Outbound message then parses measurement item to be retired by dispatching the primitive parsing thread according to the target measurement primitive message Mark;
Thread is parsed to data buffer storage thread issues caching expiry notification by dispatching the primitive, and the caching stops logical Know the mark for including the measurement item to be retired;
Thread is parsed to data upload thread issues upload expiry notification by dispatching the primitive, and the upload stops logical Know the mark for including the measurement item to be retired;
The caching expiry notification issued to it is obtained, and according to the caching expiry notification by dispatching the data buffer storage thread In measurement item to be retired mark, stop the measurement data of the measurement item to be retired being cached to buffer zone, and to institute It states measurement control thread and sends out caching interrupt notification;
The upload expiry notification issued to it is obtained, and according to the upload expiry notification by dispatching the data upload thread In measurement item to be retired mark, stop the measurement data of the measurement item to be retired uploading to terminal to be measured, and to institute It states measurement control thread and sends out upload interrupt notification;
The caching interrupt notification issued to it and upload interrupt notification are obtained by dispatching the control thread that measures, if getting The caching interrupt notification of same measurement item and upload interrupt notification, then control thread to the Measurement Algorithm mould by scheduling measurement Block, which is sent, measures exit message, and the exit message that measures includes the caching interrupt notification of shown same measurement item and upload to interrupt Measurement item to be retired mark in notice.
8. the method according to the description of claim 7 is characterized in that described parse thread according to by dispatching the primitive After target measurement primitive message parses the mark of measurement item to be retired, further include:
The state control line journey is notified to update the state of the measurement item to be retired by dispatching the primitive parsing thread It is interrupted for test.
9. a kind of measuring and controlling based on multithreading, which is characterized in that including:
Thread creation module measures control thread, primitive parsing thread, data buffer storage thread, data upload thread for creating With state control line journey;
Processing module dispatches the measurement control thread, primitive parsing thread, data buffer storage thread, data upload for passing through Thread and state control line journey, concurrently measure control to the test process of at least two measurement items.
10. device according to claim 9, which is characterized in that the processing module, including:
Measurement control submodule dispatches the measurement preparation for measuring control thread and receiving Measurement Algorithm module and sending for passing through Message prepares message completion measurement preparation according to described measure, measures and be ready to complete to Measurement Algorithm module transmission Message so that the Measurement Algorithm module according to it is described measurement be ready to complete message to the primitive parsing thread send described in extremely The measurement primitive message of few two measurement items, to start the test process at least two measurement item;Wherein described measurement Primitive message includes at least measurement item primitive message;
The processing module is additionally operable to:Thread, data buffer storage thread, data upload thread, shape are parsed by dispatching the primitive State controls thread, according to the measurement primitive message of at least two measurement item, concurrently at least two measurement item Test process measures control.
11. device according to claim 10, which is characterized in that the processing module further includes:
Primitive analyzing sub-module, for passing through the measurement for dispatching the primitive parsing thread and receiving the Measurement Algorithm module and sending Primitive message;Primitive message will be each measured successively as target measurement primitive message, if the target measurement primitive message is Measurement item primitive message then parses measurement item by dispatching the primitive parsing thread according to the target measurement primitive message Mark and measurement data parameter, and cache and notify to the data buffer storage thread issues, the caching notice includes the measurement Item mark and measurement data parameter;
Data buffer storage submodule, for pass through dispatch the data buffer storage thread obtain to its issue caching notify;Successively will Each caching notice is notified as target cache, by dispatching the data buffer storage thread according in target cache notice Measurement item identifies and measurement data parameter, and the measurement item mark during the target cache is notified is corresponding with measurement data parameter Measurement data is cached to buffer zone, and uploads thread issues upload notifications to the data, and the upload notifications include described Measurement item mark in target cache notice;
Data upload submodule, for passing through the upload for dispatching the data and uploading thread and obtaining the data buffer storage thread issues Notice;Successively using each upload notifications as target upload notifications, thread is uploaded according to the target by dispatching the data Measurement item in the target upload notifications is identified corresponding measurement item in the caching by the measurement item mark in upload notifications Measurement data in region uploads to terminal to be measured.
12. according to the devices described in claim 11, which is characterized in that the data upload submodule and are additionally operable to:
Message is measured to Measurement Algorithm module transmission by dispatching the data upload thread, described be measured disappears Breath includes the measurement item mark in the target upload notifications.
13. according to the devices described in claim 11, which is characterized in that the data upload submodule and are additionally operable to:
Thread record is uploaded to the corresponding measurement item of measurement item mark in the target upload notifications by dispatching the data The completion number of the upload process of measurement data;
If the completion number is less than predetermined threshold value, sent out by dispatching the data upload thread to the data buffer storage thread Cloth caching notice, the caching notice include measurement item mark and measurement data parameter in the target upload notifications;
If the completion number is more than or equal to the predetermined threshold value, thread is uploaded to the survey by dispatching the data The transmission of quantity algorithm module is measured message, and the message that is measured includes the measurement item mark in the target upload notifications Know.
14. device according to claim 12 or 13, which is characterized in that
The primitive analyzing sub-module is additionally operable to:Notify the state control line journey that will solve by dispatching the primitive parsing thread The state that the measurement item being precipitated identifies corresponding measurement item is updated in test;
The data upload submodule and are additionally operable to:Notify the state control line journey by institute by dispatching the data upload thread The state for stating the corresponding measurement item of the mark of the measurement item in target upload notifications is updated to test completion.
15. device according to claim 12 or 13, which is characterized in that
The primitive analyzing sub-module is additionally operable to:The thread reception Measurement Algorithm module transmission is parsed by dispatching the primitive Measurement primitive message;Primitive message will be each measured successively as target measurement primitive message, if the target measurement primitive Message parses thread and is parsed according to the target measurement primitive message by dispatching the primitive and treats to measure exit message, then Exit the mark of measurement item;
The primitive analyzing sub-module is additionally operable to:Delayed by dispatching the primitive parsing thread to the data buffer storage thread issues Expiry notification is deposited, the caching expiry notification includes the mark of the measurement item to be retired;
The primitive analyzing sub-module is additionally operable to:Thread is parsed in data upload thread issues by dispatching the primitive Pass expiry notification, the mark for uploading expiry notification and including the measurement item to be retired;
The data buffer storage submodule is additionally operable to:The caching stopping issued by the way that the data buffer storage thread is dispatched to obtain to it is logical Know, and the mark of the measurement item to be retired in the caching expiry notification, stop the measurement of the measurement item to be retired Data buffer storage sends out caching interrupt notification to buffer zone, and to the control thread that measures;
The data upload submodule and are additionally operable to:The upload obtained by dispatching the data upload thread to its publication stops logical Know, and the mark of the measurement item to be retired in the upload expiry notification, stop the measurement of the measurement item to be retired Data upload to terminal to be measured, and send out upload interrupt notification to the control thread that measures;
The measurement control submodule is additionally operable to:By dispatch it is described measure control thread obtain to its issue caching in it is open close Know and upload interrupt notification, if getting the caching interrupt notification of same measurement item and uploading interrupt notification, surveyed by dispatching Amount control thread is sent to the Measurement Algorithm module measures exit message, and the measurement exit message includes shown same measurement The caching interrupt notification of item and the measurement item to be retired uploaded in interrupt notification identify.
16. device according to claim 15, which is characterized in that the primitive analyzing sub-module is additionally operable to:
The state control line journey is notified to update the state of the measurement item to be retired by dispatching the primitive parsing thread It is interrupted for test.
CN201711408398.2A 2017-12-22 2017-12-22 Measurement control method and device based on multithreading Active CN108134635B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711408398.2A CN108134635B (en) 2017-12-22 2017-12-22 Measurement control method and device based on multithreading

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711408398.2A CN108134635B (en) 2017-12-22 2017-12-22 Measurement control method and device based on multithreading

Publications (2)

Publication Number Publication Date
CN108134635A true CN108134635A (en) 2018-06-08
CN108134635B CN108134635B (en) 2021-02-09

Family

ID=62391653

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711408398.2A Active CN108134635B (en) 2017-12-22 2017-12-22 Measurement control method and device based on multithreading

Country Status (1)

Country Link
CN (1) CN108134635B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112711406A (en) * 2020-12-30 2021-04-27 西安精密机械研究所 LabVIEW-based test flow editing and analyzing and thread interaction method
CN114967599A (en) * 2021-02-23 2022-08-30 长鑫存储技术有限公司 Production equipment control method, device, system, equipment and medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101018162A (en) * 2007-01-15 2007-08-15 华为技术有限公司 Simulated testing system and method of the business processing network element
CN103647685A (en) * 2013-12-18 2014-03-19 中国电子科技集团公司第四十一研究所 Processing method for unloading and receiving test result information
CN105573874A (en) * 2015-12-10 2016-05-11 湖北三江航天红峰控制有限公司 Multi-thread based real-time data transmission bus test method
US20170083420A1 (en) * 2015-02-10 2017-03-23 International Business Machines Corporation Compare point detection in multi-threaded computing environments
CN107197475A (en) * 2016-03-14 2017-09-22 重庆邮电大学 A kind of sensing node identifier resolution method of testing and system based on multithreading

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101018162A (en) * 2007-01-15 2007-08-15 华为技术有限公司 Simulated testing system and method of the business processing network element
CN103647685A (en) * 2013-12-18 2014-03-19 中国电子科技集团公司第四十一研究所 Processing method for unloading and receiving test result information
US20170083420A1 (en) * 2015-02-10 2017-03-23 International Business Machines Corporation Compare point detection in multi-threaded computing environments
CN105573874A (en) * 2015-12-10 2016-05-11 湖北三江航天红峰控制有限公司 Multi-thread based real-time data transmission bus test method
CN107197475A (en) * 2016-03-14 2017-09-22 重庆邮电大学 A kind of sensing node identifier resolution method of testing and system based on multithreading

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112711406A (en) * 2020-12-30 2021-04-27 西安精密机械研究所 LabVIEW-based test flow editing and analyzing and thread interaction method
CN114967599A (en) * 2021-02-23 2022-08-30 长鑫存储技术有限公司 Production equipment control method, device, system, equipment and medium
WO2022179052A1 (en) * 2021-02-23 2022-09-01 长鑫存储技术有限公司 Method and apparatus for controlling production equipment, system, device, and medium

Also Published As

Publication number Publication date
CN108134635B (en) 2021-02-09

Similar Documents

Publication Publication Date Title
CN105281981B (en) The data traffic monitoring method and device of network service
CN108762687B (en) I/O service quality control method, device, equipment and storage medium
WO2015074584A1 (en) Automatic inspection and monitoring method based on time domain slotting control
CN106874187A (en) code coverage collection method and device
CN108134635A (en) Measurement control method and device based on multithreading
CN106453506A (en) Resource unified scheduling test system and method
CN104796880B (en) Client identification module SIM card resource allocation methods, relevant device and system
CA2965177C (en) Throttling solutions into a legacy inventory system during a service disruption
CN108171362A (en) Power supply facilities breakdown repair method, system and terminal device
CN109660421A (en) Method, apparatus, server and the storage medium of flexible scheduling resource
CN109828790A (en) A kind of data processing method and system based on Shen prestige isomery many-core processor
CN106502796A (en) A kind of software development test platform, system and using method
CN110413527A (en) Test macro, test method, electronic equipment and computer readable storage medium
CN112291809A (en) Method for realizing frequency monitoring system
CN109218086A (en) A kind of switching network construction method and system
CN109324959A (en) A kind of method, server and the computer readable storage medium of automatic transfer data
CN110278101A (en) A kind of method for managing resource and equipment
CN109474917A (en) A kind of roadside device RSU and its ' In System Reconfiguration Method
CN104038388B (en) Based on distributed Internet of Things Auto-Test System and method of testing
CN111784185B (en) Timing task scheduling system of distributed power distribution communication network
CN106897124A (en) A kind of multi-tenant request processing method, device and equipment
CN100450255C (en) Method for cross-testing validating reliability in wireless network central monitoring service
JP5169117B2 (en) Data stream analysis system and apparatus, method and program used therefor
CN106707930A (en) Continuous casting ladle conveying-to-platform management system and method
CN110532153A (en) A kind of business level user's operation experience visualization system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant