Signal gain control method and device, terminal equipment and storage medium
By performing a zero-setting operation on the spread spectrum code sequence and adjusting the gain of the digital spread spectrum signal, the problems of high signal gain control steps and high costs in the existing technology are solved, achieving more precise signal gain control and reducing equipment costs. Effect.
Patent Information
- Application Number
- CN202410804136.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-20
- Publication Date
- 2024-10-29
AI Technical Summary
Existing signal gain control methods are expensive and difficult to achieve precise control in analog signal processing. The gain control steps of digital signals are high and cannot meet the demand for lower steps.
By obtaining the initial spreading code sequence, it is determined that the target zero-setting threshold corresponds to the target signal gain value, and some codes in the spreading code sequence are set to zero according to the target zero-setting threshold, and the target spreading code sequence is generated. According to the target spreading code The sequence and preset carrier signal generate a target digital spread spectrum signal, thereby adjusting the gain of the digital spread spectrum signal.
It achieves finer signal gain control, reduces the gain control step, reduces signal spectrum energy fluctuations, and reduces equipment costs.
Smart Images

Figure CN118869003A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application belong to the field of signal processing technology, and in particular, relate to a signal gain control method, device, terminal equipment and storage medium. Background Art
[0002] Signal gain control mainly includes digital signal and analog signal control. The analog signal control method has higher gain control accuracy. It uses dynamic adjustment of the signal carrier amplitude to achieve signal gain control. This control method requires a processor with stronger analog circuit computing power, which makes the cost of the satellite signal generator very expensive. At the same time, the dynamic adjustment of the carrier amplitude may cause harmonic signals to cause energy fluctuations in the signal spectrum.
[0003] For discrete digital signals, the hardware implementation uses the same signal amplitude control method to right-shift the digital signal binary sequence by 1 bit. At this time, the signal amplitude is reduced by 1 / 2 and the signal power is reduced to 1 / 4. Then the signal gain will drop by 6dB (decibel), which cannot meet the gain control with lower steps. Summary of the invention
[0004] In view of this, an embodiment of the present application provides a signal gain control method for adjusting the gain of a digital spread spectrum signal through a spread spectrum code sequence, reducing the gain control step, and improving the gain control precision.
[0005] A first aspect of an embodiment of the present application provides a signal gain control method, including:
[0006] Obtaining an initial spreading code sequence;
[0007] Determine a target zeroing threshold; the target zeroing threshold corresponds to a target signal gain value;
[0008] Setting part of the spreading codes in the initial spreading code sequence to zero according to the target zeroing threshold to generate a target spreading code sequence;
[0009] A target digital spread spectrum signal is generated according to the target spread spectrum code sequence, a preset carrier signal and a data code.
[0010] A second aspect of an embodiment of the present application provides a signal gain control device, including:
[0011] An initial spread spectrum code sequence acquisition module, used to acquire an initial spread spectrum code sequence;
[0012] A target zeroing threshold determination module, used to determine a target zeroing threshold; the target zeroing threshold corresponds to a target signal gain value;
[0013] a target spreading code sequence generating module, configured to set part of the spreading codes in the initial spreading code sequence to zero according to the target zeroing threshold value, so as to generate a target spreading code sequence;
[0014] The target digital spread spectrum signal generating module is used to generate a target digital spread spectrum signal according to the target spread spectrum code sequence, a preset carrier signal and a data code.
[0015] A third aspect of an embodiment of the present application provides a terminal device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the signal gain control method as described in the first aspect above is implemented.
[0016] A fourth aspect of an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the signal gain control method as described in the first aspect above is implemented.
[0017] A fifth aspect of the embodiments of the present application provides a computer program product. When the computer program product is run on a computer, the computer is enabled to execute the signal gain control method described in the first aspect.
[0018] Compared with the prior art, the embodiments of the present application have the following beneficial effects:
[0019] In an embodiment of the present application, an initial spread spectrum code sequence is obtained; a target zeroing threshold is determined; the target zeroing threshold corresponds to a target signal gain value; part of the spread spectrum codes in the initial spread spectrum code sequence is zeroed according to the target zeroing threshold to generate a target spread spectrum code sequence; a target digital spread spectrum signal is generated according to the target spread spectrum code sequence, a preset carrier signal and a data code, thereby adjusting the gain of the digital spread spectrum signal by zeroing part of the spread spectrum codes in the spread spectrum code sequence according to the target zeroing threshold. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the following briefly introduces the drawings required for use in the embodiments or prior art descriptions. Obviously, the drawings described below are only some embodiments of the present application, and for ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0021] Figure 1 It is a graph of signal gain changing with decreasing signal amplitude in the prior art;
[0022] Figure 2 is a schematic diagram of a signal gain control method provided in an embodiment of the present application;
[0023] Figure 3 It is a schematic diagram of a flow chart of a satellite signal generator generating gain change information provided by an embodiment of the present application;
[0024] Figure 4 is a curve of signal gain changing with zeroing threshold provided in an embodiment of the present application;
[0025] Figure 5 is a schematic diagram of a signal gain control device provided in an embodiment of the present application;
[0026] Figure 6 It is a schematic diagram of a terminal device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0027] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.
[0028] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or combinations thereof.
[0029] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0030] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.
[0031] In addition, in the description of the present application specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.
[0032] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the statements "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways. The terms "including", "comprising", "having" and their variations all mean "including but not limited to", unless otherwise specifically emphasized in other ways.
[0033] Digital Spread Spectrum Signal is a communication technology that transmits information by spreading the data code (original data signal) to a wider frequency band. Generally, a spread spectrum code sequence is used to spread the data code, and the spread signal is modulated to obtain a digital spread spectrum signal.
[0034] One expression of a digital spread spectrum signal is:
[0035] S(n)=A·C(n)·exp(2πfn),n=0,1,2,3…N-1
[0036] Among them, A is the amplitude, C is the spread spectrum code sequence, f is the carrier frequency, and N is the signal length.
[0037] One of the existing technologies is to use binary sequence truncation to adjust the amplitude of the digital spread spectrum signal to adjust its gain. Figure 1 , shows a graph of the change of signal gain with the decrease of signal amplitude in the prior art. When the signal amplitude remains unchanged, is halved, and is reduced to 1 / 4 of the original, the signal gain decreases by 0dB, 6dB, and 18dB, respectively. For the method of truncating the binary sequence to reduce the signal amplitude, the signal gain control step is as high as 6dB, which makes it difficult to improve the fine control of the signal gain.
[0038] The embodiments of the present application can be applicable to digital spread spectrum signal processing equipment, including but not limited to signal transmitting equipment, signal simulation equipment, etc. The technical solution of the present application is explained below through specific embodiments.
[0039] Reference Figure 2 , shows a schematic diagram of a signal gain control method provided in an embodiment of the present application, which may specifically include the following steps:
[0040] Step 201, obtaining an initial spreading code sequence;
[0041] The spread spectrum code sequence is a series of specific digital sequences used to spread the data code to a wider frequency band. The spread spectrum code sequence usually has good autocorrelation and cross-correlation to ensure the uniqueness and anti-interference of the signal. Common spread spectrum codes include pseudo-random noise (PN) sequences, Walsh codes, etc. The process of spreading the data code can be to multiply the data code with the spread spectrum code sequence to expand the bandwidth of the data code to a wider frequency band. This process can be achieved through direct sequence spread spectrum (DSSS) or frequency hopping spread spectrum (FHSS).
[0042] The initial spreading code sequence may be a spreading code sequence used to generate a digital spreading code signal that needs to be gain controlled. The initial spreading code sequence may be generated in advance according to a specified rule, or sent by a specified device.
[0043] Step 202, determining a target zeroing threshold; the target zeroing threshold corresponds to a target signal gain value;
[0044] A plurality of zeroing thresholds and their corresponding signal gain values may be pre-stored. The signal gain values correspond to different gain change controls, and one of the zeroing thresholds may be determined as the target zeroing threshold according to actual requirements.
[0045] Step 203, setting part of the spreading codes in the initial spreading code sequence to zero according to the target zeroing threshold to generate a target spreading code sequence;
[0046] The initial spreading code sequence includes a plurality of spreading codes of different values in order, and the values of some spreading codes in the spreading code sequence are changed to zero using a target zeroing threshold to obtain a target spreading code sequence.
[0047] Step 204: Generate a target digital spread spectrum signal according to the target spread spectrum code sequence, a preset carrier signal and a data code.
[0048] The gain of the target digital spread spectrum signal relative to the initial digital spread spectrum signal is the above target gain, and the initial digital spread spectrum signal is generated according to the initial spread spectrum code sequence, a preset carrier signal and a data code.
[0049] Exemplarily, the data code may be a satellite navigation message, and the target digital spread spectrum signal may be a satellite signal.
[0050] In an embodiment of the present application, an initial spread spectrum code sequence is obtained; a target zeroing threshold is determined; the target zeroing threshold corresponds to a target signal gain value; part of the spread spectrum codes in the initial spread spectrum code sequence is zeroed according to the target zeroing threshold to generate a target spread spectrum code sequence; a target digital spread spectrum signal is generated based on the target spread spectrum code sequence, a preset carrier signal and a data code, thereby achieving adjustment of the digital spread spectrum signal gain by zeroing part of the spread spectrum codes in the spread spectrum code sequence according to the target zeroing threshold.
[0051] In an optional embodiment, step 202 may include:
[0052] Sub-step 2021, obtaining gain change information; the gain change information includes a plurality of signal gain values and their corresponding zeroing thresholds;
[0053] The gain change information may be predetermined and stored, the gain change information including a plurality of signal gain values, each signal gain value corresponding to a zeroing threshold.
[0054] In one example, the signal gain value in the gain change information is a discrete value, and the one-to-one corresponding signal gain value and zero threshold value can be stored in a table.
[0055] Sub-step 2022, determining a target signal gain value from the plurality of signal gain values;
[0056] According to actual needs, one of the multiple signal gain values can be determined as the target signal gain value.
[0057] In one example, various signal gain values may be displayed to the user, and the user selects one of them as the target signal gain value.
[0058] In another example, the user may input a gain requirement value, and if there is a signal gain value that is consistent with the gain requirement value, the signal gain value is determined as the target signal gain value; if there is no signal gain value that is consistent with the gain requirement value, the signal gain value with the smallest difference from the gain requirement value may be determined as the target signal gain value, or the signal gain value that is not greater than the gain requirement value and has the smallest difference from the gain requirement value may be determined as the target signal gain value, or the signal gain value that is not less than the gain requirement value and has the smallest difference from the gain requirement value may be determined as the target signal gain value, or two signal gain values that are adjacent in size to the gain requirement value may be provided and the user may determine one of them as the target signal gain value.
[0059] Sub-step 2023, determining a target zeroing threshold corresponding to the target signal gain value.
[0060] After determining the target signal gain value, determine the zeroing threshold corresponding to the target signal gain value in the gain change information as the target zeroing threshold.
[0061] In an optional embodiment, step 203 may include:
[0062] Sub-step 2031, determining a sequence index based on the target zeroing threshold and the initial spreading code sequence;
[0063] Sub-step 2032: setting the spreading codes after the sequence index in the initial spreading code sequence to zero to generate a target spreading code sequence.
[0064] The initial spreading code sequence is composed of a plurality of spread spectrum codes in order, and the initial spreading code sequence is a periodic signal. In each period, one of the spreading codes in the initial spreading code sequence is determined as a sequence index based on a target zeroing threshold, and the spreading codes in the initial spreading code sequence that are ordered at the sequence index and before the sequence index are kept unchanged, and the spreading codes that are ordered after the sequence index are set to zero, thereby obtaining a target spreading sequence.
[0065] In an optional embodiment, sub-step 2031 may include: determining a periodic code length of the initial spreading code sequence; and determining a sequence index according to a product of the target zeroing threshold and the periodic code length.
[0066] The number of spreading codes in a single period of the initial spreading code sequence may be determined as the period code length, and the sequence index may be determined according to the product of the target zeroing threshold and the period code length.
[0067] In one example, if the product of the target zeroing threshold and the periodic code length is an integer, the integer is used as the sequence index, and the target spreading sequence is obtained by keeping the spreading codes arranged at the sequence index and before the sequence index in a single period in the initial spreading code sequence unchanged and setting the spreading codes arranged after the sequence index to zero.
[0068] In another example, if the product of the target zeroing threshold and the periodic code length is a non-integer, the integer obtained by rounding the product can be used as the sequence index, and the spreading codes in the initial spreading code sequence that are located at the sequence index and before the sequence index in a single period remain unchanged, and the spreading codes that are located after the sequence index are set to zero, thereby obtaining the target spreading sequence. For example: if the target zeroing threshold is 0.01, the periodic code length is 1024, and the product of the target zeroing threshold and the periodic code length is 10.24, then the integer 10 obtained by rounding the product can be used as the sequence index, wherein the rounding calculation method does not affect the execution of this embodiment and the corresponding beneficial effects.
[0069] In an optional embodiment, step 204 may include: generating spread spectrum data according to the target spread spectrum code sequence and the data code; and modulating the spread spectrum signal according to the frequency of the carrier signal to generate a digital spread spectrum signal.
[0070] The target spread spectrum code sequence is used to perform a point multiplication operation with the data code to obtain the spread spectrum data, and the spread spectrum data is modulated onto the carrier according to the frequency of the carrier signal. The modulated signal is a digital spread spectrum signal.
[0071] In an optional embodiment, the gain change information is generated by the following method: obtaining a first digital spread spectrum signal and a threshold set; the threshold set includes multiple zeroing thresholds; for each of the zeroing thresholds, setting part of the spread spectrum codes in the first spread spectrum code sequence in the first digital spread spectrum to zero according to the zeroing threshold to obtain a second digital spread spectrum signal, and determining a signal gain value based on the second digital spread spectrum signal and the first digital spread spectrum signal; generating the gain change information based on each of the zeroing thresholds and their corresponding signal gain values.
[0072] The following further illustrates the method for generating gain variation information by taking an example, which can generate a simulation signal, a first digital spread spectrum signal S1 (n).
[0073] S1(n)=A·C(n)·exp(2πfn),n=0,1,2,3…N-1
[0074] Set the threshold set V to contain multiple zero thresholds v i , for each of the zeroing thresholds, a portion of the spreading codes in the first spreading code sequence in the first digital spreading is set to zero according to the zeroing threshold, to obtain an adjustment signal C adjust (n), based on the adjustment signal C adjust (n) Obtaining the second digital spread spectrum signal S adjust (n).
[0075]
[0076] S adjust (n) = A·C adjust (n)·exp(2πfn),n=0,1,2,3…N-1
[0077] Where Idx = v i ·L c , L c is the periodic code length of the spread spectrum code.
[0078] Then, the signal gain values of the second digital spread spectrum signal corresponding to each zeroing threshold relative to the first digital spread spectrum signal are calculated. The gain change relationship is generated by using each zeroing threshold and the signal gain values of the second digital spread spectrum signal corresponding to each zeroing threshold relative to the first digital spread spectrum signal, that is, the gain change relationship includes each zeroing threshold in the threshold set and the signal gain value corresponding to each zeroing threshold.
[0079] The carrier-to-noise ratio of the first digital spread spectrum signal is set to a certain value. In the embodiment of the present application, part of the spread spectrum codes in the spread spectrum code sequence is set to zero, and the process only processes the original spread spectrum code and does not involve the carrier-to-noise ratio. Therefore, the size of the carrier-to-noise ratio will not affect the embodiment of the present application.
[0080] In an optional embodiment, determining the signal gain value based on the second digital spread spectrum signal and the first digital spread spectrum signal includes: calculating the self-coherence integration value of the first digital spread spectrum signal; calculating the mutual coherence integration value of the first digital spread spectrum signal and the second digital spread spectrum signal; and calculating the signal gain value using a preset gain calculation formula, the self-coherence integration value and the mutual coherence integration value.
[0081] The calculation formula of the self-coherence integral value is:
[0082]
[0083] The calculation formula of the mutual interference integral value is:
[0084]
[0085] In the calculation of the mutual interference integral value, "*" represents the complex conjugate.
[0086] The signal gain value is calculated as:
[0087] D=10lg(R och / R auto )
[0088] The self-coherence integral value calculation formula can be used to calculate the self-coherence integral value of the first digital spread spectrum signal. According to the first digital spread spectrum signal and the second digital spread spectrum signal corresponding to different zeroing thresholds, the mutual coherence integral value calculation formula is used to calculate the mutual coherence integral value corresponding to each zeroing threshold. The signal gain value corresponding to each zeroing threshold is calculated by using the signal gain value calculation formula, the self-coherence integral value of the first digital spread spectrum signal, and the mutual coherence integral value corresponding to each zeroing threshold.
[0089] Reference Figure 3 , shows a schematic diagram of a flow chart of a satellite signal generator generating gain change information provided by an embodiment of the present application, and the steps of generating gain change information include: Step 301, generating an initial satellite signal. Taking the intermediate frequency digital signal of the B1I frequency band of the Beidou-3 satellite as an example, its signal structure includes a carrier, a pseudo code, and an NH code, which can generate a simulated initial satellite signal. Step 302, setting different zeroing thresholds, setting a pseudo code sequence to zero according to a certain ratio, and obtaining an adjustment signal. The zeroing threshold v can be set i ∈[0,1], v with adjacent size iThe difference between them is 0.01. Step 303, calculate the self-coherence integral value and the mutual coherence integral value, and calculate the signal gain value by the signal gain value calculation formula. Step 304, according to the gain and zero threshold change relationship, obtain the step relationship of the gain control step less than 1dB. The step relationship with a step less than 1dB can be used as gain change information, so as to achieve gain control of the initial satellite signal with an accuracy not exceeding 1dB.
[0090] Reference Figure 4 , shows a curve of a signal gain value varying with a zeroing threshold value provided by an embodiment of the present application; Figure 4 It can be seen that the zero threshold is in the interval [0,0.5], and the relationship between the zero threshold and the gain reduction is approximately a linear relationship. The threshold can be adjusted in this interval to achieve gain control, so that its range can be adjusted arbitrarily from 0dB to -6dB. From the following Table 1, it can be seen that the step of signal gain can be adjusted by less than 0.5dB. According to the above steps 301-304, the signal gain values corresponding to the various zero thresholds shown in Table 1 below can be obtained, and the step of the signal gain value is less than 0.5dB.
[0091]
[0092]
[0093] Table 1
[0094] Table 1 shows the gain change information corresponding to the intermediate frequency digital signal of the B1I frequency band of the Beidou-3 satellite.
[0095] Can be combined with the embodiments of the present application and Figure 3 The steps shown are used to implement step gain control of other satellite signals, and the embodiments of the present application will not be repeated here.
[0096] It should be noted that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0097] Reference Figure 5 , shows a schematic diagram of a signal gain control device provided in an embodiment of the present application, which may specifically include an initial spread spectrum code sequence acquisition module 501, a target zeroing threshold determination module 502, a target spread spectrum code sequence generation module 503, and a target digital spread spectrum signal generation module 504, wherein:
[0098] An initial spreading code sequence acquisition module 501 is used to acquire an initial spreading code sequence;
[0099] A target zeroing threshold determination module 502 is used to determine a target zeroing threshold; the target zeroing threshold corresponds to a target signal gain value;
[0100] A target spreading code sequence generating module 503 is used to set some spreading codes in the initial spreading code sequence to zero according to the target zeroing threshold to generate a target spreading code sequence;
[0101] The target digital spread spectrum signal generating module 504 is used to generate a target digital spread spectrum signal according to the target spread spectrum code sequence, a preset carrier signal and a data code.
[0102] In an optional embodiment, the target zeroing threshold determination module 502 may include:
[0103] A gain change information acquisition submodule, used to acquire gain change information; the gain change information includes a plurality of signal gain values and their corresponding zeroing thresholds;
[0104] a target signal gain value determination submodule, configured to determine a target signal gain value from among the plurality of signal gain values;
[0105] The target zeroing threshold determination submodule is used to determine the target zeroing threshold corresponding to the target signal gain value.
[0106] In an optional embodiment, the target spreading code sequence generating module 503 includes:
[0107] A sequence index determination submodule, configured to determine a sequence index based on the target zeroing threshold and the initial spreading code sequence;
[0108] The target spreading code sequence generating submodule is used to set the spreading codes after the sequence index in the initial spreading code sequence to zero to generate a target spreading code sequence.
[0109] In an optional embodiment, the sequence index determination submodule includes:
[0110] A periodic code length determining unit, used to determine the periodic code length of the initial spread spectrum code sequence;
[0111] The sequence index determining unit is used to determine the sequence index according to the product of the target zeroing threshold and the periodic code length.
[0112] In an optional embodiment, the target digital spread spectrum signal generating module 504 includes:
[0113] A spread spectrum data generation submodule, used to generate spread spectrum data according to the target spread spectrum code sequence and the data code;
[0114] The digital spread spectrum signal generating submodule is used to modulate the spread spectrum signal according to the frequency of the carrier signal to generate a digital spread spectrum signal.
[0115] In an optional embodiment, the gain change information is generated by the following modules:
[0116] A first digital spread spectrum signal and threshold set acquisition module, used to acquire a first digital spread spectrum signal and a threshold set; the threshold set includes a plurality of zero-setting thresholds;
[0117] a signal gain value determining module, configured to set a portion of the spreading codes in the first spreading code sequence in the first digital spreading signal to zero according to each of the zeroing thresholds, to obtain a second digital spreading signal, and to determine a signal gain value according to the second digital spreading signal and the first digital spreading signal;
[0118] The gain change information generating module is used to generate gain change information according to each of the zeroing thresholds and the corresponding signal gain values.
[0119] In an optional embodiment, the signal gain value determination module includes:
[0120] A self-coherence integral value calculation submodule, used to calculate the self-coherence integral value of the first digital spread spectrum signal;
[0121] a mutual dry integral value calculation submodule, configured to calculate a mutual dry integral value of the first digital spread spectrum signal and the second digital spread spectrum signal;
[0122] The signal gain value calculation submodule is used to calculate the signal gain value by using a preset gain calculation formula, the self-coherence integral value and the mutual coherence integral value.
[0123] An embodiment of the present application provides a signal gain control device, and by using the device, each step in the aforementioned method embodiments can be implemented.
[0124] As for the device embodiment, since it is basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the description of the method embodiment part.
[0125] Reference Figure 6 , shows a schematic diagram of a terminal device provided in an embodiment of the present application. Figure 6 As shown, the terminal device 600 in the embodiment of the present application includes: a processor 610, a memory 620, and a computer program 621 stored in the memory 620 and executable on the processor 610. When the processor 610 executes the computer program 621, the steps in each embodiment of the above-mentioned signal gain control method are implemented, for example Figure 2Alternatively, when the processor 610 executes the computer program 621, the functions of each module / unit in the above-mentioned device embodiments are realized, for example Figure 4 Functions of modules 401 to 404 are shown.
[0126] Exemplarily, the computer program 621 may be divided into one or more modules / units, which are stored in the memory 620 and executed by the processor 610 to complete the present application. The one or more modules / units may be a series of computer program instruction segments capable of completing specific functions, which may be used to describe the execution process of the computer program 621 in the terminal device 600. For example, the computer program 621 may be divided into an initial spread spectrum code sequence acquisition module, an initial spread spectrum code sequence acquisition module, a target zeroing threshold determination module, and a target digital spread spectrum signal generation module, and the specific functions of each module are as follows:
[0127] An initial spread spectrum code sequence acquisition module, used to acquire an initial spread spectrum code sequence;
[0128] A target zeroing threshold determination module, used to determine a target zeroing threshold; the target zeroing threshold corresponds to a target signal gain value;
[0129] a target spreading code sequence generating module, configured to set part of the spreading codes in the initial spreading code sequence to zero according to the target zeroing threshold value, so as to generate a target spreading code sequence;
[0130] The target digital spread spectrum signal generating module is used to generate a target digital spread spectrum signal according to the target spread spectrum code sequence, a preset carrier signal and a data code.
[0131] The terminal device 600 may be the digital spread spectrum signal processing device in the above-mentioned embodiments. The terminal device 600 may include, but is not limited to, a processor 610 and a memory 620. Those skilled in the art may understand that Figure 6 It is only an example of the terminal device 600 and does not constitute a limitation of the terminal device 600. It may include more or fewer components than shown in the figure, or a combination of certain components, or different components. For example, the terminal device 600 may also include input and output devices, network access devices, buses, etc.
[0132] The processor 610 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.
[0133] The memory 620 may be an internal storage unit of the terminal device 600, such as a hard disk or memory of the terminal device 600. The memory 620 may also be an external storage device of the terminal device 600, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. equipped on the terminal device 600. Further, the memory 620 may also include both an internal storage unit of the terminal device 600 and an external storage device. The memory 620 is used to store the computer program 621 and other programs and data required by the terminal device 600. The memory 620 may also be used to temporarily store data that has been output or is to be output.
[0134] The embodiment of the present application further discloses a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the signal gain control method as described in the above-mentioned embodiments is implemented.
[0135] The embodiment of the present application further discloses a computer program product. When the computer program product is run on a computer, the computer is enabled to execute the signal gain control method described in the above-mentioned embodiments.
[0136] The above-described embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application is described in detail with reference to the above-mentioned embodiments, a person skilled in the art should understand that the technical solutions described in the above-mentioned embodiments can still be modified, or some of the technical features can be replaced by equivalents; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application, and should be included in the protection scope of the present application.
Claims
1. A signal gain control method, characterized in that: include: Obtaining an initial spreading code sequence; Determine target zeroing threshold; The target zeroing threshold corresponds to the target signal gain value; Setting part of the spreading codes in the initial spreading code sequence to zero according to the target zeroing threshold to generate a target spreading code sequence; A target digital spread spectrum signal is generated according to the target spread spectrum code sequence, a preset carrier signal and a data code.
2. The method according to claim 1, characterized in that The determining of the target zeroing threshold, wherein the target zeroing threshold corresponds to the target signal gain value, includes: Acquire gain change information; the gain change information includes multiple signal gain values and their corresponding zeroing thresholds; determining a target signal gain value among the plurality of signal gain values; A target zeroing threshold corresponding to the target signal gain value is determined.
3. The method according to claim 1, characterized in that The step of setting a portion of the spreading codes in the initial spreading code sequence to zero according to the target zeroing threshold to generate a target spreading code sequence includes: Determine a sequence index based on the target zeroing threshold and the initial spreading code sequence; The spreading codes located after the sequence index in the initial spreading code sequence are set to zero to generate a target spreading code sequence.
4. The method according to claim 3, characterized in that The determining a sequence index based on the target zeroing threshold and the initial spreading code sequence comprises: Determining a periodic code length of the initial spreading code sequence; A sequence index is determined according to a product of the target zeroing threshold and the periodic code length.
5. The method according to claim 1, characterized in that The step of generating a digital spread spectrum signal according to the target spread spectrum code sequence, a preset carrier signal and a data code comprises: generating spread spectrum data according to the target spread spectrum code sequence and the data code; The spread spectrum signal is modulated according to the frequency of the carrier signal to generate a digital spread spectrum signal.
6. The method according to claim 2, characterized in that The gain change information is generated by the following method: Acquire a first digital spread spectrum signal and a threshold set; the threshold set includes a plurality of zero-setting thresholds; For each of the zeroing thresholds, a portion of the spreading codes in the first spreading code sequence in the first digital spreading signal is set to zero according to the zeroing threshold to obtain a second digital spreading signal, and a signal gain value is determined according to the second digital spreading signal and the first digital spreading signal; Gain change information is generated according to each of the zeroing thresholds and the corresponding signal gain values.
7. The method according to claim 6, characterized in that The step of determining a signal gain value according to the second digital spread spectrum signal and the first digital spread spectrum signal comprises: Calculating a self-coherent integration value of the first digital spread spectrum signal; Calculating a mutual dry integral value of the first digital spread spectrum signal and the second digital spread spectrum signal; The signal gain value is calculated using a preset gain calculation formula, the self-coherence integral value and the mutual coherence integral value.
8. A signal gain control device, characterized in that: include: An initial spread spectrum code sequence acquisition module, used to acquire an initial spread spectrum code sequence; A target zeroing threshold determination module, used to determine a target zeroing threshold; The target zeroing threshold corresponds to the target signal gain value; a target spreading code sequence generating module, configured to set part of the spreading codes in the initial spreading code sequence to zero according to the target zeroing threshold value, so as to generate a target spreading code sequence; The target digital spread spectrum signal generating module is used to generate a target digital spread spectrum signal according to the target spread spectrum code sequence, a preset carrier signal and a data code.
9. A terminal device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the signal gain control method according to any one of claims 1 to 7 is implemented.
10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the signal gain control method according to any one of claims 1 to 7 is implemented.
