Short wave data link message polling method based on state control and response
By adopting a polling method based on state control and response in short-wave data link communication, the time of each stage in the polling process is optimized, and the problem of insufficient polling interval time is solved, and more efficient data link message polling is achieved. Improves the reliability and efficiency of the system.
Patent Information
- Application Number
- CN202411269221.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-11
- Publication Date
- 2025-01-03
AI Technical Summary
In the existing short-wave data link communication, there is insufficient estimation of the polling interval time, which leads to a fixed time waiting for the message when it does not reach the maximum length, which affects the polling efficiency.
Using the short-wave data link message polling method based on state control and response, by initializing the polling system, setting a timer and state transfer mechanism, optimizing the time of each stage in the polling process, ensuring seamless connection and efficiency improvement of the polling process .
Without adding additional facilities, the polling efficiency of data link messages is effectively improved, the polling time is reduced, and the reliability and efficiency of the system are improved.
Smart Images

Figure CN119254391A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to a shortwave data link message polling method, in particular to a method based on state control and response, belonging to the technical field of shortwave data link messages. Background Art
[0002] At present, shortwave data link communication mostly uses polling protocol as the access protocol for Class I and Class II stations. Class I stations are responsible for initiating link control commands, and Class II stations parse the commands of Class I stations and perform corresponding operations. When a Class I station uses the polling protocol to initiate a control command, it will generate a polling roll call list based on the Class II station information in the polling group that has established a link. Class I stations will initiate roll calls to each Class II station in sequence according to the roll call list. The roll call information will ask the Class II station whether there is a data link message that needs to be transmitted to the Class I station. All Class II stations in the roll call list will receive this roll call message and decide whether to respond by comparing the received address code with their own address code. If the addresses are consistent, the Class II station needs to respond within the specified time; if there is no response after the timeout, in order to improve the reliability of the transmission, the Class I station will resend the roll call message. After a period of time, regardless of whether the current Class II station responds, the Class I station will call the next Class II station in the roll call sequence. The time from the first-class station initiating the roll call to the complete receipt of the response message from the second-class station is called a poll. The current common practice is to estimate the minimum time for a first-class station to call two second-class stations based on experience as the polling interval. This method is simple to implement, but it has some shortcomings. The estimated polling interval is the minimum time under the maximum transmission length, but in many cases, the roll call message will not reach the maximum length, and the roll call and response will end early. At this time, it is also necessary to wait for a fixed time to enter the next round of polling. This paper proposes a shortwave data link message polling method based on state control and response, which can effectively improve the polling efficiency of data link messages without adding additional facilities. Summary of the invention
[0003] Purpose of the invention: The purpose of the present invention is to provide a shortwave data link message polling method based on state control and response, which can improve the efficiency of data link message polling.
[0004] Technical solution: The shortwave data link message polling method based on state control and response of the present invention comprises:
[0005] (1) Initialize the polling system, set the polling entry switch including the on and off states, turn on the polling entry switch, and start the timer tmr1 with a timeout interval of T1;
[0006] (2) When the polling entry switch is turned on, when the timer tmr1 times out, the first-class station initiates polling to the second-class station, and the polling system state at this time is defined as polling sending, and the polling entry switch is turned off, and the start timeout interval is Ts ′ nd Timer tmr2;
[0007] (3) When the polling system receives the sending end information of a type of station before the timer tmr2 times out, the state of the polling system is changed to polling sending end, the timer tmr2 is stopped, and the timeout interval is T ′ wait Timer tmr3;
[0008] (4) When the polling system receives a response message from a Class II station before timer tmr3 times out, the polling system changes its state to waiting for the response to be received, stops timer tmr3, and starts a timeout interval of T r ′ cv Timer tmr4;
[0009] (5) When the polling system receives the stop code of the response data of the Class II station within the timeout period of timer tmr4, the state of the polling system is changed to response end, the timer tmr4 is stopped, the current round of polling ends, the polling entry switch is turned on, and the system returns to step (2) to prepare for the next round of polling.
[0010] Furthermore, the timeout interval T1 of the timer tmr1 is less than 10 ms.
[0011] Furthermore, when the polling entry switch is in the off state, it does not respond to the timer tmr1 timeout signal.
[0012] Furthermore, in step (3), when the polling system does not receive the sending end information of a type of station before tmr2 times out, the timer tmr2 is stopped after tmr2 times out, and the timeout interval is T ′ wait Timer tmr3.
[0013] Furthermore, in step (4), when the polling system does not receive a response message sent by the second-class station before tmr3 times out, the timer tmr3 is stopped after tmr3 times out, and the timeout interval is T r ′ cv Timer tmr4.
[0014] Furthermore, in step (5), when the polling system does not receive a response message sent by the Class II station before TMR4 times out, timer TMR4 is stopped after TMR4 times out, this round of polling ends, the polling entry switch is turned on, and the system returns to step (2) to prepare for the next round of polling.
[0015] Furthermore, it also includes: if no response message is received from the Class II station before TMR4 times out, after TMR4 times out and timer TMR4 is stopped, before the end of this round of polling, it is determined whether this round of polling has been retransmitted; if not, it returns to step (2) to retransmit this round of polling.
[0016] Furthermore, the timeout interval T of the timer tmr2 is s ′ nd >a, where a is the preset threshold.
[0017] Furthermore, the timeout interval T of the timer tmr3 is ′ wait >b, where b is the preset threshold.
[0018] Furthermore, the timeout interval T of the timer tmr4 is r ′ cv >c, where c is the preset threshold.
[0019] Beneficial effects: Compared with the prior art, the present invention proposes a shortwave data link message polling method based on state control and response, which can effectively improve the polling efficiency of data link messages without adding additional facilities. BRIEF DESCRIPTION OF THE DRAWINGS
[0020] Figure 1 A schematic diagram of the composition of a shortwave data link system according to an embodiment of the present invention;
[0021] Figure 2 A schematic diagram of state transition of an embodiment of the present invention;
[0022] Figure 3 The figure is a flow chart of a method according to an embodiment of the present invention. DETAILED DESCRIPTION
[0023] The principles and features of the present invention are described below in conjunction with the accompanying drawings.
[0024] The communication between shortwave data links adopts polling control protocol. There is a one-to-many relationship between Class I stations and Class II stations. Class I stations send data link messages to Class II stations via shortwave radio through transmitters. When Class II stations send responses, they also send data link messages to Class I stations via shortwave radio through transmitters. The composition relationship of the system is as follows: Figure 1 shown.
[0025] For a polling roll call, the first-class station initiates the polling roll call, and the second-class station named initiates a response after receiving the message. After the first-class station receives the response message, the polling ends. Figure 2 .
[0026] From the start of polling to the end of this round of polling, it can be divided into the sum of several stages: Theoretical polling transmission time T snd , Theoretical waiting time for response T wait , Theoretical response receiving time T rcv and the theoretical state update time T update . T snd It is the time taken by the transmitter to send the data link message to the Class II station. wait It is the time from when the first-class station finishes sending to when it starts receiving the response from the second-class station. rcv It is the time from when a Class I station starts to receive the response from a Class II station to when it completes the reception. update It is the time from when a Class I station receives the response from a Class II station to when it initiates the next round of polling.
[0027] Ideally, T snd It is related to the transmission rate and message length. For a poll with a certain rate and length, T snd It is a fixed value regardless of the polling method used. wait and T rcv Involving air interface transmission and information processing time of Class II stations, T wait It includes the time of two air interface wireless transmissions plus the time of the second-class station processing the roll call message and sending a response; T rcv Includes the time for the Class II station to transmit the data link response message through the air interface once or multiple times. These two parts of time are also independent of the polling method. update This is the time that a station can actively control, and this time should be as small as possible.
[0028] Under ideal polling conditions, the theoretical polling time T is met:
[0029] T=T snd +T wait +T rcv +T update
[0030] When used in engineering, it is impossible to accurately determine T snd , T wait , T rcv The actual polling transmission time T of the first three stages is usually estimated based on different rates and message lengths. s ′ nd , actual waiting time for response T ′ wait , actual response receiving time T r ′ cv ,satisfy:
[0031] T s′ nd =T snd +Δ snd ,Δ snd ≥0
[0032] T ′ wait =T wait +Δ wait ,Δ wait ≥0
[0033] T r ′ cv =T rcv +Δ rcv ,Δ rcv ≥0
[0034] Among them, Δ snd is the difference between the actual polling transmission time and the theoretical polling transmission time, Δ wait is the difference between the actual waiting time for response and the theoretical waiting time for response, Δ rcv It is the difference between the actual response receiving time and the theoretical response receiving time.
[0035] As attached Figure 3 As shown, the shortwave data link message polling method based on state control and response of this embodiment includes:
[0036] (1) Initialize the polling system, set the polling entry switch including the on and off states, turn on the polling entry switch, and start the timer tmr1 with a timeout interval of T1;
[0037] (2) When the polling entry switch is turned on, when the timer tmr1 times out, the first-class station initiates polling to the second-class station, and the polling system state at this time is defined as polling sending, and the polling entry switch is turned off, and the start timeout interval is T s ′ nd Timer tmr2;
[0038] (3) When the polling system receives the sending end information of a type of station before the timer tmr2 times out, the state of the polling system is changed to polling sending end, the timer tmr2 is stopped, and the timeout interval is T ′ wait Timer tmr3;
[0039] (4) When the polling system receives a response message from a Class II station before timer tmr3 times out, the polling system changes its state to waiting for the response to be received, stops timer tmr3, and starts a timeout interval of T r ′ cv Timer tmr4;
[0040] (5) When the polling system receives the stop code of the response data of the Class II station within the timeout period of timer tmr4, the state of the polling system is changed to response end, the timer tmr4 is stopped, the current round of polling ends, the polling entry switch is turned on, and the system returns to step (2) to prepare for the next round of polling.
[0041] Specifically, in step (1), when the system is initialized, the default polling entry switch is set to polling available, and the timer tmr1 with a timeout interval of T1 is started. T1 should be as small as possible to ensure that once the polling conditions are met, the next polling can be entered immediately. This step is equivalent to controlling T update As small as possible.
[0042] After tmr1 times out in step (2), the first-class station initiates a poll to the second-class station, and the system status is transferred to the "polling sending" state, and the polling available flag is set to non-polling, and the start timeout interval is T s ′ nd During the period when the polling available flag is marked as non-polling, the timeout signal of tmr1 will be received multiple times, but none of them will be processed.
[0043] In step (3), if the system receives the transmission end information of the transmitting device of a type of station, the state is transferred to the "polling transmission end" state, the timer tmr2 is stopped, and the timeout interval is T ′ wait Timer tmr3. Since the state transfer is performed immediately after the launch, it ensures that Δ snd As small as possible. If the system is abnormal and the sending end signal is not received, the timeout event of tmr2 will be triggered. At this time, timer tmr2 should be stopped and the start timeout interval is T ′ wait The timer tmr3, in this abnormal situation, Δ snd =T s ′ nd -T rcv .
[0044] In step (4), after receiving the response message sent by the second-class station in the "polling transmission completed" state, the system state is transferred to the "waiting for response reception completed" state, the timer tmr3 is stopped, and the timeout interval is T r ′ cv Timer tmr4. Since the state is transferred immediately after receiving the response, Δ wait As small as possible. If the system does not receive a response message, it will trigger the tmr3 timeout event. At this time, the timer tmr3 should be stopped and the start timeout interval is T r′ cv The timer tmr4, in this abnormal situation, Δ wait =T ′ wait -T wait .
[0045] In step (5), after receiving the response message sent by the second-class station in the "waiting for response reception completion" state (when receiving the stop code of the response data of the second-class station), the system state is transferred to the "response completion" state and the timer tmr4 is stopped. The time spent on the state transfer in this stage is only the time of receiving the response of the second-class station, and there is no other redundant time-consuming operation, so Δ rcv As small as possible. If the system does not receive the response end message, it will trigger the timeout event of tmr4. At this time, timer tmr4 should be stopped. In this abnormal situation, Δ rcv =T r ′ cv -T rcv After receiving the response end information or triggering the timeout event of TMR4, a complete data link polling ends. At this time, the polling entry switch is set to pollable.
[0046] When the polling available flag is set to pollable, after tmr1 times out, go to step 2 and start the next round of polling. From step 5, the polling available flag is set to pollable until tmr1 times out to trigger the next round of polling, which can be achieved within a timing cycle, that is, max(T update )=T1.
[0047] In order to ensure reliability, the system has designed a retransmission mechanism. For abnormal situations such as sending timeout, response timeout, and end timeout, the timeout event of tmr4 in step (5) will be triggered. If the current polling has not been retransmitted, the roll call message needs to be retransmitted once, otherwise the current polling will be terminated. If each state of the polling works normally and the response or end information can be received in time, according to the method of the present invention, the actual time of a polling is:
[0048] T″=T snd +T wait +T rcv +T update ≤T snd +T wait +T rcv +T1
[0049] In extreme cases, the system works abnormally and executes the polling retransmission step, resulting in the longest polling time. At this time, the actual polling time is:
[0050] T″=2(T s′ nd +T ′ wait +T r ′ cv +T update )=2T ′
[0051] If the system works normally, the method of the present invention can basically perform polling and roll calling according to the ideal polling time, which is much shorter than the polling cycle T set according to experience. ′ In case of abnormal system operation, the total time required for retransmission is 2T ′ , which is consistent with the conventional method.
[0052] In summary, the present invention combines the state of a type of station transmitting device with the response of a data link message to maximize the Δ snd , Δ wait , Δ rcv and T update When the data link message is not sent, the transmitter is in idle state. When the data link polling message is sent, the system transfers to the "polling sending" state and enters T snd At this stage, the transmitter is in a busy state. After the message is sent, the system switches to the "polling transmission completed" state, and the transmitter is in an idle state. When the system detects the transition from busy to idle state, it immediately considers T snd The current stage ends and enters T wait When the first packet of response data from the second-class station is received, the system switches to the "waiting for response reception completion" state and immediately considers that T wait The current stage ends and enters T rcv When receiving the stop code of the response data from the second-class station, the system transfers to the "response end" state and immediately considers T rcv The current stage ends and enters T update At this stage, the system determines that all states of the current polling have been completed and considers that T update The current phase ends and the next round of polling begins immediately.
[0053] According to the status change and response information of the transmitter, the various stages of the polling process can be seamlessly connected, so that Δ snd , Δ wait , Δ rcv and T update As small as possible, which also means the actual total time
[0054] T ′ =T s ′ nd +T ′wait +T r ′ cv +T update 。
Claims
1. A shortwave data link message polling method based on state control and response, characterized in that: include: (1) Initialize the polling system, set the polling entry switch including the on and off states, turn on the polling entry switch, and start the timer tmr1 with a timeout interval of T1; (2) When the polling entry switch is turned on, when the timer tmr1 times out, the first-class station initiates polling to the second-class station, and the polling system state at this time is defined as polling sending, and the polling entry switch is turned off, and the start timeout interval is T′ snd Timer tmr2; (3) When the polling system receives the sending end information of a type of station before the timer tmr2 times out, the state of the polling system is changed to polling sending end, the timer tmr2 is stopped, and the timeout interval is started as T′ wait Timer tmr3; (4) When the polling system receives a response message from a Class II station before timer tmr3 times out, the polling system changes its state to waiting for the response to be received, stops timer tmr3, and starts a timeout interval of T′ rcv Timer tmr4; (5) When the polling system receives the stop code of the response data of the Class II station within the timeout period of timer tmr4, the state of the polling system is changed to response end, the timer tmr4 is stopped, the current round of polling ends, the polling entry switch is turned on, and the system returns to step (2) to prepare for the next round of polling.
2. The shortwave data link message polling method based on state control and response according to claim 1 is characterized in that: The timeout interval T1 of the timer tmr1 is less than 10 ms.
3. The shortwave data link message polling method based on state control and response according to claim 1 is characterized in that: When the polling entry switch is in the off state, it does not respond to the timer tmr1 timeout signal.
4. The shortwave data link message polling method based on state control and response according to claim 1 is characterized in that: In the step (3), if the polling system does not receive the sending end information of the first type of station before tmr2 times out, the timer tmr2 is stopped after tmr2 times out, and the timeout interval is T′. wait Timer tmr3.
5. The shortwave data link message polling method based on state control and response according to claim 1 is characterized in that: In the step (4), if the polling system does not receive a response message sent by the second-class station before tmr3 times out, the timer tmr3 is stopped after tmr3 times out, and the timeout interval is T′. rcv Timer tmr4.
6. The shortwave data link message polling method based on state control and response according to claim 1 is characterized in that: In step (5), when the polling system does not receive a response message sent by the Class II station before TMR4 times out, timer TMR4 is stopped after TMR4 times out, the current round of polling ends, the polling entry switch is turned on, and the system returns to step (2) to prepare for the next round of polling.
7. The shortwave data link message polling method based on state control and response according to claim 6 is characterized in that: It also includes: if no response message is received from the Class II station before TMR4 times out, after TMR4 times out and timer TMR4 is stopped, before the end of this round of polling, it is determined whether this round of polling has been retransmitted; if not, it returns to step (2) to retransmit this round of polling.
8. The shortwave data link message polling method based on state control and response according to claim 1 is characterized in that: The timeout interval T′ of the timer tmr2 snd >a, where a is the preset threshold.
9. The shortwave data link message polling method based on state control and response according to claim 1 is characterized in that: The timeout interval T′ of the timer tmr3 wait >b, where b is the preset threshold.
10. The shortwave data link message polling method based on state control and response according to claim 1 is characterized in that: The timeout interval T′ of the timer tmr4 rcv >c, where c is the preset threshold.
