Sensor data transmission method and device, electronic equipment and storage medium

By configuring the sensor hardware abstraction layer on the main system-level chip, using the remote process call protocol to send sensor data to the slave system-level chip, the problem of transmission delay and cost of virtualization platform is solved, and multi-platform sensor data sharing and development are realized Improved efficiency.

CN119206894APending Publication Date: 2024-12-27ECARX TECHNOLOGY PTE LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411258686.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-09
Publication Date
2024-12-27

AI Technical Summary

Technical Problem

In the prior art, multiple systems of the virtualization platform need to rely on virtualized transmission methods to obtain sensor data, resulting in problems of transmission delay and increased costs.

Method used

Configure sensor hardware abstraction layer on the main system-level chip, and send sensor data to multiple sensor data routers on the slave system-level chip through remote process call protocols, realizing the sharing of sensor data, supporting different types of operating systems, and supporting transmission Frequency setting and data playback function.

Benefits of technology

It realizes sensor data sharing on virtualized and non-virtualized platforms, supports the development of multiple platforms and multiple projects, saves development costs, and optimizes transmission efficiency and data use.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119206894A_ABST
    Figure CN119206894A_ABST
Patent Text Reader

Abstract

The invention provides a sensor data transmission method and device, electronic equipment and a storage medium, the method is applied to a main system-on-chip, a sensor hardware abstraction layer is configured on the main system-on-chip, and the sensor hardware abstraction layer comprises a sensor data router. The method comprises the steps that a sensor data router on a main system-on-chip acquires sensor data on a sensor driving program; and sending the sensor data to sensor data routers on a plurality of slave system-on-chip through a remote procedure call protocol, so that the sensor data routers on each slave system-on-chip share the sensor data. A sensor hardware abstraction layer on the master system-level chip reads sensor data from a sensor driving program and transmits the sensor data to the plurality of slave system-level chips, so that the use on a virtualization platform and a non-virtualization platform is realized, a plurality of system platforms share the sensor data, the multi-platform and multi-project development is supported, and the development efficiency is improved. And the development cost is saved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of vehicle cockpits, and in particular to a sensor data transmission method, device, electronic equipment and computer-readable storage medium. Background Art

[0002] With the rapid development of automotive electronic technology, the functional complexity of vehicles is increasing. In order to better enhance the user's driving experience, sensor data has been widely used in smart cockpits.

[0003] With the development of smart cockpits, there are scenarios where multiple systems require sensor data. In order to save costs, sensors are usually deployed on the host system, and the slave (Guest) system obtains the corresponding sensor data by interacting with the host system. For multiple systems on a virtualization platform, the host virtual machine (Host VM) is usually used as the host system and the guest virtual machine (Guest VM) as the slave system. Then, the Guest VM uses the underlying hypervisor to obtain sensor data from the Host VM through virtualization. However, in the related art, the slave system needs to obtain sensor data from the host system through virtualization, and transmission through virtualization is prone to transmission delays, which increases cost issues.

[0004] Therefore, how the system can achieve sensor data sharing without relying on virtualized transmission methods is a technical problem that needs to be solved. Summary of the invention

[0005] The present invention provides a method, device, electronic device and computer-readable storage medium for transmitting sensor data, so as to at least solve the technical problem in the related art that multiple systems of a virtualized platform need to rely on a virtualized transmission mode to obtain sensor data, thereby causing transmission delay and increased cost. The technical solution of the present invention is as follows:

[0006] According to a first aspect of an embodiment of the present invention, a method for transmitting sensor data is provided. The method is applied to a main system-level chip, the main system-level chip is configured with a sensor hardware abstraction layer, the sensor hardware abstraction layer includes a sensor data router, and the method includes:

[0007] Get sensor data on the sensor driver;

[0008] The sensor data is sent to a plurality of slave sensor data routers on the system-level chip through a remote procedure call protocol, so that each of the slave sensor data routers on the system-level chip shares the sensor data.

[0009] Optionally, the multiple slave system-on-chips install the same type of operating system, or the multiple slave system-on-chips install different types of operating systems.

[0010] Optionally, the multiple slave system-on-chips install the same type of operating system, or the multiple slave system-on-chips install different types of operating systems, including:

[0011] When the plurality of slave system-level chips are all installed with the first type of operating system, each slave system-level chip sends the acquired sensor data to a corresponding sensor service for sharing; or

[0012] When the second type of operating system is installed on all of the plurality of slave system-level chips, each slave system-level chip sends the acquired sensor data to the corresponding middleware for sharing; or

[0013] When a part of the plurality of slave SoCs installs the first type of operating system and the remaining part installs the second type of operating system, each of the remaining slave SoCs sends the acquired sensor data to the corresponding middleware for sharing.

[0014] Optionally, the method further includes:

[0015] receiving a transmission frequency setting request sent by at least one of the plurality of slave SoCs;

[0016] Setting the corresponding transmission frequency according to the setting transmission frequency request;

[0017] According to the set transmission frequency, the sensor data is sent through a remote procedure call protocol to at least one sensor data router on the slave system-on-chip that requests to set the transmission frequency.

[0018] Optionally, after acquiring the sensor data on the sensor driver, the method further includes:

[0019] The sensor data acquired on the sensor driver is recorded in real time so as to play back the stored sensor data when simulating a problem scenario.

[0020] According to a second aspect of an embodiment of the present invention, a method for transmitting sensor data is provided, the method being applied to a sensor data router on a system-on-chip, comprising:

[0021] Obtain sensor data sent by a sensor data router on a main system-level chip;

[0022] The sensor data is transmitted to the corresponding sensor service or middleware for sharing.

[0023] Optionally, sending the sensor data to a corresponding sensor service or middleware for sharing includes:

[0024] When the first type of operating system is installed on the slave system-level chip, the slave system-level chip includes a sensor hardware abstraction layer, and the sensor hardware abstraction layer includes a sensor data router; the sensor data is sent to the sensor service of the corresponding local service layer through the sensor data router on the sensor hardware abstraction layer for sharing; or

[0025] When the second type of operating system is installed on the slave system-on-chip, the slave system-on-chip includes a sensor data router; the sensor data is sent to the corresponding sensor service of the middleware through the sensor data router and the sensor daemon process for sharing.

[0026] Optionally, the method further includes:

[0027] sending a request to set a transmission frequency to a sensor data router on the main system-on-chip;

[0028] The sensor data is received from the sensor data router on the main system-on-chip and sent through the remote procedure call protocol according to the transmission frequency set by the request.

[0029] According to a third aspect of an embodiment of the present invention, a sensor data transmission device is provided, the device is applied to a main system-level chip, the main system-level chip is configured with a sensor hardware abstraction layer, the sensor hardware abstraction layer includes: a sensor data router, the device includes:

[0030] The acquisition module is used to obtain sensor data on the sensor driver;

[0031] The first transmission module is used to send the sensor data to a plurality of slave sensor data routers on the system-on-chip through a remote procedure call protocol, so that each of the slave sensor data routers on the system-on-chip shares the sensor data.

[0032] Optionally, the first transmission module transmits multiple slave system-on-chips to install the same type of operating system, or transmits multiple slave system-on-chips to install different types of operating systems.

[0033] Optionally, the first transmission module transmits a plurality of operating systems of the same type installed from the system-on-chip, or a plurality of operating systems of different types installed from the system-on-chip, including:

[0034] When the plurality of slave system-level chips are all installed with the first type of operating system, each slave system-level chip sends the acquired sensor data to a corresponding sensor service for sharing; or

[0035] When the second type of operating system is installed on all of the plurality of slave system-level chips, each slave system-level chip sends the acquired sensor data to the corresponding middleware for sharing; or

[0036] When a part of the plurality of slave SoCs installs the first type of operating system and the remaining part installs the second type of operating system, each of the remaining slave SoCs sends the acquired sensor data to the corresponding middleware for sharing.

[0037] Optionally, the device further comprises:

[0038] a receiving module, configured to receive a transmission frequency setting request sent by at least one slave system-on-chip among the plurality of slave system-on-chips;

[0039] A setting module, used for setting the corresponding transmission frequency according to the setting transmission frequency request;

[0040] The second transmission module is used to send the sensor data to at least one sensor data router on the slave system-level chip that requests to set the transmission frequency through the remote procedure call protocol according to the set transmission frequency.

[0041] Optionally, the device further comprises:

[0042] The recording module is used to record the sensor data on the sensor driver in real time after the acquisition module acquires the sensor data on the sensor driver, so as to play back the stored sensor data when simulating the problem scenario.

[0043] According to a fourth aspect of an embodiment of the present invention, a sensor data transmission device is provided, the device being applied to a sensor data router on a system-on-chip, the device comprising:

[0044] An acquisition module, used for acquiring sensor data sent by a sensor data router on a main system-level chip;

[0045] The transmission module is used to send the sensor data to the corresponding sensor service or middleware for sharing.

[0046] Optionally, the transmission module includes:

[0047] A first sending module is used for, when the first type of operating system is installed on the slave system-level chip, the slave system-level chip includes a sensor hardware abstraction layer, and the sensor hardware abstraction layer includes a sensor data router; the sensor data is sent to the sensor service of the corresponding local service layer through the sensor data router on the sensor hardware abstraction layer for sharing; and / or

[0048] The second sending module is used to send the sensor data to the corresponding middleware sensor service for sharing through the sensor data router and the sensor daemon process when the second type of operating system is installed on the slave system-level chip, and the slave system-level chip includes a sensor data router.

[0049] Optionally, the device further comprises:

[0050] A request module, used for sending a request for setting a transmission frequency to the sensor data router on the main system-level chip;

[0051] The receiving module is used to receive the sensor data sent by the sensor data router on the main system-level chip through the remote procedure call protocol according to the transmission frequency set by the request.

[0052] According to a fifth aspect of an embodiment of the present invention, there is provided an electronic device, characterized in that it includes:

[0053] processor;

[0054] a memory for storing instructions executable by the processor;

[0055] The processor is configured to execute the instructions to implement the sensor data transmission method as described above.

[0056] According to a sixth aspect of an embodiment of the present invention, a computer-readable storage medium is provided. When instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the sensor data transmission method as described above.

[0057] According to a seventh aspect of an embodiment of the present invention, there is provided a computer program product, comprising a computer program or instructions, which, when executed by a processor of an electronic device, implements the sensor data transmission method as described above.

[0058] The technical solution provided by the embodiments of the present invention brings at least the following beneficial effects:

[0059] In the embodiment of the present invention, the sensor data router on the master system-level chip first obtains the sensor data on the sensor driver; then, the sensor data is sent to the sensor data routers on multiple slave system-level chips through the remote procedure call protocol, so that each sensor data router on the slave system-level chip can share the sensor data. That is, when the sensor hardware abstraction layer (VenusSensorHal) is configured on the master system-level chip, the sensor hardware abstraction layer needs to read the sensor data from the sensor driver and distribute it, that is, transmit it to multiple slave system-level chips, which can be used on virtualized platforms and non-virtualized platforms at the same time, and multiple system platforms share sensor data, so as to realize the development of supporting multiple platforms and multiple projects, saving development costs.

[0060] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0061] The drawings herein are incorporated into the specification and constitute a part of the specification, showing embodiments consistent with the present invention, and are used together with the specification to explain the principles of the present invention, and do not constitute an improper limitation of the present invention. In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the drawings required for use in the embodiments or the prior art description will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.

[0062] Figure 1 It is a flow chart of a sensor data transmission method provided by an embodiment of the present invention.

[0063] Figure 2 This is another flow chart of a sensor data transmission method provided by an embodiment of the present invention.

[0064] Figure 3 It is a schematic diagram of an application example of a sensor data transmission method provided by an embodiment of the present invention.

[0065] Figure 4 It is a block diagram of a sensor data transmission device provided by an embodiment of the present invention.

[0066] Figure 5 This is another block diagram of a sensor data transmission device provided by an embodiment of the present invention.

[0067] Figure 6 This is another block diagram of a sensor data transmission device provided by an embodiment of the present invention.

[0068] Figure 7 This is another block diagram of a sensor data transmission device provided by an embodiment of the present invention.

[0069] Figure 8 It is a block diagram of an electronic device provided by an embodiment of the present invention.

[0070] Fig. 9 The invention is a block diagram of a device for transmitting sensor data provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0071] In order to enable ordinary persons in the art to better understand the technical solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings.

[0072] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. The embodiments described in the following exemplary embodiments do not represent all embodiments consistent with the present invention. Instead, they are merely examples of devices and methods consistent with some aspects of the present invention as detailed in the appended claims.

[0073] Figure 1 is a flow chart of a sensor data transmission method provided by an embodiment of the present invention. Figure 1 As shown, the method is applied to a master system-level chip (Master Soc, or Host Soc), the master system-level chip is configured with a sensor hardware abstraction layer (Venus Sensor Hal), the sensor hardware abstraction layer includes: a sensor data router (libVenus Sensor Router), the method includes:

[0074] Step 101: Get sensor data on the sensor driver.

[0075] Step 102: Send the sensor data to multiple slave sensor data routers on the system-on-chip through the remote procedure call protocol, so that each slave sensor data router on the system-on-chip shares the sensor data.

[0076] The sensor data transmission method described in the present invention can be applied to terminals, servers, etc., without limitation herein. The terminal implementation device can be an electronic device such as a smart phone, a laptop computer, a tablet computer, a desktop computer, a personal digital assistant (PDA, Personal Digital Assistant) and a wearable device. The server can be an independent server or a server cluster, or a server that provides cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, intermediate services, domain name services, security services, content distribution networks, or a big data and artificial intelligence platform, etc., without limitation herein.

[0077] Combine the following Figure 1 , the specific implementation steps of a sensor data transmission method provided by an embodiment of the present invention are described in detail. The method specifically includes:

[0078] In step 101, sensor data on a sensor driver is obtained.

[0079] In this step, the sensor data router (lib Venus Sensor Router) in the sensor hardware abstraction layer (Venus Sensor Hal) on the main system-level chip can read the sensor data on a sensor driver (Sensor Driver), or can read the sensor data on multiple sensor drivers at the same time, which is not limited in this embodiment. It should be noted that the sensor driver is located on the main system-level chip and is connected to the sensor hardware abstraction layer.

[0080] The acquired sensor data may include data of various sensors, such as data of an accelerometer, a gyroscope, a magnetometer, and a light sensor, etc. These data are collectively referred to as sensor data.

[0081] In step 102, the sensor data is sent to a plurality of slave sensor data routers on the system-on-chip through a remote procedure call protocol, so that each of the slave sensor data routers on the system-on-chip shares the sensor data.

[0082] In this step, the sensor data router (lib Venus Sensor Route) on the master system-level chip sends the sensor data routers (lib Venus Sensor Route) on multiple slave system-level chips (Slave Soc) through the remote procedure call protocol (RPC, Remote Procedure Call Protocol), so that the sensor data routers on each slave system-level chip share the sensor data.

[0083] In the embodiment of the present invention, the sensor data router on the master system-level chip first obtains the sensor data on the sensor driver; then, the sensor data is sent to the sensor data routers on multiple slave system-level chips through the remote procedure call protocol, so that each sensor data router on the slave system-level chip can share the sensor data. That is, when the sensor hardware abstraction layer (VenusSensorHal) is configured on the master system-level chip, the sensor hardware abstraction layer needs to read the sensor data from the sensor driver and distribute it, that is, transmit it to multiple slave system-level chips, which can be used on virtualized platforms and non-virtualized platforms at the same time, and multiple system platforms share sensor data, so as to realize the development of supporting multiple platforms and multiple projects, saving development costs.

[0084] Optionally, in another embodiment, based on the above embodiment, the multiple slave system-level chips install the same type of operating system, or the multiple slave system-level chips install different types of operating systems.

[0085] In this embodiment, in one case, when the plurality of slave system-level chips are all installed with the first type of operating system, each slave system-level chip sends the acquired sensor data to the corresponding sensor service for sharing.

[0086] In another case, when the plurality of slave system-level chips are all installed with the second type of operating system, each slave system-level chip sends the acquired sensor data to the corresponding middleware for sharing.

[0087] In another case, when a part of the multiple slave system-level chips install the first type of operating system and the remaining part installs the second type of operating system, each of the remaining slave system-level chips will send the acquired sensor data to the corresponding middleware for sharing.

[0088] That is to say, in this embodiment, if the first type of operating system is an Android system, then the corresponding second operating system may be a Linux / QNX system. Conversely, if the first type of operating system is a Linux / QNX system, then the corresponding second operating system may be an Android system. Of course, this embodiment is not limited to the Android system and the Linux / QNX system, and may also be other operating systems, which are not limited in this embodiment.

[0089] For example, multiple slave system-level chips can all be installed with the Android system or the Linux / QNX system. Of course, some of them can be installed with the Android system and the other part can be installed with the Linux / QNX system, etc. This embodiment does not limit this.

[0090] In the embodiment of the present invention, various types of operating systems share sensor data, and support the development of multiple platforms and multiple projects through configuration, thereby saving the cost of project development.

[0091] Optionally, in another embodiment, based on the above embodiment, the method may also include: receiving a request for setting a transmission frequency sent by at least one of the multiple slave system-level chips; setting a corresponding transmission frequency according to the request for setting the transmission frequency; and sending the sensor data to a sensor data router on at least one of the slave system-level chips that requests to set the transmission frequency through a remote procedure call protocol RPC according to the set transmission frequency.

[0092] In the embodiment of the present invention, the network transmission of C / S architecture is used as the design infrastructure, the master system-level chip (Master Soc, also known as Host Soc) is used as the server, and the slave system-level chip (Slave Soc, also known as Guest Soc) is used as the client. The data collected by the Master Soc is accurately sent to the client that needs to collect Sensor data. At the same time, the transmission rate is optimized to avoid data delay caused by network transmission as much as possible.

[0093] In the embodiment of the present invention, the main system-level chip supports multiple operating systems (such as Android, Linux, etc.) to set the transmission frequency. In addition to the Host Soc being able to set the transmission frequency, it also supports the Guest Soc to set the transmission frequency to meet the different requirements of the Guest Soc-side application for the transmission frequency.

[0094] Optionally, in another embodiment, based on the above embodiment, after acquiring the sensor data on the sensor driver, the method may also include: real-time recording of the sensor data acquired on the sensor driver to facilitate playback of the stored sensor data when simulating problem scenarios.

[0095] The embodiment of the present invention supports a data playback function, which records the sensor data in real time and simulates the scene of the problem at that time. For problems that are difficult to reproduce, such as navigation positioning, the problem can be quickly located and segmented.

[0096] See also Figure 2 , is another flow chart of a sensor data transmission method provided by an embodiment of the present invention, the method is applied to a sensor data router (lib Venus SensorRouter) on a slave system-on-chip (Slave Soc), and the method includes:

[0097] Step 201: Acquire sensor data sent by a sensor data router on a main system-on-chip.

[0098] In this step, the slave system-on-chip receives the sensor data sent by the sensor data router on the master system-on-chip through the remote procedure call protocol RPC.

[0099] In this step, the sensor data obtained may include data of various sensors, such as data of an accelerometer, a gyroscope, a magnetometer, and a light sensor, etc. These data are collectively referred to as sensor data.

[0100] Step 202: Transmit the sensor data to the corresponding sensor service or middleware for sharing.

[0101] In this step, the sensor data is sent from the system-level chip to the corresponding sensor service or middleware for sharing, which specifically includes:

[0102] When the first type of operating system is installed on the slave system-level chip, the slave system-level chip includes a sensor hardware abstraction layer (Venus Sensor Hal), and the Venus Sensor Hal includes a sensor data router (libVenus Sensor Router); the sensor data is sent to the corresponding local service layer through the sensor data router on the sensor hardware abstraction layer for sharing; or

[0103] When the second type of operating system is installed on the slave system-level chip, the slave system-level chip includes a sensor data router lib Venus Sensor Router; the sensor data is sent to the corresponding sensor service of the middleware through the sensor data router and the sensor daemon process for sharing.

[0104] That is to say, in this embodiment, the SensorHal service of the master system-level chip (Master Soc) will notify the sensor service (SensorService) on the Master Soc of the data, and forward the acquired sensor data to other slave system-level chips (Slave Soc), that is, the slave system-level chip (Slave Soc) receives the sensor data sent by the master system-level chip (MasterSoc), and then the Slave Soc performs different processing according to the installed system. If the SlaveSoc is installed with the Android system, it will be sent to the sensor service (SensorService) of the local service layer through the sensor data router (lib Venus Sensor Router) on the sensor hardware abstraction layer (Venus Sensor Hal) for sharing; if Linux or QNX is installed, it will be sent to the sensor service (SensorService) of the middleware through the sensor data router (lib Venus Sensor Router) and the sensor daemon process for sharing. In general, the sensor data will be notified to the user so that the supporter can share the sensor data.

[0105] It should be noted that, in this embodiment, the sensor hardware abstraction layer (Venus Sensor Hal) is the SensorHal customized by Ecarx, which specifically includes:

[0106] 1) Supports the collection of multiple sensor data, including accelerometers, gyroscopes, magnetometers, light sensors, etc., and is perfectly adapted to the sensors natively supported by Android.

[0107] 2) SensorHal supports configurable Master Soc or Slave Soc.

[0108] 3) When acting as a Master Soc, the sensor hardware abstraction layer (VenusSensorHal) needs to read data from the sensor driver (Sensor Dricer) and distribute it to the Slave Soc. Android also provides SensorHal natively, but does not implement specific functions. Therefore, this embodiment, based on the native design, proposes to interact with the sensor manufacturer to obtain the corresponding Sensor data and connect to the Android native SensorService. Users can obtain the corresponding Sensor data through the Android native interface, and VenusSensorHal will forward the data to other Slave Socs through libVenusSensorRouter.

[0109] 4) When acting as a Slave SoC, it will receive Sensor data through libVenusSensorRouter and then connect to Android's native SensorService.

[0110] 5) When acting as a Slave Soc, it also supports setting parameters such as frequency, notifying the Master Soc, and sending Sensor data to the Slave Soc at the corresponding frequency.

[0111] 6) Supports data playback function, which will record sensor data in real time and simulate the scene of the problem at that time. For problems that are difficult to reproduce, such as navigation positioning, the problem can be located and segmented quickly.

[0112] Among them, the sensor data router (libVenusSensorRouter) is the dynamic library responsible for data forwarding:

[0113] 1) Supports the Router function that can be configured as Master Soc or Slave Soc.

[0114] 2) When acting as a Master Soc, libVenusSensorRouter will act as a server to forward Sensor data and support multiple client connections.

[0115] 3) When acting as a Slave Soc, libVenusSensorRouter will act as a client to connect to the server and obtain Sensor data.

[0116] 4) Supports configurable communication protocol, such as someip / ipcp / iplm, which can be applied to multiple platforms.

[0117] 5) When used as a Slave Soc, if the system is not Android, a cross-platform dynamic library is provided, and the middleware of the Linux / QNX system can obtain the corresponding sensor data through the dynamic library.

[0118] Optionally, in another embodiment, based on the above embodiment, the method may also include: sending a request to set a transmission frequency to the sensor data router on the main system-level chip; receiving the sensor data sent by the sensor data router on the main system-level chip through the remote procedure call protocol RPC according to the transmission frequency set by the request.

[0119] It should be noted that, in all embodiments of the present invention, Master Soc can also be understood as Host Soc, and the functions of the two are the same or similar; Slave Soc can also be understood as Guest Soc, and the functions of the two are the same or similar.

[0120] The sensor data transmission method provided by the embodiment of the present invention can be used on both Qualcomm platform (virtualization platform) and non-virtualization platform, not limited to Android system, and supports the sharing of sensor data obtained by Linux / QNX system, and supports the development of multiple platforms and multiple projects through configuration; supports multiple protocol communications for forwarding Sensor data, such as someip / ipcp / iplm, and supports multiple client connections; fully adapts to Android native Sensor process, and users are unaware that Sensor data can be obtained through Android native interface; supports Slave Soc to set Sensor data frequency; and provides Sensor data playback function to better locate and segment problems.

[0121] See also Figure 3 , is a schematic diagram of an application example of a sensor data transmission method provided in an embodiment of the present invention. This embodiment takes a DHU sensor architecture (DHU Sensor Architecture) as an example, but in actual applications, it is not limited to this.

[0122] like Figure 3As shown, this embodiment includes: a master system chip (Master Soc), a slave system chip 1 (SlaveSoc1) and a slave system chip 2 (Slave Soc2), wherein the master system chip is installed with an Android system, the slave system chip 1 is installed with an Android system, and the slave system chip 2 is installed with a Linux / Qnx system as an example, and the structures of the master system chip and the slave system chip 1 installed with the Android system respectively include: an application layer (APP), a framework layer (FWK), a local service layer (Natice) and a hardware abstraction layer (hal); the structure of the slave system chip 2 installed with the Linux / Qnx system includes: an application layer (APP), a middleware (MW), and a sensor daemon and a sensor router.

[0123] The application layer includes multiple applications, and this embodiment takes one application (APK) as an example.

[0124] The framework layer includes: a sensor manager (SensorManager) and a constant sensor JAVA local interface (SensorJnl), which can communicate with each other.

[0125] The local service layer includes: sensor service (SensorService); wherein the sensor service performs process communication with the sensor JAVA local interface.

[0126] The hardware abstraction layer includes: sensor hardware abstraction service (VenusSensorHal) and multiple sensor drivers (Sensor Driver). This embodiment takes two sensor drivers as an example. Among them, the sensor hardware abstraction service and the sensor service communicate with each other. The sensor hardware abstraction service includes: a sensor router (lib VenusSensor Router), wherein the sensor router is used to obtain sensor data on multiple sensor drivers. And the sensor data is sent to the sensor data routers on the slave system-level chip 1 and the slave system-level chip 2 respectively through the remote procedure call protocol RPC, so that each sensor data router on the slave system-level chip shares the sensor data.

[0127] The middleware includes: sensor service (SensorService).

[0128] like Figure 3As shown in the figure: In this embodiment, it is necessary to rely on a hal program (VenusSensorHal) and a dynamic library (libVenusSensorRouter) to cooperate with each other. The main function of the Hal program is to provide a set of hardware-independent interfaces, hiding the specific implementation details of the underlying hardware. In this way, the upper framework and applications of the Android system can use a unified API to interact with the hardware. Figure 3 As can be seen from the overall architecture diagram, there will be a Master Soc with an Android system, and the sensors will be deployed on the Master Soc, while supporting multiple Slave Socs. The Slave Soc can be an Android system, or a QNX / Linux system, etc., which is not limited in this embodiment.

[0129] The SensorHal service of the master system-level chip (Master Soc) will send the sensor data notification to the sensor service (SensorService) on the MasterSoc, and can also forward the acquired sensor data to other slave system-level chips (Slave Soc). After that, the Slave Soc will perform different processing according to the installed system. If the Slave Soc is installed with the Android system, it will be sent to the sensor service (SensorService) of the local service layer through the sensor data router (lib Venus Sensor Router) on the sensor hardware abstraction layer (Venus Sensor Hal) for sharing; if Linux or QNX is installed, it will be sent to the sensor service (SensorService) of the middleware through the sensor data router (lib Venus SensorRouter) and the sensor daemon process for sharing. In general, the sensor data will be notified to the user so that the supporter can share the sensor data.

[0130] This embodiment can be applied to the following application scenarios, but is not limited thereto:

[0131] 1) It can be applied on the Master Android system. Taking the navigation application as an example, by calling the registration interface in the Android native SensorManager, the corresponding frequency and sensor type are registered, and then the SensorManager notifies the SensorService of the Native layer by calling Jni, and the SensorService then sets it to the Sensor Driver through the VenusSensorHal customized in this embodiment. After the Sensor Driver receives the registration and activation, it will send data of the corresponding Sensor data type to the VenusSensorHal according to the registered frequency, and the VenusSensorHal returns it to the SensorService, the SensorService returns it to the SensorJni, the SensorJni is given to the SensorManager, and the SensorManager notifies the application.

[0132] 2) It can be applied on the Slave Android system. Taking the navigation application as an example, by calling the registration interface in the Android native SensorManager, the corresponding frequency and sensor type are registered, and then the SensorManager notifies the SensorService of the Native layer by calling Jni. The SensorService then notifies the libVenusSensorRouter of the Master system through the VenusSensorHal customized by the embodiment of the present invention, and the libVenusSensorRouter of the Slave system of the corresponding frequency and sensor type. Then the libVenusSensorRouter of the Master system notifies the VenusSensorHal, and the VenusSensorHal will be set to the Sensor Driver, and the Sensor After the Driver receives a registration, it will send data of the corresponding Sensor data type to VenusSensorHal according to the registration frequency, and then VenusSensorHal will forward it to the Slave's libVenusSensorRouter through libVenusSensorRouter, and then the Slave's libVenusSensorRouter will give it to VenusSensorHal, VenusSensorHal will return it to SensorService, SensorService will return it to SensorJni, SensorJni will give it to SensorManager, and SensorManager will notify the application.

[0133] 3) It can be applied on the Slave linux / Qnx system. The application can be a navigation application. By calling the SensorService of the MW layer, the SensorService notifies our customized SensorDaemon, and the SensorDaemon of the Slave system calls libVenusSensorRouter to notify the libVenusSensorRouter of the Master system of the corresponding frequency and sensor type. Then the libVenusSensorRouter of the Master system notifies VenusSensorHal, and VenusSensorHal will be set to the Sensor Driver. After the Sensor Driver receives the registration, it will send the corresponding Sensor data type to VenusSensorHal according to the registered frequency. Then, VenusSensorHal will forward it to the Slave's libVenusSensorRouter through libVenusSensorRouter, and then the Slave's libVenusSensorRouter sends it to SensorDaemon, and SensorDaemon returns it to SensorService, and SensorService notifies the application.

[0134] It should be noted that, for the method embodiments, for the sake of simplicity, they are all described as a series of action combinations, but those skilled in the art should know that this implementation disclosure is not limited by the order of the actions described, because according to the present invention, certain steps can be performed in other orders or simultaneously. Secondly, those skilled in the art should also know that the embodiments described in the specification are all preferred embodiments, and the actions involved are not necessarily required by the present invention.

[0135] See also Figure 4 , is a block diagram of a sensor data transmission device provided by an embodiment of the present invention. The device is applied to a main system-level chip, and a sensor hardware abstraction layer is configured on the main system-level chip. The sensor hardware abstraction layer includes: a sensor data router, and the device includes: an acquisition module 401 and a first transmission module 402, wherein,

[0136] An acquisition module 401 is used to acquire sensor data on a sensor driver;

[0137] The first transmission module 402 is used to send the sensor data to multiple slave sensor data routers on the system-on-chip through the remote procedure call protocol, so that each slave sensor data router on the system-on-chip shares the sensor data.

[0138] Optionally, in another embodiment, based on the above embodiment, the first transmission module transmits multiple slave system-level chips to install the same type of operating system, or multiple slave system-level chips to install different types of operating systems.

[0139] Optionally, in another embodiment, based on the above embodiment, the first transmission module transmits multiple operating systems of the same type installed from the system-level chip, or multiple operating systems of different types installed from the system-level chip, including:

[0140] When the plurality of slave system-level chips are all installed with the first type of operating system, each slave system-level chip sends the acquired sensor data to a corresponding sensor service for sharing; or

[0141] When the second type of operating system is installed on all of the plurality of slave system-level chips, each slave system-level chip sends the acquired sensor data to the corresponding middleware for sharing; or

[0142] When a part of the plurality of slave SoCs installs the first type of operating system and the remaining part installs the second type of operating system, each of the remaining slave SoCs sends the acquired sensor data to the corresponding middleware for sharing.

[0143] Optionally, in another embodiment, based on the above embodiment, the device further includes: a receiving module 501, a setting module 502 and a second transmission module 503, and its structural block diagram is as follows: Figure 5 As shown,

[0144] The receiving module 501 is configured to receive a request for setting a transmission frequency sent by at least one of the plurality of slave SoCs before the first transmission module 402 sends the sensor data to the sensor data routers on the plurality of slave SoCs through the remote procedure call protocol;

[0145] A setting module 502, configured to set a corresponding transmission frequency according to the setting transmission frequency request;

[0146] The second transmission module 503 is used to send the sensor data to at least one sensor data router on the slave system-on-chip that requests to set the transmission frequency through the remote procedure call protocol according to the set transmission frequency.

[0147] Optionally, in another embodiment, based on the above embodiment, the device further includes: a recording module 601, whose structural block diagram is as follows: Figure 6 As shown,

[0148] The recording module 601 is used to record the sensor data on the sensor driver in real time after the acquisition module 401 acquires the sensor data on the sensor driver, so as to play back the stored sensor data when simulating a problem scenario.

[0149] See also Figure 7 , is a block diagram of a sensor data transmission device provided by an embodiment of the present invention, the device is applied to a sensor data router on a system-level chip, the device includes: an acquisition module 701 and a transmission module 702, wherein,

[0150] An acquisition module 701 is used to acquire sensor data sent by a sensor data router on a main system-level chip;

[0151] The transmission module 702 is used to send the sensor data to the corresponding sensor service or middleware for sharing.

[0152] Optionally, in another embodiment, based on the above embodiment, the transmission module includes: a first sending module and / or a second sending module, wherein:

[0153] A first sending module is used for, when the first type of operating system is installed on the slave system-level chip, the slave system-level chip includes a sensor hardware abstraction layer, and the sensor hardware abstraction layer includes a sensor data router; then the sensor data is sent to the sensor service of the corresponding local service layer through the sensor data router on the sensor hardware abstraction layer for sharing;

[0154] The second sending module is used to send the sensor data to the corresponding middleware sensor service for sharing through the sensor data router and the sensor daemon process when the second type of operating system is installed on the slave system-level chip, and the slave system-level chip includes a sensor data router.

[0155] Optionally, in another embodiment, based on the above embodiment, the device further includes: a request module and a receiving module, wherein:

[0156] A request module, used for sending a request for setting a transmission frequency to the sensor data router on the main system-level chip;

[0157] The receiving module is used to receive the sensor data sent by the sensor data router on the main system-level chip through the remote procedure call protocol according to the transmission frequency set by the request.

[0158] Optionally, an embodiment of the present invention further provides an electronic device, including:

[0159] processor;

[0160] a memory for storing instructions executable by the processor;

[0161] The processor is configured to execute the instructions to implement the sensor data transmission method as described above.

[0162] Optionally, an embodiment of the present invention further provides a computer-readable storage medium, when instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the sensor data transmission method as described above.

[0163] Optionally, an embodiment of the present invention further provides a computer program product, including a computer program or instructions, which implement the above-mentioned sensor data transmission method when executed by a processor of an electronic device.

[0164] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0165] The device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the scheme of this embodiment. Ordinary technicians in this field can understand and implement it without paying creative labor.

[0166] Figure 8 800 is a block diagram of an electronic device 800 provided in an embodiment of the present invention. For example, the electronic device 800 may be a mobile terminal or a server, and the electronic device is a mobile terminal as an example for explanation in the embodiment of the present invention. For example, the electronic device 800 may be a mobile phone, a computer, a digital broadcast terminal, a message transceiver device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.

[0167] Reference Figure 8 , the electronic device 800 may include one or more of the following components: a processing component 802 , a memory 804 , a power component 806 , a multimedia component 808 , an audio component 810 , an input / output (I / O) interface 812 , a sensor component 814 , and a communication component 816 .

[0168] The processing component 802 generally controls the overall operation of the electronic device 800, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 802 may include one or more processors 820 to execute instructions to complete all or part of the steps of the above-mentioned method. In addition, the processing component 802 may include one or more modules to facilitate the interaction between the processing component 802 and other components. For example, the processing component 802 may include a multimedia module to facilitate the interaction between the multimedia component 808 and the processing component 802.

[0169] The memory 804 is configured to store various types of data to support operations on the device 800. Examples of such data include instructions for any application or method operating on the electronic device 800, contact data, phone book data, messages, pictures, videos, etc. The memory 804 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.

[0170] The power supply component 806 provides power to the various components of the electronic device 800. The power supply component 806 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the electronic device 800.

[0171] The multimedia component 808 includes a screen that provides an output interface between the electronic device 800 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 808 includes a front camera and / or a rear camera. When the device 800 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and the rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.

[0172] The audio component 810 is configured to output and / or input audio signals. For example, the audio component 810 includes a microphone (MIC), and when the electronic device 800 is in an operating mode, such as a call mode, a recording mode, and a voice recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 804 or sent via the communication component 816. In some embodiments, the audio component 810 also includes a speaker for outputting audio signals.

[0173] I / O interface 812 provides an interface between processing component 802 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: home button, volume button, start button, and lock button.

[0174] The sensor assembly 814 includes one or more sensors for providing various aspects of status assessment for the electronic device 800. For example, the sensor assembly 814 can detect the open / closed state of the device 800, the relative positioning of components, such as the display and keypad of the electronic device 800, and the sensor assembly 814 can also detect the position change of the electronic device 800 or a component of the electronic device 800, the presence or absence of contact between the user and the electronic device 800, the orientation or acceleration / deceleration of the electronic device 800, and the temperature change of the electronic device 800. The sensor assembly 814 may include a proximity sensor configured to detect the presence of nearby objects without any physical contact. The sensor assembly 814 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 814 may also include an accelerometer, a gyroscope sensor, a magnetic sensor, a pressure sensor, or a temperature sensor.

[0175] The communication component 816 is configured to facilitate wired or wireless communication between the electronic device 800 and other devices. The electronic device 800 can access a wireless network based on a communication standard, such as WiFi, a carrier network (such as 2G, 3G, 4G or 5G), or a combination thereof. In an exemplary embodiment, the communication component 816 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 816 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.

[0176] In an embodiment, the electronic device 800 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors, or other electronic components to execute the sensor data transmission method shown above.

[0177] In an embodiment, a computer-readable storage medium is also provided, and when the instructions in the computer-readable storage medium are executed by the processor of the electronic device, the electronic device 800 can execute the above-mentioned sensor data transmission method. For example, the computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0178] In an embodiment, a computer program product is further provided, including a computer program or instructions. When the computer program or instructions are executed by the processor 820 of the electronic device 800, the electronic device 800 executes the above-mentioned sensor data transmission method.

[0179] Fig. 9 is a block diagram of a device 900 for transmitting sensor data provided by an embodiment of the present invention. For example, the device 900 may be provided as a server. Fig. 9 , the apparatus 900 includes a processing component 922, which further includes one or more processors, and a memory resource represented by a memory 932 for storing instructions, such as an application, that can be executed by the processing component 922. The application stored in the memory 932 may include one or more modules, each corresponding to a set of instructions. In addition, the processing component 922 is configured to execute the instructions to perform the above method.

[0180] The device 900 may also include a power supply component 926 configured to perform power management of the device 900, a wired or wireless network interface 950 configured to connect the device 900 to a network, and an input / output (I / O) interface 958. The device 900 may operate based on an operating system stored in the memory 932, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, or the like.

[0181] Those skilled in the art will readily appreciate other embodiments of the present invention after considering the specification and practicing the invention disclosed herein. This application is intended to cover any variations, uses or adaptations of the present invention that follow the general principles of the present invention and include common knowledge or customary techniques in the art that are not disclosed by the present invention. The specification and examples are to be considered exemplary only, and the true scope and spirit of the present invention are indicated by the following claims.

[0182] It should be understood that the present invention is not limited to the exact construction that has been described above and shown in the drawings and that various modifications and changes may be made without departing from the scope thereof. The scope of the present invention is limited only by the appended claims.

Claims

1. A method for transmitting sensor data, characterized in that: The method is applied to a main system-level chip, the main system-level chip is configured with a sensor hardware abstraction layer, the sensor hardware abstraction layer includes a sensor data router, and the method includes: Get sensor data on the sensor driver; The sensor data is sent to a plurality of slave sensor data routers on the system-level chip through a remote procedure call protocol, so that each of the slave sensor data routers on the system-level chip shares the sensor data.

2. The method for transmitting sensor data according to claim 1, characterized in that: The plurality of slave SoCs may install the same type of operating system, or the plurality of slave SoCs may install different types of operating systems.

3. The method for transmitting sensor data according to claim 1, characterized in that: The multiple slave system-on-chips install the same type of operating system, or the multiple slave system-on-chips install different types of operating systems, including: When the plurality of slave system-level chips are all installed with the first type of operating system, each slave system-level chip sends the acquired sensor data to a corresponding sensor service for sharing; or When the second type of operating system is installed on all of the plurality of slave system-level chips, each slave system-level chip sends the acquired sensor data to the corresponding middleware for sharing; or When a part of the plurality of slave SoCs installs the first type of operating system and the remaining part installs the second type of operating system, each of the remaining slave SoCs sends the acquired sensor data to the corresponding middleware for sharing.

4. The method for transmitting sensor data according to any one of claims 1 to 3, characterized in that: The method further comprises: receiving a transmission frequency setting request sent by at least one of the plurality of slave SoCs; Setting the corresponding transmission frequency according to the setting transmission frequency request; According to the set transmission frequency, the sensor data is sent through a remote procedure call protocol to at least one sensor data router on the slave system-on-chip that requests to set the transmission frequency.

5. The method for transmitting sensor data according to any one of claims 1 to 3, characterized in that: After acquiring the sensor data on the sensor driver, the method further includes: The sensor data acquired on the sensor driver is recorded in real time so as to play back the stored sensor data when simulating a problem scenario.

6. A method for transmitting sensor data, characterized in that: The method is applied to a sensor data router on a system-level chip, comprising: Obtain sensor data sent by a sensor data router on a main system-level chip; The sensor data is transmitted to the corresponding sensor service or middleware for sharing.

7. The method for transmitting sensor data according to claim 6, characterized in that: The sending the sensor data to a corresponding sensor service or middleware for sharing includes: When the first type of operating system is installed on the slave system-level chip, the slave system-level chip includes a sensor hardware abstraction layer, and the sensor hardware abstraction layer includes a sensor data router; the sensor data is sent to the sensor service of the corresponding local service layer through the sensor data router on the sensor hardware abstraction layer for sharing; or When the second type of operating system is installed on the slave system-on-chip, the slave system-on-chip includes a sensor data router; the sensor data is sent to the corresponding sensor service of the middleware through the sensor data router and the sensor daemon process for sharing.

8. The method for transmitting sensor data according to claim 6, characterized in that: The method further comprises: sending a request to set a transmission frequency to a sensor data router on the main system-on-chip; The sensor data is received from the sensor data router on the main system-on-chip and sent through the remote procedure call protocol according to the transmission frequency set by the request.

9. A sensor data transmission device, characterized in that: The device is applied to a main system-level chip, and a sensor hardware abstraction layer is configured on the main system-level chip. The sensor hardware abstraction layer includes: a sensor data router. The device includes: The acquisition module is used to obtain sensor data on the sensor driver; The first transmission module is used to send the sensor data to a plurality of slave sensor data routers on the system-on-chip through a remote procedure call protocol, so that each of the slave sensor data routers on the system-on-chip shares the sensor data.

10. A sensor data transmission device, characterized in that: The device is applied to a sensor data router on a system-level chip, and the device comprises: An acquisition module, used for acquiring sensor data sent by a sensor data router on a main system-level chip; The transmission module is used to send the sensor data to the corresponding sensor service or middleware for sharing.

11. An electronic device, characterized in that: include: processor; a memory for storing instructions executable by the processor; The processor is configured to execute the instructions to implement the sensor data transmission method according to any one of claims 1 to 8.

12. A computer-readable storage medium, characterized in that: When the instructions in the computer-readable storage medium are executed by a processor of an electronic device, the electronic device is enabled to execute the sensor data transmission method according to any one of claims 1 to 8.