Wireless channel air interface utilization rate detection method
By capturing and analyzing the data packets of the wireless channel and calculating its air interface utilization, it solves the problems of high hardware detection cost and strict data requirements in the existing technology, and realizes a low-cost, easy-to-use wireless channel air interface utilization detection method.
Patent Information
- Application Number
- CN202310856984.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-13
- Publication Date
- 2025-01-14
AI Technical Summary
In the prior art, hardware detection costs are high, complex and has strict data requirements, making it difficult to effectively obtain wireless channel air interface utilization in actual scenarios.
By continuously capturing data packets of each frame of the wireless channel within a set time period, the duration of the data frame and the transmission time of other types of frames are determined and calculated, and the wireless channel air interface utilization is calculated after accumulating the total time.
It realizes the detection of wireless channel air interface utilization, avoids the use of additional hardware and strict requirements on data, and is low-cost, simple and easy to use.
Smart Images

Figure CN119316865A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the field of wireless transmission, and in particular to a method for detecting air interface utilization of a wireless channel. Background Art
[0002] In the prior art, the channel air interface utilization is usually obtained based on statistical prediction models such as hardware detection or expert knowledge. Chinese patent document CN115514439A discloses a channel air interface utilization prediction method, system, electronic device and medium. The method includes: obtaining an air interface utilization time series, and preprocessing it to obtain a preprocessed time series; decomposing the preprocessed time series into multiple IMF components and a Res component through an EMD algorithm; dividing the multiple IMF components into high-frequency components and low-frequency components respectively, and superimposing and combining the low-frequency components and the Res components to obtain a combined component; constructing a CNN-LSTM model, and inputting the high-frequency components and the combined components into the CNN-LSTM model for processing, and correspondingly obtaining multiple component prediction values; superimposing the multiple component prediction values to obtain the air interface utilization prediction result of the air interface utilization time series.
[0003] However, in the actual use of the method of CN115514439A, the following problems were found: the hardware detection cost is high, the difficulty is great, the data processing is complex, and the installation and maintenance personnel are required to have professional skills and knowledge. The data model prediction has some strict requirements for the data of air interface utilization, usually requiring the data to have seasonality, periodicity, etc. These requirements are difficult to meet in actual scenarios, and the accuracy of the model also has certain limitations. Summary of the invention
[0004] The present invention provides a method for detecting air interface utilization of a wireless channel, which does not require the use of additional hardware and does not require strict requirements on detection data, has low implementation cost, and is simple and easy to use.
[0005] The present invention provides the following technical solutions:
[0006] A method for detecting air interface utilization of a wireless channel, the method comprising:
[0007] S10: continuously capture each frame data packet of the wireless channel within a set time period;
[0008] S20: Determine the type of each captured frame data packet. If the type of the data packet is a data frame, obtain the duration of the data frame from the duration field of the data frame. If the type of the data packet is a frame of another type other than a data frame, obtain the transmission rate of the frame of another type from the header file of the frame of another type, and calculate the transmission time of the frame of another type according to the data length of the frame of another type and its transmission rate.
[0009] S30: summing the duration of all data frames and the transmission time of all other types of frames to obtain a cumulative total time;
[0010] S40: Calculate the air interface utilization rate of the wireless channel according to the accumulated total time and the set time period.
[0011] Further, the wireless channel is a WiFi channel, and S10 includes:
[0012] S11: Switch the WiFi module to monitoring mode to capture each frame of data packets transmitted via WiFi in the wireless network;
[0013] S12: Perform channel switching operation on the wireless network card to capture frame data packets transmitted through WiFi in the 2.4g channel and the 5g channel in turn.
[0014] Furthermore, the transmission time is calculated according to the following formula:
[0015] Transmission time = data length / transmission rate.
[0016] Furthermore, the wireless channel air interface utilization is calculated according to the following formula:
[0017] Wireless channel air interface utilization = accumulated total time / set time period*100%.
[0018] The present invention has the following beneficial effects:
[0019] The wireless channel air interface utilization detection method proposed by the present invention can calculate the wireless channel air interface utilization by analyzing wireless data packets, without using additional hardware and without strict requirements on detection data. It has low implementation cost and is simple and easy to use. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 The present invention is a flow chart of a method for detecting air interface utilization of a wireless channel. DETAILED DESCRIPTION
[0021] In order to make the technical problems, technical solutions and advantages to be solved by the present invention more clear, a detailed description will be given below with reference to the accompanying drawings and specific embodiments.
[0022] The present invention provides a method for detecting air interface utilization of a wireless channel. In the embodiment of the present invention, a wireless channel is described as WiFi (Wireless Fidelity) as an example. Figure 1 As shown, the method includes:
[0023] S10: continuously capture each frame data packet of the wireless channel within a set time period.
[0024] In an example, the specific implementation of this step includes:
[0025] S11: Switch the WiFi module to monitoring mode to capture each frame of data packets transmitted via WiFi in the wireless network.
[0026] S12: Perform channel switching operation on the wireless network card to capture frame data packets transmitted through WiFi in the 2.4g channel and the 5g channel in turn.
[0027] The present invention first sets the working mode of the WiFi802.11 module, switches the WiFi module to the monitoring mode, and captures WiFi data packets in the wireless network. In the monitoring mode, the WiFi module can only receive data but cannot send data. Secondly, the wireless network card is switched to a channel, and data packets transmitted through WiFi in the 2.4g channel and the 5g channel are captured in turn.
[0028] S20: Determine the type of each captured frame of data packets. If the type of the data packets is a data frame, obtain the duration of the data frame from the duration field of the data frame.
[0029] When the data packet type is a data frame, the data frame header is analyzed. The WiFi802.11 data frame header contains field information such as frame control field, duration and ID bit, receiving end MAC address, sending end MAC address, etc., and the duration field (i.e., duration field) is obtained.
[0030] The format of the data frame header is as follows:
[0031]
[0032] If the type of the data packet is other types of frames other than data frames (such as Beacon frames, RTS, CTS and other frame types), the transmission rate of the other types of frames is obtained from the header files of the other types of frames, and the transmission time of the other types of frames is calculated based on the data length of the other types of frames and their transmission rate.
[0033] When the data packet is a frame of other types other than a data frame, analyze the header file in the WiFi data packet, which contains the identification bit, version number, regional time, precise timestamp, maximum length of the data packet, and link layer type (Link-type). According to the link layer type, parse the data of type Radio Tap. Analyze the Radio Tap Header. The Radio tap Header is a listening header belonging to the WiFi802.11 standard. The header information contains physical layer information such as signal level, noise level, and transmission rate (Data Rate). After analysis, obtain the transmission rate. And calculate the transmission time according to the formula: Transmission time = data length / transmission rate.
[0034] The format of the Radio tap Header is as follows:
[0035]
[0036] S30: Sum the duration of all data frames and the transmission time of all other types of frames to obtain a cumulative total time.
[0037] S40: Calculate the air interface utilization rate of the wireless channel according to the accumulated total time and the set time period.
[0038] The calculation formula is: wireless channel air interface utilization = accumulated total time / set time period*100%.
[0039] For example, a data packet is captured within a set time period of 110ms, and the duration field of the data frame type is analyzed, and the cumulative occupancy time is 50ms. For other types of frames, such as Beacon frames, RTS frames, CTS frames, etc., the transmission time is calculated, and the cumulative total transmission time is 10ms. The calculated channel utilization is (50ms+10ms) / 110ms*100%=54%.
[0040] The wireless channel air interface utilization detection method proposed by the present invention can calculate the wireless channel air interface utilization by analyzing wireless data packets, without using additional hardware and without strict requirements on detection data. It has low implementation cost and is simple and easy to use.
[0041] The above is a preferred embodiment of the present invention. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present invention. These improvements and modifications should also be regarded as the scope of protection of the present invention.
Claims
1. A method for detecting air interface utilization of a wireless channel, characterized in that: The method comprises: S10: continuously capture each frame data packet of the wireless channel within a set time period; S20: Determine the type of each captured frame data packet. If the type of the data packet is a data frame, obtain the duration of the data frame from the duration field of the data frame. If the type of the data packet is a frame of another type other than a data frame, obtain the transmission rate of the frame of another type from the header file of the frame of another type, and calculate the transmission time of the frame of another type according to the data length of the frame of another type and its transmission rate. S30: summing the duration of all data frames and the transmission time of all other types of frames to obtain a cumulative total time; S40: Calculate the air interface utilization rate of the wireless channel according to the accumulated total time and the set time period.
2. The method for detecting air interface utilization of a wireless channel according to claim 1, characterized in that: The wireless channel is a WiFi channel, and S10 includes: S11: Switch the WiFi module to monitoring mode to capture each frame of data packets transmitted via WiFi in the wireless network; S12: Perform channel switching operation on the wireless network card to capture frame data packets transmitted through WiFi in the 2.4g channel and the 5g channel in turn.
3. The method for detecting air interface utilization of a wireless channel according to claim 1, characterized in that: The transmission time is calculated according to the following formula: Transmission time = data length / transmission rate.
4. The method for detecting air interface utilization of a wireless channel according to any one of claims 1 to 3, characterized in that: The wireless channel air interface utilization is calculated according to the following formula: Wireless channel air interface utilization = accumulated total time / set time period*100%.
Citation Information
Patent Citations
Channel air interface utilization rate prediction method and system, electronic equipment and medium
CN115514439A