Remote upgrading method and system for vehicle-mounted terminal firmware
By detecting the firmware version and network status of the vehicle terminal, remote firmware upgrades are realized when the network is stable, solving the problem of insufficient upgrade efficiency and security in the existing technology, and ensuring data security and stability.
Patent Information
- Application Number
- CN202411990217.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-31
- Publication Date
- 2025-04-11
AI Technical Summary
The existing on-board terminal firmware upgrade methods have network instability, firmware damage, security risks, long upgrade time and compatibility problems, resulting in insufficient upgrade efficiency and security.
By detecting the firmware version and network status of the on-board terminal, if there is a new version and the network is stable, an upgrade signal is sent to the remote server, a firmware upgrade package is received and verified, and an upgrade log is generated.
It realizes efficient remote upgrade of on-board terminal firmware while ensuring data security and stability, and improves upgrade efficiency and security.
Smart Images

Figure CN119806590A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of vehicle-mounted firmware upgrade, and in particular relates to a remote upgrade method and system for vehicle-mounted terminal firmware. Background Art
[0002] The vehicle terminal firmware is low-level software embedded in the vehicle electronic equipment, which directly controls and manages the hardware resources. It is closely related to the vehicle system (such as infotainment system, navigation, vehicle control unit, etc.), and is responsible for the startup, operation and basic function support of the equipment. The upgrade of the vehicle terminal firmware is the process of updating and replacing the embedded software in the vehicle equipment. As the vehicle system becomes more and more complex, the update of firmware becomes particularly important. Through firmware upgrades, automakers can fix vulnerabilities, improve performance, add new features, and even optimize security.
[0003] In the prior art, USB upgrade, OTA (Over-the-Air) upgrade and on-board diagnostic interface (OBD-II) upgrade are usually used to upgrade the firmware of the vehicle terminal. However, the above methods have many problems and limitations, such as: OTA upgrade depends on a stable network connection, and the upgrade process may fail when the network is unstable or there is no network coverage; during the upgrade process, if the power is off or the network is interrupted, the firmware may be damaged, and the vehicle terminal cannot be started normally; the firmware package may be tampered with, and there is a risk of being attacked by hackers, especially if strong encryption and digital signatures are not used; the firmware package of OTA upgrade is usually large, and the download and installation time is long, which may affect the owner's experience; the new firmware may be incompatible with the old version of hardware or software, causing vehicle failure or performance degradation. Therefore, there is an urgent need for a remote, safe and efficient upgrade method to upgrade the firmware of the vehicle terminal. Summary of the invention
[0004] The object of the present invention is to provide a remote upgrade method and system for vehicle terminal firmware, which can be achieved through the following technical solutions:
[0005] In a first aspect, an embodiment of the present application provides a method for remotely upgrading the firmware of a vehicle terminal, comprising the following steps:
[0006] The vehicle terminal detects the embedded firmware version to determine whether there is a new version of the firmware in the current vehicle terminal. If there is a new version of the firmware, a firmware upgrade signal is output; otherwise, a trigger condition for the firmware upgrade is set and the next round of version detection is waited for;
[0007] The vehicle terminal detects the current network status and determines whether the current vehicle network is stable. If the current vehicle network is stable, the vehicle terminal sends a network connection request to the remote server; otherwise, waits for the next round of network detection;
[0008] The remote server identifies the vehicle-mounted terminal according to the network connection request, and establishes a remote network connection based on the identification result;
[0009] The vehicle-mounted terminal sends the firmware upgrade signal to the remote server;
[0010] The remote server receives and analyzes the firmware upgrade signal, and sends the firmware upgrade package to the vehicle terminal;
[0011] The vehicle terminal performs integrity check on the firmware upgrade package, and if the integrity check passes, the firmware upgrade is performed; otherwise, the firmware upgrade package is re-acquired from the remote server;
[0012] The vehicle terminal performs a new firmware self-test after completing the firmware upgrade, and sends the self-test result and the upgrade completion signal to the remote server;
[0013] The remote server records each firmware upgrade process and operation data of the vehicle-mounted terminal to generate a firmware upgrade log.
[0014] Preferably, the vehicle-mounted terminal detects the embedded firmware version, including:
[0015] Obtaining the current firmware version information of the vehicle terminal, including the current version number, the current build number, the current update log, and the current version release date;
[0016] Get the latest firmware version information, including the latest version number, latest build number, latest change log, and latest version release date;
[0017] The current firmware version information is compared with the latest firmware version information. If the version numbers, build numbers, update logs, and version release dates of the two are inconsistent, it is determined that a new version of firmware to be upgraded exists in the current vehicle terminal.
[0018] Preferably, the triggering condition for setting the firmware upgrade includes:
[0019] Set the automatic detection period of the firmware version as the first trigger condition;
[0020] Set security vulnerability detection as the second trigger condition;
[0021] Set virus and Trojan detection as the third trigger condition;
[0022] Setting network anomaly as the fourth trigger condition includes network fluctuation, restart, replacement or interruption;
[0023] Set equipment failure or abnormal operation as the fifth trigger condition;
[0024] Wherein, when any trigger condition is met, the vehicle-mounted terminal performs a new round of version detection on the embedded firmware version.
[0025] Preferably, the vehicle-mounted terminal detects the current network status, including:
[0026] Performing a first detection on the current network state based on the data traffic to obtain a first detection result;
[0027] Performing a second detection on the current network state based on the network state data to obtain a second detection result;
[0028] A comprehensive judgment is made based on the first detection result and the second detection result. If at least one of the two shows that the network status is unstable, the output is: the current vehicle network is unstable and waiting for the next round of network detection; if both show that the network status is stable, the output is: the current vehicle network is stable, and the vehicle terminal sends a network connection request to the remote server.
[0029] Preferably, the first detection of the current network status based on the data traffic includes:
[0030] Obtaining traffic information of data traffic generated by the vehicle terminal;
[0031] Determine, according to the flow information, a stable value of the data flow generated by the vehicle-mounted terminal in the current detection cycle, wherein the stable value is used to characterize the stability of the data flow generated by the vehicle-mounted terminal in the current detection cycle;
[0032] Determining whether a network status of the vehicle-mounted terminal is abnormal according to the stable value of the data flow;
[0033] Wherein, the determining of the stable value of the data traffic generated by the vehicle-mounted terminal in the current detection cycle includes: determining the stable value of the uplink data traffic and the stable value of the downlink data traffic generated by the vehicle-mounted terminal in the current detection cycle;
[0034] Wherein, determining whether the network state of the vehicle terminal is abnormal according to the stable value of the data flow includes: when the stable value of the uplink data flow is less than the stable value of the downlink data flow, determining that the network state of the vehicle terminal is abnormal;
[0035] Further, the determining of the stable value of the uplink data traffic and the stable value of the downlink data traffic generated by the vehicle-mounted terminal in the current detection cycle includes:
[0036] Determine uplink data flow information and downlink data flow information generated by the vehicle-mounted terminal in each detection time interval within the current detection cycle;
[0037] Based on the uplink data flow information and the downlink data flow information, determine an average value of the uplink data flow and an average value of the downlink data flow generated in each detection time interval;
[0038] Based on the average value of the uplink data traffic and the average value of the downlink data traffic, the uplink data traffic information and the downlink data traffic information generated in each detection time interval, and the number of the detection time intervals, the stable value of the uplink data traffic and the stable value of the downlink data traffic generated in the current detection period are determined respectively.
[0039] Preferably, performing a second detection on the current network state based on the network state data includes:
[0040] Determine a target k-nearest neighbor value based on historical network status data, wherein the historical network status data includes normal data and abnormal data, and the target k-nearest neighbor value is the number of k-nearest neighbor points corresponding to any data object used to monitor the real-time network status data of the vehicle-mounted terminal;
[0041] Monitoring the real-time network status data based on the target k-nearest neighbor value to determine normal data and abnormal data in the real-time network status data;
[0042] Wherein, the target k nearest neighbor value is determined under the condition that the nearest neighbor link point in the historical network status data includes abnormal data;
[0043] Wherein, determining the target k nearest neighbor value according to the historical network status data includes:
[0044] Iterate over each candidate value in the candidate value set and perform the following operations on the current candidate value:
[0045] Determine a neighbor link point in the historical network status data based on the current candidate value, and add the neighbor link point to a preset data structure;
[0046] If there is abnormal data in the preset data structure, output the target k nearest neighbor value according to the current candidate value and stop traversing the candidate value;
[0047] If there is no abnormal data in the preset data structure, the operation on the current candidate value ends;
[0048] When abnormal data is detected in the vehicle terminal, it indicates that the network status of the current vehicle terminal is unstable.
[0049] Preferably, the performing identity recognition on the vehicle-mounted terminal includes:
[0050] Receive and parse the network connection request, and extract request-related information, including a device identifier, an IP address, and a request type;
[0051] The remote server verifies the device identifier, and if it is verified that the vehicle-mounted terminal is not registered, the network connection request is rejected, otherwise the legitimacy of the vehicle-mounted terminal is verified;
[0052] If the vehicle-mounted terminal is legitimate, the access rights of the vehicle-mounted terminal are verified again, and corresponding data is obtained according to the access rights; otherwise, the network connection request is rejected.
[0053] Preferably, before sending the firmware upgrade package to the vehicle-mounted terminal, the following steps are also included:
[0054] The remote server receives and parses the firmware upgrade signal;
[0055] The remote server performs a security check on the firmware upgrade package;
[0056] The remote server performs data backup on the firmware upgrade package.
[0057] Preferably, the vehicle-mounted terminal performs integrity verification on the firmware upgrade package, including: digital signature verification, hash value verification, firmware version verification, compatibility verification, transmission integrity verification, and metadata verification in the firmware upgrade package.
[0058] In a second aspect, an embodiment of the present application provides a remote upgrade system for vehicle terminal firmware, which uses the remote upgrade method for vehicle terminal firmware as described above, including:
[0059] The firmware version detection module is used for the vehicle terminal to detect the embedded firmware version and determine whether there is a new version of the firmware in the current vehicle terminal. If there is a new version of the firmware, a firmware upgrade signal is output; otherwise, the trigger condition for the firmware upgrade is set and the next round of version detection is waited for;
[0060] The network status detection module is used for the vehicle terminal to detect the current network status and determine whether the current vehicle network is stable. If the current vehicle network is stable, the vehicle terminal sends a network connection request to the remote server; otherwise, wait for the next round of network detection;
[0061] An identity recognition module, used for the remote server to perform identity recognition on the vehicle-mounted terminal according to the network connection request, and to establish a remote network connection based on the recognition result;
[0062] A firmware package verification module is used for the vehicle terminal to send the firmware upgrade signal to the remote server; the remote server receives and parses the firmware upgrade signal, and sends the firmware upgrade package to the vehicle terminal; the vehicle terminal performs integrity verification on the firmware upgrade package, and if the verification passes, the firmware upgrade is performed, otherwise the firmware upgrade package is re-acquired from the remote server;
[0063] The firmware self-check and recording module is used for the vehicle terminal to perform a new firmware self-check after completing the firmware upgrade, and send the self-check result and the upgrade completion signal to the remote server; the remote server records each firmware upgrade process and operation data of the vehicle terminal to generate a firmware upgrade log.
[0064] The beneficial effects of the present invention are as follows: the present invention determines whether a firmware update is required by detecting the firmware version of the vehicle-mounted terminal, and ensures data security and stability during the firmware upgrade process by detecting network status and identity recognition; and after completing the upgrade, the vehicle-mounted terminal will also ensure the reliability of the firmware upgrade by self-checking and generating logs, thereby improving the efficiency, security and stability of the firmware upgrade. BRIEF DESCRIPTION OF THE DRAWINGS
[0065] For better understanding and implementation, the technical solution of the present application is described in detail below with reference to the accompanying drawings.
[0066] Figure 1 A flowchart of a method for remotely upgrading the firmware of a vehicle terminal provided in an embodiment of the present application;
[0067] Figure 2 A flowchart of the steps for detecting the firmware version provided in an embodiment of the present application;
[0068] Figure 3 A flowchart of the steps for detecting the network status provided in an embodiment of the present application;
[0069] Figure 4 A flowchart of the steps for performing identity recognition on a vehicle-mounted terminal provided in an embodiment of the present application;
[0070] Figure 5 A schematic diagram of the structure of a remote upgrade system for vehicle terminal firmware provided in an embodiment of the present application. DETAILED DESCRIPTION
[0071] In order to further explain the technical means and effects taken by the present invention to achieve the predetermined invention purpose, exemplary embodiments will be described in detail here, and examples thereof are shown in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present application. Instead, they are only examples of methods and systems consistent with some aspects of the present application as detailed in the attached claims.
[0072] The terms used in this application are only for the purpose of describing specific embodiments and are not intended to limit this application. The singular forms of "a", "said" and "the" used in this application and the appended claims are also intended to include plural forms unless the context clearly indicates other meanings. It should also be understood that the term "and / or" used in this article refers to any or all possible combinations of one or more associated listed items.
[0073] The specific implementation methods, features and effects of the present invention are described in detail below in conjunction with the accompanying drawings and preferred embodiments.
[0074] Example 1
[0075] See also Figure 1 The present application embodiment provides a method for remotely upgrading the firmware of a vehicle terminal, comprising the following steps:
[0076] The vehicle terminal detects the embedded firmware version to determine whether there is a new version of the firmware in the current vehicle terminal. If there is a new version of the firmware, a firmware upgrade signal is output; otherwise, a trigger condition for the firmware upgrade is set and the next round of version detection is waited for;
[0077] The vehicle terminal detects the current network status and determines whether the current vehicle network is stable. If the current vehicle network is stable, the vehicle terminal sends a network connection request to the remote server; otherwise, waits for the next round of network detection;
[0078] The remote server identifies the vehicle-mounted terminal according to the network connection request, and establishes a remote network connection based on the identification result;
[0079] The vehicle-mounted terminal sends the firmware upgrade signal to the remote server;
[0080] The remote server receives and analyzes the firmware upgrade signal, and sends the firmware upgrade package to the vehicle terminal;
[0081] The vehicle terminal performs integrity check on the firmware upgrade package, and if the integrity check passes, the firmware upgrade is performed; otherwise, the firmware upgrade package is re-acquired from the remote server;
[0082] The vehicle terminal performs a new firmware self-test after completing the firmware upgrade, and sends the self-test result and the upgrade completion signal to the remote server;
[0083] The remote server records each firmware upgrade process and operation data of the vehicle-mounted terminal to generate a firmware upgrade log.
[0084] Specifically, since the firmware of the vehicle terminal needs to be updated and upgraded in a timely manner, but the upgrade process has high requirements for the network connection status, and the firmware package is easily tampered with or stolen, this application determines whether a firmware update is required by detecting the firmware version of the vehicle terminal, and ensures data security and stability during the firmware upgrade process by detecting the network status and identity recognition; and after the upgrade is completed, the vehicle terminal will also ensure the reliability of the firmware upgrade by self-checking and generating logs, thereby improving the efficiency, security and stability of the firmware upgrade. This application specifically adopts the following method to achieve the above effect: First, the vehicle terminal detects the embedded firmware version to determine whether there is a new version of the firmware in the current vehicle terminal. If there is a new version of the firmware, a firmware upgrade signal is output; otherwise, the trigger condition for the firmware upgrade is set and the next round of version detection is waited for; then the vehicle terminal detects the current network status to determine whether the current vehicle network is stable. If the current vehicle network is stable, the vehicle terminal sends a network connection request to the remote server; otherwise, wait for the next round of network detection; then the remote server identifies the identity of the vehicle terminal according to the network connection request, and establishes a firmware upgrade signal based on the identification result. Remote network connection; then the vehicle terminal sends the firmware upgrade signal to the remote server; then the remote server receives and parses the firmware upgrade signal, and sends the firmware upgrade package to the vehicle terminal; then the vehicle terminal performs integrity check on the firmware upgrade package, if it passes the check, the firmware upgrade is performed, otherwise the firmware upgrade package is re-acquired from the remote server; then the vehicle terminal performs a new firmware self-test after completing the firmware upgrade, and sends the self-test result and the upgrade completion signal to the remote server; finally, the remote server records each firmware upgrade process and operation data of the vehicle terminal to generate a firmware upgrade log. Through the above content, this application enables the software of the vehicle terminal to always be kept up to date, thereby improving the stability, security and functionality of the system.
[0085] like Figure 2 As shown, in one embodiment provided in the present application, the vehicle-mounted terminal detects the embedded firmware version, including:
[0086] Obtaining the current firmware version information of the vehicle terminal, including the current version number, the current build number, the current update log, and the current version release date;
[0087] Get the latest firmware version information, including the latest version number, latest build number, latest change log, and latest version release date;
[0088] The current firmware version information is compared with the latest firmware version information. If the version numbers, build numbers, update logs, and version release dates of the two are inconsistent, it is determined that a new version of firmware to be upgraded exists in the current vehicle terminal.
[0089] Specifically, in this embodiment, the vehicle terminal detects the embedded firmware version to determine whether there is a new version of firmware for upgrading and updating. In this embodiment, the current firmware version information of the vehicle terminal is compared with the latest firmware version information. If the information of the two is exactly the same, it means that the current firmware version is the latest firmware version and no further upgrading is required. If the information of the two is inconsistent, it means that the current version is not the latest and the latest version needs to be obtained for updating and upgrading. It should be noted that the version number, build number, update log and version release date are the key parameters that best reflect the firmware version information, so this embodiment uses the above parameters for comparative analysis.
[0090] In an embodiment provided in the present application, the triggering condition for setting the firmware upgrade includes:
[0091] Set the automatic detection period of the firmware version as the first trigger condition;
[0092] Set security vulnerability detection as the second trigger condition;
[0093] Set virus and Trojan detection as the third trigger condition;
[0094] Set network anomaly as the fourth trigger condition, such as network fluctuation, restart, replacement or interruption;
[0095] Set equipment failure or abnormal operation as the fifth trigger condition;
[0096] Wherein, when any trigger condition is met, the vehicle-mounted terminal performs a new round of version detection on the embedded firmware version.
[0097] Specifically, this embodiment sets multiple trigger conditions for firmware upgrades. When there is no new version of the firmware, if the terminal appears or meets any of the above trigger conditions, the vehicle-mounted terminal performs a new round of version detection on the embedded firmware version to ensure that the terminal can update the firmware version in time, thereby ensuring stable and safe operation of the equipment.
[0098] like Figure 3 As shown, in one embodiment provided in the present application, the vehicle-mounted terminal detects the current network status, including:
[0099] Performing a first detection on the current network state based on the data traffic to obtain a first detection result;
[0100] Performing a second detection on the current network state based on the network state data to obtain a second detection result;
[0101] A comprehensive judgment is made based on the first detection result and the second detection result. If at least one of the two shows that the network status is unstable, the output is: the current vehicle network is unstable and waiting for the next round of network detection; if both show that the network status is stable, the output is: the current vehicle network is stable, and the vehicle terminal sends a network connection request to the remote server.
[0102] Specifically, in this embodiment, the first detection is performed based on data traffic, and the second detection is performed based on network status data. By obtaining and combining the results of the two detections, a comprehensive judgment is made on the stability of the above network status, and based on the judgment result, a choice is made whether to perform the next round of detection or send a network connection request.
[0103] In an embodiment provided in the present application, performing a first detection on the current network state based on data traffic includes:
[0104] Obtaining traffic information of data traffic generated by the vehicle terminal;
[0105] Determine, according to the flow information, a stable value of the data flow generated by the vehicle-mounted terminal in the current detection cycle, wherein the stable value is used to characterize the stability of the data flow generated by the vehicle-mounted terminal in the current detection cycle;
[0106] Determining whether a network status of the vehicle-mounted terminal is abnormal according to the stable value of the data flow;
[0107] Wherein, determining the stable value of the data flow generated by the vehicle-mounted terminal in the current detection cycle includes:
[0108] Determine a stable value of uplink data traffic and a stable value of downlink data traffic generated by the vehicle-mounted terminal in the current detection period;
[0109] The determining, according to the stable value of the data flow, whether the network status of the vehicle-mounted terminal is abnormal includes:
[0110] When the stable value of the uplink data traffic is less than the stable value of the downlink data traffic, determining that the network state of the vehicle-mounted terminal is abnormal;
[0111] The determining of a stable value of uplink data traffic and a stable value of downlink data traffic generated by the vehicle-mounted terminal in the current detection cycle includes:
[0112] Determine uplink data flow information and downlink data flow information generated by the vehicle-mounted terminal in each detection time interval within the current detection cycle;
[0113] Based on the uplink data flow information and the downlink data flow information, determine an average value of the uplink data flow and an average value of the downlink data flow generated in each detection time interval;
[0114] Based on the average value of the uplink data traffic and the average value of the downlink data traffic, the uplink data traffic information and the downlink data traffic information generated in each detection time interval, and the number of the detection time intervals, the stable value of the uplink data traffic and the stable value of the downlink data traffic generated in the current detection period are determined respectively.
[0115] Specifically, this embodiment determines the stable value of the data traffic generated by the vehicle terminal in the current detection cycle based on the traffic information, and the stable value is used to characterize the stability of the data traffic generated by the vehicle terminal in the current detection cycle; based on the stable value, it is determined whether the network status of the vehicle terminal is abnormal. This embodiment uses the stability of the data traffic generated by the vehicle terminal in the current detection cycle to determine whether the network status is abnormal, which can make the judgment result more accurate and effectively avoid the problem of misjudgment when judging whether the network status is abnormal.
[0116] In an embodiment provided in the present application, performing a second detection on the current network state based on the network state data includes:
[0117] Determine a target k-nearest neighbor value based on historical network status data, wherein the historical network status data includes normal data and abnormal data, and the target k-nearest neighbor value is the number of k-nearest neighbor points corresponding to any data object used to monitor the real-time network status data of the vehicle-mounted terminal;
[0118] Monitoring the real-time network status data based on the target k-nearest neighbor value to determine normal data and abnormal data in the real-time network status data;
[0119] The target k nearest neighbor value is determined when the nearest neighbor link point in the historical network status data includes abnormal data; the nearest neighbor link point is a data object that meets the following conditions:
[0120] The data object and at least one k-nearest neighbor point of the data object are k-nearest neighbors to each other;
[0121] Wherein, determining the target k nearest neighbor value according to the historical network status data includes:
[0122] Iterate over each candidate value in the candidate value set and perform the following operations on the current candidate value:
[0123] Determine a neighbor link point in the historical network status data based on the current candidate value, and add the neighbor link point to a preset data structure;
[0124] If there is abnormal data in the preset data structure, output the target k nearest neighbor value according to the current candidate value and stop traversing the candidate value;
[0125] If there is no abnormal data in the preset data structure, the operation on the current candidate value ends;
[0126] Wherein, determining the neighboring link point in the historical network status data based on the current candidate value includes:
[0127] Each data object in the historical network status data is traversed, and the following operations are performed for the currently traversed data object:
[0128] If the preset data structure includes the currently traversed data object, the currently traversed data object is a neighbor link point;
[0129] If the data object is not included in the preset data structure, determining k nearest neighbor points of the data object based on the current candidate value;
[0130] If the data object and any k-nearest neighbor point are mutually k-nearest neighbors, then the data object is a neighbor link point;
[0131] If the data object and any k-nearest neighbor point are not mutually k-nearest neighbors, then the data object is a non-neighbor link point;
[0132] Wherein, outputting a target k-nearest neighbor value according to the current candidate value includes:
[0133] Subtract 1 from the current candidate value to obtain a target k-nearest neighbor value and output the target k-nearest neighbor value;
[0134] The monitoring of real-time network status data based on the target k-nearest neighbor value includes:
[0135] Traversing each data object in the real-time network status data, for the data object currently traversed in the real-time network status data, determining the k nearest neighbor points of the data object currently traversed in the real-time network status data based on the target k nearest neighbor value, if the data object currently traversed in the real-time network status data and any k nearest neighbor points are mutual k nearest neighbors, then the data object currently traversed in the real-time network status data is normal data, if the data object currently traversed in the real-time network status data and any k nearest neighbor points are not mutual k nearest neighbors, then the data object currently traversed in the real-time network status data is abnormal data;
[0136] When abnormal data is detected in the vehicle terminal, it indicates that the network status of the current vehicle terminal is unstable.
[0137] Specifically, this embodiment determines the target k-nearest neighbor value based on historical network status data, and the historical network status data includes normal data and abnormal data; the real-time network status data is monitored based on the target k-nearest neighbor value to monitor the normal data and abnormal data in the real-time network status data; wherein the target k-nearest neighbor value is determined under the condition that the neighbor link point in the historical network status data includes abnormal data. This embodiment monitors the real-time network status data according to the target k-nearest neighbor value determined by the historical network status data, and determines the normal data and abnormal data in the real-time network status data, ensuring that when abnormal data appears, it can be monitored and protected in time, thereby ensuring the safe operation of the vehicle-mounted terminal and the network connection. It can be understood that the preset data structure in this embodiment is a k-dimensional tree.
[0138] It is understandable that the above K-nearest Neighbors refers to the K-nearest Neighbors algorithm. K-Nearest Neighbors (KNN) is a commonly used supervised learning algorithm, mainly used for classification and regression problems. Its basic idea is: for a new sample point, the KNN algorithm calculates the distance between the point and all sample points in the training set (usually using the Euclidean distance), and then selects the K sample points closest to it, and determines the label of the new sample based on the labels of these K sample points.
[0139] like Figure 4 As shown, in one embodiment provided in the present application, the identification of the vehicle-mounted terminal includes:
[0140] Receive and parse the network connection request, and extract request-related information, including a device identifier, an IP address, and a request type;
[0141] The remote server verifies the device identifier, and if it is verified that the vehicle-mounted terminal is not registered, the network connection request is rejected, otherwise the legitimacy of the vehicle-mounted terminal is verified;
[0142] If the vehicle-mounted terminal is legitimate, the access rights of the vehicle-mounted terminal are verified again, and corresponding data is obtained according to the access rights; otherwise, the network connection request is rejected.
[0143] In an embodiment provided in the present application, before sending the firmware upgrade package to the vehicle-mounted terminal, the following steps are also included:
[0144] The remote server receives and parses the firmware upgrade signal;
[0145] The remote server performs a security check on the firmware upgrade package;
[0146] The remote server performs data backup on the firmware upgrade package.
[0147] In an embodiment provided in the present application, the vehicle-mounted terminal performs integrity verification on the firmware upgrade package, including: digital signature verification, hash value verification, firmware version verification, compatibility verification, transmission integrity verification, and metadata verification in the firmware upgrade package.
[0148] Specifically, the above verification measures jointly ensure the authenticity, integrity and security of the firmware upgrade package, thereby avoiding potential risks brought by malicious software, erroneous firmware or transmission errors, and ensuring that the vehicle-mounted terminal can smoothly and safely complete the firmware update during the upgrade process.
[0149] Example 2
[0150] See also Figure 5 The embodiment of the present application provides a remote upgrade system of vehicle terminal firmware, which is applied to the remote upgrade method of vehicle terminal firmware as described above, including:
[0151] The firmware version detection module is used for the vehicle terminal to detect the embedded firmware version and determine whether there is a new version of the firmware in the current vehicle terminal. If there is a new version of the firmware, a firmware upgrade signal is output; otherwise, the trigger condition for the firmware upgrade is set and the next round of version detection is waited for;
[0152] The network status detection module is used for the vehicle terminal to detect the current network status and determine whether the current vehicle network is stable. If the current vehicle network is stable, the vehicle terminal sends a network connection request to the remote server; otherwise, wait for the next round of network detection;
[0153] An identity recognition module, used for the remote server to perform identity recognition on the vehicle-mounted terminal according to the network connection request, and to establish a remote network connection based on the recognition result;
[0154] A firmware package verification module is used for the vehicle terminal to send the firmware upgrade signal to the remote server; the remote server receives and parses the firmware upgrade signal, and sends the firmware upgrade package to the vehicle terminal; the vehicle terminal performs integrity verification on the firmware upgrade package, and if the verification passes, the firmware upgrade is performed, otherwise the firmware upgrade package is re-acquired from the remote server;
[0155] The firmware self-check and recording module is used for the vehicle terminal to perform a new firmware self-check after completing the firmware upgrade, and send the self-check result and the upgrade completion signal to the remote server; the remote server records each firmware upgrade process and operation data of the vehicle terminal to generate a firmware upgrade log.
[0156] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0157] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.
[0158] Those skilled in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of the present invention.
[0159] The above description is only a preferred embodiment of the present invention and does not limit the present invention in any form. Although the present invention has been disclosed as a preferred embodiment as above, it is not used to limit the present invention. Any technical personnel in this field can make some changes or modify the technical contents disclosed above into equivalent embodiments without departing from the scope of the technical solution of the present invention. However, any simple modification, equivalent change and modification made to the above embodiments according to the technical essence of the present invention without departing from the content of the technical solution of the present invention still fall within the scope of the technical solution of the present invention.
Claims
1. A remote upgrade method for vehicle terminal firmware, characterized in that: The steps include: The vehicle terminal detects the embedded firmware version to determine whether there is a new version of the firmware in the current vehicle terminal. If there is a new version of the firmware, a firmware upgrade signal is output; otherwise, a trigger condition for the firmware upgrade is set and the next round of version detection is waited for; The vehicle terminal detects the current network status and determines whether the current vehicle network is stable. If the current vehicle network is stable, the vehicle terminal sends a network connection request to the remote server; otherwise, waits for the next round of network detection; The remote server identifies the vehicle-mounted terminal according to the network connection request, and establishes a remote network connection based on the identification result; The vehicle-mounted terminal sends the firmware upgrade signal to the remote server; The remote server receives and analyzes the firmware upgrade signal, and sends the firmware upgrade package to the vehicle terminal; The vehicle terminal performs integrity check on the firmware upgrade package, and if the integrity check passes, the firmware upgrade is performed; otherwise, the firmware upgrade package is re-acquired from the remote server; The vehicle terminal performs a new firmware self-test after completing the firmware upgrade, and sends the self-test result and the upgrade completion signal to the remote server; The remote server records each firmware upgrade process and operation data of the vehicle-mounted terminal to generate a firmware upgrade log.
2. A method for remotely upgrading vehicle terminal firmware according to claim 1, characterized in that: The vehicle-mounted terminal detects the embedded firmware version, including: Obtaining the current firmware version information of the vehicle terminal, including the current version number, the current build number, the current update log, and the current version release date; Get the latest firmware version information, including the latest version number, latest build number, latest change log, and latest version release date; The current firmware version information is compared with the latest firmware version information. If the version numbers, build numbers, update logs, and version release dates of the two are inconsistent, it is determined that a new version of firmware to be upgraded exists in the current vehicle terminal.
3. The remote upgrade method of the vehicle terminal firmware according to claim 1, characterized in that: The triggering condition for setting the firmware upgrade includes: Set the automatic detection period of the firmware version as the first trigger condition; Set security vulnerability detection as the second trigger condition; Set virus and Trojan detection as the third trigger condition; Setting network anomaly as the fourth trigger condition includes network fluctuation, restart, replacement or interruption; Set equipment failure or abnormal operation as the fifth trigger condition; Wherein, when any trigger condition is met, the vehicle-mounted terminal performs a new round of version detection on the embedded firmware version.
4. The remote upgrade method of the vehicle terminal firmware according to claim 1, characterized in that: The vehicle-mounted terminal detects the current network status, including: Performing a first detection on the current network state based on the data traffic to obtain a first detection result; Performing a second detection on the current network state based on the network state data to obtain a second detection result; A comprehensive judgment is made based on the first detection result and the second detection result. If at least one of the two shows that the network status is unstable, the output is: the current vehicle network is unstable and waiting for the next round of network detection; if both show that the network status is stable, the output is: the current vehicle network is stable, and the vehicle terminal sends a network connection request to the remote server.
5. A method for remotely upgrading vehicle terminal firmware according to claim 4, characterized in that: The first test of the current network status is performed based on data traffic, including: Obtaining traffic information of data traffic generated by the vehicle terminal; Determine, according to the flow information, a stable value of the data flow generated by the vehicle-mounted terminal in the current detection cycle, wherein the stable value is used to characterize the stability of the data flow generated by the vehicle-mounted terminal in the current detection cycle; Determining whether a network status of the vehicle-mounted terminal is abnormal according to the stable value of the data flow; Wherein, the determining of the stable value of the data traffic generated by the vehicle-mounted terminal in the current detection cycle includes: determining the stable value of the uplink data traffic and the stable value of the downlink data traffic generated by the vehicle-mounted terminal in the current detection cycle; Wherein, determining whether the network state of the vehicle terminal is abnormal according to the stable value of the data flow includes: when the stable value of the uplink data flow is less than the stable value of the downlink data flow, determining that the network state of the vehicle terminal is abnormal; Further, the determining of the stable value of the uplink data traffic and the stable value of the downlink data traffic generated by the vehicle-mounted terminal in the current detection cycle includes: Determine uplink data flow information and downlink data flow information generated by the vehicle-mounted terminal in each detection time interval within the current detection cycle; Based on the uplink data flow information and the downlink data flow information, determine an average value of the uplink data flow and an average value of the downlink data flow generated in each detection time interval; Based on the average value of the uplink data traffic and the average value of the downlink data traffic, the uplink data traffic information and the downlink data traffic information generated in each detection time interval, and the number of the detection time intervals, the stable value of the uplink data traffic and the stable value of the downlink data traffic generated in the current detection period are determined respectively.
6. A method for remotely upgrading vehicle terminal firmware according to claim 4, characterized in that: Perform a second test on the current network status based on the network status data, including: Determine a target k-nearest neighbor value based on historical network status data, wherein the historical network status data includes normal data and abnormal data, and the target k-nearest neighbor value is the number of k-nearest neighbor points corresponding to any data object used to monitor the real-time network status data of the vehicle-mounted terminal; Monitoring the real-time network status data based on the target k-nearest neighbor value to determine normal data and abnormal data in the real-time network status data; Wherein, the target k nearest neighbor value is determined under the condition that the nearest neighbor link point in the historical network status data includes abnormal data; Wherein, determining the target k nearest neighbor value according to the historical network status data includes: Iterate over each candidate value in the candidate value set and perform the following operations on the current candidate value: Determine a neighbor link point in the historical network status data based on the current candidate value, and add the neighbor link point to a preset data structure; If there is abnormal data in the preset data structure, output the target k nearest neighbor value according to the current candidate value and stop traversing the candidate value; If there is no abnormal data in the preset data structure, the operation on the current candidate value ends; When abnormal data is detected in the vehicle terminal, it indicates that the network status of the current vehicle terminal is unstable.
7. The remote upgrade method of vehicle terminal firmware according to claim 1, characterized in that: The performing identity recognition on the vehicle-mounted terminal includes: Receive and parse the network connection request, and extract request-related information, including a device identifier, an IP address, and a request type; The remote server verifies the device identifier, and if it is verified that the vehicle-mounted terminal is not registered, the network connection request is rejected, otherwise the legitimacy of the vehicle-mounted terminal is verified; If the vehicle-mounted terminal is legitimate, the access rights of the vehicle-mounted terminal are verified again, and corresponding data is obtained according to the access rights; otherwise, the network connection request is rejected.
8. The remote upgrade method of vehicle terminal firmware according to claim 1, characterized in that: Before sending the firmware upgrade package to the vehicle-mounted terminal, the following steps are also included: The remote server receives and parses the firmware upgrade signal; The remote server performs a security check on the firmware upgrade package; The remote server performs data backup on the firmware upgrade package.
9. A method for remotely upgrading vehicle terminal firmware according to claim 1, characterized in that: The vehicle-mounted terminal performs integrity verification on the firmware upgrade package, including: digital signature verification, hash value verification, firmware version verification, compatibility verification, transmission integrity verification, and metadata verification in the firmware upgrade package.
10. A remote upgrade system for vehicle terminal firmware, using a remote upgrade method for vehicle terminal firmware as claimed in any one of claims 1 to 9, characterized in that: include: The firmware version detection module is used for the vehicle terminal to detect the embedded firmware version and determine whether there is a new version of the firmware in the current vehicle terminal. If there is a new version of the firmware, a firmware upgrade signal is output; Otherwise, set the triggering conditions for firmware upgrade and wait for the next round of version detection; The network status detection module is used for the vehicle terminal to detect the current network status and determine whether the current vehicle network is stable. If the current vehicle network is stable, the vehicle terminal sends a network connection request to the remote server; otherwise, wait for the next round of network detection; An identity recognition module, used for the remote server to perform identity recognition on the vehicle-mounted terminal according to the network connection request, and to establish a remote network connection based on the recognition result; A firmware package verification module, used for the vehicle terminal to send the firmware upgrade signal to the remote server; The remote server receives and parses the firmware upgrade signal, and sends the firmware upgrade package to the vehicle-mounted terminal; the vehicle-mounted terminal performs an integrity check on the firmware upgrade package, and if the integrity check passes, the firmware upgrade is performed; otherwise, the remote server is requested to reacquire the firmware upgrade package; A firmware self-check and recording module, used for the vehicle terminal to perform a new firmware self-check after completing the firmware upgrade, and send the self-check result and the upgrade completion signal to the remote server; The remote server records each firmware upgrade process and operation data of the vehicle-mounted terminal to generate a firmware upgrade log.
Citation Information
Patent Citations
Remote upgrading method for vehicle-mounted communication terminal
CN105978921A
Network state detection method and device, electronic equipment and readable storage medium
CN111314169A
Automatic driving vehicle software remote upgrading method based on vehicle management system
CN113946358A
Upgrading method and device based on over-the-air technology OTA and storage medium
CN114666323A
Network state abnormal data monitoring method, device, equipment, medium and product
CN118214691A