CN107996021B - Data processing method and base station equipment - Google Patents

Data processing method and base station equipment Download PDF

Info

Publication number
CN107996021B
CN107996021B CN201680038037.0A CN201680038037A CN107996021B CN 107996021 B CN107996021 B CN 107996021B CN 201680038037 A CN201680038037 A CN 201680038037A CN 107996021 B CN107996021 B CN 107996021B
Authority
CN
China
Prior art keywords
data
base station
interval time
station equipment
baud rate
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201680038037.0A
Other languages
Chinese (zh)
Other versions
CN107996021A (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.)
Shenzhen A&E Intelligent Technology Institute Co Ltd
Original Assignee
Shenzhen A&E Intelligent Technology Institute 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 Shenzhen A&E Intelligent Technology Institute Co Ltd filed Critical Shenzhen A&E Intelligent Technology Institute Co Ltd
Publication of CN107996021A publication Critical patent/CN107996021A/en
Application granted granted Critical
Publication of CN107996021B publication Critical patent/CN107996021B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • H04L1/0056Systems characterized by the type of code used
    • H04L1/0061Error detection codes
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/004Arrangements for detecting or preventing errors in the information received by using forward error control
    • H04L1/0056Systems characterized by the type of code used
    • H04L1/0067Rate matching
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L1/00Arrangements for detecting or preventing errors in the information received
    • H04L1/0078Avoidance of errors by organising the transmitted data in a format specifically designed to deal with errors, e.g. location
    • H04L1/0083Formatting with frames or packets; Protocol or part of protocol for error control
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W56/00Synchronisation arrangements

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention discloses a data processing method and base station equipment, wherein the method comprises the following steps: the method comprises the steps that first base station equipment receives first data, and when the first base station equipment analyzes that the first data have transmission errors, the first data are sent by second base station equipment, the value of a counter is added with 1; the first base station equipment judges whether the value of the counter is greater than a preset value; if yes, carrying out baud rate synchronization operation; and if not, receiving second data. The embodiment of the invention aims to solve the problem of robustness of programs in a mobile communication system.

Description

Data processing method and base station equipment
Technical Field
The present invention relates to the field of mobile communications technologies, and in particular, to a data processing method and a base station device.
Background
The baud rate, i.e. the modulation rate, refers to the number of baud in a unit time after the signal is modulated, i.e. the number of times the carrier parameter changes in the unit time.
In asynchronous serial communication, communication can be performed normally only when the baud rates of both parties of communication are identical. Therefore, before communication, both the communication parties need to set respective baud rates. Meanwhile, in the communication process, when one of the two communication parties changes the baud rate, the other of the two communication parties needs to perform baud rate self-adaptive operation, namely baud rate synchronization.
However, in practical applications, when the communication between the two parties is abnormal, the baud rates of the two parties may be different, or the baud rates may be caused by external signal interference. If the two communication parties are not in normal communication, the program enters baud rate self-adaptive operation, and the robustness problem of the program is caused. The robustness of the program means that the program can judge that the input does not meet the specification requirement for the input except the specification requirement, and a reasonable processing mode can be provided.
Disclosure of Invention
The embodiment of the invention provides a data processing method and base station equipment, aiming at solving the problem of robustness of a program in a mobile communication system.
A first aspect of an embodiment of the present invention provides a data processing method, including:
a first base station device receives first data, the first data being transmitted by a second base station device;
when the first base station equipment analyzes that the first data has transmission errors, adding 1 to the value of the counter;
the first base station equipment judges whether the value of the counter is greater than a preset value;
if so, carrying out baud rate synchronous operation by the first base station equipment;
and if not, the second base station equipment receives second data.
Correspondingly, when the value of the counter is greater than the preset value, the baud rate synchronization operation performed by the first base station device includes:
the first base station equipment acquires a first group of data, wherein the first group of data comprises at least one piece of data;
when the first base station equipment detects that a first data segment with high level and low level changes exists in the first group of data, at least one first interval time of each change from a first high/low level to a first low/high level and then from the first low/high level to a second high/low level in the first data segment is recorded;
the first base station equipment determines the first interval time with the shortest time in the at least one first interval time as the shortest first interval time;
the first base station equipment acquires a second group of data, wherein the second group of data comprises at least one piece of data;
when the first base station equipment detects that a second data segment with high level and low level changes exists in the second group of data, at least one second interval time of each change from the first high/low level to the first low/high level and then from the first low/high level to the second high/low level in the second data segment is recorded;
the first base station equipment judges whether a second interval time which is less than twice the shortest first interval time exists in the at least one second interval time;
if so, calculating an average value of second interval time which is less than twice the shortest first interval time in the at least one second interval time, and calculating the baud rate of the second base station equipment according to the average value;
and the first base station equipment carries out baud rate synchronization according to the baud rate of the second base station equipment.
Accordingly, after the first base station device receives the first data, the method further comprises:
and when the first base station equipment analyzes that the first data has no transmission error, changing the value of the counter to a default value, and processing the first data.
Accordingly, the transmission error includes: at least one of a noise error, a parity error, a frame error, and a Cyclic Redundancy Check (CRC) check error.
A second aspect of the embodiments of the present invention provides a base station apparatus, including:
a receiving module, configured to receive first data, where the first data is sent by a second base station device;
the analysis module is used for analyzing whether the first data has transmission errors;
the counting module is used for adding 1 to the value of the counter when the first data has transmission errors;
the judging module is used for judging whether the value of the counter is larger than a preset value or not;
the operation module is used for carrying out baud rate synchronous operation when the value of the counter is greater than a preset value;
the receiving module is further used for receiving second data when the value of the counter is not larger than a preset value.
Accordingly, the operation module comprises:
a first acquisition unit configured to acquire a first set of data, the first set of data including at least one data;
a first detection unit for detecting whether there is a high level and low level change first data segment in the first group of data;
the first recording unit is used for recording at least one first interval time of each change from a first high/low level to a first low/high level and then from the first low/high level to a second high/low level in the first data segment when detecting that the first data segment with high level and low level changes exists in the first group of data;
a first determining unit, configured to determine a first interval time with the shortest time among the at least one first interval time as a shortest first interval time;
the first calculating unit is used for calculating the baud rate of the second base station equipment according to the shortest first interval time;
and the first synchronization unit is used for carrying out baud rate synchronization according to the baud rate of the second base station equipment.
Accordingly, the operation module further comprises:
a second acquiring unit, configured to acquire a second set of data, where the second set of data includes at least one piece of data;
a second detection unit for detecting whether there is a first data segment with a high level and a low level change in the at least one data;
a second recording unit, configured to record at least one second interval time when a second data segment with a high level and a low level changes exists in the at least one data, where the second data segment changes from a first high/low level to a first low/high level and then from the first low/high level to a second high/low level each time;
a second determining unit, configured to determine a second interval time with a shortest time among the at least one second interval time as a shortest second interval time;
the second obtaining unit is further configured to obtain a third set of data, where the third set of data includes at least one data;
the second detection unit is further configured to detect whether a third data segment with a high level and a low level changing exists in the third set of data;
the second recording unit is further used for recording at least one third interval time of each change from the first high/low level to the first low/high level and then from the first low/high level to the second high/low level in the third data segment when the third data segment with high level and low level changes exists in the third group of data;
the judging unit is used for judging whether a third interval time which is less than twice of the shortest second interval time exists in the at least one third interval time;
a calculating unit, configured to calculate, when a third interval time that is less than twice the shortest second interval time is included in the at least one third interval time, an average value of the third interval times that are less than twice the shortest first interval time in the at least one third interval time, and obtain a baud rate of the second base station device through calculation of the average value;
and the synchronization unit is used for carrying out baud rate synchronization according to the baud rate of the second base station equipment.
Correspondingly, the base station device further comprises:
and the zero clearing processing module is used for changing the value of the counter into a default value and processing the first data when the first data has no transmission error.
Accordingly, the transmission error includes: at least one of a noise error, a parity error, a frame error, and a CRC check error.
A third aspect of the embodiments of the present invention provides a base station apparatus, including: a central processing unit, a storage medium and an input/output interface;
the storage medium stores program codes, and the central processing unit is used for calling the program codes to execute any one of the data processing methods.
In the technical solution provided in the embodiment of the present invention, the first base station device analyzes the first data sent by the second base station device to determine whether there is a transmission error, and determines the cause of the transmission error of the first base station device by combining the value of the counter, so compared with the prior art, in the embodiment of the present invention, the problem of robustness of a program in a mobile communication system is solved by analyzing the first data sent by the second base station device and combining the value of the counter.
Drawings
FIG. 1 is a flow chart of one embodiment of a data processing method in an embodiment of the present invention;
FIG. 2 is a flow chart of one embodiment of baud rate synchronization operation in an embodiment of the present invention;
FIG. 3 is a flow chart of another embodiment of baud rate synchronization operation in an embodiment of the present invention;
fig. 4 is a block diagram of an embodiment of a base station apparatus according to the present invention;
fig. 5 is a hardware block diagram of an embodiment of a base station apparatus in the embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The terms "first," "second," "third," and "fourth," if any, in the description and claims of the invention and the above-described figures are used for distinguishing between similar elements and not necessarily for describing a particular sequential or chronological order. It will be appreciated that the data so used may be interchanged under appropriate circumstances such that the embodiments described herein may be practiced otherwise than as specifically illustrated or described herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed, but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
Referring to fig. 1, fig. 1 is a flowchart of an embodiment of a data processing method according to the present invention, the method including:
101. the method comprises the steps that first base station equipment receives first data sent by second base station equipment;
the second base station may be a master base station device, the first base station device may be a slave base station device of the master base station device, and the first data may be one of the master base station device transmitting periodic inquiry frames to the slave base station device. In the normal communication process, the master base station device periodically sends an inquiry frame to each slave base station device to inquire the state of each slave base station device. The slave base station device can calculate the baud rate of the master base station device according to the special data (such as data segments of '010' or '101') in the query frame, so as to set the baud rate of the slave base station device to be consistent with the baud rate of the master base station device, namely baud rate self-adaption, also called baud rate synchronization.
It should be understood that, in terms of baud rate adaptation, the master base station device does not need to additionally add any operation related to baud rate adaptation, and only needs to add a baud rate adaptation function module to the slave base station device to implement baud rate adaptation between the slave base station device and the master base station device. The baud rate adaptive function module may specifically include the following functions:
1) after the system is powered on, the baud rates of the slave base station equipment and the master base station equipment are self-adaptive;
2) when the baud rate of the main base station equipment is changed, the slave base station equipment automatically detects the change of the baud rate of the main base station equipment and automatically synchronizes to the baud rate after the change of the main base station equipment;
3) and when the master base station equipment is replaced (namely the slave base station equipment is replaced to new master base station equipment), the slave base station equipment can carry out self-adaptation according to the baud rate of the new master base station equipment.
The slave base station device may receive the query frame periodically transmitted by the master base station device by using a General Purpose Input/Output (GPIO) of a single chip.
102. The first base station equipment analyzes whether the first data has transmission errors; if yes, go to step 103; if not, go to step 104;
the transmission error may include: at least one of a noise error, a parity error, a frame error, and a Cyclic Redundancy Check (CRC) check error. That is, the transmission error may be one of the foregoing errors, or may be multiple of the foregoing errors, and is not limited herein.
When the slave base station device analyzes whether the query frame has a transmission error, it may analyze whether there are the above errors one by one.
It should be noted that, the method for detecting whether there is a transmission error in the query frame is described in detail in the prior art, and for brevity of writing, the description is omitted here.
For example: the slave base station device may analyze whether the query frame has a noise error, if yes, execute step 103, if no, analyze whether the query frame has a parity error, and so on.
When the slave base station device analyzes the transmission errors one by one, the analysis sequence of the transmission errors is not limited herein.
103. The first base station apparatus adds 1 to the value of the counter;
and when the slave base station equipment analyzes whether each periodic inquiry frame has transmission errors, adding 1 to the value of the counter every time the transmission errors occur.
104. The first base station apparatus changes the value of the counter to a default value and processes the first data.
When the slave base station equipment resolves that the query frame has no transmission error, the slave base station equipment normally processes the first data, which shows that the query frame is not interfered by signals during transmission and the problem that the baud rates of the slave base station equipment and the master base station equipment are inconsistent does not occur.
105. The first base station equipment judges whether the value of the counter is greater than a preset value; if yes, go to step 107, otherwise go to step 106;
the initial value of the counter may be 0 or other values, and the slave base station device, after adding 1 to the value of the counter, correspondingly determines whether the value of the counter exceeds 1, and if so, indicates that the transmission error of the query frame exceeds one time. In the data transmission process, if the periodic query frame has a transmission error for the first time, the transmission error will continue to occur for the next time. It is indicated that the query frame may be caused by the fact that the baud rates of the slave base station device and the master base station device are not consistent, so that the query frame is repeatedly transmitted, because signal interference may cause the query frame to be transmitted incorrectly for the first time, and because signal interference is eliminated or weakened for the second time or more, the query frame is not transmitted incorrectly.
Optionally, if the query frame is interfered by a signal, the slave base station device may also cause the query frame to have more than one repeated transmission error, and then the slave base station device may determine whether the value of the counter is greater than a preset value, that is, the number of times of the transmission errors of the query frame continuously reaches the preset value or more. That is, as long as the number of times that the program does not generate transmission errors does not continuously reach the preset value, the program will not jump to the baud rate synchronization PRE-IDLE state (PRE-IDLE: a self-defined state machine name designed to perform baud rate adaptive operation in this state).
The embodiment of the invention records the times of transmission errors through the counter, jumps into the mode of the PRE-IDLE state machine when the counter reaches a preset value (for example, the value of the counter is 5, or other values), effectively improves the readability and the robustness of the program, solves the problem that the baud rate is different due to signal interference when judging errors through differential processing of different types of exceptions of the serial port, improves the practicability of the program, and can ensure the robustness and the practicability of the program by utilizing a state machine processing mechanism and a special exception processing mechanism.
106. The first base station equipment receives second data sent by the second base station equipment;
if the value of the counter is not greater than the preset value, the slave base station equipment continues to receive the periodic query frame, and then performs analysis of the transmission error, that is, returns to execute step 102, and so on.
107. Carrying out baud rate synchronization operation by the first base station equipment;
in this embodiment, after a plurality of transmission errors occur in the query frame, it is determined that the baud rates of the slave base station device and the master base station device may be inconsistent, and at this time, baud rate synchronization operation of the slave base station device is performed.
In practical applications, the baud rate is usually divided into several steps, which may range from 1200bps to 10Mbps, such as: 1200bps, 2400bps, 4800bps, 9600bps, 14400bps, 19200bps, 38400bps, 56000bps, 57600bps, 115200bps, 230400bps, 460800bps, 921600bps, etc.
When the slave base station equipment performs baud rate synchronous operation, the baud rates at two communication ends are manually set in the prior art, the mode has low efficiency and is troublesome to operate, and particularly when only one baud rate is known but the other baud rate is not known, the slave base station equipment needs to try or use an oscilloscope for measurement for many times.
Of course, in the prior art, the baud rate of the main base station device is detected first, and then baud rate synchronization operation is performed. There are many methods in the prior art for detecting baud rate, including hardware methods and software methods. The hardware method includes a counter-based detection method and a phase-locked loop-based detection method, and the software method includes a table look-up method, a calculation method and the like.
However, although the hardware method has a fast detection speed, it needs to occupy additional hardware resources. Although there are many solutions to the software method, these solutions only solve the problem of adaptation in principle, and are still not enough in the robustness of the program, and the practicability is low.
Referring to fig. 2, fig. 2 is a flowchart of an embodiment of baud rate synchronization operation according to the present invention, including:
201. the method comprises the steps that first base station equipment acquires a first group of data, wherein the first group of data comprises at least one piece of data;
after confirming that the baud rates of the slave base station equipment and the master base station equipment are inconsistent, the slave base station equipment continues to receive periodic query frames through the GPIO and receives a plurality of query frames, so that the accuracy of the slave base station equipment in calculating the baud rate of the master base station equipment is improved.
202. When the first base station equipment detects that a first data segment with high level and low level changes exists in the first group of data, at least one first interval time from the first high/low level to the first low/high level and from the first low/high level to the second high/low level in each time of the first data segment is recorded;
in the process of calculating the baud rate of the master base station equipment, the slave base station equipment needs to acquire a first interval time of changing a 010 data segment from a low level to a high level and then to the low level or a first interval time of changing a 101 data segment from the high level to the low level and then to the high level in an inquiry frame through a timer.
203. The first base station equipment determines the first interval time with the shortest time in all the first interval times as the shortest first interval time;
since there are data segments such as "1001" and "10001" in addition to the data segment of "010" or "101" in the query frame, and the first interval time of the high-low level change of the data segment of "010" or "101" is the shortest, it is necessary to extract the first interval time with the shortest time and determine the first interval time as the shortest first interval time.
In order to ensure that the slave base station device can obtain the first interval time of the high-low level change of the data segment of "010" or "101", the above steps 201 to 203 may be repeated 20 times, continuously collect the first interval time of the high-low level change of the data segment in the query frame, and make the judgment on the shortest first interval time.
204. When the first base station equipment detects that a second data segment with high level and low level changes exists in the second group of data, at least one second interval time of each change from the first high/low level to the first low/high level and then from the first low/high level to the second high/low level in the second data segment is recorded;
after determining the shortest first interval time of the high-low level change of the data segment in the query frame, the slave base station device may further receive a second set of data again, where the second set of data includes at least one data, and may further collect a second interval time of the high-low level change of the data segment in the query frame.
It should be noted that the first base station device may receive at least one piece of data again, or may use at least one piece of data received before, which is not limited herein.
205. The first base station equipment judges whether a second interval time which is less than twice the shortest first interval time exists in all the second interval times; if yes, go to step 206, otherwise go to step 207;
the slave base station apparatus may compare the second interval time of the high-low level change of the data segment in the query frame acquired in step 204 with the shortest first interval time determined in step 203, determine whether the second interval time in step 205 is less than twice the shortest first interval time, if yes, perform step 206, and if not, perform step 207.
206. The first base station equipment calculates the average value of all the second interval time which is less than twice the shortest first interval time, and obtains the baud rate of the second base station equipment through the average value calculation;
the slave base station apparatus calculates the baud rate of the master base station apparatus by averaging all the second interval times smaller than twice the shortest first interval time in step 205.
It should be noted that, after the average value of all the second interval times is calculated, the time required for receiving one bit of character can be obtained by dividing the average value time by the number of bits of the received character in the average value time, and then the baud rate of the main base station device can be obtained by calculating how many bits of character can be received in 1 second.
In order to improve the accuracy of calculating the baud rate of the main base station device, the above steps 204 and 205 may be repeated 40 times, the second interval time of the high-low level change of the data segment in the query frame is continuously collected, and the judgment is performed on the first interval time which is less than twice as short as the first interval time.
207, step 204 is re-executed.
When it is determined that the second interval time in step 205 is not less than twice the shortest first interval time, step 204 is re-executed until it is determined that there is a second interval time in the second interval time that is less than twice the shortest first interval time.
208. And the first base station equipment carries out baud rate synchronization according to the baud rate of the second base station equipment.
After the baud rate of the main base station equipment is calculated, the slave base station equipment can perform baud rate synchronization, so that the baud rates of the slave base station equipment and the main base station equipment are consistent.
After the baud rate is synchronized, the slave base station equipment feeds back the state information of the slave base station equipment to the master base station equipment, and if the master base station equipment receives the reply of the slave base station equipment, the success of communication is indicated. If the baud rate of the main base station equipment is changed in the middle of communication or the slave base station equipment is replaced to new main base station equipment, the communication fails, and the program also enters a PRE-IDLE state.
The embodiment of the invention measures the time for sending a symbol in the periodic query frame sent by the main base station equipment to each slave base station equipment by using the GPIO and the timer, and calculates the baud rate of actual communication by adopting a method of measuring and averaging multiple groups of measured data, thereby achieving the purpose of baud rate self-adaption, improving the usability of products and simplifying the operation. The measurement accuracy of the baud rate is improved by an innovative method of averaging.
Meanwhile, the embodiment of the invention utilizes the inquiry frame of the slave base station equipment which is periodically sent to the slave base station equipment by the main base station equipment, thereby realizing the synchronization without the training sequence.
In addition, the embodiment of the invention can be used for baud rate synchronization in serial communication and can also be applied to other occasions requiring baud rate self-adaptation, and the embodiment of the invention is not limited in the details.
Referring to fig. 3, fig. 3 is a flowchart of another embodiment of baud rate synchronization operation according to the present invention, including:
301. the method comprises the steps that first base station equipment acquires a first group of data, wherein the first group of data comprises at least one piece of data;
302. when the first base station equipment detects that a first data segment with high level and low level changes exists in the first group of data, at least one first interval time from the first high/low level to the first low/high level and from the first low/high level to the second high/low level in each time of the first data segment is recorded;
303. the first base station equipment determines the first interval time with the shortest time in all the first interval times as the shortest first interval time;
it should be noted that steps 301 to 303 are similar to steps 201 to 203 in fig. 2, and detailed description is given above, which is not repeated herein.
304. The first base station equipment calculates the baud rate of the second base station equipment through the shortest first interval time;
in this embodiment, after the first base station device determines the shortest first interval time, the number of bits of the received character in the shortest interval time may be divided by the shortest interval time, so as to obtain the amount of time required for receiving one bit of the character, and then, the number of bits of the received character in 1 second may be calculated, so as to obtain the baud rate of the second base station device.
305. The first base station equipment carries out baud rate synchronization according to the baud rate of the second base station equipment
It should be noted that step 305 is similar to step 307 described in fig. 2, and the above description has been already made in detail, and is not repeated here.
Compared with the prior art, the embodiment of the invention has the following advantages:
1) the installation, the test and the maintenance are convenient: compared with the mode of manually setting the baud rate in the prior art, the baud rate self-adaption technology of the embodiment of the invention effectively reduces manual configuration operation, reduces the possibility of configuration error and improves the efficiency;
2) and the synchronous speed is high: the embodiment of the invention utilizes the query frame sent by the main base station equipment when the main base station equipment normally works, adopts a method of once acquisition, direct judgment and repeated acquisition and averaging, and more simply and efficiently finishes baud rate synchronization work.
3) No extra cost is required to be added: and the related functions are completed in a software control mode under the condition of not using extra hardware.
4) And high program stability: and an effective error processing mechanism is utilized to enable the program to have higher robustness.
With reference to fig. 4, fig. 4 is a block diagram of a base station device according to an embodiment of the present invention, where the base station device includes:
a receiving module 401, configured to receive first data, where the first data is sent by a second base station device;
an analyzing module 402, configured to analyze whether the first data has a transmission error;
a counting module 403, configured to add 1 to the value of the counter when the first data has a transmission error;
a judging module 404, configured to judge whether a value of the counter is greater than a preset value;
an operation module 405, configured to perform baud rate synchronization operation when the value of the counter is greater than a preset value;
the receiving module 401 is further configured to receive second data when the value of the counter is not greater than the preset value.
Optionally, the operation module 405 may specifically include:
a first acquisition unit configured to acquire a first set of data, the first set of data including at least one data;
a first detection unit for detecting whether there is a high level and low level change first data segment in the first group of data;
the first recording unit is used for recording at least one first interval time of each change from a first high/low level to a first low/high level and then from the first low/high level to a second high/low level in the first data segment when detecting that the first data segment with high level and low level changes exists in the first group of data;
a first determining unit, configured to determine a first interval time with the shortest time among the at least one first interval time as a shortest first interval time;
the first calculating unit is used for calculating the baud rate of the second base station equipment according to the shortest first interval time;
and the first synchronization unit is used for carrying out baud rate synchronization according to the baud rate of the second base station equipment.
Optionally, the operation module 405 may further specifically include:
a second acquiring unit, configured to acquire a second set of data, where the second set of data includes at least one piece of data;
a second detection unit for detecting whether there is a first data segment with a high level and a low level change in the at least one data;
a second recording unit, configured to record at least one second interval time when a second data segment with a high level and a low level changes exists in the at least one data, where the second data segment changes from a first high/low level to a first low/high level and then from the first low/high level to a second high/low level each time;
a second determining unit, configured to determine a second interval time with a shortest time among the at least one second interval time as a shortest second interval time;
the second obtaining unit is further configured to obtain a third set of data, where the third set of data includes at least one data;
the second detection unit is further configured to detect whether a third data segment with a high level and a low level changing exists in the third set of data;
the second recording unit is further used for recording at least one third interval time of each change from the first high/low level to the first low/high level and then from the first low/high level to the second high/low level in the third data segment when the third data segment with high level and low level changes exists in the third group of data;
the judging unit is used for judging whether a third interval time which is less than twice of the shortest second interval time exists in the at least one third interval time;
a calculating unit, configured to calculate, when a third interval time that is less than twice the shortest second interval time is included in the at least one third interval time, an average value of the third interval times that are less than twice the shortest first interval time in the at least one third interval time, and obtain a baud rate of the second base station device through calculation of the average value;
and the synchronization unit is used for carrying out baud rate synchronization according to the baud rate of the second base station equipment.
Optionally, the base station device may further include:
and the zero clearing processing module is used for changing the value of the counter into a default value and processing the first data when the first data has no transmission error.
Optionally, the transmission error may include: at least one of a noise error, a parity error, a frame error, and a CRC check error.
Referring to fig. 5, fig. 5 is a schematic structural diagram of a base station device according to an embodiment of the present invention, where the base station device 500 may generate a relatively large difference due to different configurations or performances, and may include one or more Central Processing Units (CPUs) 522 (e.g., one or more processors), one or more storage media 530 for storing applications 542 or data 544 (the storage media may be one or more mass storage devices, or temporary storage devices such as one or more memories, or one or more hard disks, or one or more memories and hard disks used together, which is not limited herein). Storage medium 530 may be, among other things, transient or persistent storage. The program stored on the storage medium 530 may include one or more modules (not shown), each of which may include a series of instruction operations for the server. Still further, the central processor 522 may be configured to communicate with the storage medium 530, and execute a series of instruction operations in the storage medium 530 on the base station apparatus 500.
The base station 500 may further include one or more input/output interfaces 558 (which may be one or more wired or wireless network interfaces, or other input/output interfaces, without limitation) and/or one or more operating systems 541, such as Windows server, Mac OS XTM, unix, linux, freebs dtm, and so on.
The steps performed by the base station apparatus in the above-described embodiment may be based on the structure of the base station apparatus shown in fig. 5.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The above-mentioned embodiments are only used for illustrating the technical solutions of the present invention, and not for limiting the same; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (9)

1. A data processing method, comprising:
a first base station device receives first data, the first data being transmitted by a second base station device;
when the first base station equipment analyzes that the first data has transmission errors, adding 1 to the value of the counter;
the first base station equipment judges whether the value of the counter is greater than a preset value;
if so, carrying out baud rate synchronous operation by the first base station equipment;
if not, the first base station equipment receives second data;
when the value of the counter is greater than a preset value, the baud rate synchronization operation of the first base station device includes:
the first base station equipment acquires a second group of data, wherein the second group of data comprises at least one data;
when the first base station equipment detects that a second data segment with high level and low level changes exists in the second group of data, at least one second interval time from the first high/low level to the first low/high level and from the first low/high level to the second high/low level in each time of the second data segment is recorded;
the first base station device determines the interval time with the shortest time in the at least one second interval time as the shortest second interval time;
the first base station equipment acquires a third group of data, wherein the third group of data comprises at least one data;
when the first base station equipment detects that a third data segment with high level and low level changes exists in the third group of data, at least one third interval time from the first high/low level to the first low/high level and from the first low/high level to the second high/low level in each time of the third data segment is recorded;
the first base station equipment judges whether a third interval time which is less than twice the shortest second interval time exists in the at least one third interval time;
if so, calculating an average value of third interval time which is less than twice the shortest second interval time in the at least one third interval time, and calculating the baud rate of the second base station equipment according to the average value;
and the first base station equipment carries out baud rate synchronization according to the baud rate of the second base station equipment.
2. The method of claim 1, wherein when the value of the counter is greater than a preset value, the baud rate synchronization operation of the first base station device comprises:
the first base station equipment acquires a first group of data, wherein the first group of data comprises at least one piece of data;
when the first base station equipment detects that a first data segment with high level and low level changes exists in the first group of data, at least one first interval time from the first high/low level to the first low/high level and from the first low/high level to the second high/low level in each time of the first data segment is recorded;
the first base station equipment determines the first interval time with the shortest time in the at least one first interval time as the shortest first interval time;
the first base station equipment calculates the baud rate of the second base station equipment according to the shortest first interval time;
and the first base station equipment carries out baud rate synchronization according to the baud rate of the second base station equipment.
3. The method of claim 1, wherein after the first base station device receives the first data, the method further comprises:
and when the first base station equipment analyzes that the first data has no transmission error, changing the value of the counter to a default value, and processing the first data.
4. The method according to any of claims 1 to 3, wherein the transmission error comprises: at least one of a noise error, a parity error, a frame error, and a Cyclic Redundancy Check (CRC) check error.
5. A base station apparatus, which is a first base station apparatus, comprising:
a receiving module, configured to receive first data, where the first data is sent by a second base station device;
the analysis module is used for analyzing whether the first data has transmission errors;
the counting module is used for adding 1 to the value of the counter when the first data has transmission errors;
the judging module is used for judging whether the value of the counter is larger than a preset value or not;
the operation module is used for carrying out baud rate synchronous operation when the value of the counter is greater than the preset value;
the receiving module is further used for receiving second data when the value of the counter is not greater than the preset value;
the operation module comprises:
a second acquiring unit, configured to acquire a second set of data, where the second set of data includes at least one piece of data;
a second detection unit for detecting whether there is a first data segment with a high level and a low level change in the at least one data;
a second recording unit, configured to record at least one second interval time when a second data segment with a high level and a low level changes exists in the at least one data, where the second data segment changes from a first high/low level to a first low/high level and then from the first low/high level to a second high/low level each time;
a second determining unit, configured to determine a second interval time with a shortest time among the at least one second interval time as a shortest second interval time;
the second obtaining unit is further configured to obtain a third set of data, where the third set of data includes at least one data;
the second detection unit is further configured to detect whether a third data segment with a high level and a low level changing exists in the third set of data;
the second recording unit is further used for recording at least one third interval time of each change from the first high/low level to the first low/high level and then from the first low/high level to the second high/low level in the third data segment when the third data segment with high level and low level changes exists in the third group of data;
the judging unit is used for judging whether a third interval time which is less than twice of the shortest second interval time exists in the at least one third interval time;
a calculating unit, configured to calculate, when a third interval time that is less than twice the shortest second interval time is included in the at least one third interval time, an average value of the third interval times that are less than twice the shortest first interval time in the at least one third interval time, and obtain a baud rate of the second base station device through calculation of the average value;
and the synchronization unit is used for carrying out baud rate synchronization according to the baud rate of the second base station equipment.
6. The base station device of claim 5, wherein the operation module comprises:
a first acquisition unit configured to acquire a first set of data, the first set of data including at least one data;
a first detection unit for detecting whether there is a high level and low level change first data segment in the first group of data;
the first recording unit is used for recording at least one first interval time of each change from a first high/low level to a first low/high level and then from the first low/high level to a second high/low level in the first data segment when detecting that the first data segment with high level and low level changes exists in the first group of data;
a first determining unit, configured to determine a first interval time with the shortest time among the at least one first interval time as a shortest first interval time;
the first calculating unit is used for calculating the baud rate of the second base station equipment according to the shortest first interval time;
and the first synchronization unit is used for carrying out baud rate synchronization according to the baud rate of the second base station equipment.
7. The base station apparatus according to claim 5, wherein the base station apparatus further comprises:
and the zero clearing processing module is used for changing the value of the counter into a default value and processing the first data when the first data has no transmission error.
8. The base station device according to any of claims 5 to 7, wherein the transmission error comprises: at least one of a noise error, a parity error, a frame error, and a CRC check error.
9. A base station apparatus, comprising:
a central processing unit, a storage medium and an input/output interface;
program code stored on the storage medium, the central processor being configured to invoke the program code to perform the data processing method of any of claims 1 to 4.
CN201680038037.0A 2016-10-18 2016-10-18 Data processing method and base station equipment Active CN107996021B (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2016/102421 WO2018072091A1 (en) 2016-10-18 2016-10-18 Data processing method and base station device

Publications (2)

Publication Number Publication Date
CN107996021A CN107996021A (en) 2018-05-04
CN107996021B true CN107996021B (en) 2020-11-17

Family

ID=62018254

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201680038037.0A Active CN107996021B (en) 2016-10-18 2016-10-18 Data processing method and base station equipment

Country Status (2)

Country Link
CN (1) CN107996021B (en)
WO (1) WO2018072091A1 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114389911A (en) * 2022-01-13 2022-04-22 上海步科自动化股份有限公司 Parameter setting method, device, terminal and storage medium
CN114584261B (en) * 2022-04-28 2022-08-02 武汉慧联无限科技有限公司 Data processing method, device and storage medium
CN114584276B (en) * 2022-05-05 2022-08-23 合肥芯荣微电子有限公司 UART baud rate self-adaption method and system and SoC chip

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101707500A (en) * 2009-11-23 2010-05-12 北京东方信联科技有限公司 Method, device and trunk equipment for realizing signal synchronization
CN102158617A (en) * 2006-04-13 2011-08-17 华为技术有限公司 Communicating method and device for digital subscriber technique
CN102467477A (en) * 2010-11-12 2012-05-23 施耐德电器工业公司 Baud rate self-adapting Modbus relay and Baud rate self-adapting system and method
CN103618588A (en) * 2013-11-26 2014-03-05 中国科学院嘉兴微电子与系统工程中心 Automatic Baud rate detection method and detection module
CN104199298A (en) * 2014-08-18 2014-12-10 广西师范大学 Controller area network (CAN) bus Baud rate self-adapting method

Family Cites Families (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7711078B2 (en) * 2007-06-01 2010-05-04 Smsc Holdings Sarl Frequency synchronization
US8699444B2 (en) * 2007-12-21 2014-04-15 Apple Inc. Broadcast system interference protection method and apparatus
CN102938744B (en) * 2012-10-08 2015-09-23 中国航天科技集团公司第九研究院第七七一研究所 A kind of implementation method of universal serial transceiver

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102158617A (en) * 2006-04-13 2011-08-17 华为技术有限公司 Communicating method and device for digital subscriber technique
CN101707500A (en) * 2009-11-23 2010-05-12 北京东方信联科技有限公司 Method, device and trunk equipment for realizing signal synchronization
CN102467477A (en) * 2010-11-12 2012-05-23 施耐德电器工业公司 Baud rate self-adapting Modbus relay and Baud rate self-adapting system and method
CN103618588A (en) * 2013-11-26 2014-03-05 中国科学院嘉兴微电子与系统工程中心 Automatic Baud rate detection method and detection module
CN103618588B (en) * 2013-11-26 2016-10-05 中国科学院嘉兴微电子与系统工程中心 A kind of auto-baud-detect method and detection module
CN104199298A (en) * 2014-08-18 2014-12-10 广西师范大学 Controller area network (CAN) bus Baud rate self-adapting method

Also Published As

Publication number Publication date
CN107996021A (en) 2018-05-04
WO2018072091A1 (en) 2018-04-26

Similar Documents

Publication Publication Date Title
EP3635914B1 (en) Anomaly detection in computer networks
US20200106795A1 (en) Anomaly detection in computer networks
CN109669899B (en) Method for adaptively adjusting serial port communication baud rate and serial port device
CN107996021B (en) Data processing method and base station equipment
CN1618192B (en) OFDM demodulation circuit and OFDM reception apparatus using the same
RU2016113845A (en) DEVICE AND METHOD OF ACTIVATION MANAGEMENT NCT SCC, METHOD OF MANAGEMENT AND DEVELOPMENT OF A BASIC STATION
CN104106301B (en) Equipment matching based on the information to be communicated in voice-grade channel
US10396921B2 (en) Multi-lane synchronization method, synchronization apparatus and system, and computer storage medium
CN112653600A (en) Network card performance testing method and device based on USB network card and electronic equipment
CN102904766A (en) Baud rate identification method and device for serial communication and monitoring equipment
CN112069098B (en) Baud rate identification method and device
CN110278008A (en) A kind of power line communication method and device
CN108052094A (en) A kind of extension card identification method, device and frequency converter
JP5238369B2 (en) Data receiving apparatus, data receiving method, and data receiving program
CN103812610A (en) Data communication method, terminal and information safety equipment
JP5250505B2 (en) Mobile communication device test system and test method
CN105159439A (en) User interaction information processing method and apparatus
CN103840914A (en) Data communication method, terminal and information security equipment
US9847809B2 (en) Using multiple correlators to determine signal sent and frequency offset
CN106341107B (en) Pulse-modulated signal calibration method and device
CN101938437B (en) Single antenna interference cancellation (SAIC) capability recognizing method and device
CN104702550A (en) Digital detection and error correction algorithm applied to FSK (Frequency Shift Keying) modulating system
CN104333479A (en) Server power connection relation detecting method and detecting system
CN111490892A (en) Master-slave machine system, equipment terminal and communication verification method thereof
CN110209624B (en) Data transmission method and system of serial bus

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