Disclosure of Invention
The invention provides a device and a method for monitoring power, which are used for solving the problem that the antenna power cannot be monitored conveniently and remotely in the prior art and improving the accuracy of antenna power monitoring.
In a first aspect, the present invention provides an apparatus for power monitoring, when an antenna is connected to a base station through a power divider, the apparatus being mounted between the power divider and the antenna, the apparatus comprising: the first radio frequency connector, the second radio frequency connector, the first load, the second load, the processing module, the first detection diode and the second detection diode, wherein:
one end of the first radio frequency connector is connected with the power divider, the other end of the first radio frequency connector is connected with one end of the second radio frequency connector through a first microstrip line, and the other end of the second radio frequency connector is connected with the antenna;
the positive pole of the first detection diode is connected with the first load through a second microstrip line, the negative pole of the first detection diode is connected with a first ADC pin of the processing module, the positive pole of the second detection diode is connected with the second load through a third microstrip line, the negative pole of the second detection diode is connected with a second ADC pin of the processing module, the first microstrip line and the second microstrip line form a first coupling structure, and the first microstrip line and the third microstrip line form a second coupling structure;
a first radio frequency signal entering a first radio frequency connector is input into the processing module through a first coupling structure and a first detection diode, and a second radio frequency signal entering a second radio frequency connector reaches a second detection diode through a second coupling structure and is input into the processing module;
the processing module is used for processing the first radio frequency signal and the second radio frequency signal to obtain the standing-wave ratio of the antenna.
Optionally, the processing module is an NB-IoT module or a LoRa module.
Optionally, the processing module is an NB-IoT module, and the apparatus further comprises an NB-IoT antenna:
the NB-IoT module sends the standing-wave ratio to user terminal equipment through the NB-IoT antenna, so that the user terminal equipment determines the working condition of the antenna in real time through the standing-wave ratio; wherein, the standing wave ratio characterizes the working condition of the antenna.
Optionally, the processing module is a LoRa module, and the device further includes a LoRa antenna:
the LoRa module sends the standing-wave ratio to user terminal equipment through the LoRa antenna, so that the user terminal equipment determines the working condition of the antenna in real time through the standing-wave ratio; wherein, the standing wave ratio characterizes the working condition of the antenna.
Optionally, the first rf connector and the second rf connector are N-type rf connectors.
Optionally, the first rf connector and the second rf connector are of other types than N-type rf connectors, and the apparatus further includes:
one end of the first conversion connector is connected with the first radio frequency connector, and the other end of the first conversion connector is connected with the power divider;
and one end of the second conversion connector is connected with the second radio frequency connector, and the other end of the second conversion connector is connected with the power divider.
Optionally, the processing module is further configured to: sampling the voltage values of the first detection diode and the second detection diode under different power values, and calculating an average value; calculating the ratio of the average value to the temperature at different temperatures, and calculating the average value of the ratio; calculating corrected voltage values of the first detection diode and the second detection diode through the average value of the ratio and the voltage received by the processing module; and calculating the corrected standing wave ratio through the corrected voltage value.
Optionally, the first detection diode and the second detection diode are passive detection diodes.
Optionally, the power supply of the processing module is a button cell.
Optionally, the first load and the second load are 50 ohm resistive loads.
In a second aspect, the present invention also provides a method for power monitoring based on the apparatus of the first aspect, the method comprising:
correspondingly converting the first radio frequency signal and the second radio frequency signal into a first digital signal and a second digital signal;
determining a first power value and a second power value corresponding to the first digital signal and the second digital signal respectively;
and obtaining the standing wave ratio of the antenna according to the first power value and the second power value.
Optionally, when the first radio frequency signal and the second radio frequency signal are analog signals, before converting the first radio frequency signal and the second radio frequency signal into the first digital signal and the second digital signal, the method further includes:
determining a temperature interval corresponding to the current temperature value of the environment of the device;
inquiring the corresponding slope of the temperature interval in a preset data table; the data table represents the corresponding relation of detection voltage, power value and slope at different temperatures; the slope is the average value of the ratio of the temperature to the detection voltage;
calculating to obtain a corrected analog voltage based on the slope corresponding to the temperature interval and the first radio frequency signal and the second radio frequency signal;
updating the first radio frequency signal and the second radio frequency signal based on the modified analog voltage.
Optionally, the obtaining the standing wave ratio of the antenna according to the first power value and the second power value includes:
querying said data table to determine that said modified analog voltage is between-a first detected voltage and a second detected voltage;
inquiring a first correction power value corresponding to the first detection voltage and a second correction power value corresponding to the second detection voltage in the data table;
calculating the first correction power value and the second correction power value based on a uniform division method to obtain a third correction power value;
and calculating the corrected standing wave ratio based on the third correction power value.
The invention has the following beneficial effects:
the power detection device is connected with the antenna and the power divider through the radio frequency connector, the processing module in the power detection device processes the input radio frequency signals to obtain the standing-wave ratio corresponding to the antenna, and then the standing-wave ratio is sent to the user terminal equipment through the base station, so that a user can monitor the power of the antenna in real time. Once the indoor signal distribution system fails, the place where the fault occurs can be rapidly determined and maintained in time through the power monitoring device and the method. In addition, the processing module of the power monitoring device also adopts a temperature compensation algorithm, so that the problem of larger power reading error under different temperature conditions is effectively solved, and the accuracy of power monitoring is improved.
Detailed Description
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the apparatus for monitoring power in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are some embodiments of the present invention, but not all embodiments of the present invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
Example 1
As shown in fig. 2, an embodiment of the present invention provides a device for monitoring power, which is installed between a power divider 200 and an antenna 201 when the antenna is connected to a base station through the power divider, and includes: a first radio frequency connector 202, a second radio frequency connector 203, a first load 204, a second load 205, a processing module 206, a first detection diode 207, and a second detection diode 208, wherein:
one end of the first radio frequency connector 202 is connected with the power divider 200, the other end of the first radio frequency connector is connected with one end of the second radio frequency connector 203 through a first microstrip line 209, and the other end of the second radio frequency connector 203 is connected with the antenna 201;
the positive pole of the first detection diode 207 is connected to the first load 204 through a second microstrip line 210, the negative pole of the first detection diode 207 is connected to a first ADC pin of the processing module 206, the positive pole of the second detection diode 208 is connected to the second load 205 through a third microstrip line, the negative pole of the second detection diode is connected to a second ADC pin of the processing module 206, the first microstrip line 209 and the second microstrip line 210 form a first coupling structure, and the first microstrip line 209 and the third microstrip line 211 form a second coupling structure;
in the present embodiment, the load is preferably a 50 ohm resistive load, that is:
optionally, the first load and the second load are 50 ohm resistive loads.
A first radio frequency signal entering the first radio frequency connector 202 is input into the processing module 206 through a first coupling structure and a first detection diode 207, and a second radio frequency signal entering the second radio frequency connector 203 is input into the processing module 206 through a second coupling structure to a second detection diode 208;
the processing module 206 is configured to process the first radio frequency signal and the second radio frequency signal to obtain a standing wave ratio of the antenna 201.
Specifically, when the base station has a radio frequency signal, after passing through the radio frequency feeder line and the power divider, the radio frequency signal enters the radio frequency connector 202, passes through the microstrip line 209, and the detection diode 207 detects the radio frequency signal, and outputs an analog voltage value corresponding to the radio frequency signal, and then the analog voltage value enters the processing module 206, where the processing module 206 may specifically be an NB-IoT module (Narrow Band Internet of Things, cellular-based narrowband internet of things) or a LoRa module.
As shown in fig. 3, taking the processing module as an NB-IoT module as an example, the Analog voltage value V1 obtained through the microstrip line 309 and the detector diode 307 is input to an ADC (Analog-to-Digital Converter) module of the NB-IoT module 306 through an ADC1 pin of the NB-IoT module 306, and the Analog voltage value V1 is converted into a digital signal. The NB-IoT module 306 calculates the digital signal to obtain the rf power into the power monitoring device, with the magnitude P1.
The radio frequency signal of the antenna enters the detection diode 308 through the radio frequency connector 303, and outputs an analog voltage value V2 corresponding to the radio frequency signal, the analog voltage value V2 is input to the ADC module of the NB-IoT module 306 through the ADC2 pin of the NB-IoT module 306 to convert the analog voltage V2 into a digital signal, and the NB-IoT module 306 calculates the digital signal to obtain the radio frequency power entering the power monitoring device, wherein the magnitude of the radio frequency power is P2.
After obtaining P1 and P2, NB-IoT module 306 calculates the standing wave ratio of the antenna port according to the following formula:
the reflectance calculation formula: k=p1/P2;
standing wave ratio calculation formula of antenna port: vswr= (1+k)/(1-K).
Specifically, the user can set the coupling power of the first coupling structure and the second coupling structure according to the requirement, for example, set that the first coupling structure and the second coupling structure respectively couple signals 20dB smaller than the signals transmitted by the first microstrip line 209 into the first detection diode 207 and the second detection diode 208. Because the coupling degree is 20dB, the signal transmitted by the first microstrip line 209 cannot be greatly attenuated after the embodiment of the invention is added in the indoor distribution system.
It should be noted that the first load 204 and the second load 205 are used to absorb the isolation power of the coupled microstrip line, that is, the first load 204 and the second load 205 are used to prevent the coupled power from reflecting, and influence the signals input to the first detection diode 207 and the second detection diode 208, so as to cause calculation errors of standing wave ratio.
It should be noted that the specific types of the first detection diode and the second detection diode are not limited by the present invention. In addition, the invention can also comprise a shell, wherein the first detection diode, the second detection diode, the first load, the second load and the processing module are accommodated in the shell.
Further, as shown in fig. 3, when the processing module is NB-IoT module 306, the apparatus further comprises NB-IoT antenna 313:
the NB-IoT module 306 sends the standing-wave ratio to a user terminal device through the NB-IoT antenna 313, so that the user terminal device determines the working condition of the antenna in real time through the standing-wave ratio; wherein, the standing wave ratio characterizes the working condition of the antenna.
Specifically, the user terminal device may be a mobile communication device such as a mobile phone, a pad, etc., but the present invention does not limit the type of the user terminal device. Besides standing wave ratio, the information received by the user terminal equipment can also include coding information, temperature information, power information and the like of the device.
For example, the NB-IoT module 306 modulates the output power P1, the standing wave ratio VSWR, the number information of the NB-IoT module 306, and the device temperature information onto the NB-IoT signal through an F-OFDM (Orthogonal Frequency Division Multiplexing ) modulation scheme, and finally transmits the modulated information to the outside of the device through the NB-IoT antenna 313. The NB-IoT base station outside the device receives the NB-IoT signal and returns the NB-IoT signal to the mobile communication network of the operator, and engineering maintenance personnel can remotely access to the mobile communication network of the operator through equipment such as a mobile phone, so that the output power value and standing wave ratio condition of each antenna port can be remotely mastered. When the engineering maintenance personnel find that the output power value P1 of the device corresponding to certain number information is lower than the normal output power, the engineering maintenance personnel can check whether the corresponding base station works normally or not. Further, if the standing-wave ratio of the antenna is poor, for example, the standing-wave ratio is greater than or equal to a set threshold, then engineering maintenance personnel can find the antenna to find out the problem in a targeted manner.
It should be noted that, the above-mentioned set threshold may be set to a value of 3, but the present invention is not limited to the setting of the set threshold, and the user may set the set threshold according to the needs. Meanwhile, as shown in the apparatus of fig. 3, the base station transmitting the standing wave ratio to the user terminal does not need to be separately established by the user, and can directly use the base station established by the operator.
On the other hand, as shown in fig. 4, the processing module is a LoRa module 406, and the apparatus further includes a LoRa antenna 413:
the loRa module 406 sends the standing-wave ratio to the user terminal equipment through the loRa antenna 413, so that the user terminal equipment determines the working condition of the antenna in real time through the standing-wave ratio; wherein, the standing wave ratio characterizes the working condition of the antenna.
It should be noted that, when the processing module is a LoRa module, the base station for transmitting the standing-wave ratio to the user terminal device needs to be established separately by the user, and the base station established by the operator cannot be directly used.
Furthermore, the interface size of the N-type radio frequency connector is matched with the size of the radio frequency feeder line, so that the N-type radio frequency connector can be directly installed and used, and signal transmission is realized. Therefore, the first rf connector and the second rf connector are preferably N-type rf connectors.
Of course, in a practical use environment, the first rf connector 502 and the second rf connector 503 may be other types than N-type rf connectors, and it should be noted that the size of the rf connectors other than N-type rf connectors is not matched with the size of the rf feeder, so an adapter needs to be added, and the size of the adapter is matched with the size of the rf feeder. After adding the adapter, the device can be connected with the power divider and the antenna through the adapter. When other types of radio frequency connectors than the N type radio frequency connector are adopted, the specific structure of the device is shown in fig. 5, and the device further comprises:
a first conversion connector 512, wherein one end of the first conversion connector 512 is connected to the first rf connector 502, and the other end is connected to the power divider 500;
and one end of the second switching connector 513 is connected with the second radio frequency connector 503, and the other end is connected with the power divider 500.
Further, in order to solve the problem of inaccurate detection caused by the difference of the environmental temperature, an algorithm for performing temperature compensation on the voltage value corresponding to the signal is required, so the processing module is preferably further configured to: sampling the voltage values of the first detection diode and the second detection diode under different power values, and calculating an average value; calculating the ratio of the average value to the temperature at different temperatures, and calculating the average value of the ratio; calculating corrected voltage values of the first detection diode and the second detection diode through the average value of the ratio and the voltage value received by the processing module; and calculating the corrected standing wave ratio through the corrected voltage value.
Specifically, first, the voltage values of the first detection diode and the second detection diode are sampled under different power values, for example, 200 data may be collected, and then the voltage values under each power are averaged to obtain the data shown in fig. 6. Calculating to obtain the ratio of the average voltage value to the temperature at different temperatures to obtain the slopes of the voltage in the high temperature region and the low temperature region, and averaging the slopes of the high temperature region and the low temperature region to obtain the average slopes of the high temperature region and the low temperature region as 0.000131V/. Degree.C and 0.000823V/. Degree.C respectively
Let the voltage value read by the processing module be V, and the temperature at this time be T. Firstly, judging whether T belongs to the range of-40 ℃ to 25 ℃ or 25 ℃ to 60 ℃. If the temperature is exactly 25 ℃, the temperature is defaults to the range of-40 ℃ to 25 ℃. Assuming that in this interval of-40 ℃ to 25 ℃, V0 at 25 ℃ is calculated according to v0+ (25-T) 0.000823 =v, then the table shown in fig. 6 is used to search to obtain that the V0 is between V3 and V4, and the input power at this time is finally calculated by a division method between the powers P3 and P4 as follows: p3+ (V0-V3) P4/(V4-V3).
For example, the voltage value read by the processing module is 0.3V, when the temperature is 45 ℃, the processing module determines that the voltage value is in a high temperature range, and finally calculates a corrected voltage value according to v0=0.3v- (25 ℃ -45 ℃) 0.000131V/°c= 0.29738V.
It should be noted that, the temperature compensation algorithm can enable the power monitoring device to accurately detect in different temperature ranges.
Further, the first detection diode and the second detection diode are passive detection diodes.
It should be noted that, in the embodiment of the present invention, the type of the passive diode may be HSMS2850, but the present invention is not limited to the specific type of the passive detection diode.
Because the passive detection diode does not need to be independently powered and does not consume energy, the whole power consumption of the power monitoring device is low, and therefore, the power supply of the processing module is preferably a button battery.
It is worth to say that the button cell is small in size, which is very favorable for the miniaturization of the power monitoring device. In addition, in the embodiment of the invention, the model of the button cell can be CR2477, but the invention is not limited to the specific model of the button cell used.
Example two
As shown in fig. 7, a second embodiment of the present invention provides a method for monitoring power of a device according to the first embodiment of the present invention, where the method includes:
s701, converting the first radio frequency signal and the second radio frequency signal into a first digital signal and a second digital signal correspondingly;
the first radio frequency signal and the second radio frequency signal are signals output by the first detection diode and the second detection diode in the device according to the embodiment of the invention.
S702, determining a first power value and a second power value respectively corresponding to the first digital signal and the second digital signal;
the method for determining the power value corresponding to the digital signal is the same as the method in the prior art, and the invention is not repeated.
S703, obtaining the standing wave ratio of the antenna according to the first power value and the second power value.
Specifically, the process of obtaining the standing wave ratio of the antenna according to the first power value and the second power value is as follows:
the reflectance calculation formula: k=p1/P2;
standing wave ratio calculation formula of antenna: vswr= (1+k)/(1-K).
Wherein, the first power value is represented by P1, the second power value is represented by P2, the reflection coefficient is calculated by the ratio of P1 to P2, then the standing-wave ratio of the antenna is calculated according to the relation between the standing-wave ratio and the reflection coefficient, and the user can monitor the antenna by the standing-wave ratio of the antenna.
Further, as shown in fig. 8, when the first radio frequency signal and the second radio frequency signal are analog signals, the method further includes, before S701:
s710, determining a temperature interval corresponding to the current temperature value of the environment of the device;
the device is specifically a power monitoring device in the first embodiment of the present invention, and the current temperature value of the environment of the device is specifically the temperature of the processing module in the power monitoring device in the first embodiment of the present invention. The temperature range is divided into a high temperature range and a low temperature range. The high temperature range can be 25-60 ℃, the low temperature range can be-40-25 ℃, if the temperature value is just 25 ℃, the temperature value can be classified into the high temperature range or the low temperature range, but the temperature value is classified into the low temperature range by default. It should be noted that the present invention does not limit the critical value of the temperature interval, and the user can adjust the critical value of the temperature interval according to the self-demand.
S711, inquiring the slope corresponding to the temperature interval in a preset data table; as shown in fig. 6, the data table represents the correspondence of the detection voltage, the power value and the slope at different temperatures; the slope is the average value of the ratio of the temperature to the detection voltage;
specifically, in the second embodiment of the present invention, sample data of 200 detection voltages are collected at different temperatures, and the slopes of the high temperature region and the low temperature region are determined to be 0.000131V/°c and 0.000823V/°c, respectively. The invention does not limit the numerical value of the slopes of the high temperature interval and the low temperature interval, and a user can automatically calculate and determine the slopes of the high temperature interval and the low temperature interval according to sample data acquired as required.
S712, calculating to obtain a corrected analog voltage based on the slope corresponding to the temperature interval and the first radio frequency signal and the second radio frequency signal;
for example, the voltage value corresponding to the first rf signal is 0.3V, when the temperature is 45 ℃, it is determined that the first rf signal is in a high temperature range, and, taking the high temperature range of 25 ℃ to 60 ℃ as an example, 25 ℃ or 60 ℃ may be taken as a temperature reference value, and then the voltage value corresponding to the corrected analog voltage is 0.29738V according to the formula v0=0.3v- (25 ℃ to 45 ℃) 0.000131V/°c by calculating the temperature reference value.
S713, updating the first radio frequency signal and the second radio frequency signal based on the corrected analog voltage.
Further, as shown in fig. 9, based on a preset data table, obtaining the standing wave ratio of the antenna according to the first power value and the second power value specifically includes:
s720, inquiring the data table to determine that the corrected analog voltage is between a first detection voltage and a second detection voltage;
for example, the voltage value corresponding to the corrected analog voltage obtained above is 0.29738V, and this voltage value is between 0.2765V and 0.3174V by looking up column B of fig. 6.
S721, inquiring a first correction power value corresponding to the first detection voltage and a second correction power value corresponding to the second detection voltage in the data table;
for example, when corrected voltage values are 0.2765V and 0.3174V, a power corresponding to 0.2765V of 0dBm and a power corresponding to 0.3174V of 1dBm are obtained by looking up the first column of fig. 6.
S722, calculating the first correction power value and the second correction power value to obtain a third correction power value based on a uniform division method;
for example, after obtaining two values of 0dBm and 1dBm, the input power at this time is finally obtained by a division method as follows: 0dbm+ (0.29738V-0.2765V) 1 dBm/(0.3174V-0.2765V) =0.51 dBm
S723, calculating the corrected standing wave ratio based on the third correction power value.
It should be noted that, the power monitoring method according to the second embodiment of the present invention may be implemented by the processing module in the device according to the first embodiment of the present invention.
The power detection device is connected with the antenna and the power divider through the radio frequency connector, the processing module in the power detection device processes the input radio frequency signals to obtain the standing-wave ratio corresponding to the antenna, and then the standing-wave ratio is sent to the user terminal equipment through the base station, so that a user can monitor the power of the antenna in real time. Once the indoor signal distribution system fails, the place where the fault occurs can be rapidly determined and maintained in time through the power monitoring device and the method. In addition, the processing module of the power monitoring device also adopts a temperature compensation algorithm, so that the problem of larger power reading error under different temperature conditions is effectively solved, and the accuracy of power monitoring is improved.
It will be apparent to those skilled in the art that various modifications and variations can be made to the present invention without departing from the spirit or scope of the invention. Thus, it is intended that the present invention also include such modifications and alterations insofar as they come within the scope of the appended claims or the equivalents thereof.