Search

CN-122001795-A - On-line state judging method and system for vehicle-mounted equipment

CN122001795ACN 122001795 ACN122001795 ACN 122001795ACN-122001795-A

Abstract

The invention provides a method and a system for judging the on-line state of vehicle-mounted equipment, which belong to the technical field of Internet of vehicles, and the method comprises the steps of obtaining a heartbeat message issued by target vehicle-mounted equipment in a first fixed period through a first channel, sending a detection request message to the target vehicle-mounted equipment in a second fixed period through a second channel, and obtaining a response message which is replied by the target vehicle-mounted equipment and contains the same serial number as the detection request message; and carrying out state judgment on the target vehicle-mounted equipment according to the dynamic credibility score. The invention effectively distinguishes the instantaneous interruption of the network link and the real off-line of the equipment by introducing a double-channel cross-validation mechanism of the uplink heartbeat (DIH) of the equipment and the downlink detection (PIP) of the platform and combining a dynamic credibility score model, and fundamentally solves the misjudgment problem of the false on-line and the false off-line.

Inventors

  • GAO XINPENG
  • Zhu Danhe
  • Xiong Hongcan
  • ZHANG RUI
  • YU ZHONGYU

Assignees

  • 东风汽车集团股份有限公司

Dates

Publication Date
20260508
Application Date
20260108

Claims (10)

  1. 1. A vehicle-mounted device online state determination method, characterized by comprising: Acquiring a heartbeat message issued by target vehicle-mounted equipment in a first fixed period through a first channel, sending a detection request message to the target vehicle-mounted equipment in a second fixed period through a second channel, and acquiring a response message which is replied by the target vehicle-mounted equipment and contains the same serial number as the detection request message; calculating a dynamic credibility score in real time according to the interaction result of the first channel and the second channel; And judging the state of the target vehicle-mounted equipment according to the dynamic credibility score.
  2. 2. The method according to claim 1, wherein the step of obtaining the response message that includes the same serial number as the probe request message and is replied by the target vehicle-mounted device, includes the steps of sending the probe request message to the target vehicle-mounted device in a first fixed period through a first channel, and sending the probe request message to the target vehicle-mounted device in a second fixed period through a second channel, wherein the heartbeat message is published in the first fixed period through the first channel by the target vehicle-mounted device: The heartbeat message comprises equipment ID and a time stamp, and at least one of network signal strength, network delay, network type, equipment CPU occupancy rate and equipment battery power.
  3. 3. The method of claim 2, wherein the step of calculating a dynamic confidence score in real time based on the interaction results of the first channel and the second channel comprises: Calculating a signal strength score from the network signal strength; Calculating a network delay score from the network delay; calculating network type weight according to the network type; Calculating a network quality compensation factor according to the signal strength score, the network delay score and the network type weight; And calculating the dynamic credibility score in real time according to the interaction result of the first channel and the second channel and the network quality compensation factor.
  4. 4. The method of claim 3, wherein said calculating a signal strength score from said network signal strength comprises calculating a signal strength score S_ rsrp using the formula: (1), In the formula (1), rsrp _current is the current signal strength value, rsrp _max is the preset signal strength maximum threshold value, and rsrp _min is the preset signal strength minimum threshold value; the step of calculating the network delay score according to the network delay comprises the following formula: (2), In the formula (2), rtt_current is a current network delay value, and rtt_base is a preset network delay reference value; the step of calculating the network type weight according to the network type comprises the steps of enabling the network type weight W_type to be a first preset network type weight value when the network type is WiFi/5G, enabling the network type weight W_type to be a second preset network type weight value when the network type is 4G, and enabling the network type weight W_type to be a third preset network type weight value when the network type is 3G; The step of calculating the network quality compensation factor according to the signal strength score, the network delay score and the network type weight comprises the following steps of calculating the network quality compensation factor alpha by adopting the following formula: α = (S_rsrp * W_rsrp + S_rtt * W_rtt) * W_type(3), In the formula (3), the value range of α is greater than 0 and less than or equal to 1, w_rsrp is a preset signal strength weight, w_rtt is a preset network delay weight, Σ (w_ rsrp, w_rtt) =1; The step of calculating the dynamic credibility score in real time according to the interaction result of the first channel and the second channel and combining with a network quality compensation factor comprises the following steps: When the target vehicle-mounted equipment is connected for the first time, setting a dynamic credibility score S as an initial value; When a heartbeat message issued by the target vehicle-mounted equipment through the first channel is acquired in a first fixed period, calculating a dynamic credibility score S by adopting a formula S=S+R1, wherein R1 successfully sets a reward value for a preset heartbeat of the first channel; When a detection request message is sent to the target vehicle-mounted equipment through a second channel in a second fixed period, and a response message which is replied by the target vehicle-mounted equipment and contains the same serial number as the detection request message is obtained, calculating a dynamic credibility score S by adopting a formula S=S+R2, wherein R2 is a preset reward value successfully set for the detection of the second channel, and R2 is larger than R1; When a heartbeat message issued by the target vehicle-mounted equipment through the first channel is not acquired in the first fixed period, calculating a dynamic reliability score S by adopting a formula S=S- (P1 x alpha), wherein P1 is a preset first channel heartbeat timeout punishment base value; When a detection request message is sent to the target vehicle-mounted device through a second channel in a second fixed period, and a response message which is returned by the target vehicle-mounted device and contains the same serial number as the detection request message is not obtained, calculating a dynamic credibility score S by adopting a formula S=S- (P2. Alpha.) and P2 is a preset second channel detection failure punishment base value.
  5. 5. The method according to claim 4, wherein the target in-vehicle device state determination step according to the dynamic confidence score includes: setting an online threshold S_online and an offline threshold S_offline; When the dynamic credibility score S is larger than the online threshold S_online, the state of the target vehicle-mounted equipment is judged to be online; when the dynamic credibility score S is larger than the offline threshold S_ofline and smaller than or equal to the online threshold S_online, the state of the target vehicle-mounted equipment is judged to be sub-healthy; And when the dynamic credibility score S is smaller than or equal to the offline threshold S_offly, the state of the target vehicle-mounted equipment is judged to be offline.
  6. 6. The method as recited in claim 5, further comprising: When the state of the target vehicle-mounted equipment is judged to be sub-healthy, an enhanced detection mode is triggered, and a second fixed period is shortened.
  7. 7. The method as recited in claim 5, further comprising: and when the state of the target vehicle-mounted equipment is judged to be offline, a strong wake-up instruction is sent to the target vehicle-mounted equipment through a standby link which is independent of the current MQTT connection, and if the target vehicle-mounted equipment is not awakened yet, the target vehicle-mounted equipment is finally confirmed to be offline.
  8. 8. An in-vehicle apparatus presence determination system configured to enable the method according to any one of claims 1 to 7, the system comprising: The dual-channel interaction module is used for acquiring heartbeat messages issued by the target vehicle-mounted equipment in a first fixed period through the first channel, sending detection request messages to the target vehicle-mounted equipment in a second fixed period through the second channel, and acquiring response messages which are returned by the target vehicle-mounted equipment and contain the same serial numbers as the detection request messages; the dynamic credibility score calculation module is used for calculating the dynamic credibility score in real time according to the interaction result of the first channel and the second channel; And the state judging module is used for judging the state of the target vehicle-mounted equipment according to the dynamic credibility score.
  9. 9. An electronic device, comprising: One or more processors; a memory for storing one or more programs; When executed by the one or more processors, causes the one or more processors to implement the method of any of claims 1 to 7.
  10. 10. A computer readable medium having a computer program stored thereon, characterized in that the computer program, when executed by a processor, implements the steps of the method according to any of claims 1 to 7.

Description

On-line state judging method and system for vehicle-mounted equipment Technical Field The invention relates to the technical field of Internet of vehicles, in particular to a method and a system for judging the online state of vehicle-mounted equipment. Background In the technical scheme of realizing data interaction between a cloud end and a vehicle-mounted device based on an MQTT protocol in the current vehicle networking system, the judgment logic of the cloud end on the on-line state of the device is that when the vehicle-mounted device successfully establishes the MQTT connection, a message is issued to a/connected theme, a cloud service subscribes the theme and monitors the message, then the device identifier and the on-line state are stored in a Redis cache, and an expiration time (for example, 2 hours) is set. When the cloud needs to send data to the device, whether the device is online or not is judged only by checking whether the corresponding device identifier exists in the Redis cache. If the cache is out of date, the device is judged to be offline, and the data issuing flow is terminated. The prior art scheme has the obvious defects that firstly, the problem of false offline is remarkable, because the Redis cache is set for fixing the expiration time of 2 hours, when the equipment is actually kept on line but the cache is deleted overtime, the cloud can erroneously judge that the equipment is offline, so that serious consequences such as failure in issuing a remote control instruction, incapability of executing an OTA upgrading task and the like are caused, and the user experience and the system function integrity are greatly influenced. Secondly, hysteresis exists in state updating, the DISCONNECT message of the MQTT protocol is triggered only when the device is normally closed for connection, and if the device is abnormally disconnected due to sudden situations such as network instantaneous disconnection, vehicle-mounted power supply abnormal power failure and the like, the cloud can not timely receive a state change notification, and the device can still be misjudged to be in an on-line state, so that data issuing errors or resource waste are caused. Thirdly, the buffer time parameter is difficult to optimize, if the expiration time of the Redis buffer is prolonged, the false offline probability can be reduced, but the offline equipment is misjudged to be online for a long time, invalid data is sent out, if the expiration time is shortened, the false offline phenomenon is aggravated, and the normal communication flow is blocked frequently. Therefore, the existing solutions cannot achieve an effective balance among accuracy, real-time performance and resource utilization efficiency of the device on-line status determination, and need for improvement. Disclosure of Invention The invention aims to solve at least one of the technical problems in the prior art, and provides an improved on-line state judgment technical scheme for vehicle-mounted equipment, which accurately judges the on-line off-line condition of the vehicle-mounted equipment based on a double-channel heartbeat mechanism and dynamic state compensation and ensures the accuracy of a service link. In a first aspect, an embodiment of the present invention provides a method for determining an online status of a vehicle-mounted device, including: Acquiring a heartbeat message issued by target vehicle-mounted equipment in a first fixed period through a first channel, sending a detection request message to the target vehicle-mounted equipment in a second fixed period through a second channel, and acquiring a response message which is replied by the target vehicle-mounted equipment and contains the same serial number as the detection request message; calculating a dynamic credibility score in real time according to the interaction result of the first channel and the second channel; And judging the state of the target vehicle-mounted equipment according to the dynamic credibility score. In a preferred embodiment, the step of obtaining the heartbeat message issued by the target vehicle-mounted device in the first fixed period through the first channel, sending the probe request message to the target vehicle-mounted device in the second fixed period through the second channel, and obtaining the response message including the same serial number as the probe request message, which is replied by the target vehicle-mounted device, includes: The heartbeat message comprises equipment ID and a time stamp, and at least one of network signal strength, network delay, network type, equipment CPU occupancy rate and equipment battery power. In a preferred embodiment, the step of calculating the dynamic credibility score in real time according to the interaction result of the first channel and the second channel includes: Calculating a signal strength score from the network signal strength; Calculating a network delay score from the network delay; calculat