CN116931988A - An OTA upgrade method, device, electronic equipment and storage medium - Google Patents
An OTA upgrade method, device, electronic equipment and storage medium Download PDFInfo
- Publication number
- CN116931988A CN116931988A CN202310854791.3A CN202310854791A CN116931988A CN 116931988 A CN116931988 A CN 116931988A CN 202310854791 A CN202310854791 A CN 202310854791A CN 116931988 A CN116931988 A CN 116931988A
- Authority
- CN
- China
- Prior art keywords
- upgrade
- group
- file
- gateway
- ota
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000000034 method Methods 0.000 title claims abstract description 71
- 238000004590 computer program Methods 0.000 claims description 19
- 230000008569 process Effects 0.000 claims description 12
- 230000000977 initiatory effect Effects 0.000 claims description 4
- 230000001186 cumulative effect Effects 0.000 claims description 3
- 238000004891 communication Methods 0.000 abstract description 23
- 230000009286 beneficial effect Effects 0.000 abstract description 3
- 238000010586 diagram Methods 0.000 description 9
- 230000003993 interaction Effects 0.000 description 9
- 230000006870 function Effects 0.000 description 6
- 238000005516 engineering process Methods 0.000 description 5
- 230000005540 biological transmission Effects 0.000 description 4
- WXZOXVVKILCOPG-UHFFFAOYSA-N bis(2-ethylhexyl) benzene-1,3-dicarboxylate Chemical compound CCCCC(CC)COC(=O)C1=CC=CC(C(=O)OCC(CC)CCCC)=C1 WXZOXVVKILCOPG-UHFFFAOYSA-N 0.000 description 3
- 238000012790 confirmation Methods 0.000 description 2
- 238000001514 detection method Methods 0.000 description 2
- 238000011161 development Methods 0.000 description 2
- 238000009434 installation Methods 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 238000012545 processing Methods 0.000 description 2
- 238000006467 substitution reaction Methods 0.000 description 2
- 238000012546 transfer Methods 0.000 description 2
- 101000741965 Homo sapiens Inactive tyrosine-protein kinase PRAG1 Proteins 0.000 description 1
- 102100038659 Inactive tyrosine-protein kinase PRAG1 Human genes 0.000 description 1
- 230000002159 abnormal effect Effects 0.000 description 1
- 239000002131 composite material Substances 0.000 description 1
- 230000003247 decreasing effect Effects 0.000 description 1
- 230000007246 mechanism Effects 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 230000004044 response Effects 0.000 description 1
- 238000012795 verification Methods 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/60—Software deployment
- G06F8/65—Updates
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04W—WIRELESS COMMUNICATION NETWORKS
- H04W8/00—Network data management
- H04W8/22—Processing or transfer of terminal data, e.g. status or physical capabilities
- H04W8/24—Transfer of terminal data
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- General Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Computer Security & Cryptography (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Databases & Information Systems (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Stored Programmes (AREA)
Abstract
Description
技术领域Technical field
本申请涉及新能源汽车领域,尤其涉及一种OTA升级方法、装置、电子设备及存储介质。This application relates to the field of new energy vehicles, and in particular to an OTA upgrade method, device, electronic equipment and storage medium.
背景技术Background technique
OTA(Over the Air Technology),即空间下载技术,汽车OTA升级是指利用空中下载技术对汽车进行固件升级和/或软件升级。OTA (Over the Air Technology) means over-the-air download technology. Car OTA upgrade refers to using over-the-air download technology to upgrade the firmware and/or software of the car.
目前的OTA升级基本上都是由OTA主控对被升级部件(如ECU等)进行升级刷写,而各被升级部件“被动式”接收升级刷写。由于这种“被动式”的升级刷写方式不管被升级部件是否有升级刷写需求,OTA主控都会对被升级部件进行升级刷写,所以不仅需要消耗大量的网络带宽,而且难以充分发挥OTA升级的潜力,升级效率也较低。The current OTA upgrade basically uses the OTA master to upgrade and flash the upgraded components (such as ECU, etc.), and each upgraded component "passively" receives the upgrade and flash. Because of this "passive" upgrade and flash method, the OTA master will upgrade and flash the upgraded components regardless of whether the upgraded components have upgrade and flash requirements. Therefore, it not only consumes a large amount of network bandwidth, but also makes it difficult to give full play to the OTA upgrade. potential, and the upgrade efficiency is also low.
发明内容Contents of the invention
有鉴于此,本申请实施例提供了一种OTA升级方法、装置、电子设备及存储介质,以解决现有的OTA升级方法需要消耗大量的网络带宽,难以充分发挥OTA升级的潜力,且升级效率较低的问题。In view of this, embodiments of the present application provide an OTA upgrade method, device, electronic device, and storage medium to solve the problem that the existing OTA upgrade method consumes a large amount of network bandwidth, is difficult to fully utilize the potential of OTA upgrade, and has high upgrade efficiency. Lower question.
本申请实施例的第一方面,提供了一种OTA升级方法,包括:A first aspect of the embodiment of this application provides an OTA upgrade method, including:
向OTA升级主控提交第一升级服务申请,第一升级服务申请包括第一标识信息以及与第一标识信息对应的第一订阅事件组,第一订阅事件组包括至少一个第一订阅内容;Submit a first upgrade service application to the OTA upgrade master. The first upgrade service application includes first identification information and a first subscription event group corresponding to the first identification information. The first subscription event group includes at least one first subscription content;
在接收OTA升级主控传输过来的与每一个第一订阅内容对应的第一升级文件时,使用第一升级文件进行升级刷写,并发布广播消息,广播消息至少包括第一升级文件的第一版本信息;When receiving the first upgrade file corresponding to each first subscription content transmitted from the OTA upgrade master, use the first upgrade file to perform upgrade flashing, and publish a broadcast message, which at least includes the first part of the first upgrade file. Version Information;
接收其他升级需求方发送的第二升级服务申请,第二升级服务申请包括第二标识信息以及与第二标识信息对应的第二订阅事件组,第二订阅事件组包括至少一个第二订阅内容;Receive a second upgrade service application sent by other upgrade demanders. The second upgrade service application includes second identification information and a second subscription event group corresponding to the second identification information. The second subscription event group includes at least one second subscription content;
将与第二订阅内容对应的第一升级文件确定为目标升级文件,并将目标升级文件发送至其他升级需求方,以使其他升级需求方使用目标升级文件进行升级刷写。The first upgrade file corresponding to the second subscription content is determined as the target upgrade file, and the target upgrade file is sent to other upgrade demanders, so that the other upgrade demanders use the target upgrade file to perform upgrade flashing.
本申请实施例的第二方面,提供了一种OTA升级装置,包括:A second aspect of the embodiment of the present application provides an OTA upgrade device, including:
申请发起模块,被配置为向OTA升级主控提交第一升级服务申请,第一升级服务申请包括第一标识信息以及与第一标识信息对应的第一订阅事件组,第一订阅事件组包括至少一个第一订阅内容;The application initiation module is configured to submit a first upgrade service application to the OTA upgrade master. The first upgrade service application includes first identification information and a first subscription event group corresponding to the first identification information. The first subscription event group includes at least A first subscription content;
消息广播模块,被配置为在接收OTA升级主控传输过来的与每一个第一订阅内容对应的第一升级文件时,使用第一升级文件进行升级刷写,并发布广播消息,广播消息至少包括第一升级文件的第一版本信息;The message broadcast module is configured to, when receiving the first upgrade file corresponding to each first subscription content transmitted from the OTA upgrade master, use the first upgrade file to perform upgrade flashing, and publish a broadcast message, which at least includes The first version information of the first upgrade file;
申请接收模块,被配置为接收其他升级需求方发送的第二升级服务申请,第二升级服务申请包括第二标识信息以及与第二标识信息对应的第二订阅事件组,第二订阅事件组包括至少一个第二订阅内容;The application receiving module is configured to receive a second upgrade service application sent by other upgrade demanders. The second upgrade service application includes second identification information and a second subscription event group corresponding to the second identification information. The second subscription event group includes at least one secondary subscription;
文件发送模块,被配置为将与第二订阅内容对应的第一升级文件确定为目标升级文件,并将目标升级文件发送至其他升级需求方,以使其他升级需求方使用目标升级文件进行升级刷写。The file sending module is configured to determine the first upgrade file corresponding to the second subscription content as the target upgrade file, and send the target upgrade file to other upgrade demanders, so that the other upgrade demanders use the target upgrade file to perform upgrades. Write.
本申请实施例的第三方面,提供了一种电子设备,包括存储器、处理器以及存储在存储器中并且可在处理器上运行的计算机程序,该处理器执行计算机程序时实现上述方法的步骤。A third aspect of the embodiment of the present application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, the steps of the above method are implemented.
本申请实施例的第四方面,提供了一种计算机可读存储介质,该计算机可读存储介质存储有计算机程序,该计算机程序被处理器执行时实现上述方法的步骤。A fourth aspect of the embodiments of the present application provides a computer-readable storage medium. The computer-readable storage medium stores a computer program. When the computer program is executed by a processor, the steps of the above method are implemented.
本申请实施例与现有技术相比,其有益效果至少包括:一方面,升级需求方(例如,某个ECU)可作为升级服务需求方,向OTA升级主控提交第一升级服务申请,以向OTA升级主控获取与第一升级服务申请中的第一订阅内容对应的第一升级文件;之后,在使用该第一升级文件进行升级刷写时,可发布广播消息,以告知其他升级需求方(例如,其他ECU等)其当前可提供的升级服务,包括升级文件版本及升级文件等;另一方面,该升级需求方可作为升级服务提供方,在接收到其他升级需求方发送的第二升级服务申请时,将与第二升级服务申请中的第二订阅内容对应的第一升级文件确定为目标升级文件,并将该目标升级文件发送至其他升级需求方,以使其他升级需求方使用目标升级文件进行升级刷写。也即,升级需求方既可作为升级服务需求方,也可以作为升级服务提供方。在升级需求方作为升级服务需求方时,升级需求方在有升级需求时才会主动向OTA升级主控申请获取其所需求的第一升级文件,打破了传统的“被动式”接收升级刷写的模式,实现了“主动式”的升级刷写,这种“订阅-发布”的通信方式有利于节约大量的网络带宽。在升级需求方作为升级服务提供方时,可向其他升级需求方提供升级服务(包括升级文件下载等服务),使得OTA升级的方式更加灵活和多样化,从而充分发挥OTA升级的潜力。通过上述方式,可实现一个升级需求方同时升级多个不同的应用,也可实现多个不同的升级需求方同时升级同一应用,从而有效提高了升级效率。Compared with the existing technology, the beneficial effects of the embodiments of this application at least include: on the one hand, the upgrade demander (for example, a certain ECU) can serve as the upgrade service demander and submit a first upgrade service application to the OTA upgrade master to Obtain the first upgrade file corresponding to the first subscription content in the first upgrade service application from the OTA upgrade master; later, when using the first upgrade file for upgrade flashing, a broadcast message can be issued to inform other upgrade requirements The upgrade service that the party (for example, other ECU, etc.) can currently provide, including upgrade file version and upgrade file, etc.; on the other hand, the upgrade requester can serve as an upgrade service provider and receive the third upgrade requester sent by other upgrade requesters. When applying for the second upgrade service, determine the first upgrade file corresponding to the second subscription content in the second upgrade service application as the target upgrade file, and send the target upgrade file to other upgrade demanders so that other upgrade demanders Use the target upgrade file to perform upgrade flashing. That is, the upgrade demander can be both an upgrade service demander and an upgrade service provider. When the upgrade demander serves as the upgrade service demander, the upgrade demander will actively apply to the OTA upgrade master to obtain the first upgrade file it needs when there is an upgrade demand, breaking the traditional "passive" method of receiving upgrade flashes. mode, realizing "active" upgrade and flashing. This "subscribe-publish" communication method is conducive to saving a large amount of network bandwidth. When the upgrade demander acts as an upgrade service provider, it can provide upgrade services (including upgrade file downloads and other services) to other upgrade demanders, making the OTA upgrade method more flexible and diversified, thereby giving full play to the potential of OTA upgrades. Through the above method, one upgrade requester can upgrade multiple different applications at the same time, and multiple different upgrade requesters can upgrade the same application at the same time, thereby effectively improving the upgrade efficiency.
附图说明Description of the drawings
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其它的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the embodiments or description of the prior art will be briefly introduced below. Obviously, the drawings in the following description are only for the purpose of the present application. For some embodiments, for those of ordinary skill in the art, other drawings can be obtained based on these drawings without exerting creative efforts.
图1是本申请实施例的一种应用场景的场景示意图;Figure 1 is a schematic diagram of an application scenario according to the embodiment of the present application;
图2是本申请实施例提供的一种OTA升级系统的系统架构示意图;Figure 2 is a schematic system architecture diagram of an OTA upgrade system provided by an embodiment of the present application;
图3是本申请实施例提供的一种OTA升级方法的流程示意图;Figure 3 is a schematic flow chart of an OTA upgrade method provided by an embodiment of the present application;
图4是本申请实施例提供的另一种OTA升级系统的系统架构示意图;Figure 4 is a schematic system architecture diagram of another OTA upgrade system provided by an embodiment of the present application;
图5是本申请实施例提供的另一种OTA升级方法的流程示意图;Figure 5 is a schematic flow chart of another OTA upgrade method provided by an embodiment of the present application;
图6是本申请实施例提供的一种OTA升级装置的示意图;Figure 6 is a schematic diagram of an OTA upgrade device provided by an embodiment of the present application;
图7是本申请实施例提供的一种电子设备的结构示意图。FIG. 7 is a schematic structural diagram of an electronic device provided by an embodiment of the present application.
具体实施方式Detailed ways
以下描述中,为了说明而不是为了限定,提出了诸如特定系统结构、技术之类的具体细节,以便透彻理解本申请实施例。然而,本领域的技术人员应当清楚,在没有这些具体细节的其它实施例中也可以实现本申请。在其它情况中,省略对众所周知的系统、装置、电路以及方法的详细说明,以免不必要的细节妨碍本申请的描述。In the following description, for the purpose of explanation rather than limitation, specific details such as specific system structures and technologies are provided to provide a thorough understanding of the embodiments of the present application. However, it will be apparent to those skilled in the art that the present application may be practiced in other embodiments without these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
下面将结合附图详细说明根据本申请实施例的一种OTA升级方法和装置。An OTA upgrade method and device according to embodiments of the present application will be described in detail below with reference to the accompanying drawings.
图1是本申请实施例的一种应用场景的场景示意图。该应用场景可以包括OTA升级主控101、升级需求方102、其他升级需求方103、服务器104。Figure 1 is a schematic diagram of an application scenario according to an embodiment of the present application. The application scenario may include the OTA upgrade master 101, the upgrade requester 102, other upgrade requesters 103, and the server 104.
OTA升级主控101,可以是承载于VBOX(Vehicle BOX)中的OTA升级主控(简称“UMC”)。The OTA upgrade master 101 may be an OTA upgrade master (referred to as "UMC") carried in a VBOX (Vehicle BOX).
升级需求方102、其他升级需求方103,均可以是整车网关(简称“VGW”),也可以是挂接在整车网关下的各个ECU(Electronic Control Unit,电子控制单元)件,还可以是IVI(In-vehicle info ainment,车载信息娱乐系统)等。其中,升级需求方102、其他升级需求方103为不同的升级需求方,例如,当升级需求方102为整车网关1下挂接的ECU1时,其他升级需求方103可为除了ECU1之外的其他ECU件或者整车网关(如VGW2、VGW3……)、IVI等。The upgrade demander 102 and other upgrade demanders 103 can be vehicle gateways (referred to as "VGW"), or various ECU (Electronic Control Unit, electronic control unit) components connected to the vehicle gateway, or It is IVI (In-vehicle infotainment, in-vehicle infotainment system), etc. Among them, the upgrade demander 102 and other upgrade demanders 103 are different upgrade demanders. For example, when the upgrade demander 102 is the ECU1 connected to the vehicle gateway 1, the other upgrade demanders 103 can be other than ECU1. Other ECU components or vehicle gateways (such as VGW2, VGW3...), IVI, etc.
整车网关承载有OTA升级代理(简称“UA”);各ECU承载有OTA升级从控(简称“US”)。The vehicle gateway carries the OTA upgrade agent (referred to as "UA"); each ECU carries the OTA upgrade slave control (referred to as "US").
OTA升级主控101与升级需求方102、服务器104之间分别可通过100M/1000M以太网(EHT)相连;升级需求方102与其他升级需求方103之间可通过100M/1000M以太网相连。The OTA upgrade master 101 can be connected to the upgrade requesting party 102 and the server 104 through 100M/1000M Ethernet (EHT) respectively; the upgrade requesting party 102 can be connected to other upgrade requesting parties 103 through 100M/1000M Ethernet.
服务器104,可以是一台服务器,也可以是由若干台服务器组成的服务器集群,或者还可以是一个云计算服务中心,本申请实施例对此不作限制。The server 104 may be one server, a server cluster composed of several servers, or a cloud computing service center, which is not limited in the embodiment of the present application.
图2是本申请实施例提供的一种OTA升级系统的系统架构示意图。为了便于描述,图中仅示出了与本申请实施例相关的部分。Figure 2 is a schematic system architecture diagram of an OTA upgrade system provided by an embodiment of the present application. For convenience of description, only parts related to the embodiments of the present application are shown in the figure.
如图2所示,该OTA升级系统包括OTA升级主控101、升级需求方102、其他升级需求方103、服务器104。As shown in Figure 2, the OTA upgrade system includes an OTA upgrade master 101, an upgrade demander 102, other upgrade demanders 103, and a server 104.
其中,OTA升级主控101包括远控/V2X(vehicle to vehicle)/OTA主控服务层、原子服务层、设备抽象层、中间件、操作系统和硬件层。原子服务层包括多个原子服务,如请求下载、版本推送、版本检测、请求升级、文件验签、通信算法、发布升级、文件(自)升级、加解密等。中间件包括SOMEIP/MQTT/DOIP/UDS协议栈。每一个原子服务对应一个单一功能的函数接口。Among them, OTA upgrade main control 101 includes remote control/V2X (vehicle to vehicle)/OTA main control service layer, atomic service layer, device abstraction layer, middleware, operating system and hardware layer. The atomic service layer includes multiple atomic services, such as request download, version push, version detection, request upgrade, file signature verification, communication algorithm, release upgrade, file (self) upgrade, encryption and decryption, etc. Middleware includes SOMEIP/MQTT/DOIP/UDS protocol stack. Each atomic service corresponds to a single-function functional interface.
作为一示例,升级需求方102为整车网关1(VGW1)下挂接的ECU1-1,其他升级需求方103为与整车网关1(VGW1)连接的IVI。升级需求方102包括组合服务层(实现多个原子服务的组合功能)、原子服务层、设备抽象层、中间件(包括SOMEIP/MQTT/DOIP/UDS协议栈)、操作系统和硬件层。其他升级需求方103包括影音娱乐/OTA服务层、原子服务层(包括多个原子服务,如人机交互、音乐播放、文件下载、文件(自)升级、请求下载、订阅升级等)、设备抽象层、中间件(包括SOMEIP/MQTT/DOIP/UDS协议栈)、操作系统和硬件层。As an example, the upgrade requester 102 is the ECU1-1 mounted under the vehicle gateway 1 (VGW1), and the other upgrade requesters 103 are IVIs connected to the vehicle gateway 1 (VGW1). The upgrade requester 102 includes a composite service layer (implementing the combined function of multiple atomic services), an atomic service layer, a device abstraction layer, middleware (including SOMEIP/MQTT/DOIP/UDS protocol stack), an operating system and a hardware layer. Other upgrade demand parties 103 include audio and video entertainment/OTA service layer, atomic service layer (including multiple atomic services, such as human-computer interaction, music playback, file download, file (self) upgrade, request download, subscription upgrade, etc.), device abstraction Layer, middleware (including SOMEIP/MQTT/DOIP/UDS protocol stack), operating system and hardware layer.
OTA升级主控101、升级需求方102、其他升级需求方103、服务器104之间可通过SOME/IP(Scalable service-Oriented Middle ware over IP)协议实现“订阅-发布”通信。SOME/IP是实现SOA(Service-Oriented Architecture,面向服务的体系结构)的协议之一。车载以太网包括应用层、传输层、网络层、数据链路层和物理层。SOME/IP是在传输层UDP/TCP协议基础之上,拥有特定的服务交互机制,服务上线后广播告知域内其他节点,其他节点收到服务广播后,请求或者订阅相关服务接口,不同于传统车载网络的通讯方式,当有请求发出时,SOME/IP才会发送数据,否则不发送,这样总线上就没有不必要的数据,降低了系统负荷。随着汽车通信总线及整车电子电气架构的不断发展,基于CAN总线的面向信号的通信模式已不能满足智能汽车SOA架构的发展要求,SOME/IP协议是当前汽车通信实现SOA架构最核心的通信协议之一。The OTA upgrade master 101, the upgrade requester 102, other upgrade requesters 103, and the server 104 can realize "subscribe-publish" communication through the SOME/IP (Scalable service-Oriented Middle ware over IP) protocol. SOME/IP is one of the protocols that implements SOA (Service-Oriented Architecture, service-oriented architecture). Automotive Ethernet includes application layer, transport layer, network layer, data link layer and physical layer. SOME/IP is based on the transport layer UDP/TCP protocol and has a specific service interaction mechanism. After the service goes online, it broadcasts to inform other nodes in the domain. After receiving the service broadcast, other nodes request or subscribe to relevant service interfaces, which is different from traditional vehicle-mounted According to the communication method of the network, SOME/IP will only send data when a request is sent, otherwise it will not send it. In this way, there will be no unnecessary data on the bus and the system load will be reduced. With the continuous development of automobile communication bus and vehicle electronic and electrical architecture, the signal-oriented communication model based on CAN bus can no longer meet the development requirements of smart automobile SOA architecture. The SOME/IP protocol is the core communication of the current SOA architecture for automobile communication. One of the agreements.
SOME/IP协议以服务元素为单位管理数据信息,服务元素可分为Event、Method、Field三种类型。Event是一种单向的数据传输方式,由Server向其订阅者发布服务事件;Method是一种远程函数调用的通信方式;Field类似于Event和Method的结合体,允许Client获取/设置/订阅Server端事件的状态信息。通过Service Interface实现数据信息的传输与共享。The SOME/IP protocol manages data information in units of service elements. Service elements can be divided into three types: Event, Method, and Field. Event is a one-way data transmission method, in which the Server publishes service events to its subscribers; Method is a communication method for remote function calls; Field is similar to a combination of Event and Method, allowing the Client to obtain/set/subscribe to the Server Status information of end events. The transmission and sharing of data information is realized through Service Interface.
需要说明的是,上述的OTA升级主控101、升级需求方102、其他升级需求方103、服务器104的具体类型、数量和组合等可以根据应用场景实际需求进行调整,本申请在此不做具体限制。It should be noted that the specific types, quantities and combinations of the above-mentioned OTA upgrade master 101, upgrade demander 102, other upgrade demanders 103, and servers 104 can be adjusted according to the actual needs of the application scenario, and will not be detailed here in this application. limit.
图3是本申请实施例提供的一种OTA升级方法的流程示意图。图3的OTA升级方法可以由图1的升级需求方102执行。如图3所示,该OTA升级方法包括:Figure 3 is a schematic flowchart of an OTA upgrade method provided by an embodiment of the present application. The OTA upgrade method in Figure 3 can be performed by the upgrade requester 102 in Figure 1 . As shown in Figure 3, the OTA upgrade method includes:
步骤S301,向OTA升级主控提交第一升级服务申请,第一升级服务申请包括第一标识信息以及与第一标识信息对应的第一订阅事件组,第一订阅事件组包括至少一个第一订阅内容。Step S301: Submit a first upgrade service application to the OTA upgrade master. The first upgrade service application includes first identification information and a first subscription event group corresponding to the first identification information. The first subscription event group includes at least one first subscription. content.
第一标识信息,是指升级需求方102的身份标识信息,例如,可以是身份ID、数字编码等。The first identification information refers to the identity identification information of the upgrade requester 102, which may be an identity ID, a digital code, etc., for example.
第一订阅内容,通常是指升级需求方102根据其实际需求想要订阅的升级软件名称及升级版本号等内容。The first subscription content usually refers to the upgrade software name and upgrade version number that the upgrade requester 102 wants to subscribe to based on its actual needs.
第一订阅事件组,为包括各个第一订阅内容的集合,用于表征升级需求方102想要订阅的所有升级服务。The first subscription event group is a set including each first subscription content, and is used to represent all upgrade services that the upgrade requester 102 wants to subscribe to.
例如,若升级需求方102想要订阅“QQ”、“微信”、“头条”和“固件升级更新”这四款软件的最新升级版本,则第一订阅事件组包括[(A,up-to-date),(B,up-to-date),(C,up-to-date),(D,up-to-date)],共四个第一订阅内容。其中,(A,up-to-date)为一个第一订阅内容,A表示“QQ”,up-to-date表示最新版本;(B,up-to-date)为一个第一订阅内容,B表示“微信”,up-to-date表示最新版本;(C,up-to-date)为一个第一订阅内容,C表示“头条”,up-to-date表示最新版本;(D,up-to-date)为一个第一订阅内容,D表示“固件升级更新”,up-to-date表示最新版本。For example, if the upgrade demander 102 wants to subscribe to the latest upgrade versions of the four software "QQ", "WeChat", "Toutiao" and "Firmware Upgrade Update", then the first subscription event group includes [(A, up-to -date), (B, up-to-date), (C, up-to-date), (D, up-to-date)], a total of four first subscription contents. Among them, (A, up-to-date) is a first subscription content, A represents "QQ", up-to-date represents the latest version; (B, up-to-date) is a first subscription content, B means "WeChat", up-to-date means the latest version; (C, up-to-date) is the first subscription content, C means "Toutiao", up-to-date means the latest version; (D, up- to-date) is the first subscription content, D means "firmware upgrade update", and up-to-date means the latest version.
步骤S302,在接收OTA升级主控传输过来的与每一个第一订阅内容对应的第一升级文件时,使用第一升级文件进行升级刷写,并发布广播消息,广播消息至少包括第一升级文件的第一版本信息。Step S302: When receiving the first upgrade file corresponding to each first subscription content transmitted by the OTA upgrade master, use the first upgrade file to perform upgrade flashing, and publish a broadcast message, which at least includes the first upgrade file. of the first version information.
为了便于理解,继续沿用上述示例,第一订阅内容(A,up-to-date)对应的第一升级文件为“QQ”的最新升级版本文件;第一订阅内容(B,up-to-date)对应的第一升级文件为“微信”的最新升级版本文件;第一订阅内容(C,up-to-date)对应的第一升级文件为“头条”的最新升级版本文件;第一订阅内容(D,up-to-date)对应的第一升级文件为“固件升级更新”的最新升级版本文件。For ease of understanding, continue to use the above example. The first upgrade file corresponding to the first subscription content (A, up-to-date) is the latest upgraded version file of "QQ"; the first subscription content (B, up-to-date) ) is the latest upgraded version file of “WeChat”; the first upgraded file corresponding to the first subscription content (C, up-to-date) is the latest upgraded version file of “Toutiao”; the first subscription content The first upgrade file corresponding to (D, up-to-date) is the latest upgrade version file of the "firmware upgrade update".
在一实施方式中,升级需求方102在获取到上述四个第一订阅内容的第一升级文件之后,可先将第一升级文件暂存在预设的存储空间内,然后可以根据实际情况(如网络带宽、用户请求等),可选地分别使用这四个第一升级文件同时升级“QQ”、“微信”、“头条”和“固件升级更新”这四款软件应用,或者分批次在不同时段使用其中的一个或两个或三个第一升级文件升级相应的软件应用,从而实现一个升级需求方同时升级多个不同的软件应用。In one embodiment, after obtaining the first upgrade files of the above four first subscription contents, the upgrade requester 102 may first temporarily store the first upgrade files in a preset storage space, and then the upgrade requester 102 may modify the files according to the actual situation (such as network bandwidth, user requests, etc.), you can optionally use these four first upgrade files to upgrade the four software applications "QQ", "WeChat", "Toutiao" and "Firmware Upgrade Update" at the same time, or in batches. One, two, or three of the first upgrade files are used to upgrade corresponding software applications at different periods of time, thereby enabling one upgrade requester to upgrade multiple different software applications at the same time.
在另一实施方式中,OTA升级主控101在接收到升级需求方102的第一订阅事件组后,若确认服务器104有与第一订阅事件组中的第一订阅内容对应的第一升级文件,可以直接对升级需求方102的相应软件进行升级刷写,无需再将第一升级文件传输至升级需求方102后,再由升级需求方102自行进行升级刷写,由此可简化第一升级文件的中间传输流程,提高升级效率。In another embodiment, after receiving the first subscription event group from the upgrade requester 102, the OTA upgrade master 101 confirms that the server 104 has the first upgrade file corresponding to the first subscription content in the first subscription event group. , the corresponding software of the upgrade requesting party 102 can be directly upgraded and flashed. There is no need to transfer the first upgrade file to the upgrade requesting party 102, and then the upgrade requesting party 102 can perform the upgrade and flashing by itself, thus simplifying the first upgrade. The intermediate file transfer process improves upgrade efficiency.
步骤S303,接收其他升级需求方发送的第二升级服务申请,第二升级服务申请包括第二标识信息以及与第二标识信息对应的第二订阅事件组,第二订阅事件组包括至少一个第二订阅内容。Step S303: Receive a second upgrade service application sent by other upgrade requesters. The second upgrade service application includes second identification information and a second subscription event group corresponding to the second identification information. The second subscription event group includes at least one second Subscription content.
第二标识信息,是指其他升级需求方103的身份标识信息,例如,可以是身份ID、数字编码等。The second identification information refers to the identity identification information of other upgrade requesting parties 103, for example, it may be an identity ID, a digital code, etc.
第二订阅内容,通常是指其他升级需求方103根据其实际需求想要订阅的升级软件名称及升级版本号等内容。The second subscription content usually refers to the upgrade software name and upgrade version number that other upgrade demanders 103 want to subscribe to based on their actual needs.
第二订阅事件组,为包括各个第二订阅内容的集合,用于表征其他升级需求方103想要订阅的所有升级服务。The second subscription event group is a set including each second subscription content, and is used to represent all upgrade services that other upgrade demanders 103 want to subscribe to.
例如,若其他升级需求方103想要订阅“QQ”和“微信”这两款软件应用的最新升级版本,则第二订阅事件组包括[(A,up-to-date),(B,up-to-date)],共两个第二订阅内容。其中,(A,up-to-date)为一个第二订阅内容,A表示“QQ”,up-to-date表示最新版本;(B,up-to-date)为一个第二订阅内容,B表示“微信”,up-to-date表示最新版本。For example, if other upgrade demanders 103 want to subscribe to the latest upgraded versions of the two software applications "QQ" and "WeChat", the second subscription event group includes [(A, up-to-date), (B, up -to-date)], a total of two second subscription contents. Among them, (A, up-to-date) is a second subscription content, A means "QQ", up-to-date means the latest version; (B, up-to-date) is a second subscription content, B It means "WeChat", and up-to-date means the latest version.
步骤S304,将与第二订阅内容对应的第一升级文件确定为目标升级文件,并将目标升级文件发送至其他升级需求方,以使其他升级需求方使用目标升级文件进行升级刷写。Step S304: Determine the first upgrade file corresponding to the second subscription content as the target upgrade file, and send the target upgrade file to other upgrade demanders, so that other upgrade demanders use the target upgrade file to perform upgrade flashing.
作为一示例,假设升级需求方102接收到其他升级需求方103的第二订阅事件组为[(A,up-to-date),(B,up-to-date)],那么升级需求方102可先搜索其存储空间内是否存储有与第二订阅内容(A,up-to-date)对应的“QQ”最新版本文件,以及与第二订阅内容(B,up-to-date)对应的“微信”最新版本文件。若存在,则将之前从OTA升级主控101处获取到的“QQ”最新版本文件、“微信”最新版本文件确定为目标升级文件,并将这些目标升级文件发送至其他升级需求方103。As an example, assume that the upgrade requester 102 receives the second subscription event group of other upgrade requesters 103 as [(A, up-to-date), (B, up-to-date)], then the upgrade requester 102 You can first search whether the latest version of "QQ" file corresponding to the second subscription content (A, up-to-date) is stored in its storage space, and whether it is stored in the storage space corresponding to the second subscription content (B, up-to-date). "WeChat" latest version file. If they exist, determine the latest version files of "QQ" and the latest version of "WeChat" previously obtained from the OTA upgrade master 101 as target upgrade files, and send these target upgrade files to other upgrade demanders 103.
若是升级需求方102经搜索发现其存储空间内没有与第二订阅内容(A,up-to-date)对应的“QQ”最新版本文件时,可向其他升级需求方103返回订阅不成功的消息。此后,其他升级需求方103可自行向OTA升级主控101提出第三升级服务申请,该第三升级服务申请包括第二订阅内容(A,up-to-date),以获取到对应的“QQ”最新版本文件。If the upgrade requesting party 102 finds through search that there is no latest version of "QQ" file corresponding to the second subscription content (A, up-to-date) in its storage space, it can return a message of unsuccessful subscription to other upgrade requesting parties 103. . After that, other upgrade demanders 103 can submit a third upgrade service application to the OTA upgrade master 101 on their own. The third upgrade service application includes the second subscription content (A, up-to-date) to obtain the corresponding "QQ "The latest version of the file.
本申请实施例提供的技术方案,升级需求方既可作为升级服务需求方,也可以作为升级服务提供方。在升级需求方作为升级服务需求方时,升级需求方在有升级需求时才会主动向OTA升级主控申请获取其所需求的第一升级文件,打破了传统的“被动式”接收升级刷写的模式,实现了“主动式”的升级刷写,这种“订阅-发布”的通信方式有利于节约大量的网络带宽。在升级需求方作为升级服务提供方时,可向其他升级需求方提供升级服务(包括升级文件下载等服务),使得OTA升级的方式更加灵活和多样化,从而充分发挥OTA升级的潜力。通过上述方式,可实现一个升级需求方同时升级多个不同的应用,也可实现多个不同的升级需求方同时升级同一应用,从而有效提高了升级效率。According to the technical solution provided by the embodiment of this application, the upgrade requester can be either the upgrade service demander or the upgrade service provider. When the upgrade demander serves as the upgrade service demander, the upgrade demander will actively apply to the OTA upgrade master to obtain the first upgrade file it needs when there is an upgrade demand, breaking the traditional "passive" method of receiving upgrade flashes. mode, realizing "active" upgrade and flashing. This "subscribe-publish" communication method is conducive to saving a large amount of network bandwidth. When the upgrade demander acts as an upgrade service provider, it can provide upgrade services (including upgrade file downloads and other services) to other upgrade demanders, making the OTA upgrade method more flexible and diversified, thereby giving full play to the potential of OTA upgrades. Through the above method, one upgrade requester can upgrade multiple different applications at the same time, and multiple different upgrade requesters can upgrade the same application at the same time, thereby effectively improving the upgrade efficiency.
在一些实施例中,上述步骤S301中,向OTA升级主控提交第一升级服务申请,包括:In some embodiments, in the above step S301, submitting a first upgrade service application to the OTA upgrade master includes:
获取OTA升级主控发布的升级服务报文、升级指标信息和第一标识信息,升级服务报文包括至少一个升级事件,每一个升级事件均包括升级标识信息以及与升级标识信息对应的升级文件版本信息;Obtain the upgrade service message, upgrade indicator information and first identification information issued by the OTA upgrade master. The upgrade service message includes at least one upgrade event. Each upgrade event includes upgrade identification information and the upgrade file version corresponding to the upgrade identification information. information;
根据升级指标信息、升级标识信息和升级文件版本信息,确定至少一个第一订阅内容;Determine at least one first subscription content based on the upgrade indicator information, upgrade identification information and upgrade file version information;
基于第一订阅内容和第一标识信息,向OTA升级主控提交第一升级服务申请。Based on the first subscription content and the first identification information, a first upgrade service application is submitted to the OTA upgrade master.
升级服务报文,通常是指升级服务提供方(如OTA升级主控等)在准备好升级服务,且该升级服务满足发布条件后,主动发布的Offer Service报文。Offer Service报文中至少包括升级标识信息(如软件名称、软件ID等)、与该升级标识信息对应的升级文件版本信息(如软件版本号等)。The upgrade service message usually refers to the Offer Service message that the upgrade service provider (such as OTA upgrade master, etc.) actively releases after the upgrade service is ready and the upgrade service meets the release conditions. The Offer Service message at least includes upgrade identification information (such as software name, software ID, etc.) and upgrade file version information (such as software version number, etc.) corresponding to the upgrade identification information.
升级指标信息,主要是指升级需求方想要升级的固件或软件及其软件版本信息。例如,升级需求方(如IVI)想要将“QQ”和“微信”这两款软件升级至当前最新版本,那么升级指标信息至少包括“QQ”和“微信”的软件名称及其当前最新版本号。Upgrade indicator information mainly refers to the firmware or software that the upgrade demander wants to upgrade and its software version information. For example, if the upgrade demander (such as IVI) wants to upgrade the two software "QQ" and "WeChat" to the latest version, then the upgrade indicator information at least includes the software names of "QQ" and "WeChat" and their current latest versions. Number.
作为一示例,OTA升级主控101可以在升级服务准备好,且该服务满足发布条件后,主动发布Offer Service报文(即升级服务报文),告知组播内其他节点,该服务已经启动,可以创建服务连接。升级需求方102在网络中接收到相关服务的Offer Service报文,且想要访问该升级服务时,可向OTA升级主控101提交第一升级服务申请。As an example, the OTA upgrade master 101 can actively publish an Offer Service message (i.e., an upgrade service message) after the upgrade service is ready and the service meets the release conditions to inform other nodes in the multicast that the service has been started. Service connections can be created. When the upgrade demander 102 receives the Offer Service message of the relevant service in the network and wants to access the upgrade service, it can submit a first upgrade service application to the OTA upgrade master 101.
若是升级需求方102在网络中未接收到或暂时未接收到OTA升级主控101发布的升级服务报文,则可发送Find Service报文主动寻找服务,如果OTA升级主控101准备好升级服务,则会回复Offer Service报文。If the upgrade requesting party 102 does not receive or temporarily does not receive the upgrade service message issued by the OTA upgrade master 101 in the network, it can send a Find Service message to actively search for services. If the OTA upgrade master 101 is ready to upgrade the service, An Offer Service message will be replied.
当OTA升级主控101发现升级服务不可用,不满足服务发布条件时,会主动发送Stop Offer Service报文,告知组播内其他节点,该升级服务已不可用,停止服务支持。When the OTA upgrade master 101 discovers that the upgrade service is unavailable and does not meet the service release conditions, it will actively send a Stop Offer Service message to inform other nodes in the multicast that the upgrade service is no longer available and service support will be stopped.
作为一示例,假设升级需求方102想要订阅“QQ”、“微信”、“头条”和“固件升级更新”这四款软件的最新升级版本,即升级指标信息包括“QQ”、“微信”、“头条”和“固件升级更新”的软件名称和最新版本号;若升级需求方102接收到的升级服务报文中包含这四款软件的软件名称和最新版本号,那么可确定(A,up-to-date),(B,up-to-date),(C,up-to-date),(D,up-to-date)这四个第一订阅内容。之后,升级需求方102可将这四个第一订阅内容与其身份标识信息(即第一标识信息)组装成Subscribe报文(即订阅报文),该Subscribe报文包括第一订阅事件组[(A,up-to-date),(B,up-to-date),(C,up-to-date),(D,up-to-date)],并向OTA升级主控101提出第一升级服务申请。As an example, assume that the upgrade demander 102 wants to subscribe to the latest upgrade versions of the four software "QQ", "WeChat", "Toutiao" and "Firmware Upgrade Update", that is, the upgrade indicator information includes "QQ", "WeChat" , "Toutiao" and "Firmware Upgrade Update" software names and latest version numbers; if the upgrade service message received by the upgrade demander 102 contains the software names and latest version numbers of these four software, then it can be determined (A, up-to-date), (B, up-to-date), (C, up-to-date), (D, up-to-date) are the four first subscription contents. Afterwards, the upgrade demander 102 can assemble the four first subscription contents and their identity identification information (i.e., first identification information) into a Subscribe message (i.e., subscription message), which Subscribe message includes the first subscription event group [( A,up-to-date),(B,up-to-date),(C,up-to-date),(D,up-to-date)], and proposed the first step to OTA upgrade master 101 Upgrade service application.
OTA升级主控101在接收到升级需求方102的订阅报文后,需先判断升级需求方102是否符合订阅条件(例如,判断升级需求方是否为会员用户,是否具有订阅该服务的权限等),若是确定升级需求方102满足事件组订阅条件,则发送Subscribe ACK(订阅确认字符),告知升级需求方102订阅成功。当第一事件组内的事件准备就绪之后(即准备好与第一订阅内容对应的第一升级文件),OTA升级主控101会以约定好的形式发送相关事件给成功订阅的升级需求方102。如果该升级需求方102不符合事件组订阅条件,OTA升级主控101会直接回复Subscribe NACK(订阅不确认字符),告知订阅不成功。After receiving the subscription message from the upgrade requester 102, the OTA upgrade master 101 needs to first determine whether the upgrade requester 102 meets the subscription conditions (for example, determine whether the upgrade requester 102 is a member user and has the authority to subscribe to the service, etc.) , if it is determined that the upgrade requester 102 meets the event group subscription conditions, a Subscribe ACK (subscription confirmation character) is sent to inform the upgrade requester 102 that the subscription is successful. When the events in the first event group are ready (that is, the first upgrade file corresponding to the first subscription content is ready), the OTA upgrade master 101 will send the relevant events to the successfully subscribed upgrade requester 102 in the agreed form. . If the upgrade requester 102 does not meet the event group subscription conditions, the OTA upgrade master 101 will directly reply Subscribe NACK (subscription non-confirmation character) to inform that the subscription was unsuccessful.
当升级需求方102订阅某个事件组之后,发现后续并不在需要该事件组的数据了,可发送Stop Subscribe报文向OTA升级主控101取消订阅相应事件。When the upgrade demander 102 subscribes to an event group and finds that the data of the event group is no longer needed, it can send a Stop Subscribe message to the OTA upgrade master 101 to unsubscribe from the corresponding event.
在一些实施例中,在上述步骤S304中,将与第二订阅内容对应的第一升级文件确定为目标升级文件,并将目标升级文件发送至其他升级需求方,具体包括:In some embodiments, in the above step S304, the first upgrade file corresponding to the second subscription content is determined as the target upgrade file, and the target upgrade file is sent to other upgrade requesters, specifically including:
若不存在与第二订阅内容对应的第一升级文件,则将第二升级服务申请转发至OTA升级主控;If there is no first upgrade file corresponding to the second subscription content, forward the second upgrade service application to the OTA upgrade master;
接收OTA升级主控下发的与第二订阅内容对应的第二升级文件,并将第二升级文件转发至其他升级需求方。Receive the second upgrade file corresponding to the second subscription content issued by the OTA upgrade master, and forward the second upgrade file to other upgrade requesters.
作为一示例,假设升级需求方102接收到其他升级需求方103的第二订阅事件组为[(A,up-to-date),(B,up-to-date)],若是升级需求方102经搜索发现其存储空间内没有与第二订阅内容(A,up-to-date)对应的“QQ”最新版本文件,只存在与第二订阅内容(B,up-to-date)对应的“微信”最新版本文件,那么可以先把“微信”最新版本文件确定为目标升级文件并发送至其他升级需求方103。与此同时,升级需求方102可向OTA升级主控101提交第四升级服务申请,该第四升级服务申请包括第二订阅内容(A,up-to-date)。升级需求方102在获取到OTA升级主控101传输过来的与第二订阅内容(A,up-to-date)对应的“QQ”最新版本文件后,再将该“微信”最新版本文件确定为目标升级文件并发送至其他升级需求方103。As an example, assume that the upgrade demander 102 receives the second subscription event group of other upgrade demanders 103 as [(A, up-to-date), (B, up-to-date)]. If the upgrade demander 102 After searching, it was found that there is no "QQ" latest version file corresponding to the second subscription content (A, up-to-date) in its storage space, and only the "QQ" file corresponding to the second subscription content (B, up-to-date) exists. "WeChat" latest version file, then you can first determine the latest version file of "WeChat" as the target upgrade file and send it to other upgrade requesters 103. At the same time, the upgrade demander 102 may submit a fourth upgrade service application to the OTA upgrade controller 101. The fourth upgrade service application includes the second subscription content (A, up-to-date). After obtaining the latest version file of "QQ" corresponding to the second subscription content (A, up-to-date) transmitted by the OTA upgrade master 101, the upgrade demander 102 determines the latest version file of "WeChat" as The target upgrade file is sent to other upgrade requesters 103.
若是OTA升级主控101以及服务器104均没有与第二订阅内容(A,up-to-date)对应的“QQ”最新版本文件,则可由OTA升级主控101向其他升级需求方103返回订阅不成功的消息。OTA升级主控101可根据与其他升级需求方103的约定,在有与第二订阅内容(A,up-to-date)对应的“QQ”最新版本文件后,再向其他升级需求方103下发与第二订阅内容(A,up-to-date)对应的“QQ”最新版本文件。If neither the OTA upgrade master 101 nor the server 104 has the latest "QQ" version file corresponding to the second subscription content (A, up-to-date), the OTA upgrade master 101 can return a subscription failure message to other upgrade requesters 103. Success news. The OTA upgrade master 101 can, according to the agreement with other upgrade demanders 103, have the latest version of "QQ" file corresponding to the second subscription content (A, up-to-date), and then download it to other upgrade demanders 103. Send the latest version file of "QQ" corresponding to the second subscription content (A, up-to-date).
在一些实施例中,在上述步骤S304中,将目标升级文件发送至其他升级需求方,包括:In some embodiments, in the above step S304, the target upgrade file is sent to other upgrade requesters, including:
向组内网关申请获取组内成员信息;Apply to the group gateway to obtain group member information;
根据组内成员信息,判断其他升级需求方是否为组内升级需求方;Based on the member information in the group, determine whether other upgrade demanders are upgrade demanders in the group;
若其他升级需求方为组内升级需求方,则将目标升级文件发送至其他升级需求方。If other upgrade requesters are within the group, the target upgrade file will be sent to the other upgrade requesters.
结合图4,作为一示例,假设升级需求方102为整车网关VGW1下挂接的ECU1-1,其他升级需求方103为整车网关VGW1下挂接的ECU1-n,那么ECU1-1可先向组内网关(即VGW1)发送组内成员信息的获取请求;ECU1-1在接收到VGW1返回的组内成员信息(包括组内成员的标识信息等)后,判断该组内成员信息中是否存在ECU1-n的标识信息;若存在ECU1-n的标识信息,则可确定ECU1-n为VGW1的组内成员,即为组内升级需求方,之后,ECU1-1可直接将目标升级文件发送至ECU1-n。Combined with Figure 4, as an example, assuming that the upgrade demander 102 is the ECU1-1 attached to the vehicle gateway VGW1, and the other upgrade demanders 103 are ECU1-n attached to the vehicle gateway VGW1, then ECU1-1 can first Send a request to obtain the group member information to the gateway in the group (i.e. VGW1); after receiving the group member information (including the identification information of the group members, etc.) returned by VGW1, ECU1-1 determines whether the group member information contains The identification information of ECU1-n exists; if the identification information of ECU1-n exists, it can be determined that ECU1-n is a member of the group of VGW1, that is, it is the upgrade requester in the group. After that, ECU1-1 can directly send the target upgrade file to ECU1-n.
在另一些实施例中,若其他升级需求方为组外升级需求方,则获取组外网关及其隶属成员的信息,并根据组外网关及其隶属成员的信息,确定其他升级需求方所隶属的组外网关;In other embodiments, if the other upgrade requesters are upgrade requesters outside the group, the information of the gateways outside the group and its affiliated members is obtained, and based on the information of the gateways outside the group and its affiliated members, determine the affiliations of the other upgrade demanders. The gateway outside the group;
若组外网关与组内网关为同车网关组,则将目标升级文件发送至组内网关,以使组内网关将目标升级文件发送至组外网关,经由组外网关将目标升级文件发送至其他升级需求方。If the gateway outside the group and the gateway within the group are in the same vehicle gateway group, send the target upgrade file to the gateway within the group, so that the gateway within the group sends the target upgrade file to the gateway outside the group, and then sends the target upgrade file to the gateway through the gateway outside the group. Other upgrade requesters.
结合图4,作为一示例,假设升级需求方102为整车网关VGW1下挂接的ECU1-1,其他升级需求方103为整车网关VGW2下挂接的ECU2-1,ECU1-1经查找VGW1提供的组内成员信息发现,该组内成员信息中不包含ECU2-1的标识信息,由此可确定ECU2-1与其分别隶属于不同的整车网关,即可确定ECU2-1为组外升级需求方。此时,ECU1-1可经由整车网关VGW1获取组外网关及其隶属成员的信息,通过查找组外网关及其隶属成员的信息确定ECU2-1是隶属于哪一个组外网关。Combined with Figure 4, as an example, assume that the upgrade demander 102 is ECU1-1 attached to the vehicle gateway VGW1, and the other upgrade demanders 103 are ECU2-1 attached to the vehicle gateway VGW2. ECU1-1 searches for VGW1 The provided member information of the group found that the member information of the group does not contain the identification information of ECU2-1. From this, it can be determined that ECU2-1 and the two belong to different vehicle gateways, and it can be determined that ECU2-1 is upgraded outside the group. demand side. At this time, ECU1-1 can obtain the information of the group external gateway and its subordinate members through the vehicle gateway VGW1, and determine which group external gateway ECU2-1 belongs to by searching the information of the group external gateway and its subordinate members.
假设经查找发现ECU2-1是隶属于整车网关VGW2的ECU件,那么进一步确认整车网关VGW2与整车网关VGW1是否为同车网关组(即属于同一辆车的网关)。若是VGW2与VGW1为同车网关组,则可将目标升级文件发送至VGW1,再经由VGW1将目标升级文件转发至VGW2,最后经由VGW2将目标升级文件转发其挂接的ECU2-1。Assume that ECU2-1 is found to be an ECU component belonging to the vehicle gateway VGW2, then further confirm whether the vehicle gateway VGW2 and the vehicle gateway VGW1 are in the same vehicle gateway group (that is, gateways belonging to the same vehicle). If VGW2 and VGW1 are in the same vehicle gateway group, the target upgrade file can be sent to VGW1, then forwarded to VGW2 via VGW1, and finally forwarded to its attached ECU2-1 via VGW2.
在一些实施例中,若组外网关与组内网关为异车网关组,则检测组外网关与组内网关之间的网络通道的网络连接状态;In some embodiments, if the gateway outside the group and the gateway within the group are in a different vehicle gateway group, the network connection status of the network channel between the gateway outside the group and the gateway within the group is detected;
若网络连接状态正常,则将目标升级文件发送至组内网关,以使组内网关将目标升级文件发送至组外网关,经由组外网关将目标升级文件发送至其他升级需求方。If the network connection status is normal, the target upgrade file is sent to the gateway in the group, so that the gateway in the group sends the target upgrade file to the gateway outside the group, and then sends the target upgrade file to other upgrade demanders via the gateway outside the group.
作为一示例,假设升级需求方102为甲车的整车网关VGW1下挂接的ECU1-1,其他升级需求方103为乙车的整车网关VGW3′下挂接的ECU3′-1,整车网关VGW1与整车网关VGW3′为异车网关组(即分别隶属于不同车辆的网关)。之后,可ECU1-1检测整车网关VGW1与整车网关VGW3′之间的网络通道的网络连接状态,例如,可以通过获取整车网关VGW1上外接整车网关VGW3′的网卡接口的网卡状态值来判断整车网关VGW1与整车网关VGW3′之间的网络通道的网络连接状态是否正常。一般地,网卡状态值为linkup时,表示网络连接状态正常,网卡状态值为linkdown时,表示网络连接状态异常。若是网络连接状态正常,则将目标升级文件发送至整车网关VGW1,经由整车网关VGW1将目标升级文件转发至乙车的整车网关VGW3′,再由整车网关VGW3′将该目标升级文件转发至ECU3′-1。As an example, assume that the upgrade requester 102 is the ECU1-1 attached to the vehicle gateway VGW1 of vehicle A, and the other upgrade requesters 103 are the ECU3′-1 attached to the vehicle gateway VGW3′ of vehicle B. The gateway VGW1 and the vehicle gateway VGW3' are different vehicle gateway groups (that is, gateways belonging to different vehicles). Afterwards, ECU1-1 can detect the network connection status of the network channel between the vehicle gateway VGW1 and the vehicle gateway VGW3'. For example, it can obtain the network card status value of the network card interface of the vehicle gateway VGW1 that is externally connected to the vehicle gateway VGW3'. To determine whether the network connection status of the network channel between the vehicle gateway VGW1 and the vehicle gateway VGW3' is normal. Generally, when the network card status value is linkup, it means that the network connection status is normal; when the network card status value is linkdown, it means that the network connection status is abnormal. If the network connection status is normal, the target upgrade file is sent to the vehicle gateway VGW1, and the target upgrade file is forwarded to the vehicle gateway VGW3′ of vehicle B via the vehicle gateway VGW1, and then the vehicle gateway VGW3′ forwards the target upgrade file. Forwarded to ECU3′-1.
通过上述方式,可实现属于组内网关的升级需求方和其他升级需求方、同车网关组间的升级需求方和其他升级需求方、异车网关组间的的升级需求方和其他升级需求方之间的“订阅-发布”服务通信交互,使得OTA升级的方式更加灵活和多样化,从而充分发挥OTA升级的潜力。此外,组内网关、同车网关组间的升级服务通信可采用以太网或CAN总线实现,可节约大量的网络带宽。Through the above method, it is possible to realize the upgrade demanders and other upgrade demanders belonging to the gateways within the group, the upgrade demanders and other upgrade demanders between the gateway groups of the same car, the upgrade demanders and other upgrade demanders between the gateway groups of different cars. The "subscribe-publish" service communication interaction between them makes the OTA upgrade method more flexible and diversified, thereby fully utilizing the potential of OTA upgrade. In addition, the upgrade service communication between gateways within the group and gateway groups in the same vehicle can be implemented using Ethernet or CAN bus, which can save a lot of network bandwidth.
当升级需求方和其他升级需求方所隶属的网关为异车网关组,可进一步判断升级需求方和其他升级需求方的所属车辆的距离差值是否满足预设的距离范围,若是满足预设的距离范围,则利用近场通信交互、蓝牙通信交互等方式来实现升级文件的传输,有利于节约传输所需的流量,降低OTA升级成本。When the gateway to which the upgrade demander and other upgrade demanders belong is a different vehicle gateway group, it can be further determined whether the distance difference between the upgrade demander and the vehicles belonging to other upgrade demanders meets the preset distance range. If it meets the preset distance range, Within the distance range, near-field communication interaction, Bluetooth communication interaction and other methods are used to realize the transmission of upgrade files, which is beneficial to saving the traffic required for transmission and reducing the cost of OTA upgrade.
示例性的,假设升级需求方102为甲车的整车网关VGW1下挂接的ECU1-1,其他升级需求方103为乙车的整车网关VGW3′下挂接的ECU3′-1,整车网关VGW1与整车网关VGW3′为异车网关组。ECU1-1可进一步获取自车(即甲车)的第一位置信息和乙车的第二位置信息,然后,根据第一位置信息和第二位置信息确认两车之间的距离差值;若是该距离差值满足预设的距离范围(例如,≤5米),则整车网关VGW1与整车网关VGW3′之间的通信交互可切换为近场通信模式或蓝牙通信模式,并基于近场通信交互或蓝牙通信交互,整车网关VGW1将目标升级文件传输至整车网关VGW3′,再经由整车网关VGW3′通过以太网/CAN总线转发至ECU3′-1。For example, it is assumed that the upgrade requester 102 is the ECU1-1 connected to the vehicle gateway VGW1 of vehicle A, and the other upgrade requesters 103 are the ECU3'-1 connected to the vehicle gateway VGW3' of vehicle B. The gateway VGW1 and the vehicle gateway VGW3' are different vehicle gateway groups. ECU1-1 can further obtain the first position information of its own vehicle (i.e. vehicle A) and the second position information of vehicle B, and then confirm the distance difference between the two vehicles based on the first position information and the second position information; if If the distance difference meets the preset distance range (for example, ≤5 meters), the communication interaction between the vehicle gateway VGW1 and the vehicle gateway VGW3' can be switched to the near field communication mode or the Bluetooth communication mode, and based on the near field Communication interaction or Bluetooth communication interaction, the vehicle gateway VGW1 transmits the target upgrade file to the vehicle gateway VGW3′, and then forwards it to the ECU3′-1 through the vehicle gateway VGW3′ through the Ethernet/CAN bus.
在一些实施例中,上述OTA,升级方法,还可包括如下步骤:In some embodiments, the above OTA upgrade method may also include the following steps:
在发布广播消息后,累计时间达到预设时长仍未接收到其他升级需求方发送的第二升级服务申请时,判断使用第一升级文件进行升级刷写的刷写流程是否已全部结束;After publishing the broadcast message, when the accumulated time reaches the preset time and no second upgrade service application is received from other upgrade demanders, it is determined whether the flash process of using the first upgrade file for upgrade flash has been completed;
若确定使用第一升级文件进行升级刷写的刷写流程已全部结束,则清空所有的第一升级文件。If it is determined that the flashing process of using the first upgrade file for upgrade and flashing has been completed, all the first upgrade files are cleared.
预设时长,可根据实际情况灵活设置,例如,可以设置为24小时、48小时等。The preset duration can be flexibly set according to actual conditions, for example, it can be set to 24 hours, 48 hours, etc.
作为一示例,假设预设时长为24小时,升级需求方102在发布广播消息后开始计时,在累计时间达到24小时仍未接收到其他升级需求方发送的第二升级服务申请时,先判断其使用第一升级文件进行刷写的刷写流程是否已全部结束;如果已经全部结束,则清空其存储空间内的所有第一升级文件,以释放占用的内容。As an example, assuming that the preset time is 24 hours, the upgrade requesting party 102 starts timing after publishing the broadcast message. When the cumulative time reaches 24 hours and has not received the second upgrade service application sent by other upgrade requesting parties, it first determines its Whether the flashing process using the first upgrade file for flashing has been completely completed; if it has been completely completed, clear all the first upgrade files in the storage space to release the occupied content.
上述所有可选技术方案,可以采用任意结合形成本申请的可选实施例,在此不再一一赘述。All the above optional technical solutions can be combined in any way to form optional embodiments of the present application, and will not be described again one by one.
图5是本申请实施例提供的另一种OTA升级方法的流程示意图。Figure 5 is a schematic flowchart of another OTA upgrade method provided by an embodiment of the present application.
以升级服务需求方为ECU,升级服务提供方为UMC为例,ECU侧的OTA升级流程大致如下:首先,ECU通过调用SOME/IP服务接口向UMC订阅该ECU件升级服务;然后,根据UMC返回的应答ACK判断该订阅是否成功;若是订阅成功,则判断是否有UMC推送的升级版本;若是有UMC推送的升级版本,则进一步确认是否升级新版本;若确认升级新版本,则调用原子服务层中的请求文件下载服务,以从UMC处下载相应的ECU文件(即UMC推送的升级版本文件);接着,判断是否接收到UMC发送的ECU文件下载完成通知;若是接收到UMC发送的ECU文件下载完成通知,则调用原子服务层中的请求文件升级刷写服务,进行升级文件刷写;之后,查询ECU文件安装是否完成;若是安装完成,则退出。Taking the upgrade service demander as ECU and the upgrade service provider as UMC as an example, the OTA upgrade process on the ECU side is roughly as follows: First, the ECU subscribes to the ECU software upgrade service from UMC by calling the SOME/IP service interface; then, according to the UMC return The response ACK determines whether the subscription is successful; if the subscription is successful, determine whether there is an upgraded version pushed by UMC; if there is an upgraded version pushed by UMC, further confirm whether to upgrade the new version; if it is confirmed to upgrade the new version, call the atomic service layer Request the file download service in to download the corresponding ECU file from UMC (i.e. the upgraded version file pushed by UMC); then, determine whether the ECU file download completion notification sent by UMC is received; if the ECU file download completion notification sent by UMC is received When the notification is completed, the request file upgrade and flash service in the atomic service layer is called to flash the upgrade file; after that, it is queried whether the ECU file installation is completed; if the installation is completed, exit.
TSP(服务器)作为OTA服务提供方,主要提供ECU件的升级版本及文件,管理着各ECU件的升级文件,各ECU需要升级时可经由VBOX从服务器获取相关的升级文件。As an OTA service provider, TSP (server) mainly provides upgraded versions and files of ECU software, and manages the upgrade files of each ECU software. When each ECU needs to be upgraded, the relevant upgrade files can be obtained from the server through VBOX.
对于UMC/UA/US而言,它们均既可作为服务提供方,也可作为服务需求方。UMC和TSP间,UMC为服务需求者,需从TSP获取需升级ECU的版本信息及文件升级包。For UMC/UA/US, they can serve as both service providers and service demanders. Between UMC and TSP, UMC is the service demander and needs to obtain the version information and file upgrade package of the ECU to be upgraded from TSP.
UMC、UA、US间,UMC/UA/US既可作为服务提供者也可作为服务需求者,按照自身系统提供OTA的升级服务进行OTA的文件升级及刷写。Between UMC, UA and US, UMC/UA/US can serve as both a service provider and a service demander, providing OTA upgrade services according to their own systems to upgrade and flash OTA files.
SOA SOMEIP OTA升级服务内容包括但不限于“提醒用户有新版本更新,请用户确认”、“下载指令对下载进行控制”、“升级指令对升级进行控制”、“请求下载”等。SOA SOMEIP OTA upgrade service content includes but is not limited to "reminding users that there is a new version update, asking users to confirm", "download instructions to control downloads", "upgrade instructions to control upgrades", "request downloads", etc.
在一实施例中,假设升级需求方102为IVI,VI同时向OTA升级主控101订阅了“QQ,微信,头条”和“固件升级更新”等升级事件组(即订阅了这些升级)需求,这时OTA升级主控101会将这些订阅需求同步到TSP。如果TSP有这些服务将通过OTA升级主控101通道将这些升级文件下载到IVI(或VBOX暂存)件中进行升级刷写,这样可以实现在一个升级需求方102同时升级不同的应用程序。如果暂时没有则将订阅消息保存,等有了新的版本及文件则以通知发布的消息通知订阅组件。In one embodiment, assuming that the upgrade requester 102 is IVI, the VI also subscribes to the OTA upgrade master 101 for upgrade event groups such as "QQ, WeChat, Toutiao" and "firmware upgrade update" (that is, it subscribes to these upgrades) requirements, At this time, the OTA upgrade master 101 will synchronize these subscription requirements to the TSP. If the TSP has these services, it will download these upgrade files to the IVI (or VBOX temporary storage) file through the OTA upgrade master 101 channel for upgrade and flashing, so that different applications can be upgraded simultaneously on one upgrade requester 102. If it is not available for the time being, the subscription message will be saved. When a new version and file are available, the subscription component will be notified with a notification release message.
在另一实施例中,假设升级需求方102为整车网关VGW1、VGW2、VGW3和VGW4,它们同时向OTA升级主控101订阅“TCP/IP END”等升级事件组(即订阅了这些升级)需求,这时OTA升级主控101会将这些订阅需求同步到TSP。如果TSP有这些服务将通过OTA升级主控101将这些升级文件下载到VGW1、VGW2、VGW3和VGW4中进行升级刷写,这样可以实现在多个升级需求方升级同一升级文件数据包。如果暂时没有则将订阅消息保存,等有了新的版本及文件则以通知发布的消息通知订阅组件。In another embodiment, it is assumed that the upgrade demander 102 is the vehicle gateway VGW1, VGW2, VGW3 and VGW4, and they simultaneously subscribe to upgrade event groups such as "TCP/IP END" to the OTA upgrade master 101 (that is, they subscribe to these upgrades) requirements, then the OTA upgrade master 101 will synchronize these subscription requirements to the TSP. If the TSP has these services, it will download these upgrade files to VGW1, VGW2, VGW3 and VGW4 through the OTA upgrade master 101 for upgrade and flashing, so that the same upgrade file data package can be upgraded on multiple upgrade demand parties. If it is not available for the time being, the subscription message will be saved. When a new version and file are available, the subscription component will be notified with a notification release message.
通过上述方式,各升级需求方可通过发布或订阅相同或不同的OTA升级服务,实现一个升级需求方同时升级多个不同的应用程序,也可实现多个升级需求方并行升级同一个应用程序,从而可实现“千人千面”的OTA定制升级服务。Through the above method, each upgrade demander can publish or subscribe to the same or different OTA upgrade services, so that one upgrade demander can upgrade multiple different applications at the same time, or multiple upgrade demanders can upgrade the same application in parallel. This enables OTA customized upgrade services for “thousands of people, thousands of faces”.
下述为本申请装置实施例,可以用于执行本申请方法实施例。对于本申请装置实施例中未披露的细节,请参照本申请方法实施例。The following are device embodiments of the present application, which can be used to execute method embodiments of the present application. For details not disclosed in the device embodiments of this application, please refer to the method embodiments of this application.
图6是本申请实施例提供的一种OTA升级装置的示意图。如图6所示,该OTA升级装置包括:Figure 6 is a schematic diagram of an OTA upgrade device provided by an embodiment of the present application. As shown in Figure 6, the OTA upgrade device includes:
申请发起模块601,被配置为向OTA升级主控提交第一升级服务申请,第一升级服务申请包括第一标识信息以及与第一标识信息对应的第一订阅事件组,第一订阅事件组包括至少一个第一订阅内容;The application initiation module 601 is configured to submit a first upgrade service application to the OTA upgrade master. The first upgrade service application includes first identification information and a first subscription event group corresponding to the first identification information. The first subscription event group includes At least one first subscription content;
消息广播模块602,被配置为在接收OTA升级主控传输过来的与每一个第一订阅内容对应的第一升级文件时,使用第一升级文件进行升级刷写,并发布广播消息,广播消息至少包括第一升级文件的第一版本信息;The message broadcast module 602 is configured to, when receiving the first upgrade file corresponding to each first subscription content transmitted from the OTA upgrade master, use the first upgrade file to perform upgrade flashing, and publish a broadcast message. The broadcast message is at least Includes first version information of the first upgrade file;
申请接收模块603,被配置为接收其他升级需求方发送的第二升级服务申请,第二升级服务申请包括第二标识信息以及与第二标识信息对应的第二订阅事件组,第二订阅事件组包括至少一个第二订阅内容;The application receiving module 603 is configured to receive a second upgrade service application sent by other upgrade demanders. The second upgrade service application includes second identification information and a second subscription event group corresponding to the second identification information. The second subscription event group Include at least one secondary subscription content;
文件发送模块604,被配置为将与第二订阅内容对应的第一升级文件确定为目标升级文件,并将目标升级文件发送至其他升级需求方,以使其他升级需求方使用目标升级文件进行升级刷写。The file sending module 604 is configured to determine the first upgrade file corresponding to the second subscription content as the target upgrade file, and send the target upgrade file to other upgrade demanders, so that other upgrade demanders use the target upgrade file to upgrade. Flash writing.
本申请实施例提供的技术方案,升级需求方既可作为升级服务需求方,也可以作为升级服务提供方。在升级需求方作为升级服务需求方时,升级需求方在有升级需求时才会主动向OTA升级主控申请获取其所需求的第一升级文件,打破了传统的“被动式”接收升级刷写的模式,实现了“主动式”的升级刷写,这种“订阅-发布”的通信方式有利于节约大量的网络带宽。在升级需求方作为升级服务提供方时,可向其他升级需求方提供升级服务(包括升级文件下载等服务),使得OTA升级的方式更加灵活和多样化,从而充分发挥OTA升级的潜力。通过上述方式,可实现一个升级需求方同时升级多个不同的应用,也可实现多个不同的升级需求方同时升级同一应用,从而有效提高了升级效率。According to the technical solution provided by the embodiment of this application, the upgrade requester can be either the upgrade service demander or the upgrade service provider. When the upgrade demander serves as the upgrade service demander, the upgrade demander will actively apply to the OTA upgrade master to obtain the first upgrade file it needs when there is an upgrade demand, breaking the traditional "passive" method of receiving upgrade flashes. mode, realizing "active" upgrade and flashing. This "subscribe-publish" communication method is conducive to saving a large amount of network bandwidth. When the upgrade demander acts as an upgrade service provider, it can provide upgrade services (including upgrade file downloads and other services) to other upgrade demanders, making the OTA upgrade method more flexible and diversified, thereby giving full play to the potential of OTA upgrades. Through the above method, one upgrade requester can upgrade multiple different applications at the same time, and multiple different upgrade requesters can upgrade the same application at the same time, thereby effectively improving the upgrade efficiency.
在一些实施例中,上述申请发起模块601,包括:In some embodiments, the above-mentioned application initiation module 601 includes:
信息获取单元,被配置为获取OTA升级主控发布的升级服务报文、升级指标信息和第一标识信息,升级服务报文包括至少一个升级事件,每一个升级事件均包括升级标识信息以及与升级标识信息对应的升级文件版本信息;The information acquisition unit is configured to acquire the upgrade service message, upgrade indicator information and first identification information issued by the OTA upgrade master. The upgrade service message includes at least one upgrade event, and each upgrade event includes upgrade identification information and upgrade information. The upgrade file version information corresponding to the identification information;
订阅确定单元,被配置为根据升级指标信息、升级标识信息和升级文件版本信息,确定至少一个第一订阅内容;a subscription determination unit configured to determine at least one first subscription content based on the upgrade indicator information, upgrade identification information, and upgrade file version information;
提交单元,被配置为基于第一订阅内容和第一标识信息,向OTA升级主控提交第一升级服务申请。The submission unit is configured to submit a first upgrade service application to the OTA upgrade master based on the first subscription content and the first identification information.
在一些实施例中,上述文件发送模块604,包括:In some embodiments, the above-mentioned file sending module 604 includes:
文件转发单元,被配置为若不存在与第二订阅内容对应的第一升级文件,则将第二升级服务申请转发至OTA升级主控;The file forwarding unit is configured to forward the second upgrade service application to the OTA upgrade master if there is no first upgrade file corresponding to the second subscription content;
接收单元,被配置为接收OTA升级主控下发的与第二订阅内容对应的第二升级文件,并将第二升级文件转发至其他升级需求方。The receiving unit is configured to receive the second upgrade file corresponding to the second subscription content issued by the OTA upgrade master, and forward the second upgrade file to other upgrade demanders.
在一些实施例中,上述文件发送模块604,包括:In some embodiments, the above-mentioned file sending module 604 includes:
获取单元,被配置为向组内网关申请获取组内成员信息;The acquisition unit is configured to apply to the gateway in the group to obtain the member information in the group;
判断单元,被配置为根据组内成员信息,判断其他升级需求方是否为组内升级需求方;The judgment unit is configured to judge whether other upgrade demanders are upgrade demanders in the group based on the member information in the group;
第一发送单元,被配置为若其他升级需求方为组内升级需求方,则将目标升级文件发送至其他升级需求方。The first sending unit is configured to send the target upgrade file to other upgrade demanders if they are upgrade demanders in the group.
在一些实施例中,上述文件发送模块604,还包括:In some embodiments, the above-mentioned file sending module 604 also includes:
确定单元,被配置为若其他升级需求方为组外升级需求方,则获取组外网关及其隶属成员的信息,并根据组外网关及其隶属成员的信息,确定其他升级需求方所隶属的组外网关;The determination unit is configured to obtain the information of the gateway outside the group and its subordinate members if the other upgrade demanders are upgrade demanders outside the group, and determine the information of the gateways outside the group and its subordinate members, and determine the network to which the other upgrade demanders belong. Gateway outside the group;
第二发送单元,被配置为若组外网关与组内网关为同车网关组,则将目标升级文件发送至组内网关,以使组内网关将目标升级文件发送至组外网关,经由组外网关将目标升级文件发送至其他升级需求方。The second sending unit is configured to send the target upgrade file to the gateway in the group if the gateway outside the group and the gateway in the group are in the same vehicle gateway group, so that the gateway in the group sends the target upgrade file to the gateway outside the group via the group. The foreign gateway sends the target upgrade file to other upgrade requesters.
在一些实施例中,上述文件发送模块604,还包括:In some embodiments, the above-mentioned file sending module 604 also includes:
检测单元,被配置为若组外网关与组内网关为异车网关组,则检测组外网关与组内网关之间的网络通道的网络连接状态;The detection unit is configured to detect the network connection status of the network channel between the gateway outside the group and the gateway within the group if the gateway outside the group and the gateway within the group are in a different vehicle gateway group;
转发单元,被配置为若网络连接状态正常,则将目标升级文件发送至组内网关,以使组内网关将目标升级文件发送至组外网关,经由组外网关将目标升级文件发送至其他升级需求方。The forwarding unit is configured to send the target upgrade file to the gateway in the group if the network connection status is normal, so that the gateway in the group sends the target upgrade file to the gateway outside the group, and sends the target upgrade file to other upgraders via the gateway outside the group. demand side.
通过上述方式,可实现属于组内网关的升级需求方和其他升级需求方、同车网关组间的升级需求方和其他升级需求方、异车网关组间的的升级需求方和其他升级需求方之间的“订阅-发布”服务通信交互,使得OTA升级的方式更加灵活和多样化,从而充分发挥OTA升级的潜力。此外,组内网关、同车网关组间的升级服务通信可采用以太网或CAN总线实现,可节约大量的网络带宽。Through the above method, it is possible to realize the upgrade demanders and other upgrade demanders belonging to the gateways within the group, the upgrade demanders and other upgrade demanders between the gateway groups of the same car, the upgrade demanders and other upgrade demanders between the gateway groups of different cars. The "subscribe-publish" service communication interaction between them makes the OTA upgrade method more flexible and diversified, thereby fully utilizing the potential of OTA upgrade. In addition, the upgrade service communication between gateways within the group and gateway groups in the same vehicle can be implemented using Ethernet or CAN bus, which can save a lot of network bandwidth.
在一些实施例中,上述OTA升级装置,还包括:In some embodiments, the above OTA upgrade device also includes:
判断模块,被配置为在发布广播消息后,累计时间达到预设时长仍未接收到其他升级需求方发送的第二升级服务申请时,判断使用第一升级文件进行升级刷写的刷写流程是否已全部结束;The judgment module is configured to judge whether the flash process of using the first upgrade file to perform upgrade flash is when the cumulative time reaches the preset time and the second upgrade service application sent by other upgrade demanders has not been received after the broadcast message is released. It’s all over;
清空模块,被配置为若确定使用第一升级文件进行升级刷写的刷写流程已全部结束,则清空所有的第一升级文件。The clearing module is configured to clear all the first upgrade files if it is determined that the flash process of using the first upgrade file for upgrade and flash has been completed.
应理解,上述实施例中各步骤的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。It should be understood that the sequence number of each step in the above embodiment does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present application.
图7是本申请实施例提供的电子设备7的示意图。如图7所示,该实施例的电子设备7包括:处理器701、存储器702以及存储在该存储器702中并且可在处理器701上运行的计算机程序703。处理器701执行计算机程序703时实现上述各个方法实施例中的步骤。或者,处理器701执行计算机程序703时实现上述各装置实施例中各模块/单元的功能。FIG. 7 is a schematic diagram of the electronic device 7 provided by the embodiment of the present application. As shown in FIG. 7 , the electronic device 7 of this embodiment includes: a processor 701 , a memory 702 , and a computer program 703 stored in the memory 702 and executable on the processor 701 . When the processor 701 executes the computer program 703, the steps in each of the above method embodiments are implemented. Alternatively, when the processor 701 executes the computer program 703, it implements the functions of each module/unit in each of the above device embodiments.
电子设备7可以是桌上型计算机、笔记本、掌上电脑及云端服务器等电子设备。电子设备7可以包括但不仅限于处理器701和存储器702。本领域技术人员可以理解,图7仅仅是电子设备7的示例,并不构成对电子设备7的限定,可以包括比图示更多或更少的部件,或者不同的部件。The electronic device 7 may be a desktop computer, a notebook, a handheld computer, a cloud server and other electronic devices. The electronic device 7 may include, but is not limited to, a processor 701 and a memory 702 . Those skilled in the art can understand that FIG. 7 is only an example of the electronic device 7 and does not constitute a limitation on the electronic device 7. It may include more or less components than shown in the figure, or different components.
处理器701可以是中央处理单元(Central Processing Unit,CPU),也可以是其它通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)或者其它可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。The processor 701 can be a central processing unit (CPU), other general-purpose processor, digital signal processor (Digital Signal Processor, DSP), application specific integrated circuit (Application Specific Integrated Circuit, ASIC), or field-processable processor. Programmable gate array (Field-Programmable Gate Array, FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc.
存储器702可以是电子设备7的内部存储单元,例如,电子设备7的硬盘或内存。存储器702也可以是电子设备7的外部存储设备,例如,电子设备7上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(Secure Digital,SD)卡,闪存卡(Flash Card)等。存储器702还可以既包括电子设备7的内部存储单元也包括外部存储设备。存储器702用于存储计算机程序以及电子设备所需的其它程序和数据。The memory 702 may be an internal storage unit of the electronic device 7 , for example, a hard disk or memory of the electronic device 7 . The memory 702 may also be an external storage device of the electronic device 7, such as a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (SD) card, a flash memory card ( Flash Card), etc. The memory 702 may also include both an internal storage unit of the electronic device 7 and an external storage device. Memory 702 is used to store computer programs and other programs and data required by the electronic device.
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将装置的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。实施例中的各功能单元、模块可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中,上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the division of the above functional units and modules is used as an example. In actual applications, the above functions can be allocated to different functional units and modules according to needs. Module completion means dividing the internal structure of the device into different functional units or modules to complete all or part of the functions described above. Each functional unit and module in the embodiment can be integrated into one processing unit, or each unit can exist physically alone, or two or more units can be integrated into one unit. The above-mentioned integrated unit can be hardware-based. It can also be implemented in the form of software functional units.
集成的模块/单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在一个计算机可读存储介质中。基于这样的理解,本申请实现上述实施例方法中的全部或部分流程,也可以通过计算机程序来指令相关的硬件来完成,计算机程序可以存储在计算机可读存储介质中,该计算机程序在被处理器执行时,可以实现上述各个方法实施例的步骤。计算机程序可以包括计算机程序代码,计算机程序代码可以为源代码形式、对象代码形式、可执行文件或某些中间形式等。计算机可读介质可以包括:能够携带计算机程序代码的任何实体或装置、记录介质、U盘、移动硬盘、磁碟、光盘、计算机存储器、只读存储器(Read-Only Memory,ROM)、随机存取存储器(Random Access Memory,RAM)、电载波信号、电信信号以及软件分发介质等。需要说明的是,计算机可读介质包含的内容可以根据司法管辖区内立法和专利实践的要求进行适当的增减,例如,在某些司法管辖区,根据立法和专利实践,计算机可读介质不包括电载波信号和电信信号。Integrated modules/units can be stored in a computer-readable storage medium if they are implemented in the form of software functional units and sold or used as independent products. Based on this understanding, this application can implement all or part of the processes in the methods of the above embodiments. It can also be completed by instructing relevant hardware through a computer program. The computer program can be stored in a computer-readable storage medium. The computer program can be processed after being processed. When the processor is executed, the steps of each of the above method embodiments can be implemented. A computer program may include computer program code, and the computer program code may be in the form of source code, object code, executable file or some intermediate form. Computer-readable media may include: any entity or device that can carry computer program code, recording media, USB flash drives, mobile hard drives, magnetic disks, optical disks, computer memory, read-only memory (Read-Only Memory, ROM), random access Memory (Random Access Memory, RAM), electrical carrier signals, telecommunications signals, and software distribution media, etc. It should be noted that the content contained in the computer-readable medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, the computer-readable medium is not Including electrical carrier signals and telecommunications signals.
以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围,均应包含在本申请的保护范围之内。The above embodiments are only used to illustrate the technical solutions of the present application, but are not intended to limit them. Although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments. Modifications are made to the recorded technical solutions, or equivalent substitutions are made to some of the technical features; these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of this application, and shall be included in this application. within the scope of protection.
Claims (10)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310854791.3A CN116931988A (en) | 2023-07-12 | 2023-07-12 | An OTA upgrade method, device, electronic equipment and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310854791.3A CN116931988A (en) | 2023-07-12 | 2023-07-12 | An OTA upgrade method, device, electronic equipment and storage medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN116931988A true CN116931988A (en) | 2023-10-24 |
Family
ID=88378312
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202310854791.3A Pending CN116931988A (en) | 2023-07-12 | 2023-07-12 | An OTA upgrade method, device, electronic equipment and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN116931988A (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117459190A (en) * | 2023-12-20 | 2024-01-26 | 中汽研(天津)汽车工程研究院有限公司 | An OTA communication method for heterogeneous central computing architecture |
CN118450354A (en) * | 2024-04-19 | 2024-08-06 | 重庆赛力斯凤凰智创科技有限公司 | OTA upgrade method, device, electronic device and medium based on service-oriented architecture |
-
2023
- 2023-07-12 CN CN202310854791.3A patent/CN116931988A/en active Pending
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN117459190A (en) * | 2023-12-20 | 2024-01-26 | 中汽研(天津)汽车工程研究院有限公司 | An OTA communication method for heterogeneous central computing architecture |
CN117459190B (en) * | 2023-12-20 | 2024-04-02 | 中汽研(天津)汽车工程研究院有限公司 | An OTA communication method for heterogeneous central computing architecture |
CN118450354A (en) * | 2024-04-19 | 2024-08-06 | 重庆赛力斯凤凰智创科技有限公司 | OTA upgrade method, device, electronic device and medium based on service-oriented architecture |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN116931988A (en) | An OTA upgrade method, device, electronic equipment and storage medium | |
US10659280B2 (en) | Vehicle-based communication method, system, and apparatus | |
WO2015021905A1 (en) | Software updating method, system, and device | |
JP2023544130A (en) | Vehicle upgrade method and device | |
CN112118315A (en) | Data processing system, method, device, electronic equipment and storage medium | |
JP2023544123A (en) | Data transmission system, data transmission method, intelligent vehicle, and device | |
CN112368997B (en) | Resource management method and device | |
CN117082137A (en) | Communication method, device, equipment and medium for maintaining OTA upgrade refreshing mode | |
CN117376339A (en) | OTA-based vehicle ECU upgrade method, device, equipment and media | |
CN110417876A (en) | Session method, node server and master control device in distributed system | |
CN109981778B (en) | Method, device, equipment and storage medium for realizing service of content distribution network | |
CN118484365A (en) | Service display method and device, electronic equipment and storage medium | |
CN112003923A (en) | Interaction method and device for driver team forming terminal and server cluster and electronic equipment | |
US20220294649A1 (en) | Certificate Revocation List Updating Method and Related Device | |
US7587752B2 (en) | Methods and apparatus for providing a control channel in a data network | |
WO2022002042A1 (en) | Access request distribution method, and server, computer-readable storage medium and cluster system | |
CN116193472B (en) | Vehicle network management method, device, electronic equipment and storage medium | |
CN113271229B (en) | Equipment control method and device, storage equipment, safety equipment, switch, router and server | |
US20240338204A1 (en) | Vehicle communication system and in-vehicle system | |
CN117938913A (en) | Internet of vehicles service management and control method and device, vehicle and medium | |
CN117061513A (en) | Method, management method, device, equipment and medium for establishing vehicle end and cloud service | |
CN119210912A (en) | Network management method, system and vehicle-mounted system | |
JP2025501728A (en) | OVER-THE-AIR OTA TECHNOLOGY BASED UPGRADE METHOD AND COMMUNICATION DEVICE | |
CN107306204B (en) | Network management permission control method, device and system | |
CN117424885A (en) | Data calling method, system, device, equipment and medium under high concurrency scene |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
TA01 | Transfer of patent application right |
Effective date of registration: 20241210 Address after: 400000 No. 229, Fusheng Avenue, Jiangbei District, Chongqing Applicant after: Thalys Automobile Co.,Ltd. Country or region after: China Address before: 618 Liangjiang Avenue, Longxing Town, Yubei District, Chongqing Applicant before: Chongqing Celes New Energy Automobile Design Institute Co.,Ltd. Country or region before: China |
|
TA01 | Transfer of patent application right |