Encoding and decoding method and encoding and decoding equipment

A coding method and equipment technology, applied in the field of information coding, to achieve the effects of simple implementation, less resources, and short execution time

Active Publication Date: 2013-06-05
北京东方广视科技股份有限公司
5 Cites 4 Cited by

AI-Extracted Technical Summary

Problems solved by technology

[0005] The purpose of the present invention is to provide a fast encoding and decoding method and equipment suitable for a large amount of data transmission and commun...
View more

Abstract

The invention discloses an encoding and decoding method which comprises the steps of carrying out exclusive or operation on information code elements in a code group to obtain a bit sequence monitoring code element, sequencing the information code elements in the code group and the bit sequence monitoring code element together to enable each information code element to have an unique code sequence and the bit sequence monitoring code element to have the final sequenced code sequence, respectively carrying out odd-even check on the information code elements and the bit sequence monitoring code element, carrying out exclusive or operation on the code sequences of the information code elements with the odd-even check results of odd check or even check and the bit sequence monitoring code element to obtain a code sequence monitoring code element, adding the code sequence monitoring code element behind the bit sequence monitoring code element, and transmitting code groups with the code sequence monitoring code elements and the bit sequence monitoring code element.

Application Domain

Error prevention

Technology Topic

Coded elementExclusive or +3

Image

  • Encoding and decoding method and encoding and decoding equipment
  • Encoding and decoding method and encoding and decoding equipment
  • Encoding and decoding method and encoding and decoding equipment

Examples

  • Experimental program(1)

Example Embodiment

[0016] The specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are only used to illustrate and explain the present invention, and not to limit the present invention.
[0017] The code group mentioned in this article can be a set composed of multiple symbols, and can also be called a block code. The code element mentioned in this article can refer to a certain number of data sets. The information symbol mentioned in this article may refer to a symbol that carries valid information (data).
[0018] Before introducing the main points of the present invention in detail, some basic concepts are briefly introduced.
[0019] Generally, a data set of a certain number of bits is called a symbol; a set of certain symbols is called a block code or code group. Each code group contains information symbols that carry effective information and a certain percentage of supervision symbols. Supervision symbols are used to supervise only the information symbols in this code group. The code group is generally represented by the symbol (n, k), where n is the total number of symbols in the code group, also known as the length of the code group (code length), k is the number of information symbols in the code group, nk= r is the number of supervision symbols in the code group, or called the number of supervision symbols, the structure of the code group is as follows figure 1 As shown, figure 1 The first k symbols are information symbols, and r supervision symbols are appended to the back. Where a 0 To a k-1 Is k information symbols, r 0 To r r-1 Is r supervision symbols.
[0020] In a code group, the code element sequence is sorted backward, then a 0 Corresponding to serial number 1, a 1 Corresponds to serial number 2, and so on, r r-1 Corresponding to the sequence number n, the sequence number corresponding to each symbol in the code group is referred to as the code sequence.
[0021] In this application, supervision symbols can be divided into two types: code sequence supervision symbols and bit sequence supervision symbols: code sequence supervision symbols are used to confirm the code sequence corresponding to error information symbols; bit sequence supervision symbols are used to Confirm the bit sequence in the error message symbol. The length of the bit order supervision symbol is equal to the length of the information symbol. For example, in the case of taking one byte as one symbol, the bit sequence supervision code is one byte. The effective bit length of the code sequence supervision symbol is determined according to the code length, such as the total number of symbols in the code group ≤ 2 N (N is the effective number of bits of the code sequence supervision code element); as an agreed condition, the code sequence supervision code element is always the last code element in a code group.
[0022] Reference figure 2 According to an embodiment of the present invention, there is provided an encoding method, which includes:
[0023] Perform an exclusive OR operation on the information symbols in the code group to obtain the bit sequence supervision symbols;
[0024] Sort the information symbols in the code group together with the order supervision symbols, so that each information symbol has a unique code order, and the order supervision symbols have a code order that is the last sorted;
[0025] Parity checks are performed on the information symbols and bit sequence supervision symbols respectively, and the code sequences of the information symbols and bit sequence supervision symbols whose parity check results are one of odd check and even check are performed XOR operation to obtain code sequence supervision symbols; and
[0026] Adding the code sequence supervision symbol to the back of the bit sequence supervision symbol;
[0027] The method may further include transmitting a code group having the code sequence supervision symbol and the bit sequence supervision symbol.
[0028] The sorting can be increasing or decreasing. Those skilled in the art can understand that the value of the code sequence here is not 0.
[0029] This method discloses a method of encoding a code group. Specifically, in the encoding process, it is first necessary to calculate the order supervision symbol, and then calculate the code order supervision symbol.
[0030] Perform the exclusive OR operation on all the information symbols in the code group to obtain the bit sequence supervision symbols, and figure 1 Take the code group as an example, the bit order supervision symbol of the code group=a 0 ^a 1 ^……^a k-1 ("^" stands for XOR operator).
[0031] Calculating the code sequence supervision code element is to perform parity check on the information code and bit sequence supervision code in the code group, and then the check result is an odd check (or even check) code element (including information code and bit The code sequence of the sequence supervision code element) performs an exclusive OR operation, and the result of the operation is the code sequence supervision code element.
[0032] In order to better understand the present invention, the following takes a typical code element length of 8 bits (1 byte) and a code group length of 16 (that is, the code group contains 16 symbols) as an example. According to the concept introduced above, the bit order supervision symbol is equal to the length of the symbol, that is, one byte. Put the bit sequence supervision code element at the position of code sequence 15, and at the same time, according to the definition of the effective digits of the code sequence supervision code element, you can know that the code sequence supervision code element uses 4-bit length, and the code sequence supervision code element is used as a code group The last symbol in. In this example, the code sequence supervision symbol is placed in the 16 position of the code sequence. In this way, a code group of this example can carry up to 14 bytes of information symbols. Suppose there is a group of data as shown in Table 1 that needs to be coded and has the following sorting (code sequence).
[0033] Table 1
[0034]
[0035] Then the information code element is executed XOR operation, there is
[0036] Sequence supervision symbol =
[0037] 0x11^0x54^0x29^0x44^0x87^0x34^0x04^0xc1^0x33^0x0f^0xea^0xf9^0x1b^0x29=0x43
[0038] The bit order supervision symbol is added to the end of the last information symbol (symbol of sequence number 14) (ie, has a code sequence of 15).
[0039] Perform a parity check on the information symbols in Table 1 and the calculated bit sequence supervision symbols, and perform an exclusive OR operation on the code sequence of the symbols whose check result is odd (or even):
[0040] Code sequence supervision symbol = 2^3^6^7^8^11^14^15 = 0x02
[0041] The obtained code order supervision symbol is added after the bit order supervision symbol (i.e., has a code order of 16). The code group after encoding according to the method of the present invention is shown in Table 2
[0042] Table 2
[0043] 0x11
[0044] figure 2 It is an example coding flowchart according to an embodiment of the present invention. At the beginning of encoding, initial values ​​of the symbol sequence supervision BitChk = 0, the initial value of the code symbol sequence supervision ByteChk = 0. Perform an exclusive OR operation on the information symbols in the code group to obtain the bit sequence supervision symbols. The parity check is performed on the information symbol, and the code sequence of the information symbol whose check result is odd check (or even check) is selected for exclusive OR operation. After the bit sequence supervision symbol is stored in the information symbol (that is, added to the last information symbol), perform a parity check on the bit sequence supervision symbol, and select the check result as odd check (or even check) ) Performs an exclusive OR operation on the code sequence of the bit sequence supervision symbol, and finally performs an exclusive OR operation on the result of the code sequence exclusive OR operation of the information symbol and the result of the bit sequence supervision code sequence exclusive OR operation to obtain the code sequence supervision Code element. After the code sequence supervision symbol is stored in the sequence supervision symbol, it is added after the last sequence supervision symbol.
[0045] Correspondingly, according to the embodiment of the present invention, an encoding device for executing the foregoing encoding method is also provided, and the device may include:
[0046] The first exclusive OR operation unit is used to perform an exclusive OR operation on the information symbols in the code group to obtain the bit sequence supervision symbol;
[0047] The sorting unit is used to sort the information symbols in the code group and the order supervision symbols together, so that each information symbol has a unique code order, and the order supervision symbols have the last order Code sequence;
[0048] A parity check unit, configured to perform parity checks on the information symbols and bit sequence supervision symbols respectively;
[0049] The second exclusive OR operation unit is used to perform an exclusive OR operation on the code sequence of the information symbol and the bit sequence supervision symbol whose parity check result is one of odd check and even check, to obtain the code sequence Supervision symbols; and
[0050] The sorting unit is also used to add the code sequence supervision symbol to the back of the bit sequence supervision symbol.
[0051] Preferably, the device further includes a transmitting unit for transmitting the code group having the code sequence supervision symbol and the bit sequence supervision symbol.
[0052] Correspondingly, the present invention also proposes a decoding method. reference image 3 According to an embodiment of the present invention, a decoding method is provided, which includes:
[0053] Receive the above code group;
[0054] Performing an exclusive OR operation on the information symbols and the bit sequence supervision symbols in the code group to obtain bit sequence error indication information;
[0055] Perform parity checks on the information symbols and bit sequence supervision symbols in the code group respectively;
[0056] Perform an exclusive OR operation on the code sequence of the information symbol and the bit sequence supervision symbol whose parity check result is one of the odd check and even check, and then perform the exclusive OR operation with the code sequence supervision symbol to obtain the code Sequence error indication information; and
[0057] Determine whether the code group has an error according to the bit sequence error indication information and the code sequence error indication information.
[0058] Wherein if the bit sequence error indication information and the code sequence error indication information are both zero, it is determined that there is no error in the code group;
[0059] If at least one of the bit sequence error indication information and the code sequence error indication information is not zero, it is determined that an error has occurred in the code group.
[0060] Wherein, in the case that at least one of the bit sequence error indication information and the code sequence error indication information is not zero, the error information symbols in the code group are determined according to the code sequence error indication information, And determining the error bit in the error information symbol according to the bit sequence error indication information.
[0061] Preferably, the method further includes:
[0062] If the value of the bit sequence error indication information is satisfied, only one bit is not zero and 0
[0063] If the value of the bit sequence error indication information is not satisfied, only one bit is not zero and 0
[0064] The decoding process is the reverse process of the encoding process. In the decoding process, the bit sequence error indication information needs to be calculated first, and then the code sequence error indication information is calculated. The bit sequence error information is used to indicate the error bit sequence in the error symbol when the error occurs, and the code sequence error indication information is used to indicate the code sequence of the error symbol in the code group when the error occurs.
[0065] In order to better explain the decoding principle of the present invention, taking the code group shown in Table 2 as an example, according to the above method, it can be known:
[0066] Bit sequence error indication information
[0067] =0x11^0x54^0x29^0x44^0x87^0x34^0x04^0xc1^0x33^0x0f^0xea^0xf9^0x1b^0x29^0x43=0
[0068] Code sequence error indication information=2^3^6^7^8^11^14^15^2=0
[0069] It can be seen from the above result that when there is no transmission error during the transmission of the code group, the bit sequence error indication information and the code sequence error indication information are both 0.
[0070] Since the bit sequence supervision symbol is the result of the exclusive OR operation of all the information symbols, if an error occurs during transmission, the bit sequence error indication information will no longer be 0, which indicates the error bit of the error symbol. Similarly, when an error occurs in a certain symbol, the code sequence error indication information is also not 0, which indicates the code sequence of the error symbol.
[0071] When an error occurs, you can correct the code group. According to the bit sequence error indication information and the code sequence error indication information, the processing rules in Table 3 can be followed:
[0072] table 3
[0073]
[0074] Still taking the code group shown in Table 2 as an example, if an error occurs in the first information code in the code group during transmission, for example, 0x11 becomes 0x10, then after receiving the code group, first obtain the bit sequence error indication information:
[0075] Bit sequence error indication information
[0076] =0x10^0x54^0x29^0x44^0x87^0x34^0x04^0xc1^0x33^0x0f^0xea^0xf9^0x1b^0x29^0x43=0x01
[0077] Then get the code sequence error indication information:
[0078] Code sequence error indication information = 1^2^3^6^7^8^11^14^15^2 = 1 (note that the parity check result of the first information symbol here is odd due to an error)
[0079] It can be seen from the above results that an error occurred during the data transmission process, the bit sequence error indication information got the error bit at the 0th bit of the symbol, and the code sequence error indication information got the error bit at the 1st symbol. In this way, you can locate the location of the error and perform error correction processing. The method used for error correction can be an error correction method commonly used in the art, which is not repeated here.
[0080] If there is an error condition other than Table 3, it means that a multi-bit error has occurred, the error correction cannot be realized, and the entire code group will be discarded.
[0081] image 3 It is an example decoding flowchart according to an embodiment of the present invention. Such as image 3 As shown, the initial values ​​of the bit sequence error indication information and the code sequence error indication information are both 0. Perform an exclusive OR operation on the information symbol and the bit sequence supervision symbol in the received code group to obtain the bit sequence error indication information. Perform parity check on the information symbol, and set the check result as odd check (or even check, where the selection of check result is the same as that selected in encoding, for example, odd check is selected in the encoding process, In the decoding process, the code sequence of the information symbol with odd check is also selected for exclusive OR operation. Perform parity check on the bit sequence supervision symbol, and perform exclusive OR operation on the code sequence of the bit sequence supervision symbol whose check result is odd check (or even check), and XOR the result of the code sequence of the information symbol Perform an exclusive OR operation with the code sequence XOR operation result of the bit sequence supervision code element and then perform an XOR operation with the code sequence supervision code element to obtain code sequence error indication information.
[0082] If the code sequence error indication information and the bit sequence error indication information are both 0, it means that the received data is normal. If the bit sequence error indication information has one bit that is not 0 and 0
[0083] Correspondingly, the present invention also provides a decoding device for executing the foregoing decoding method, and the device may include:
[0084] The receiving unit is used to receive the above code group;
[0085] The first exclusive OR operation unit is used to perform an exclusive OR operation on the information symbol and the bit sequence supervision symbol in the received code group to obtain the bit sequence error indication information;
[0086] The parity check unit is used to perform parity check respectively on the information symbols and the bit sequence supervision symbols in the code group;
[0087] The second exclusive OR operation unit is used to perform an exclusive OR operation on the code sequence of the information symbol and the bit sequence supervision symbol whose parity check result is one of odd check and even check, and then with the code sequence supervision code Perform an exclusive OR operation on the element to obtain the code sequence error indication information; and
[0088] The judging unit is configured to judge whether the code group has an error according to the bit sequence error indication information and the code sequence error indication information.
[0089] Wherein, the judgment unit can be used for:
[0090] In the case where the bit sequence error indication information and the code sequence error indication information are both zero, it is determined that there is no error in the code group; and
[0091] If at least one of the bit sequence error indication information and the code sequence error indication information is not zero, it is determined that an error occurs in the code group.
[0092] Wherein, in the case that at least one of the bit sequence error indication information and the code sequence error indication information is not zero, the determining unit determines the code sequence in the code group according to the code sequence error indication information. Error information symbol, and determining the error bit in the error information symbol according to the bit sequence error indication information.
[0093] The device may also include an error correction unit for:
[0094] When it is satisfied that the value of the bit sequence error indication information has only one bit that is not zero and 0
[0095] In the case that the value of the bit sequence error indication information is not satisfied that only one bit is not zero and 0
[0096] The preferred embodiments of the present invention are described in detail above with reference to the accompanying drawings. However, the present invention is not limited to the specific details in the above-mentioned embodiments. Within the scope of the technical concept of the present invention, many simple modifications can be made to the technical solutions of the present invention. These simple modifications all belong to the protection scope of the present invention.
[0097] In addition, it should be noted that the various specific technical features described in the foregoing specific embodiments can be combined in any suitable manner without contradiction.
[0098] In addition, various different embodiments of the present invention can also be combined arbitrarily, as long as they do not violate the idea of ​​the present invention, they should also be regarded as the content disclosed in the present invention.

PUM

no PUM

Description & Claims & Application Information

We can also present the details of the Description, Claims and Application information to help users get a comprehensive understanding of the technical details of the patent, such as background art, summary of invention, brief description of drawings, description of embodiments, and other original content. On the other hand, users can also determine the specific scope of protection of the technology through the list of claims; as well as understand the changes in the life cycle of the technology with the presentation of the patent timeline. Login to view more.

Similar technology patents

Facial recognition access control equipment with advertising information media function

InactiveCN104464056AImprove targeting and effectivenesssave resources
Owner:BEIJING MASS POWER TECH

Method for saving export bandwidth of backbone network by cache acceleration system

InactiveCN102148759ASave public network egress bandwidth resourcessave resources
Owner:许旭 +1

Test system of MIPI DSI controller

ActiveCN103595862Asave expensive costssave resources
Owner:FUZHOU ROCKCHIP SEMICON

Method, system and single board for realizing net port switching

InactiveCN101052053AReduce the number of signalssave resources
Owner:NEW H3C TECH CO LTD

Classification and recommendation of technical efficacy words

  • save resources
  • Easy to implement

Software test apparatus and test method

Owner:KINGDEE SOFTWARE(CHINA) CO LTD

Granular pesticide fertilizer, and preparation method and application thereof

InactiveCN102775241AReduce stress on the farm environmentsave resources
Owner:SHENZHEN NOPOSION AGROCHEM

Distributed indesx file searching method, searching system and searching server

ActiveCN101071442Asave resourcesImprove coupling
Owner:SHENZHEN SHI JI GUANG SU INFORMATION TECH

Composite admixture for cement or high-performance concrete and preparation method thereof

InactiveCN102180612Asave resourcesgood social benefits
Owner:葫芦岛市辽西混凝土外加剂有限公司

Intelligent video monitoring method and system thereof

InactiveCN101635835AEasy to implementEasy system expansion
Owner:SHENZHEN XINYI TECH CO LTD

Voice call routing by dynamic personal profile

InactiveUS7653191B1less laboreasy to implement
Owner:MICROSOFT TECH LICENSING LLC
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Try Eureka
PatSnap group products