Data reading and writing method, device, electronic device and storage medium suitable for HARQ
By combining and retransmitting useful data and historical useful data in HARQ technology in 5G communication, the amount of read and write to external memory is reduced, and the problem of reduced data read and write speed and throughput under HARQ technology is solved, thereby achieving more efficient data transmission.
Patent Information
- Application Number
- CN202411884170.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-20
- Publication Date
- 2025-03-11
- Estimated Expiration
- 2044-12-20
AI Technical Summary
In 5G communication, the HARQ technology's data read and write access to memory is large, resulting in reduced speed and throughput.
By obtaining the transmission data sent by the base station and the transmission parameters in the communication protocol, the distribution information of the retransmitted useful data is determined, and combined with the historical useful data, reducing the amount of read and write to external memory.
This method reduces the amount of read and write to external memory and improves the speed and throughput of data transmission.
Smart Images

Figure CN119363302B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a data reading and writing method, device, electronic device and storage medium suitable for HARQ. Background Art
[0002] The development of mobile communication systems from the initial 1G to the now highly-anticipated 5G is inseparable from the continuous research of all workers. At present, 5G technology is constantly developing and has been deeply applied to various aspects of social production and management, becoming an important technology closely related to people's daily work and life.
[0003] The data in communication is divided into broadcast channel, control channel and data channel. Compared with other channels, the data channel carries a larger amount of data and has a greater transmission pressure. Therefore, even if different algorithms are used to compensate for it, decoding failures often occur in the data channel. This phenomenon may be due to the transmission environment or loopholes in the algorithm itself.
[0004] At this time, the protocol introduces a last-ditch data protection measure, namely HARQ (Hybrid Automatic Repeat reQuest, HARQ), also known as hybrid automatic retransmission technology. A simple description is that based on the final decoding result of the data, it is decided to store part of the data with higher credibility, and retransmit the other part of the less reliable data for re-decoding, and then merge them to determine whether the data is correct.
[0005] In case of unsuccessful decoding of a code block, a retransmission occurs. Instead of discarding the Log-Likelihood Ratios (LLRs) of the failed blocks, they are stored in the HARQ memory and combined with subsequent code blocks with different redundancy versions. Due to the considerable size of the LLR bits of a code block, this information is not kept in the internal memory but is brought to the external Dynamic Random Access Memory (DRAM).
[0006] Based on the above description, it can be seen that in 5G HARQ communication, in addition to the original data storage, a large amount of memory is required for HARQ. In addition to occupying area, accessing and reading and writing to the memory will also cause a significant reduction in speed and throughput. Summary of the invention
[0007] The present application provides a data reading and writing method, device, electronic device and storage medium suitable for HARQ, which is used to solve the problem in the prior art that the access and reading and writing volume to the memory is large, which will cause a relatively large reduction in speed and throughput.
[0008] In a first aspect, an embodiment of the present application provides a data reading and writing method applicable to HARQ, including:
[0009] Acquire transmission data sent by the base station, where the transmission data includes retransmission useful data and retransmission redundant data;
[0010] Get the transmission parameters in the communication protocol;
[0011] Determining first distribution information of the retransmitted useful data based on the transmission parameter;
[0012] Reading second distribution information of historical useful data from an external memory based on the transmission parameters;
[0013] Merging the retransmitted useful data and the historical useful data based on the first distribution information and the second distribution information to obtain current useful data;
[0014] Decoding the current useful data to obtain a decoding result;
[0015] When the decoding result is a decoding failure, the historical useful data in the external memory is updated to the current useful data.
[0016] Optionally, the retransmitted useful data includes first retransmitted useful data, retransmitted offset data and second retransmitted useful data, and the data structure of the retransmitted useful data is that the first retransmitted useful data is at the starting position of the transmitted data, the second retransmitted useful data is after the first retransmitted useful data, and the retransmission offset data is the data between the starting position and the second retransmitted useful data;
[0017] The transmission parameters include the maximum code block data volume specified by the transmission protocol, the block data volume llrsBlockSize of the LLR, the soft buffer size Ncb of the current code block, the number of filling bits nfiller, the rate matching redundancy version k0, the data volume cbSize of the CB, and the information bit length k;
[0018] Determining first distribution information of the retransmitted useful data based on the transmission parameter includes:
[0019] Determine the maximum storage required for actual transmission based on Ncb and nfiller;
[0020] Determine a code block size based on the maximum storage amount and the llrsBlockSize;
[0021] When k0 is 0, the amount of the first retransmission useful data is the result of taking the minimum value of cbSize and the maximum code block data amount, dividing by llrsBlockSize and rounding up, the amount of the retransmission offset data is 0, and the amount of the second retransmission useful data is 0;
[0022] In the case where k0 is not equal to 0, the puncturing value of k0 is determined based on k, k0 and nfiller, the intermediate value is determined based on the puncturing value of k0, the maximum code block data amount and the maximum storage amount, the minimum value of cbSize and the intermediate value is divided by llrsBlockSize and rounded up to obtain an intermediate result, if the intermediate result is greater than 1, the data amount of the first retransmitted useful data is determined to be the intermediate result, otherwise the data amount of the first retransmitted useful data is determined to be 1;
[0023] Determine the data amount of the retransmission offset data as the ratio of the puncturing value of k0 to the block data amount of the LLR;
[0024] If the data amount of the retransmission offset data is greater than the data amount of the first retransmission useful data, the sum of the puncturing value of k0 and the maximum code block data amount is calculated, the ratio of the minimum value of the cbSize and the sum value to the block data amount of the LLR is calculated, and the result of rounding up minus the data amount of the first retransmission useful data is the data amount of the second retransmission useful data; otherwise, the data amount of the first retransmission useful data is determined to be the ratio of the cbSize to the block data amount of the LLR, the data amount of the retransmission offset data is 0, and the data amount of the second retransmission useful data is 0;
[0025] The data amounts of the first retransmission useful data, the retransmission offset data, and the second retransmission useful data, and the data structure thereof are determined as the first distribution information.
[0026] Accessing and writing memory will also cause a significant reduction in speed and throughput. The puncturing value of k0 is determined based on k, k0, and nfiller, including:
[0027] Determine whether k is less than k0;
[0028] If so, determine the punching value of k0 as the difference between k0 and nfiller;
[0029] If not, determine the puncturing value of k0 as k0.
[0030] Optionally, determining an intermediate value based on a puncturing value of k0, a maximum code block data amount, and a maximum storage amount includes:
[0031] The sum of the puncturing value of k0 and the maximum code block data amount, and the difference between the sum and the maximum storage amount are calculated to obtain an intermediate value.
[0032] Optionally, the transmission parameter includes the number of retransmissions;
[0033] The second distribution information of reading the historical useful data from the external memory based on the transmission parameter includes:
[0034] When the number of retransmissions is 0, determining that the historical useful data is 0;
[0035] When the number of retransmissions is not 0, the historical useful data is determined to be the most recently stored current useful data.
[0036] In a second aspect, an embodiment of the present application provides a data reading and writing device suitable for HARQ, including:
[0037] A first acquisition module, used to acquire transmission data sent by the base station, wherein the transmission data includes retransmission useful data and retransmission redundant data;
[0038] A second acquisition module is used to acquire transmission parameters in the communication protocol;
[0039] A determination module, configured to determine first distribution information of the retransmitted useful data based on the transmission parameter;
[0040] A reading module, used for reading second distribution information of historical useful data from an external memory based on the transmission parameter;
[0041] a merging module, configured to merge the retransmitted useful data and the historical useful data based on the first distribution information and the second distribution information to obtain current useful data;
[0042] A decoding module, used for decoding the current useful data to obtain a decoding result;
[0043] The writing module is used to update the historical useful data in the external memory to the current useful data when the decoding result is a decoding failure.
[0044] Optionally, the transmission parameter includes the number of retransmissions; and the reading module is specifically used for:
[0045] When the number of retransmissions is 0, determining that the historical useful data is 0;
[0046] When the number of retransmissions is not 0, the historical useful data is determined to be the most recently stored current useful data.
[0047] Optionally, the retransmitted useful data includes first retransmitted useful data, retransmitted offset data and second retransmitted useful data, and the data structure of the retransmitted useful data is that the first retransmitted useful data is at the starting position of the transmitted data, the second retransmitted useful data is after the first retransmitted useful data, and the retransmission offset data is the data between the starting position and the second retransmitted useful data;
[0048] The transmission parameters include the maximum code block data volume specified by the transmission protocol, the block data volume llrsBlockSize of the LLR, the soft buffer size Ncb of the current code block, the number of filling bits nfiller, the rate matching redundancy version k0, the data volume cbSize of the CB, and the information bit length k;
[0049] Determine the module specifically for:
[0050] Determine the maximum storage required for actual transmission based on Ncb and nfiller;
[0051] Determine a code block size based on the maximum storage amount and the llrsBlockSize;
[0052] When k0 is 0, the amount of the first retransmission useful data is the result of taking the minimum value of cbSize and the maximum code block data amount, dividing by llrsBlockSize and rounding up, the amount of the retransmission offset data is 0, and the amount of the second retransmission useful data is 0;
[0053] In the case where k0 is not equal to 0, the puncturing value of k0 is determined based on k, k0 and nfiller, the intermediate value is determined based on the puncturing value of k0, the maximum code block data amount and the maximum storage amount, the minimum value of cbSize and the intermediate value is divided by llrsBlockSize and rounded up to obtain an intermediate result, if the intermediate result is greater than 1, the data amount of the first retransmitted useful data is determined to be the intermediate result, otherwise the data amount of the first retransmitted useful data is determined to be 1;
[0054] Determine the data amount of the retransmission offset data as the ratio of the puncturing value of k0 to the block data amount of the LLR;
[0055] If the data amount of the retransmission offset data is greater than the data amount of the first retransmission useful data, the sum of the puncturing value of k0 and the maximum code block data amount is calculated, the ratio of the minimum value of the cbSize and the sum value to the block data amount of the LLR is calculated, and the result of rounding up minus the data amount of the first retransmission useful data is the data amount of the second retransmission useful data; otherwise, the data amount of the first retransmission useful data is determined to be the ratio of the cbSize to the block data amount of the LLR, the data amount of the retransmission offset data is 0, and the data amount of the second retransmission useful data is 0;
[0056] The data amounts of the first retransmission useful data, the retransmission offset data, and the second retransmission useful data, and the data structure thereof are determined as the first distribution information.
[0057] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other via the communication bus;
[0058] The memory is used to store computer programs;
[0059] The processor is used to execute the program stored in the memory to implement the data reading and writing method applicable to HARQ described in the first aspect.
[0060] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the data reading and writing method applicable to HARQ described in the first aspect.
[0061] The above technical solution provided by the embodiment of the present application has the following advantages over the prior art: the method provided by the embodiment of the present application, by acquiring the transmission data sent by the base station, the transmission data includes retransmitted useful data and retransmitted redundant data; acquiring the transmission parameters in the communication protocol; determining the first distribution information of the retransmitted useful data based on the transmission parameters; reading the second distribution information of the historical useful data from the external memory based on the transmission parameters; merging the retransmitted useful data and the historical useful data based on the first distribution information and the second distribution information to obtain the current useful data; decoding the current useful data to obtain the decoding result; in the case where the decoding result is a decoding failure, updating the historical useful data in the external memory to the current useful data. In this way, each time the data in the external memory is read and written, it is for the useful data part, and there is no need to read and write other parts, thereby reducing the amount of data reading and writing, and by reducing the amount of reading and writing to the external memory, the speed and throughput are improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0062] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.
[0063] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0064] Figure 1 A schematic diagram of the locations of retransmitted data of different redundancy versions of HARQ provided in an embodiment of the present application;
[0065] Figure 2 An application scenario diagram of a data reading and writing method applicable to HARQ provided in an embodiment of the present application;
[0066] Figure 3 A flowchart of a data reading and writing method applicable to HARQ provided in an embodiment of the present application;
[0067] Figure 4 A schematic diagram of a data structure provided in an embodiment of the present application;
[0068] Figure 5 A structural diagram of an electronic device provided in one embodiment of the present application. DETAILED DESCRIPTION
[0069] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.
[0070] Before further describing the embodiments of the present invention in detail, the nouns and terms involved in the embodiments of the present invention are described. The nouns and terms involved in the embodiments of the present invention are subject to the following explanations.
[0071] In NR (New Radio), each TB (Transport Block) can contain a large number of bits. However, reception errors are often concentrated in a small portion of the interval, and retransmitting the entire TB is very inefficient, so it is necessary to evolve HARQ technology to reduce the amount of retransmitted data.
[0072] See also Figure 1, at the basic coding rate, the complete coded bits generated from the coding are arranged along the entire circle. HARQ includes four redundancy versions (RV0 to RV3), and the starting and ending points of the data are different for different redundancy versions. Depending on whether the initial transmission (RV0) or retransmission (RV>0) is in progress, the transmitted bits are read from different positions of the circular buffer. Different RVs start reading at different positions on the circle, for example, RV0 is at the 0% position, RV1 is at the 25% position, RV2 is at the 50% position, and RV3 is at about the 85% position. Therefore, for different redundancy versions, the retransmitted data is different.
[0073] According to an embodiment of the present application, a data reading and writing method applicable to HARQ is provided. Optionally, in the embodiment of the present application, the data reading and writing method applicable to HARQ can be applied to Figure 2 In the hardware environment composed of terminal 201 and server 202 shown in FIG. Figure 2 As shown, the server 202 is connected to the terminal 201 via a network, and can be used to provide services (such as video services, application services, etc.) for the terminal or a client installed on the terminal. A database can be set up on the server or independently of the server to provide data storage services for the server 202. The above-mentioned network includes but is not limited to: a wide area network, a metropolitan area network or a local area network, and the terminal 201 is not limited to a PC, a mobile phone, a tablet computer, etc.
[0074] The data reading and writing method applicable to HARQ in the embodiment of the present application may be executed by the server 202, or by the terminal 201, or by both the server 202 and the terminal 201. The terminal 201 executes the data reading and writing method applicable to HARQ in the embodiment of the present application, or it may be executed by a client installed thereon.
[0075] Taking the case where a terminal executes the data reading and writing method applicable to HARQ in an embodiment of the present application as an example, Figure 3 is a flow chart of an optional data reading and writing method applicable to HARQ according to an embodiment of the present application, such as Figure 3 As shown, the process of the method may include the following steps:
[0076] Step 301: Acquire transmission data sent by a base station, where the transmission data includes retransmitted useful data and retransmitted redundant data.
[0077] In some embodiments, Figure 1As shown, in the case of the first retransmission (RV0), the retransmitted useful data starts from approximately the starting position of the TB, in the case of RV1, the useful data starts from approximately the 25% position of the TB, in the case of RV2, the useful data starts from approximately the 50% position of the TB, and in the case of RV3, the useful data starts from approximately the 85% position of the TB. The redundant data in the transmitted data is obtained by filling zeros on the transmission bits except for the retransmitted useful data.
[0078] Among them, the retransmitted useful data (for the sake of distinction, hereinafter referred to as new data) is divided into three categories, including first retransmitted useful data (for the sake of distinction, hereinafter referred to as new data 0), retransmitted offset data (for the sake of distinction, hereinafter referred to as new data offset) and second retransmitted useful data (for the sake of distinction, hereinafter referred to as new data 1), among which the first retransmitted useful data and the second retransmitted useful data are retransmitted valid data, and the retransmitted offset data is obtained by padding with zeros.
[0079] See also Figure 4 , transmit data to Figure 4 The data structure shown exists in the form of new data 0 at the starting position of the transmitted data, the new data offset is the data between the starting position of the transmitted data and the new data 1, the new data 1 is after the new data 0, and the data after the new data 1 is retransmitted redundant data.
[0080] Step 302: Obtain transmission parameters in the communication protocol.
[0081] In some embodiments, the transmission parameters may include but are not limited to the maximum code block data amount specified by the transmission protocol, the block data amount of LLR llrsBlockSize, the soft buffer size Ncb of the current code block, the number of filling bits nfiller, the rate matching redundancy version k0, the data amount cbSize of CB, the information bit length k, and the current HARQ is the number of all supported HARQ processes (harqTxindex).
[0082] In the transmission of the physical downlink shared channel (PDSCH), after the data is encoded, it needs to be rate matched before it can be divided into CB (Code Block) and TB (TransmitBlock) for transmission. Therefore, the information of the actual amount of received data is required to calculate the actual HARQ-related data information.
[0083] Wherein, k0 represents the first bit index that should be output for different RVs when performing HARQ. If harqTxindex is 0, it means that this is the first transmission.
[0084] The transmission parameters may be provided in accordance with the 3GPP protocol. In actual baseband device operation, after decoding of the PDCCH (Physical Downlink Control Channel), the relevant calculation parameters of the parameters may be obtained, or directly decoded. In the present invention, all the parameters obtained in the PDCCH are selected from the relevant parts, and are handed over to the firmware or hardware for calculation, so as to perform subsequent calculations.
[0085] Step 303: Determine first distribution information of the retransmitted useful data based on the transmission parameters.
[0086] In some embodiments, the first distribution information of the retransmitted useful data includes the data amount and data structure of different types of data in the retransmitted useful data. The data structure can be found in Figure 4 By determining the first distribution information, the data amount of different data in the retransmitted useful data and the position in the transmission data can be determined.
[0087] For example, taking the transmission data as 100 bits, the data volume of the new data 0 is 30, the new data offset is 50, and the data volume of the new data 1 is 30. It can be determined that the position of the new data 0 in the transmission data is 0 to 30, the position of the new data offset in the transmission data is 0 to 50, and the position of the new data 1 in the transmission data is 51 to 80. Furthermore, the position of the retransmitted redundant data in the transmission data is 81 to 100.
[0088] It is understandable that, since different RVs may have different retransmitted data, any one or more of the above-mentioned data 0, data offset and data 1 may be 0.
[0089] In an optional embodiment, determining the first distribution information of the retransmitted useful data based on the transmission parameter includes:
[0090] Determine the maximum storage required for actual transmission based on Ncb and nfiller;
[0091] Determine a code block size based on the maximum storage amount and the llrsBlockSize;
[0092] When k0 is 0, the amount of the first retransmission useful data is the result of taking the minimum value of cbSize and the maximum code block data amount, dividing by llrsBlockSize and rounding up, the amount of the retransmission offset data is 0, and the amount of the second retransmission useful data is 0;
[0093] In the case where k0 is not equal to 0, the puncturing value of k0 is determined based on k, k0 and nfiller, the intermediate value is determined based on the puncturing value of k0, the maximum code block data amount and the maximum storage amount, the minimum value of cbSize and the intermediate value is divided by llrsBlockSize and rounded up to obtain an intermediate result, if the intermediate result is greater than 1, the data amount of the first retransmitted useful data is determined to be the intermediate result, otherwise the data amount of the first retransmitted useful data is determined to be 1;
[0094] Determine the data amount of the retransmission offset data as the ratio of the puncturing value of k0 to the block data amount of the LLR;
[0095] If the data amount of the retransmission offset data is greater than the data amount of the first retransmission useful data, the sum of the puncturing value of k0 and the maximum code block data amount is calculated, the ratio of the minimum value of the cbSize and the sum value to the block data amount of the LLR is calculated, and the result of rounding up minus the data amount of the first retransmission useful data is the data amount of the second retransmission useful data; otherwise, the data amount of the first retransmission useful data is determined to be the ratio of the cbSize to the block data amount of the LLR, the data amount of the retransmission offset data is 0, and the data amount of the second retransmission useful data is 0;
[0096] The data amounts of the first retransmission useful data, the retransmission offset data, and the second retransmission useful data, and the data structure thereof are determined as the first distribution information.
[0097] Specifically, first, the maximum storage required for actual transmission is calculated by nfiller, cbSizePruned, whose value is Ncb minus nFiller. Because in actual hardware, data transfer has specific standards, such as the size of the LLR information used for decoding in HARQ operations. Assuming that the LLR transferred each time is 64 bits, let this multiple relationship be llrsBlockSize, and then calculate cbSize, whose value is llrsBlockSize multiplied by the result of cbSizePruned divided by llrsBlockSize and rounded up.
[0098] If k0 is equal to 0, it means that RV = 0 at this time, and all new LLRs should be filled in the position of data 0. At this time, the new data 0 is the result of taking the minimum value of cbSize and the maximum cb data amount specified by the protocol, divided by llrsBlockSize and rounded up; the new data 1 is 0; the new data offset is 0.
[0099] If k0 is not equal to 0, first calculate the first part (that is, the amount of data of the new data 0). The minimum size of the first part is set to 1 to prevent unreasonable data relationships. Check whether the information bit length k is less than the filling bit amount k0. If so, k0Pruned is k0 minus nFiller, otherwise k0Pruned is equal to k0.
[0100] The new data 0 is: cbSize and k0Pruned plus the maximum cb data amount specified by the protocol minus the value of cbSizePruned, take the smaller one, then divide it by llrsBlockSize and round up. If the value at this time is greater than 1, it is assigned to the new data 0, otherwise 1 is assigned to the new data 0. Therefore, the new data 0 must satisfy at least a value, and for binary, the minimum value is 1.
[0101] The new data offset is k0Pruned divided by llrsBlockSize.
[0102] Then check whether the first part and the second part (that is, the data amount of new data 1) are separated (that is, whether there is an offset between the two). If the new data offset is greater than the new data 0, it means that new data 1 exists, which is the result of judging cbSize and k0Pruned plus the minimum value of the maximum cb data amount specified by the protocol, and then dividing it by llrsBlockSize and rounding up minus the new data offset; otherwise, new data 0 is the result of cbSize divided by llrsBlockSize, new data 1 is 0, and the new data offset is 0.
[0103] Step 304: Read second distribution information of historical useful data from an external memory based on the transmission parameters.
[0104] In an optional embodiment, the transmission parameter includes the number of retransmissions; and the second distribution information of the historical useful data read from the external memory based on the transmission parameter includes:
[0105] When the number of retransmissions is 0, determining that the historical useful data is 0;
[0106] When the number of retransmissions is not 0, the historical useful data is determined to be the most recently stored current useful data.
[0107] In some embodiments, the content to be read can be determined by judging whether it is the first transmission. If it is the first transmission, there is no need to read data from external storage, so the historical useful data is set to 0. If it is not the first transmission, previously stored useful data already exists in the external memory, and the historical useful data is obtained by reading the most recently stored current useful data, wherein the distribution information of the current useful data is the second distribution information mentioned above.
[0108] The external memory may be, but is not limited to, DDR (double data rate synchronous dynamic random access memory).
[0109] Among them, the historical useful data (for the sake of distinction, hereinafter referred to as old data) includes first historical useful data (for the sake of distinction, hereinafter referred to as old data 0), historical offset data (for the sake of distinction, hereinafter referred to as old data offset) and second historical useful data (for the sake of distinction, hereinafter referred to as old data 1), wherein the data structures of old data 0, old data offset and old data 1 are the same as the data structures of new data 0, new data offset and new data 1 in the above-mentioned retransmitted useful data, and are not repeated here.
[0110] Step 305: Merge the retransmitted useful data and the historical useful data based on the first distribution information and the second distribution information to obtain current useful data.
[0111] In some embodiments, after determining the first distribution information and the second distribution information, the retransmitted useful data and the historical useful data are compared, the overlapping part of the two is updated as the retransmitted useful data, and the part not included in the historical useful data is added to obtain the current useful data.
[0112] The current useful data (for the sake of distinction, hereinafter referred to as total data) includes the first current useful data (for the sake of distinction, hereinafter referred to as total data 0), the current offset data (for the sake of distinction, hereinafter referred to as total data offset) and the second current useful data (for the sake of distinction, hereinafter referred to as total data 1).
[0113] When determining the total data, the new data 0 can be assigned to the total data 0, the new data 1 can be assigned to the total data 1, and the new data offset can be assigned to the total data offset, so that each total data can have an initial value. And further by comparing the new data with the old data, the total data with the initial value is updated.
[0114] Specifically, first determine whether harqTxIndex is greater than 0: if not, it indicates that it is the first transmission. Based on the above-mentioned related embodiments, when harqTxIndex is used, the old data is all 0, so the total data is the initial value after the above-mentioned assignment.
[0115] If harqTxIndex is greater than 0, try to merge the first part:
[0116] Total data 0 takes the maximum value of total data 0 and old data 0;
[0117] If the old data offset is less than or equal to the total data 0: the total data 0 is updated to the maximum value of the total data 0 and the old data offset plus the old data 1, the old data 1 is set to 0, and the old data offset is set to 0;
[0118] If the total data offset is less than or equal to total data 0: total data 0 is updated to the maximum value of total data 0 and total data offset plus total data 1, total data 1 is set to 0, and the total data offset is set to 0.
[0119] Try incorporating the second part:
[0120] If total data 1 is greater than 0 and old data 1 is greater than 0: set the current offset to the minimum value of the old data offset and the total data offset; total data 1 is the maximum value of the sum of the old data offset plus the old data 1 and the sum of the total data offset plus the total data 1 minus the current offset, and the total data offset is set to the current offset.
[0121] Otherwise, if old data 1 is greater than 0, total data 1 is set to old data 1, and the total data offset is set to the old data offset; further, if the obtained total data offset is less than or equal to total data 0, total data 0 is updated to the maximum value of total data 0 and total data offset plus total data 1, total data 1 is set to 0, and the total data offset is set to 0.
[0122] Furthermore, after obtaining the above total data, it can be assigned to temporary data, so that the old data can be read from the temporary data to obtain the corresponding data.
[0123] Step 306: Decode the current useful data to obtain a decoding result.
[0124] In some embodiments, the decoding of the current useful data can be performed using LDPC (Low-density Parity-check) or Polar code. The specific implementation process of decoding the data according to LDPC or Polar code can refer to the relevant technology and will not be repeated here.
[0125] Step 307: When the decoding result is a decoding failure, the historical useful data in the external memory is updated to the current useful data.
[0126] In some embodiments, if the decoding is successful, the temporary data in the external memory is reset. If the decoding fails, the above-mentioned total data is converted into temporary data, and then handed over to the old data at the next clock beat to complete the corresponding operation of writing into the external memory.
[0127] After the data of the above three transmission types are calculated, they are forwarded to realize the next HARQ-related data calculation, thereby achieving normal and effective iteration.
[0128] The redundant data generated by the protocol in other parts does not need to be moved in the hardware, which can save DDR reading and writing and reduce the use of DDR.
[0129] The data reading and writing method applicable to HARQ of the present application only needs to target data 0 and data 1 for each DDR reading and writing, and the redundant data generated in other parts according to the protocol does not need to be moved in the hardware, thereby saving the reading and writing of the external memory and reducing the use of the external memory.
[0130] After the present invention is implemented, the following tests are performed to prove the advantages of the present invention:
[0131] When the source code length is 192026, under 256QAM, the transmission occupies 14 symbols and 78 resource blocks. When data 0 = 8f and data 1 = 90, the saved storage offset value is c4, and the saved DDR is 40.6%;
[0132] When the source code length is 70113, under 64QAM, the transmission occupies 14 symbols and 76 resource blocks. When data 0 = 10 and data 1 = f0, the saved storage offset value is bc, and the saved DDR is 42.3%;
[0133] When the source code length is 8424 and the transmission occupies 14 symbols and 38 resource blocks under 64QAM, when data 0 = 8c and data 1 = 3c, the saved storage offset value is 150 and the saved DDR is 62.7%.
[0134] Based on the same concept, an embodiment of the present application provides a data reading and writing device suitable for HARQ. The specific implementation of the device can refer to the description of the method embodiment part, and the repeated parts will not be repeated. The device mainly includes:
[0135] A first acquisition module, used to acquire transmission data sent by the base station, wherein the transmission data includes retransmission useful data and retransmission redundant data;
[0136] A second acquisition module is used to acquire transmission parameters in the communication protocol;
[0137] A determination module, configured to determine first distribution information of the retransmitted useful data based on the transmission parameter;
[0138] A reading module, used for reading second distribution information of historical useful data from an external memory based on the transmission parameter;
[0139] a merging module, configured to merge the retransmitted useful data and the historical useful data based on the first distribution information and the second distribution information to obtain current useful data;
[0140] A decoding module, used for decoding the current useful data to obtain a decoding result;
[0141] The writing module is used to update the historical useful data in the external memory to the current useful data when the decoding result is a decoding failure.
[0142] Based on the same concept, an electronic device is also provided in the embodiment of the present application, such as Figure 5 As shown, the electronic device mainly includes: a processor 501, a memory 502 and a communication bus 503, wherein the processor 501 and the memory 502 communicate with each other through the communication bus 503. The memory 502 stores a program executable by the processor 501, and the processor 501 executes the program stored in the memory 502 to implement the following steps:
[0143] Acquire transmission data sent by the base station, where the transmission data includes retransmission useful data and retransmission redundant data;
[0144] Get the transmission parameters in the communication protocol;
[0145] Determining first distribution information of the retransmitted useful data based on the transmission parameter;
[0146] Reading second distribution information of historical useful data from an external memory based on the transmission parameters;
[0147] Merging the retransmitted useful data and the historical useful data based on the first distribution information and the second distribution information to obtain current useful data;
[0148] Decoding the current useful data to obtain a decoding result;
[0149] When the decoding result is a decoding failure, the historical useful data in the external memory is updated to the current useful data.
[0150] The communication bus 503 mentioned in the above electronic device can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus. The communication bus 503 can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 5 Only one thick line is used in the diagram, but this does not mean that there is only one bus or only one type of bus.
[0151] The memory 502 may include a random access memory (RAM) or a non-volatile memory, such as at least one disk memory. Optionally, the memory may also be at least one storage device located away from the processor 501 .
[0152] The above-mentioned processor 501 can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc., and can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0153] The electronic device provided in the embodiment of the present application may specifically be a module capable of realizing a communication function or a terminal device including the module, etc. The terminal device may be a mobile terminal or a smart terminal. The mobile terminal may specifically be at least one of a mobile phone, a tablet computer, a laptop computer, etc.; the smart terminal may specifically be a terminal including a wireless communication module such as a smart car, a smart watch, a shared bicycle, a smart cabinet, etc.; the module may specifically be a wireless communication module, such as any one of a 2G communication module, a 3G communication module, a 4G communication module, a 5G communication module, and a NB-IOT communication module.
[0154] In another embodiment of the present application, a computer-readable storage medium is provided, in which a computer program is stored. When the computer program runs on a computer, the computer executes the data reading and writing method applicable to HARQ described in the above embodiment.
[0155] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented by software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer instruction is loaded and executed on a computer, the process or function described in the embodiment of the present application is generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network or other programmable device. The computer instruction may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instruction is transmitted from a website site, a computer, a server or a data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, microwave, etc.) mode to another website site, computer, server or data center. The computer-readable storage medium may be any available medium that a computer can access or a data storage device such as a server or a data center that includes one or more available media integrated. The available medium may be a magnetic medium (e.g., a floppy disk, a hard disk, a tape, etc.), an optical medium (e.g., a DVD) or a semiconductor medium (e.g., a solid-state hard disk), etc.
[0156] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.
[0157] The foregoing is merely a specific embodiment of the present invention, which enables those skilled in the art to understand or implement the present invention. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present invention. Therefore, the present invention will not be limited to the embodiments shown herein, but rather to the widest scope consistent with the principles and novel features claimed herein.
Claims
1. A data reading and writing method suitable for HARQ, characterized in that: include: Acquire transmission data sent by the base station, where the transmission data includes retransmission useful data and retransmission redundant data; Get the transmission parameters in the communication protocol; Determining first distribution information of the retransmitted useful data based on the transmission parameter; Reading second distribution information of historical useful data from an external memory based on the transmission parameters; Merging the retransmitted useful data and the historical useful data based on the first distribution information and the second distribution information to obtain current useful data; Decoding the current useful data to obtain a decoding result; When the decoding result is a decoding failure, updating the historical useful data in the external memory to the current useful data; The retransmitted useful data includes first retransmitted useful data, retransmitted offset data and second retransmitted useful data, and the data structure of the retransmitted useful data is that the first retransmitted useful data is at the starting position of the transmitted data, the second retransmitted useful data is after the first retransmitted useful data, and the retransmission offset data is the data between the starting position and the second retransmitted useful data; the transmission parameters include the maximum code block data amount specified by the transmission protocol, the block data amount llrsBlockSize of the LLR, the soft buffer size Ncb of the current code block, the number of filling bits nfiller, the rate matching redundancy version k0, the data amount cbSize of the CB, and the information bit length k; the first distribution information of the retransmitted useful data is determined based on the transmission parameters, including: determining the maximum storage amount required for actual transmission based on the Ncb and nfiller; determining the code block size based on the maximum storage amount and the llrsBlockSize; when k0 is 0, the data amount of the first retransmitted useful data is the minimum value of cbSize and the maximum code block data amount, divided by llrsBlockSize And round up the result, the data amount of the retransmitted offset data is 0, and the data amount of the second retransmitted useful data is 0; when k0 is not equal to 0, the puncturing value of k0 is determined based on k, k0 and nfiller, and the intermediate value is determined based on the puncturing value of k0, the maximum code block data amount and the maximum storage amount, and the minimum value of cbSize and the intermediate value is divided by llrsBlockSize and round up to obtain an intermediate result. If the intermediate result is greater than 1, the data amount of the first retransmitted useful data is determined to be the intermediate result, otherwise the data amount of the first retransmitted useful data is determined to be 1; the data amount of the retransmitted offset data is determined to be the ratio of the puncturing value of k0 to the block data amount of LLR; if the data amount of the retransmitted offset data is greater than the data amount of the first retransmitted useful data, the sum of the puncturing value of k0 and the maximum code block data amount is calculated, the ratio of the minimum value of the cbSize and the sum to the block data amount of LLR is calculated, and the result of rounding up minus the data amount of the first retransmitted useful data is obtained as the data amount of the second retransmitted useful data; otherwise, the data amount of the first retransmitted useful data is determined to be the ratio of the cbSize to the block data amount of LLR, the data amount of the retransmitted offset data is 0, and the data amount of the second retransmitted useful data is determined to be 0; the data amount of the first retransmitted useful data, the retransmission offset data, and the second retransmitted useful data, as well as the data structure, are determined to be the first distribution information; Among them, the transmission parameters include the number of retransmissions; the second distribution information of reading historical useful data from the external memory based on the transmission parameters includes: when the number of retransmissions is 0, determining that the historical useful data is 0; when the number of retransmissions is not 0, determining that the historical useful data is the current useful data stored most recently.
2. The data reading and writing method suitable for HARQ according to claim 1, characterized in that: Determine the punching value of k0 based on k, k0 and nfiller, including: Determine whether k is less than k0; If so, determine the punching value of k0 as the difference between k0 and nfiller; If not, determine the puncturing value of k0 as k0.
3. The data reading and writing method suitable for HARQ according to claim 1, characterized in that: The intermediate value is determined based on the puncturing value of k0, the maximum code block data amount, and the maximum storage amount, including: The sum of the puncturing value of k0 and the maximum code block data amount, and the difference between the sum and the maximum storage amount are calculated to obtain an intermediate value.
4. A data reading and writing device suitable for HARQ, characterized in that: include: A first acquisition module, used to acquire transmission data sent by the base station, wherein the transmission data includes retransmission useful data and retransmission redundant data; A second acquisition module is used to acquire transmission parameters in the communication protocol; A determination module, configured to determine first distribution information of the retransmitted useful data based on the transmission parameter; A reading module, used for reading second distribution information of historical useful data from an external memory based on the transmission parameter; a merging module, configured to merge the retransmitted useful data and the historical useful data based on the first distribution information and the second distribution information to obtain current useful data; A decoding module, used for decoding the current useful data to obtain a decoding result; A writing module, used for updating the historical useful data in the external memory to the current useful data when the decoding result is a decoding failure; The transmission parameter includes the number of retransmissions; the reading module is specifically used to: when the number of retransmissions is 0, determine that the historical useful data is 0; when the number of retransmissions is not 0, determine that the historical useful data is the most recently stored current useful data; Among them, the retransmitted useful data includes first retransmitted useful data, retransmission offset data and second retransmitted useful data, and the data structure of the retransmitted useful data is that the first retransmitted useful data is at the starting position of the transmission data, the second retransmitted useful data is after the first retransmitted useful data, and the retransmission offset data is the data between the starting position and the second retransmitted useful data; the transmission parameters include the maximum code block data amount specified by the transmission protocol, the block data amount llrsBlockSize of the LLR, the soft buffer size Ncb of the current code block, the number of filling bits nfiller, the rate matching redundancy version k0, the data amount cbSize of the CB, and the information bit length k; the determination module is specifically used to: determine the maximum storage amount required for actual transmission based on the Ncb and nfiller; determine the code block size based on the maximum storage amount and the llrsBlockSize; when k0 is 0, the data amount of the first retransmitted useful data is the minimum value of cbSize and the maximum code block data amount, divided by llrsBlockSize And round up the result, the data amount of the retransmitted offset data is 0, and the data amount of the second retransmitted useful data is 0; when k0 is not equal to 0, the puncturing value of k0 is determined based on k, k0 and nfiller, and the intermediate value is determined based on the puncturing value of k0, the maximum code block data amount and the maximum storage amount, and the minimum value of cbSize and the intermediate value is divided by llrsBlockSize and round up to obtain an intermediate result. If the intermediate result is greater than 1, the data amount of the first retransmitted useful data is determined to be the intermediate result, otherwise the data amount of the first retransmitted useful data is determined to be 1; the data amount of the retransmitted offset data is determined to be the ratio of the puncturing value of k0 to the block data amount of LLR; if the data amount of the retransmitted offset data is greater than the data amount of the first retransmitted useful data, the sum of the puncturing value of k0 and the maximum code block data amount is calculated, the ratio of the minimum value of the cbSize and the sum to the block data amount of LLR is calculated, and the result of rounding up is subtracted from the data amount of the first retransmitted useful data to obtain the data amount of the second retransmitted useful data; otherwise, the data amount of the first retransmitted useful data is determined to be the ratio of the cbSize to the block data amount of LLR, the data amount of the retransmitted offset data is 0, and the data amount of the second retransmitted useful data is 0; The data amounts of the first retransmission useful data, the retransmission offset data, and the second retransmission useful data, and the data structure thereof are determined as the first distribution information.
5. An electronic device, characterized in that: include: A processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other via the communication bus; The memory is used to store computer programs; The processor is used to execute the program stored in the memory to implement the data reading and writing method applicable to HARQ as described in any one of claims 1-3.
6. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the data reading and writing method applicable to HARQ as described in any one of claims 1 to 3 is implemented.
Citation Information
Patent Citations
Method for decoding data packets in a wireless communication system
CN102142945A
Data receiving end based on HARQ technology and data transmission method thereof
CN106411479A