CN111988557B - Vehicle-mounted video transmission method and vehicle-mounted video transmission system - Google Patents

Vehicle-mounted video transmission method and vehicle-mounted video transmission system Download PDF

Info

Publication number
CN111988557B
CN111988557B CN201910428825.6A CN201910428825A CN111988557B CN 111988557 B CN111988557 B CN 111988557B CN 201910428825 A CN201910428825 A CN 201910428825A CN 111988557 B CN111988557 B CN 111988557B
Authority
CN
China
Prior art keywords
application program
video data
subscription
ecu
camera
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.)
Active
Application number
CN201910428825.6A
Other languages
Chinese (zh)
Other versions
CN111988557A (en
Inventor
杜祖楠
吴承钦
杨东伟
艾兵
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
SAIC General Motors Corp Ltd
Pan Asia Technical Automotive Center Co Ltd
Original Assignee
SAIC General Motors Corp Ltd
Pan Asia Technical Automotive Center Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by SAIC General Motors Corp Ltd, Pan Asia Technical Automotive Center Co Ltd filed Critical SAIC General Motors Corp Ltd
Priority to CN201910428825.6A priority Critical patent/CN111988557B/en
Publication of CN111988557A publication Critical patent/CN111988557A/en
Application granted granted Critical
Publication of CN111988557B publication Critical patent/CN111988557B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N7/00Television systems
    • H04N7/18Closed-circuit television [CCTV] systems, i.e. systems in which the video signal is not broadcast
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N21/00Selective content distribution, e.g. interactive television or video on demand [VOD]
    • H04N21/40Client devices specifically adapted for the reception of or interaction with content, e.g. set-top-box [STB]; Operations thereof
    • H04N21/43Processing of content or additional data, e.g. demultiplexing additional data from a digital video stream; Elementary client operations, e.g. monitoring of home network or synchronising decoder's clock; Client middleware
    • H04N21/443OS processes, e.g. booting an STB, implementing a Java virtual machine in an STB or power management in an STB

Abstract

The invention relates to a vehicle-mounted communication technology, in particular to a method and a system for vehicle-mounted video transmission, a vehicle controller for implementing the method and a computer-readable storage medium. A method for vehicular video transmission according to an aspect of the present invention comprises the steps of: A) acquiring the subscription condition of an application program to video data, wherein the subscription condition comprises a local application program subscription and a cross-ECU application program subscription; and B) dynamically changing the transmission path of the video data based on the subscription condition.

Description

Vehicle-mounted video transmission method and vehicle-mounted video transmission system
Technical Field
The invention relates to a vehicle-mounted communication technology, in particular to a method and a system for vehicle-mounted video transmission, a vehicle controller for implementing the method and a computer-readable storage medium.
Background
With the development of the modern automobile industry, the scale and complexity of an automobile electric control system are increasing day by day, and the quantity of vehicle data needing to be shared is more and more, particularly the sharing of video data. At present, the vehicle-mounted video transmission scheme mainly adopts an Ethernet interface transmission scheme and an FPD-Link interface transmission scheme.
The camera type used in the ethernet interface transmission scheme is an ethernet camera, and the ethernet camera is characterized in that the sharing of Video data among a plurality of Electronic Control Units (ECUs) can be realized, and the low latency is realized by adopting an ethernet Audio Video Bridging (AVB) technology, but the scheme has some defects, for example, each camera occupies a Port of a switch, so that the number of Physical interface transceivers (PHYs) and switch chips of the ethernet is increased; the camera needs to have video compression and other functions, so that the operation complexity of a processor in the camera is improved, and a high-performance processor needs to be built in the camera, so that the cost of the camera is increased; because dynamic change of a video transmission path cannot be realized, video data can be sent to the ECU with a use requirement all the time, and because part of the ECUs can use the video data only at a certain time, and data is received all the time, waste of network bandwidth of the ECU which does not use the video data at the current time can be caused.
The camera type used by the FPD-Link interface transmission scheme is a camera with an FPD-Link interface, and the scheme can realize transmission of video, audio, control data and electric power through a Shielded Twisted Pair (STP) or coaxial cable, so that the cost of wiring harnesses is saved; meanwhile, the complexity of the internal functions of the camera is low, the performance requirement of a built-in processor is not high, and the cost is low; the cost of the FPD-Link interface coding and decoding chip is lower than that of PHY, so that the camera adopting the FPD-Link interface is more suitable for mass production. However, this solution does not enable sharing of camera video data among multiple ECUs.
Disclosure of Invention
To overcome one or more of the above disadvantages, the present invention provides the following technical solutions.
According to a first aspect of the present invention, there is provided a vehicle-mounted video transmission method, comprising the steps of: A) acquiring the subscription condition of an application program to video data, wherein the subscription condition comprises a local application program subscription and a cross-ECU application program subscription; and B) dynamically changing the transmission path of the video data based on the subscription condition.
According to an embodiment of the invention, the vehicle-mounted video transmission method further comprises the following steps: when the subscription condition is the local application program subscription, realizing the parallel access of the application program in the ECU to the video data by creating a shared memory and a read-write lock; and when the subscription condition is the cross-ECU application program subscription, dynamically configuring a virtual local area network of a switch and bandwidth reservation according to the requirement of the application program on the video data so as to realize cross-ECU sharing of the video data.
The vehicle-mounted video transmission method according to another embodiment of the present invention or any one of the above embodiments, further comprising an unsubscribing step of: when the unsubscriber is the local application program subscription, checking whether other local application program subscriptions exist at present, if no other local application program subscribers exist, removing the mapping of the shared memory and deleting the shared memory, and if other local application program subscribers exist, not processing; and when the unsubscriber is the cross-ECU application program subscription, dynamically configuring a switch virtual local area network and bandwidth reservation to end the transmission of the video data.
According to another embodiment of the invention or any embodiment of the invention, when the subscription condition is the cross-ECU application subscription, the ECU is connected via ethernet, the video data is compressed by H264 protocol, and the compressed video data is shared via ethernet by AVB protocol.
According to a second aspect of the present invention, there is provided an in-vehicle video transmission system, comprising: the camera service program module is configured to acquire the subscription condition of the application program to the video data and dynamically call the switch configuration service program module based on the subscription condition so as to realize dynamic change of the transmission path of the video data; a switch configuration server module configured to implement, in accordance with the invocation of the camera server module based on the subscription condition: when the subscription condition is cross-ECU application program subscription, dynamically configuring a virtual local area network of a switch and bandwidth reservation according to the requirement of the application program on the video data so as to realize cross-ECU sharing of the video data; and a camera data acquisition interface module packaged as an API interface and configured to provide an interface for applications to acquire the video data.
The in-vehicle video transmission system according to an embodiment of the second aspect of the present invention, wherein the camera service program module is further configured to: when the subscription condition is local application program subscription, packaging a camera drive so as to realize parallel access to the video data by the application program in the ECU through establishing a shared memory and a read-write lock; and when the subscription condition is cross-ECU application program subscription, dynamically calling a switch configuration service program module according to the requirement of the application program on the video data so as to realize cross-ECU sharing of the video data.
The in-vehicle video transmission system according to an embodiment of the second aspect of the invention or any of the above embodiments, wherein the camera service program module is further configured to perform the unsubscribing step of: when the unsubscriber is a local application program subscription, checking whether other local application program subscriptions exist currently, if no other local application program subscribers exist, removing the mapping of the shared memory and deleting the shared memory, and if other local application program subscribers exist, not processing; and when the unsubscriber is subscribed by the cross-ECU application program, dynamically calling the switch configuration service program module to dynamically configure the switch virtual local area network and the bandwidth reservation so as to finish the transmission of the video data.
According to an embodiment of the second aspect of the present invention or any one of the above embodiments, the ECU connects via ethernet, the video data is first compressed by H264 protocol, and the compressed video data is shared via ethernet by AVB protocol.
According to a third aspect of the present invention, there is provided a vehicle controller comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor executes the program to implement the in-vehicle video transmission method as defined in any one of the embodiments of the first aspect of the present invention.
According to a fourth aspect of the present invention, there is provided a computer-readable storage medium on which a computer program is stored, wherein the program, when executed by a processor, is adapted to carry out the method for in-vehicle video transmission according to any of the embodiments of the first aspect of the present invention.
According to one or more aspects of the present invention, the vehicle-mounted video transmission method and the system thereof as described above may be adopted, which introduces a Service Oriented Architecture (SOA) to form a Service-based vehicle-mounted video transmission scheme, which is a video data transmission scheme that is low in cost, high in bandwidth utilization, and capable of realizing cross-ECU sharing of video data.
Other features and advantages of the present in-vehicle video transmission method and system will be more particularly apparent from, or elucidated with, the drawings incorporated herein, and the following detailed description of certain principles of the invention.
Drawings
The above and/or other aspects and advantages of the present invention will become more apparent and more readily appreciated from the following description of the various aspects taken in conjunction with the accompanying drawings, in which like or similar elements are designated with like reference numerals. The drawings include:
fig. 1 is a flowchart of an on-board video transmission method according to an embodiment of the present invention.
Fig. 2 is a block diagram of an in-vehicle video transmission system according to still another embodiment of the present invention.
Fig. 3 is a timing chart of a video transmission method in the ECU according to the embodiment of the present invention.
Fig. 4 is a timing diagram of a video transmission method in different ECUs according to an embodiment of the present invention.
Fig. 5 is a schematic block diagram of an on-board video sharing scheme according to yet another embodiment of the present invention.
Fig. 6 is a schematic block diagram of a vehicle controller according to an embodiment of the invention.
Detailed Description
In this specification, the invention is described more fully with reference to the accompanying drawings, in which exemplary embodiments of the invention are shown. This invention may, however, be embodied in different forms and should not be construed as limited to the embodiments set forth herein. The embodiments are provided so that this disclosure will be thorough and complete, and will fully convey the scope of the invention to those skilled in the art.
Words such as "comprising" and "comprises" mean that, in addition to having elements or steps which are directly and explicitly stated in the description, the solution of the invention does not exclude other elements or steps which are not directly or explicitly stated. Terms such as "first" and "second" do not denote an order of the elements in time, space, size, etc., but rather are used to distinguish one element from another.
The present invention is described below with reference to flowchart illustrations, block diagrams, and/or flow diagrams of methods and systems according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and/or block diagrams, and combinations of blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions/acts specified in the flowchart and/or block and/or flow diagram block or blocks.
These computer program instructions may be stored in a computer-readable memory that can direct a computer or other programmable processor to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function/act specified in the flowchart and/or block diagram block or blocks.
The computer program instructions may be loaded onto a computer or other programmable data processor to cause a series of operational steps to be performed on the computer or other programmable processor to produce a computer implemented process such that the instructions which execute on the computer or other programmable processor provide steps for implementing the functions or acts specified in the flowchart and/or block diagram block or blocks. It should also be noted that, in some alternative implementations, the functions/acts noted in the blocks may occur out of the order noted in the flowcharts. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality/acts involved.
Fig. 1 is a flowchart of an on-board video transmission method according to an embodiment of the present invention.
As shown in fig. 1, in step 110, a subscription condition of the application program to the video data is obtained, wherein the subscription condition includes a local application program subscription and a cross-ECU application program subscription. In step 120, it is determined whether the local application subscription or the cross-ECU application subscription of the subscription condition is performed, so as to dynamically change the transmission path of the video data. When the subscription condition is judged to be local application program subscription, in step 130, parallel access to the video data by the application program in the ECU is realized by creating a shared memory and a read-write lock; and when the subscription condition is judged to be a cross-ECU application subscription, dynamically configuring a switch virtual local area network and bandwidth reservation according to the requirement of the application on the video data in step 140 so as to realize cross-ECU sharing of the video data. Specific embodiments of the above-described method will be further described in conjunction with the following figures.
Fig. 2 is a block diagram of an in-vehicle video transmission system according to yet another embodiment of the present invention.
As shown in fig. 2, the in-vehicle video transmission system includes, as an example, two ECUs (ECU 1 and ECU 2), two applications (application 1 and application 2), a camera service program module 210, a camera data acquisition interface module 220, a switch configuration service program module 230, a camera driver 240, an H264 protocol stack 250, an AVB protocol stack 260, an ethernet driver 270, a camera 280 whose interface is FPD-Link, an in-vehicle ethernet switch chip 290, a camera data acquisition interface module 220', an H264 protocol stack 250', an AVB protocol stack 260', and an ethernet driver 270'. The ECU1 and the ECU2 communicate via ethernet through the on-board ethernet switch chip 290, and the camera driver 240, the H264 protocol stack 250, the AVB protocol stack 260, and the ethernet driver 270 can be implemented by using existing software units in the prior art, so that they are not described in detail in this specification, and the details of the camera service program module 210, the camera data acquisition interface module 220, and the switch configuration service program module 230 will be described below.
1. Camera service program module 210
The camera service program modules 210 are core modules in the vehicle-mounted video transmission system, each camera 280 is provided with a corresponding camera service program module 210, different camera service program modules 210 have different externally provided service IDs, and the application program selects and calls different service interfaces according to requirements, so as to acquire different camera video data. The main functions of this module are as follows:
a) the Middleware constructed by SOME/IP (Scalable service-organized Middleware over IP) is used as a server side of the service, and interfaces such as the setting of a camera, the subscription of video data and the like are packaged to form a service interface available for other application programs;
b) according to the subscription condition of the client application program of the service to the video data, dynamically calling a service interface of the switch configuration provided by the switch configuration service program module 230 to implement dynamic change of the transmission path of the video data;
c) when no application program of other ECU uses video data, the camera driver 240 is packaged, video data is provided to other application programs (for example, application program 1 in ECU1 in fig. 2) of the same ECU by creating a shared memory and a read-write lock (which divides a visitor to the video data into a reader and a writer, where the reader only performs read access on the video data and the writer needs to perform write access on the video data), and the function of obtaining the video data in parallel by a plurality of application programs in the ECU is realized by packaging;
d) when there is an application of another ECU (for example, application 2 in ECU2 in fig. 2) that needs to use video data, the camera service program module 210 obtains the video data from the camera driver 240, then performs data compression through the H264 protocol stack 250, and finally sends out the compressed video data through the ethernet driver 270 through the protocol stack 260 of the AVB.
According to the specification of the SOME/IP protocol, the interface provided by the service comprises three types: method, Event, Field. The interfaces defined and included in the service provided by the camera service program module 210 mainly include a Method and an Event, which are defined as follows.
Method:
a) Camera_Service_Subscribe(in int IP,out structure Source_Info);
The method is used to subscribe to video data of the camera 280. Wherein, the input parameter is one: the IP is the IP address of the ECU where the application program of the subscriber is located; the output parameter is one: source _ Info, the structure represents video data information, including data Source type and shared memory information. The data source types are two types, namely local data and remote data, the local data is an application program and is in the same ECU with the camera service program module 210, and when the data source is 0, the current camera service program module 210 is indicated to be unavailable; the remote data is that the application is not in the same ECU as the camera service module 210. The shared memory information is a key value of the shared memory area, and when the video data source is a far end, the parameter has no meaning. After receiving the transmission parameters of the method, the camera service program module 210 gives Source _ Info according to the mapping relationship between the IP information and the internal IP and the port number of the switch, and creates a shared memory when the subscriber is a local application program; when the subscriber is an application program crossing the ECUs, the switch configuration service program module 230 is called to configure the switch, so as to realize the transmission of the video data based on the AVB protocol.
b) Camera_Service_Unsubscribe(in int IP, out int Ret);
The method is used to unsubscribe from the video data of the camera 280. After receiving the parameters of the method, the camera service program module 210 performs different processing according to the mapping relationship between the IP information and the internal IP and the port number of the switch: when the unsubscriber is a local application program, checking whether other local application programs are subscribed currently, if no other local subscribers exist, removing the mapping of the shared memory and deleting the shared memory, and if other local subscribers exist, not performing any processing; when the subscriber is an ECU-crossing application program, the switch configuration service program module 230 is called according to the current ECU-crossing application program subscription condition, the transmission of the video is ended, the configuration of the switch is performed, and the occupation of the video data on the bandwidth is reduced. Wherein, the input parameter is one, the meaning is the same as Camera _ Service _ Subscribe, and the output parameter is one: ret, indicating the unsubscribe result.
c) SetVideoParameter(in structure Parameter , out int Ret);
The method is used to set parameters of the camera 280. The structure body represents Parameter information of the camera 280, such as width, height, contrast, and the like, and the Parameter information may be different according to different cameras 280; one output parameter is as follows: ret, a result of setting various parameters of the camera 280.
Event:
a) Camera_Avaliable_State()
The event is used by the camera service program module 210 to notify the subscriber of the available state of the camera service program module 210, and when the state changes, the event is sent to the subscriber application program of each service.
2. Switch configuration service module 230
The switch configuration service program module 230 provides an interface for configuring switch parameters to the camera service program module 210, and the configured content mainly includes configuration of information such as Virtual Local Area Network (VLAN) and bandwidth reservation. The configuration method and the included parameter items are different according to Ethernet switch chips of different manufacturers.
In the traditional video transmission based on the AVB protocol, the configuration of the switch is preconfigured, dynamic change is not carried out in the operation process, and the waste of bandwidth is easily caused. For example, in the system block diagram 2, the application 2 in the ECU2 only needs video data under certain conditions (for example, when an in-vehicle anti-theft function is triggered), and uploads the video data to the cloud. When the conventional video transmission method based on the AVB protocol is used, the ECU2 continuously receives the video data from the ECU1, but the video data is not needed by the application 2, so that the network bandwidth occupied by transmitting the video data is wasted; meanwhile, for the ECU1, when the application 2 does not need the video data, the ECU1 does not need to compress and send the video data out through the AVB protocol stack, which not only wastes network bandwidth, but also wastes processing resources of the controller (because the processing resources of the controller are used for compressing the video data). After the switch configuration service program module 230 is added, the camera service program module 210 can decide whether to compress the video data and how to configure the switch parameters in real time according to the demand state of the current application program on the video data. The interface type Method provided by the switch configuration service program module 230 includes the following specific interface definitions:
a) VLAN_Configuration(in int VLAN_ID,in structure Port_Info, out int Ret);
the method is mainly used for configuring the virtual local area network information of the switch used for AVB data transmission. Wherein, the input parameters are two: VLAN _ ID represents the ID number of the virtual local area network; port _ Info indicates a Port number contained in the virtual local area network. One output parameter is as follows: ret denotes the result of the method execution.
b) Stream_Reservation_Configuration(in int Stream_ID,in structure Stream_Info, out int Ret)
The method is mainly used for configuring information configuration related to bandwidth reservation. Wherein, the input parameters are two: stream _ ID represents the ID number of Stream; the Stream _ Info represents configuration information in the Stream, different manufacturers may have different parameters for the ethernet switch chips, and the configuration information may include a virtual local area network ID, a destination address, an input port (Ingress port), an output port (Egress port), and the like. One output parameter is as follows: ret denotes the result of the method execution.
3. Camera data acquisition interface module 220
The camera data acquisition interface module 220 provides an interface for applications to acquire video data. The interface module 220 is implemented mainly because the implementation manner and processing flow of the part of code are relatively fixed, and the processing procedure needs to be called by protocol stacks such as compression/decompression, AVB, and the like. The main interfaces are defined as follows:
a) VideoCaptureInit( structure Source_Info);
the interface is used for initializing the camera data acquisition interface module 220, and different processing needs to be performed according to different Source _ types in Source _ Info: if the data source is local, acquiring and mapping the shared memory, and then returning to success; if the data source is remote, success is returned directly.
b) VideoCapture( structure Source_Info , image *image);
The video Capture is an API (application program interface) for acquiring images by an application program, the Source _ Type identifies a video data Source, the video Capture acquires video data from an AVB (Audio video bus) protocol stack or a local shared memory respectively according to different Source types, and after the images are acquired from the AVB protocol stack, an H264 protocol stack is called for image decompression, and finally the image data are placed in an image address.
c) VideoCaptureRelease( structure Source_Info);
The interface is used for releasing the camera data acquisition interface module 220, and different processing needs to be performed according to different Source _ types in Source _ Info inside the method: if the data source is local, the mapping of the shared memory needs to be released, and then success is returned; if the data source is remote, success is returned directly.
According to the position relationship between the client of the video service and the server of the camera service (the client and the server are in the same ECU; the client and the server are in different ECUs), the service-based vehicle-mounted video transmission method has different realization paths, and the differences are packaged through interfaces, so that the use flow of the application program is kept consistent, and the application developer can use the application program conveniently. The main process of the present invention is described below with respect to two positional relationships.
Fig. 3 is a timing chart of a video transmission method in the ECU according to the embodiment of the present invention. In this scenario, the camera service program and the application APP1 complete the parallel transmission of video data by creating a read-write lock and a shared memory. Different camera service programs are different in service ID provided externally, and the APP1 selects and calls different service interfaces according to requirements, so that different camera video data are subscribed.
Specifically, in fig. 3, first, the APP1 subscribes to video data of the Camera through Camera _ Service _ subscribe (in int IP), the input parameter IP is an IP address of an ECU where the subscriber application program is located, and the Camera Service program utilizes and creates the shared memory based on the information. Then, the camera service returns the camera video data information to the application APP1 by using Source _ Info (DataResource = Local, key _ t), where Local indicates that the data Source type is Local data, which indicates that the application APP1 and the camera service are in the same ECU, and key _ t indicates shared memory information, which is a key value of the shared memory area, and when the data Source is far end, the parameter is meaningless. Then, initializing a camera data acquisition interface by using a videocapturelnit (Source _ Info), wherein the method needs to perform different processing according to different Source _ types in the Source _ Info: if the data source is local, the shared memory needs to be acquired and mapped, and then success is returned. And finally, utilizing a video Capture (Source _ Info, & image) to obtain an API (application program interface) of the image for the application program, wherein the Source _ Type identifies a video data Source, and when the data Source Type is local data, the video Capture can obtain video data from a camera service program and write the video data into a shared memory, finally reading the video data and storing the video data into an image address, and then returning to success.
Optionally, a camera data acquisition interface may also be released by using a VideoCaptureRelease (Source _ Info), and different processing needs to be performed inside the method according to different Source _ types in the Source _ Info: if the data source is local, the shared memory mapping needs to be released, and then success is returned.
Alternatively, it is also possible to Unsubscribe video data of the Camera using Camera _ Service _ unscubscriber (IP, Ret). After receiving the transmission parameters of the method, the camera service program performs different processing according to the IP information and the mapping relation between the internal IP and the port number of the switch: and when the unsubscriber is the local application program, checking whether other local application programs subscribe at present, if no other local subscriber exists, removing the mapping of the shared memory and deleting the shared memory, and if other local subscribers still exist, not performing any processing. Wherein, the input parameter is one, the meaning is the same as Camera _ Service _ Subscribe, and the output parameter is one: ret, indicating the unsubscribe result. And after the camera service program removes the mapping of the shared memory and deletes the shared memory, the success is returned.
Fig. 4 is a timing diagram of a video transmission method in different ECUs according to an embodiment of the present invention. In this scenario, the camera service program configures a virtual local area network and bandwidth reservation parameters of the switch according to the IP information of the subscriber, and sends the video data to the application program APP1 through the AVB protocol, and the application program APP1 obtains the video data through the camera data obtaining interface.
Specifically, in fig. 4, first, APP1 subscribes to video data of a Camera through Camera _ Service _ subscription (in int IP), inputs parameter IP as an IP address of an ECU where a subscriber application is located, configures a switch based on the information by the Camera Service, and configures virtual local area network information of the switch Configuration Service using VLAN _ Configuration (VLAN _ ID, Port _ Info), where two parameters are input: VLAN _ ID represents the ID number of the virtual local area network; port _ Info represents the Port number contained in the virtual local area network, and returns to the camera service program after configuration is successful. Meanwhile, the bandwidth Reservation related information is configured by using Stream _ Reservation _ Configuration (Stream _ ID, Stream _ Info), where two parameters are input: stream _ ID represents the ID number of Stream; the Stream _ Info represents configuration information in the Stream, different ethernet switch chips corresponding to different manufacturers may have different parameters, and basic information may include a virtual local area network ID, a destination address, an input port (Ingress port), an output port (Egress port), and the like. In parallel, the camera service program returns the camera video data information to the application program APP1 by using Source _ Info (data resource = Remote, key _ t), where Remote indicates that the data Source type is Remote data, which indicates that the application program APP1 is not in the same ECU as the camera service program, and key _ t indicates shared memory information, which is a key value of a shared memory area, and when the data Source is Remote, the parameter is meaningless. Then, initializing a camera data acquisition interface by using a videocapturelnit (Source _ Info), wherein the method needs to perform different processing according to different Source _ types in the Source _ Info: if the data source is remote, success is returned directly. And finally, the camera data acquisition interface utilizes a video Capture (Source _ Info, & image) as an API (application programming interface) interface for acquiring the image for the application program, the Source _ Type identifies a video data Source, when the data Source Type is remote data, the video Capture acquires the video data from the AVB protocol stack, and after acquiring the image from the AVB protocol stack, the video Capture calls the H264 protocol stack to decompress the image, finally puts the image data into the image address and returns success. In parallel, the camera service program starts to periodically acquire video data from the camera driver, compresses the video data by H264, and sends the video data by using an AVB protocol stack.
Optionally, a camera data acquisition interface may also be released by using a VideoCaptureRelease (Source _ Info), and different processing needs to be performed inside the method according to different Source _ types in the Source _ Info: if the data source is remote, success is returned directly.
Alternatively, it is also possible to Unsubscribe video data of the Camera using Camera _ Service _ unscubscriber (IP, Ret). After receiving the transmission parameters of the method, the camera service program performs different processing according to the IP information and the mapping relation between the internal IP and the port number of the switch: when the subscriber is the cross-ECU application program, the transmission of the video is finished according to the current subscription condition of the cross-ECU application program, the configuration of the switch is carried out, and the occupation of the video data on the bandwidth is reduced.
Wherein, the input parameter is one, the meaning is the same as Camera _ Service _ Subscribe, and the output parameter is one: ret, indicating the unsubscribe result. And after the camera service program releases the mapping of the shared memory and deletes the shared memory, the success is returned. The Configuration of the switch may also use the above-mentioned VLAN _ Configuration (VLAN _ ID, Port _ Info) and Stream _ Reservation _ Configuration (Stream _ ID, Stream _ Info) to configure the VLAN and the bandwidth Reservation related information, and after the Configuration is completed, success is returned.
Fig. 5 is a schematic block diagram of an on-board video sharing scheme according to yet another embodiment of the present invention. The scheme comprises a camera module 510, a video processing unit 520, a video processing unit 530, a video processing unit 540 and a vehicle-mounted Ethernet switch chip 550. As shown in fig. 5, the camera module 510 is connected to each video processing unit via the FPD-Link, and each video processing unit communicates with the in-vehicle ethernet switch chip 550 via the ethernet. The present embodiment integrates the video compression function into the video processing unit, which brings advantages of reducing the complexity of the camera module 510; the requirement of the built-in processing chip is low, so that the processing chip with low performance and low cost can be selected, and the hardware cost is reduced; as the FPD-Link interface is used and the FPD-Link interface protocol chip is added, the number of physical interface transceivers and switch ports of the Ethernet is reduced.
Fig. 6 is a schematic block diagram of a vehicle controller according to still another embodiment of the present invention. The vehicle controller 60 comprises a memory 610, a processor 620 and a computer program 630 stored on said memory 610 and operable on said processor 620. The processor 620 runs the computer program 630 to implement the above-described in-vehicle video transmission method.
According to another aspect of the present invention, there is also provided a computer-readable storage medium on which a computer program is stored, which when executed by a processor, is capable of implementing the above-described in-vehicle video transmission method.
The embodiments and examples set forth herein are presented to best explain the embodiments in accordance with the present technology and its particular application and to thereby enable those skilled in the art to make and utilize the invention. Those skilled in the art, however, will recognize that the foregoing description and examples have been presented for the purpose of illustration and example only. The description as set forth is not intended to cover all aspects of the invention or to limit the invention to the precise form disclosed.

Claims (8)

1. A vehicle-mounted video transmission method is characterized by comprising the following steps:
A) acquiring the subscription condition of an application program to video data, wherein the subscription condition comprises local application program subscription and cross-ECU application program subscription; and
B) implementing dynamic alteration of a transmission path of the video data based on the subscription,
wherein the step B) further comprises:
when the subscription condition is the local application program subscription, realizing the parallel access of the application program in the ECU to the video data by creating a shared memory and a read-write lock; and
and when the subscription condition is the cross-ECU application program subscription, dynamically configuring a virtual local area network of a switch and bandwidth reservation according to the requirement of the application program on the video data so as to realize cross-ECU sharing of the video data.
2. The vehicle-mounted video transmission method according to claim 1, further comprising the unsubscribing step of:
when the unsubscriber is the local application program subscription, checking whether other local application program subscriptions exist currently, if no other local application program subscribers exist, removing the mapping of the shared memory and deleting the shared memory, and if other local application program subscribers exist, not processing; and
and when the unsubscriber is the cross-ECU application program subscription, dynamically configuring a virtual local area network of a switch and bandwidth reservation to finish the transmission of the video data.
3. The vehicle-mounted video transmission method according to any one of claims 1-2, wherein when the subscription condition is the cross-ECU application subscription, the ECU is connected via Ethernet, the video data is compressed by H264 protocol, and the compressed video data is shared via Ethernet by AVB protocol.
4. An in-vehicle video transmission system, comprising:
the camera service program module is configured to acquire the subscription condition of the application program to the video data and dynamically call the switch configuration service program module based on the subscription condition so as to realize dynamic change of the transmission path of the video data;
a switch configuration server module configured to implement, in accordance with the invocation of the camera server module based on the subscription condition: when the subscription condition is cross-ECU application program subscription, dynamically configuring a virtual local area network of a switch and bandwidth reservation according to the requirement of the application program on the video data so as to realize cross-ECU sharing of the video data; and
a camera data acquisition interface module packaged as an API interface and configured to provide an interface for applications to acquire the video data,
wherein the camera service program module is further configured to:
when the subscription condition is local application program subscription, packaging a camera drive so as to realize parallel access to the video data by the application program in the ECU through establishing a shared memory and a read-write lock; and
and when the subscription condition is cross-ECU application program subscription, dynamically calling a switch configuration service program module according to the requirement of the application program on the video data so as to realize cross-ECU sharing of the video data.
5. The in-vehicle video transmission system of claim 4, wherein the camera service program module is further configured to perform the unsubscribing step:
when the unsubscriber is a local application program subscription, checking whether other local application programs are subscribed currently, if no other local application program subscribers exist, removing the mapping of the shared memory and deleting the shared memory, and if other local application program subscribers exist, not processing; and
when the unsubscriber is subscribed by the cross-ECU application program, the switch configuration service program module is dynamically called to dynamically configure the switch virtual local area network and the bandwidth reservation so as to finish the transmission of the video data.
6. The vehicle-mounted video transmission system according to any one of claims 4 to 5, wherein the ECU is connected via Ethernet, the video data is compressed by H264 protocol first, and the compressed video data is shared via Ethernet by AVB protocol.
7. A vehicle controller comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the processor executes the program to:
the in-vehicle video transmission method according to any one of claims 1 to 3.
8. A computer-readable storage medium on which a computer program is stored, the program being executable by a processor to perform:
the in-vehicle video transmission method according to any one of claims 1 to 3.
CN201910428825.6A 2019-05-22 2019-05-22 Vehicle-mounted video transmission method and vehicle-mounted video transmission system Active CN111988557B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910428825.6A CN111988557B (en) 2019-05-22 2019-05-22 Vehicle-mounted video transmission method and vehicle-mounted video transmission system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910428825.6A CN111988557B (en) 2019-05-22 2019-05-22 Vehicle-mounted video transmission method and vehicle-mounted video transmission system

Publications (2)

Publication Number Publication Date
CN111988557A CN111988557A (en) 2020-11-24
CN111988557B true CN111988557B (en) 2022-09-13

Family

ID=73435960

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910428825.6A Active CN111988557B (en) 2019-05-22 2019-05-22 Vehicle-mounted video transmission method and vehicle-mounted video transmission system

Country Status (1)

Country Link
CN (1) CN111988557B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112532905B (en) * 2020-12-09 2022-09-23 杭州鸿泉物联网技术股份有限公司 Vehicle-mounted audio and video frame data processing method and device
CN112804249B (en) * 2021-01-28 2023-06-23 中汽创智科技有限公司 Data communication method and system for remotely calling automatic driving platform
CN114785684B (en) * 2022-04-24 2024-04-05 长城汽车股份有限公司 Port configuration method and device of vehicle switch, vehicle and storage medium

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101562731A (en) * 2009-05-08 2009-10-21 上海天形信息科技发展有限公司 Wireless mobile audio-video transmission system
US7748019B1 (en) * 1999-01-28 2010-06-29 Xsys Interactive Research Gmbh Local network in a vehicle
CN105282213A (en) * 2014-06-16 2016-01-27 哈曼国际工业有限公司 Limp-Home Operation of Audio Video Bridging Networks
CN105978997A (en) * 2016-06-24 2016-09-28 北京百度网讯科技有限公司 Data transmission method and system
CN107733839A (en) * 2016-08-11 2018-02-23 北京百度网讯科技有限公司 Data transmission method and system
CN107733945A (en) * 2016-08-11 2018-02-23 北京百度网讯科技有限公司 Information transferring method and device for robot operating system
CN108418723A (en) * 2018-05-29 2018-08-17 合肥工业大学 A kind of reserved bandwidth optimization configuration methods of vehicle-mounted Ethernet AVB
CN109348453A (en) * 2018-09-20 2019-02-15 重庆长安汽车股份有限公司 The method and system of audio transmission based on vehicle-mounted Ethernet
CN109347922A (en) * 2018-09-20 2019-02-15 青岛海信网络科技股份有限公司 A kind of read method and device for supporting Metro Network real time data processing

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9232026B2 (en) * 2011-12-21 2016-01-05 Harman International Industries, Incorporated System for communicating control messages in an AVB network

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7748019B1 (en) * 1999-01-28 2010-06-29 Xsys Interactive Research Gmbh Local network in a vehicle
CN101562731A (en) * 2009-05-08 2009-10-21 上海天形信息科技发展有限公司 Wireless mobile audio-video transmission system
CN105282213A (en) * 2014-06-16 2016-01-27 哈曼国际工业有限公司 Limp-Home Operation of Audio Video Bridging Networks
CN105978997A (en) * 2016-06-24 2016-09-28 北京百度网讯科技有限公司 Data transmission method and system
CN107733839A (en) * 2016-08-11 2018-02-23 北京百度网讯科技有限公司 Data transmission method and system
CN107733945A (en) * 2016-08-11 2018-02-23 北京百度网讯科技有限公司 Information transferring method and device for robot operating system
CN108418723A (en) * 2018-05-29 2018-08-17 合肥工业大学 A kind of reserved bandwidth optimization configuration methods of vehicle-mounted Ethernet AVB
CN109348453A (en) * 2018-09-20 2019-02-15 重庆长安汽车股份有限公司 The method and system of audio transmission based on vehicle-mounted Ethernet
CN109347922A (en) * 2018-09-20 2019-02-15 青岛海信网络科技股份有限公司 A kind of read method and device for supporting Metro Network real time data processing

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
车载以太网技术发展与测试方法研究;孟祥坤等;《汽车电器》;20190520(第05期);全文 *

Also Published As

Publication number Publication date
CN111988557A (en) 2020-11-24

Similar Documents

Publication Publication Date Title
CN111988557B (en) Vehicle-mounted video transmission method and vehicle-mounted video transmission system
CN111917988B (en) Remote camera application method, system and medium of cloud mobile phone
CN110386064B (en) Control system and method of vehicle-mounted camera, vehicle-mounted equipment and automobile
KR101630729B1 (en) Method and System for Providing Optimized Ethernet Communication for vehicle
CN109462726B (en) Camera control method and device
CN105163135B (en) Method for down loading, apparatus and system and the mobile terminal of Internet resources
EP4191355A1 (en) Uds-based communication method, ecu and upper computer
CN111327921A (en) Video data processing method and device
CN116962870A (en) Vehicle-mounted shooting data management method and device, electronic equipment and readable storage medium
CN115562872A (en) High-concurrency SOME/IP protocol stack server implementation method
CN116016295A (en) Ethernet performance monitoring method, system, industrial control equipment and storage medium
CN116668415A (en) Streaming media data processing method and system
CN114442590A (en) Vehicle diagnosis method, apparatus, diagnosis communication device, server, and storage medium
CN114745229A (en) Embedded AI video gateway and implementation method thereof
CN113676544A (en) Cloud storage network and method for realizing service isolation in entity server
CN112468510A (en) Transmission method and equipment based on SMT protocol and ALC protocol compatibility
CN109392191A (en) Automobile data recorder and the communication means of terminal, automobile data recorder and storage medium
CN117336251B (en) Vehicle-mounted data interaction method and device, electronic equipment and storage medium
CN115242970B (en) Vehicle camera data sharing system, method, electronic equipment and storage medium
CN113709344B (en) Image data processing method, device, equipment and storage medium
CN112783959B (en) Data transmission method and device based on heterogeneous storage systems
Trifunović et al. Data Exchange Interfaces in Automotive SOA
CN108491272B (en) Resource control method and device and terminal equipment
CN117311921A (en) Scheduling method and device for image data processing and vehicle
CN117221421A (en) Middleware communication method, middleware communication device, electronic equipment and storage medium

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
GR01 Patent grant
GR01 Patent grant