Method, system, device, processor and computer readable storage medium thereof for realizing modular signal management and distribution of vehicle-mounted instrument
By adopting a modular signal management and distribution method, the vehicle instrument system achieves low-coupling and configurable signal management, solving the problems of signal coupling and registration management, and improving the system's stability and scalability.
Patent Information
- Application Number
- CN202611394103.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-09
- Publication Date
- 2026-11-27
AI Technical Summary
The vehicle instrument system suffers from severe signal coupling, lack of unified signal lifecycle management, module registration relying on manual management, and signal subscription redundancy, resulting in high maintenance costs, easy display abnormalities, and difficulty in expansion.
A modular signal management and distribution approach is adopted. Through the collaborative mechanism of the signal management center, module manager and data transmission management layer, automatic module registration, declarative signal subscription and polymorphic update strategy are realized, reducing coupling and providing a global state cleanup interface.
It improves the operational stability and resource utilization of the vehicle instrument system, reduces the processor load, ensures global data consistency during power mode switching, and improves the scalability and maintenance efficiency of the software architecture.
Smart Images

Figure CN123178122A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the fields of automotive electronics and intelligent connected vehicles, and more particularly to the field of vehicle electronic and electrical architecture. Specifically, it refers to a method, system, device, processor, and computer-readable storage medium for realizing modular signal management and distribution of vehicle instruments. Background Technology
[0002] With the rapid development of automotive electronics technology, the automotive electronic and electrical architecture has evolved from a traditional distributed architecture to a domain-centralized architecture. The entire vehicle is divided into multiple functional domains, such as the powertrain domain, chassis domain, body domain, cockpit domain, and driver assistance domain. Electronic control units (ECUs) in each domain are interconnected via CAN / CAN FD, LIN, and automotive Ethernet. As a core human-machine interface component directly facing the driver in the cockpit domain, the in-vehicle instrument cluster needs to interact with dozens or even hundreds of ECUs simultaneously, handling hundreds of signals including vehicle speed, engine speed, battery status, tire pressure, and fault alarms. These signals include both periodic and event-triggered messages. Furthermore, in-vehicle instrument clusters typically run on embedded SoCs with limited computing power and storage resources, requiring them to handle the reception and processing of massive amounts of signals while ensuring smooth rendering of a high-resolution LCD interface. Based on these scenarios, the industry currently faces the following main technical challenges: (1) Severe signal coupling: The functional modules directly call each other's interfaces to transmit data through hard coding, resulting in high coupling between modules. Adding or modifying a signal requires modifying the code in multiple places, which is extremely costly to maintain and can easily introduce defects.
[0003] (2) Lack of unified signal lifecycle management: In traditional solutions, each module independently manages the registration, reception, validity judgment, and timeout handling of its required signals, without a unified signal lifecycle management mechanism. When the instrument switches power modes, it is impossible to uniformly reset the status of global signals, which can easily lead to display abnormalities caused by residual data.
[0004] (3) Module registration and discovery rely on manual management: The instantiation, registration and destruction of each functional module need to be explicitly managed by the upper-level code, and there is a lack of an automated module lifecycle registration mechanism. In vehicle instrument systems with a large number of modules, this manual management method is prone to omissions and it is difficult to achieve unified global operations (such as batch clearing data).
[0005] (4) Lack of declarative signal subscription mechanism: Modules need to subscribe to the required signals one by one by writing procedural code. The code is redundant and easy to miss. When the number of signals is as many as hundreds, the maintainability of this method is extremely poor. Summary of the Invention
[0006] The purpose of this invention is to overcome the shortcomings of the prior art and provide a method, system, device, processor and its computer-readable storage medium for realizing modular signal management and distribution of vehicle instruments, which meets the requirements of low coupling architecture, high development efficiency, simple operation and wide applicability.
[0007] To achieve the above objectives, the present invention provides a method, system, apparatus, processor, and computer-readable storage medium for modular signal management and distribution of vehicle-mounted instruments, as follows: The main feature of this method for modular signal management and distribution of vehicle instruments is that the method includes the following steps: (1) During the initialization phase, each functional module of the vehicle instrument is instantiated by inheriting a preset module base class, and a set of attention signals and an update strategy corresponding to each signal in the signal mapping table corresponding to the functional module are declared; the set of attention signals is registered with the globally unique signal management center through the module base class, and a connection relationship is established between the data change notification signal of each signal in the set of attention signals and the corresponding slot function in the functional module. (2) During the operation phase, receive signal data to be processed from external data sources; search for the signal data unit corresponding to the signal data to be processed in the global registry of the signal management center; determine whether the triggering condition is met based on the update strategy recorded in the found signal data unit; when the triggering condition is met, issue the corresponding data change notification signal through the signal data unit; the functional module that subscribes to the corresponding signal automatically receives the signal data to be processed through the slot function with the established connection relationship, and performs business logic processing based on the signal data to be processed.
[0008] Preferably, step (1), which involves registering the set of signals of interest with the globally unique signal management center through the module base class, specifically includes the following steps: The signal management center receives registration requests for signals of interest submitted by each of the aforementioned functional modules; For each requested signal, create a corresponding signal data unit; Each of the created signal data units is stored in the global registry of the signal management center with the signal name as the key; during the registration process, deduplication filtering is performed on request signals with the same signal name, so that only one signal data unit with the same signal name is maintained globally.
[0009] Preferably, step (1), establishing the connection relationship between the data change notification signal of each signal in the set of signals of interest and the corresponding slot function in the functional module, specifically includes the following steps: Iterate through the signal mapping table of the functional module and register all signals in the signal mapping table in batches with the signal management center; The binding relationship between the data change notification signal corresponding to each signal and the corresponding slot function inherited by the functional module from the module base class is automatically established through the module base class.
[0010] Preferably, the update strategy in step (1) includes at least one of the following: an immediate update strategy, a change update strategy, and a periodic update strategy; The determination of whether the triggering condition is met based on the update strategy recorded in the found signal data unit is as follows: When the corresponding update strategy is the immediate update strategy, the triggering condition is unconditionally determined to be met. When the corresponding update strategy is the change update strategy, it is determined whether the value of the signal data to be processed has actually changed compared with the data value stored in the current signal data unit. If an actual change has occurred, the currently stored data value is updated and it is determined that the triggering condition is met. When the corresponding update strategy is the periodic update strategy, it is determined whether the preset update cycle has been reached. If it has been reached, the currently stored data value is updated and it is determined that the triggering condition is met.
[0011] Preferably, the functional module subscribing to the corresponding signal in step (2) automatically receives the signal data to be processed through the slot function with the established connection, and performs business logic processing based on the signal data to be processed, specifically including the following steps: The corresponding slot function of the functional module is configured as a unified input callback entry, which receives the signal name, signal data value and data validity status as input parameters. The functional module, within the unified input callback entry, distributes the received signal data to be processed to the corresponding specific business processing function for execution based on the input signal name.
[0012] Preferably, after performing business logic processing based on the signal data to be processed in step (2), the following steps are further included: The data transmission management layer, configured using the singleton pattern, uniformly manages the sending channels of communication messages. The functional modules send response messages generated after executing business logic through the data transmission management layer.
[0013] Preferably, the method further includes an automatic module registration step, specifically comprising the following steps: During the instantiation and construction of each functional module, the constructor of the module base class automatically registers the instance of the current functional module to the module table of the globally unique module manager, and the module manager uniformly maintains the mapping relationship from module name to module instance pointer.
[0014] Preferably, the method further includes a cleanup phase processing step, specifically including the following steps: In response to the instrument power mode switching operation, a data cleanup command is triggered; The module manager is invoked to traverse all functional modules in the global module table and control each functional module to call its own configured data clearing interface to clear the module's business data. After cleaning up the business data of each of the aforementioned functional modules, the signal management center is invoked to traverse all signals in the global registry and reset the data values in the corresponding signal data units to their initial state to eliminate residual dirty data.
[0015] Preferably, the module base class defines a data initialization interface, a signal initialization interface, and a data clearing interface; the signal mapping table is configured and populated by the functional module when implementing the signal initialization interface; the data clearing interface is used by the functional module to clear its own business data.
[0016] Preferably, the signal data unit includes multiple attribute parameters, including signal name, current signal value, corresponding update strategy, and data validity status; the data validity status includes at least valid status, invalid status, and timeout status.
[0017] The system for modular signal management and distribution of in-vehicle instruments is characterized by the following features: The module base class configuration unit is used to provide a basic operating framework for multiple functional modules, enabling each functional module to be instantiated through inheritance during the initialization phase and to declare a set of attention signals and corresponding update strategies in the corresponding signal mapping table. The module base class configuration unit is also used to automatically establish the connection relationship between the data change notification signal of the signal data unit and the slot function of the corresponding functional module, so that the functional module can automatically receive the signal data to be processed and execute business logic processing when the trigger condition is met. The signal management center is used to receive registration requests submitted by each of the functional modules through the module base class configuration unit, create and manage corresponding signal data units in the global registry using the signal name as the key; it is also used to receive signal data to be processed input from external data sources during the running phase, search for the corresponding signal data unit in the global registry according to the signal name, and forward the signal data to be processed to that signal data unit. The signal data unit corresponds to each of the globally registered signals and is used to carry signal data. It determines whether the triggering condition is met based on the corresponding update strategy and sends a data change notification signal when the triggering condition is met. The module manager is used to automatically register the instance of the current functional module to a globally unique module table during the construction process of instantiating each of the aforementioned functional modules.
[0018] Preferably, the system further includes a data transmission management layer, which is implemented using a singleton pattern to uniformly manage the sending configuration of controller area network packets and IP-based service-oriented middleware packets, providing a unified data sending channel for each of the functional modules.
[0019] Preferably, the update strategy includes at least one of an immediate update strategy, a variable update strategy, and a periodic update strategy; when the corresponding update strategy is the immediate update strategy, the signal data unit unconditionally determines that the trigger condition is met; when the corresponding update strategy is the variable update strategy, the currently stored data value is updated and the trigger condition is determined to be met only when the value of the signal data to be processed changes compared to the currently stored data value; when the corresponding update strategy is the periodic update strategy, the currently stored data value is updated periodically according to a preset update cycle and the trigger condition is determined to be met.
[0020] The main feature of this device for modular signal management and distribution of vehicle-mounted instruments is that the device includes: A processor is configured to execute computer-executable instructions; The memory stores one or more computer-executable instructions, which, when executed by the processor, implement the various steps of the method for implementing modular signal management and distribution of vehicle instruments as described above.
[0021] The processor for implementing modular signal management and distribution of vehicle instruments is characterized in that the processor is configured to execute computer-executable instructions, which, when executed by the processor, implement the various steps of the above-described method for implementing modular signal management and distribution of vehicle instruments.
[0022] The main feature of this computer-readable storage medium is that it stores a computer program thereon, which can be executed by a processor to implement the various steps of the above-described method for implementing modular signal management and distribution of vehicle instruments.
[0023] This invention employs a method, system, device, processor, and computer-readable storage medium for modular signal management and distribution in vehicle-mounted instrument clusters. By constructing a modular architecture comprising a signal management center layer, a module management layer, and a signal data unit layer, coupled with a collaborative mechanism of automatic module registration and declarative mapping tables, external data sources and functional modules are decoupled. Furthermore, a polymorphic update strategy is introduced within the signal data units for change detection. These technical means change the traditional highly coupled manual subscription mode, enabling conditional triggering and automatic binding of signals, and providing a unified state cleanup interface at the global level. Based on this, the system effectively reduces invalid and repetitive data processing operations, lowers the processor's computational load, and ensures high consistency of global data states during power mode switching and other scenarios, avoiding interface display anomalies caused by residual dirty data. Ultimately, this improves the operational stability and resource utilization of the vehicle-mounted instrument cluster system, and enhances the scalability and maintenance efficiency of the software architecture. Attached Figure Description
[0024] Figure 1 This is a diagram illustrating the overall architecture of the system for modular signal management and distribution of vehicle-mounted instruments according to the present invention.
[0025] Figure 2 This is a data flow flowchart illustrating the method for modular signal management and distribution of vehicle-mounted instruments according to the present invention. Detailed Implementation
[0026] To more clearly describe the technical content of the present invention, the following description is provided in conjunction with specific embodiments.
[0027] The method for modular signal management and distribution of vehicle instrument clusters according to the present invention includes the following steps: (1) During the initialization phase, each functional module of the vehicle instrument is instantiated by inheriting a preset module base class, and a set of attention signals and an update strategy corresponding to each signal in the signal mapping table corresponding to the functional module are declared; the set of attention signals is registered with the globally unique signal management center through the module base class, and a connection relationship is established between the data change notification signal of each signal in the set of attention signals and the corresponding slot function in the functional module. (2) During the operation phase, receive signal data to be processed from external data sources; search for the signal data unit corresponding to the signal data to be processed in the global registry of the signal management center; determine whether the triggering condition is met based on the update strategy recorded in the found signal data unit; when the triggering condition is met, issue the corresponding data change notification signal through the signal data unit; the functional module that subscribes to the corresponding signal automatically receives the signal data to be processed through the slot function with the established connection relationship, and performs business logic processing based on the signal data to be processed.
[0028] As a preferred embodiment of the present invention, step (1), which involves registering the set of signals of interest with the globally unique signal management center through the module base class, specifically includes the following steps: The signal management center receives registration requests for signals of interest submitted by each of the aforementioned functional modules; For each requested signal, create a corresponding signal data unit; Each of the created signal data units is stored in the global registry of the signal management center with the signal name as the key; during the registration process, deduplication filtering is performed on request signals with the same signal name, so that only one signal data unit with the same signal name is maintained globally.
[0029] As a preferred embodiment of the present invention, step (1) of establishing the connection relationship between the data change notification signal of each signal in the set of signals of interest and the corresponding slot function in the functional module specifically includes the following steps: Iterate through the signal mapping table of the functional module and register all signals in the signal mapping table in batches with the signal management center; The binding relationship between the data change notification signal corresponding to each signal and the corresponding slot function inherited by the functional module from the module base class is automatically established through the module base class.
[0030] As a preferred embodiment of the present invention, the update strategy of step (1) includes at least one of the following: immediate update strategy, change update strategy and periodic update strategy; The determination of whether the triggering condition is met based on the update strategy recorded in the found signal data unit is as follows: When the corresponding update strategy is the immediate update strategy, the triggering condition is unconditionally determined to be met. When the corresponding update strategy is the change update strategy, it is determined whether the value of the signal data to be processed has actually changed compared with the data value stored in the current signal data unit. If an actual change has occurred, the currently stored data value is updated and it is determined that the triggering condition is met. When the corresponding update strategy is the periodic update strategy, it is determined whether the preset update cycle has been reached. If it has been reached, the currently stored data value is updated and it is determined that the triggering condition is met.
[0031] In a preferred embodiment of the present invention, the functional module subscribing to the corresponding signal in step (2) automatically receives the signal data to be processed through the slot function with the established connection relationship, and performs business logic processing based on the signal data to be processed, specifically including the following steps: The corresponding slot function of the functional module is configured as a unified input callback entry, which receives the signal name, signal data value and data validity status as input parameters. The functional module, within the unified input callback entry, distributes the received signal data to be processed to the corresponding specific business processing function for execution based on the input signal name.
[0032] In a preferred embodiment of the present invention, after performing business logic processing based on the signal data to be processed in step (2), the following steps are further included: The data transmission management layer, configured using the singleton pattern, uniformly manages the sending channels of communication messages. The functional modules send response messages generated after executing business logic through the data transmission management layer.
[0033] In a preferred embodiment of the present invention, the method further includes an automatic module registration step, specifically comprising the following steps: During the instantiation and construction of each functional module, the constructor of the module base class automatically registers the instance of the current functional module to the module table of the globally unique module manager, and the module manager uniformly maintains the mapping relationship from module name to module instance pointer.
[0034] In a preferred embodiment of the present invention, the method further includes a cleaning phase processing step, specifically comprising the following steps: In response to the instrument power mode switching operation, a data cleanup command is triggered; The module manager is invoked to traverse all functional modules in the global module table and control each functional module to call its own configured data clearing interface to clear the module's business data. After cleaning up the business data of each of the aforementioned functional modules, the signal management center is invoked to traverse all signals in the global registry and reset the data values in the corresponding signal data units to their initial state to eliminate residual dirty data.
[0035] In a preferred embodiment of the present invention, the module base class defines a data initialization interface, a signal initialization interface, and a data clearing interface; the signal mapping table is configured and populated by the functional module when implementing the signal initialization interface; the data clearing interface is used by the functional module to clear its own business data.
[0036] In a preferred embodiment of the present invention, the signal data unit includes multiple attribute parameters, including signal name, current signal value, corresponding update strategy, and data validity status; the data validity status includes at least valid status, invalid status, and timeout status.
[0037] The system for modular signal management and distribution of in-vehicle instruments is characterized by the following features: The module base class configuration unit is used to provide a basic operating framework for multiple functional modules, enabling each functional module to be instantiated through inheritance during the initialization phase and to declare a set of attention signals and corresponding update strategies in the corresponding signal mapping table. The module base class configuration unit is also used to automatically establish the connection relationship between the data change notification signal of the signal data unit and the slot function of the corresponding functional module, so that the functional module can automatically receive the signal data to be processed and execute business logic processing when the trigger condition is met. The signal management center is used to receive registration requests submitted by each of the functional modules through the module base class configuration unit, create and manage corresponding signal data units in the global registry using the signal name as the key; it is also used to receive signal data to be processed input from external data sources during the running phase, search for the corresponding signal data unit in the global registry according to the signal name, and forward the signal data to be processed to that signal data unit. The signal data unit corresponds to each of the globally registered signals and is used to carry signal data. It determines whether the triggering condition is met based on the corresponding update strategy and sends a data change notification signal when the triggering condition is met. The module manager is used to automatically register the instance of the current functional module to a globally unique module table during the construction process of instantiating each of the aforementioned functional modules.
[0038] In a preferred embodiment of the present invention, the system further includes a data transmission management layer, which is implemented in a singleton pattern and is used to uniformly manage the sending configuration of controller local area network packets and IP-based service-oriented middleware packets, providing a unified data sending channel for each of the functional modules.
[0039] In a preferred embodiment of the present invention, the update strategy includes at least one of an immediate update strategy, a variable update strategy, and a periodic update strategy; when the corresponding update strategy is the immediate update strategy, the signal data unit unconditionally determines that the trigger condition is met; when the corresponding update strategy is the variable update strategy, the currently stored data value is updated and the trigger condition is determined to be met only when the value of the signal data to be processed changes compared to the currently stored data value; when the corresponding update strategy is the periodic update strategy, the currently stored data value is updated periodically according to a preset update cycle and the trigger condition is determined to be met.
[0040] The present invention provides a device for modular signal management and distribution of in-vehicle instruments, wherein the device includes: A processor is configured to execute computer-executable instructions; The memory stores one or more computer-executable instructions, which, when executed by the processor, implement the various steps of the method for implementing modular signal management and distribution of vehicle instruments as described above.
[0041] The present invention provides a processor for implementing modular signal management and distribution of in-vehicle instruments, wherein the processor is configured to execute computer-executable instructions, and when the computer-executable instructions are executed by the processor, the various steps of the above-described method for implementing modular signal management and distribution of in-vehicle instruments are implemented.
[0042] The computer-readable storage medium of the present invention stores a computer program thereon, which can be executed by a processor to implement the various steps of the above-described method for implementing modular signal management and distribution of vehicle instruments.
[0043] This invention aims to solve the technical problems of high coupling, lack of unified lifecycle management, single signal update strategy, module registration relying on manual management, and redundant signal subscription methods in the signal management of multi-domain modules in vehicle instrument systems. It provides a modular signal management and distribution method and system with low coupling, configurability, and support for multiple update strategies.
[0044] In a specific embodiment of the present invention, a modular signal management and distribution method for vehicle-mounted instruments is provided, comprising the following core components: (a) Signal Data Set Layer Define the smallest signal data carrier unit, each of which contains the following attributes: 1) Signal name (signal identifier); 2) Current signal value; 3) Signal update strategy (immediate update, change update, periodic update); 4) Data validity status (valid, invalid, timed out).
[0045] The signal data unit internally encapsulates a data change detection and notification mechanism: when external calls are made to set data, a decision is made based on a preset update strategy to determine whether to trigger a change notification—if the strategy is "immediate update," a notification is made unconditionally; if the strategy is "change update," a notification is made only when the data value actually changes; and if the strategy is "periodic update," the data is updated periodically. This hierarchical strategy design effectively avoids invalid repetitive processing and reduces CPU load.
[0046] (ii) Signal Management Center Layer (SignalManager) Employing the singleton pattern to implement a globally unique signal management center, it provides the following core functionalities: (1) Signal Registration: Receive signal registration requests (including signal name and update strategy) submitted by each module, create a corresponding signal data unit object for each signal, and store it in the global registry with the signal name as the key. The registration process automatically removes duplicates—signal names are created only once.
[0047] (2) Signal data setting: Receive signal data from external data sources (such as CAN bus or SOME / IP data parsing module), search for the corresponding signal data unit in the registry according to the signal name, and forward the data to the unit for policy judgment and distribution.
[0048] (3) Global signal buffer cleanup: Provides a unified signal clearing interface, traversing all registered signals and resetting their data values to the initial state. This interface can be called in scenarios such as instrument power mode switching to ensure the consistency of global signal states and avoid UI abnormalities caused by dirty data.
[0049] (III) Module Base Class Layer (ModuleBase) Define an abstract base class for all functional modules, which encapsulates common capabilities such as signal lifecycle management, automatic module registration, and automatic signal binding. (1) Declarative signal subscription: Each module declares the set of signals it is interested in by maintaining a signal mapping table (signal name → update strategy). Modules do not need to write procedural signal subscription code, but only need to populate this mapping table during the initialization phase.
[0050] (2) Automatic signal binding: The base class provides a signal registration method, which traverses the module's signal mapping table, registers all signals in batches with the signal management center, and automatically establishes a Qt signal-slot connection between the notification signal of the signal data unit and the module's slot function. When the data of any signal of interest changes, the corresponding module's slot function is automatically called.
[0051] (3) Automatic module registration: The current module instance is automatically registered to the global module table of the module manager in the constructor of the module base class, without the need for manual management by the upper layer code.
[0052] (4) Virtual function interface: Define three pure virtual functions or virtual function interfaces: Data initialization (DataInit), Signal initialization (SignalInit), and Clear Data (ClearData). This forces subclasses to implement the necessary initialization and cleanup logic, while providing a unified call entry point for global batch operations.
[0053] (iv) Module Management Layer (ModuleManager) A globally unique module manager is implemented using the singleton pattern, maintaining a module pointer mapping table (module name → module instance pointer). A global batch operation interface is provided (such as batch clearing all module data), which calls the corresponding virtual function for each module instance by traversing the module table.
[0054] (v) Data Transmission Management Layer (TransmitManager) It adopts a singleton pattern to manage the transmission configuration of CAN and SOME / IP messages, providing a unified data transmission channel for the module.
[0055] The overall workflow of the system of this invention is as follows: Initialization phase: (1) Each functional module (such as the braking system module, the transmission module, etc.) inherits from ModuleBase and is instantiated; the functional modules refer to the code of each module that implements the instrument function, such as the engine module and the transmission module; (2) During the construction process, the module is automatically registered with the ModuleManager; (3) Each module fills in m_signalMap in SignalInit(), declaring the signals of interest and update strategies; (4) Call SignalRegister() to register signals in batches with SignalManager and complete the automatic signal-slot binding.
[0056] Operation phase: (1) After the external data source is parsed, the SignalManager::SetSignalData() method is called to write the signal data; (2) SignalManager finds the corresponding SignalDataSet based on the signal name, and the latter determines whether a notification needs to be triggered based on the update strategy; (3) When the policy conditions are met, SignalDataSet sends a dataChanged signal; (4) All modules that have subscribed to the signal automatically receive data and execute business logic through the bound slot function; (5) After the module has finished processing, it calls TransmitManager to send a response message as needed.
[0057] Cleanup phase (power mode switching): Calling ModuleManager::ClearModuleBaseData() iterates through all modules and executes ClearData(). Then, SignalManager::ClearSignalBuffer() is automatically called to iterate through all signals and execute DataReset(), ensuring that the global state is clean and there is no residual dirty data.
[0058] The power mode corresponds to the ON, ACC, and OFF positions on the vehicle.
[0059] The embodiments of the present invention are as follows: This embodiment uses a fully digital instrument cluster system as an example to illustrate the specific implementation of the present invention. This system simultaneously connects to more than 30 ECUs and manages signals related to over 200 instrument displays.
[0060] Taking the Braking System module as an example, this paper fully demonstrates the module development method based on the present invention: / / BrakingSystem.h — Only needs to declare the signals and related submodules of interest. class BrakingSystem:public ModuleBase{ public: BrakingSystem():ModuleBase("BrakingSystem"){ / / SignalInit is called in the external initialization process; the signal declaration is shown here. } / / Declarative signal subscription - simply populate the signals you want to follow in m_signalMap / / The framework automatically completes registration, binding, and distribution. void SignalInit()override{ / / Declare the signals you are interested in and their update strategies m_signalMap["VehicleSpeed"] =UPDATE_CHANGED; m_signalMap["BrakePedalPosition"] =UPDATE_IMMEDIATELY; m_signalMap["EPB_Status"] =UPDATE_CHANGED; m_signalMap["BrakeShoeWearLevel"]=UPDATE_CHANGED; m_signalMap["RetarderTorque"] =UPDATE_IMMEDIATELY; m_signalMap["BrakeSystemFault"] =UPDATE_IMMEDIATELY; / / Calling base class methods: Batch registration of signals + automatic binding ModuleBase::SignalRegister(); } void ClearData() override{ / Clear module business data / } private slots: / / A unified entry point for all monitored signals, automatically invoked by the framework. void sltModuleInput(const QString&name, const QVariant&data, constint&dataState) override{ if (name=="VehicleSpeed") {handleVehicleSpeed(data);} else if (name=="BrakePedalPosition"){handleBrakePedal(data);} else if (name=="EPB_Status") {handleEPBStatus(data);} else if (name=="BrakeShoeWearLevel"){handleBrakeShoeWear(data);} / / ... } }; Compared to traditional development methods, under the framework of this invention, developers of the braking system module only need to inherit from ModuleBase; declare the names and strategies of the signals they are interested in in m_signalMap of SignalInit(); call the base class SignalRegister() to complete all signal registration and binding; and implement sltModuleInput() to handle business logic.
[0061] There is no need to write subscription / registration code for each signal individually; connect binding code for each signal; registration / management code for module instances; or signal cleanup code when powering on or off.
[0062] The core innovations and technical features of this invention are as follows: 1. The modular framework's collaborative mechanism of "automatic registration, automatic binding, and declarative mapping tables" This invention implements the following functions through the ModuleBase base class: Declarative signal mapping: Modules declare signals they are interested in through m_signalMap, eliminating the need for procedural subscription code; Automatic binding: SignalRegister() traverses the mapping table and automatically establishes a Qt signal-slot connection between SignalDataSet::dataChanged and the module sltModuleInput; Automatic registration: The constructor automatically registers the module instance to the ModuleManager, eliminating the need for upper-level management; Adding a new module only requires "inheriting the base class + filling in the mapping table + implementing the virtual function" to complete the integration.
[0063] 2. Framework-level automatic signal-slot binding based on the Qt meta-object system The framework of this invention automatically establishes Qt signal-slot connections, eliminating the need for modules to write connect code.
[0064] 3. Unified cleanup of dual singleton collaboration and power mode switching SignalManager: Signal registration deduplication; if multiple modules subscribe to signals with the same name, only one SignalDataSet is created.
[0065] ModuleManager: Automatically registers modules and maintains a module pointer mapping table.
[0066] Power mode switching uses ClearModuleBaseData() → ClearSignalBuffer() → DataReset() to perform unified cleanup and resolve residual dirty data.
[0067] Compared with the prior art, the present invention has the following beneficial effects: Loosely coupled architecture: Signal producers (data parsing layer) and signal consumers (various functional modules) are decoupled through SignalManager, and neither needs to be aware of the other. Adding a new module or modifying a signal only requires declaring it in the module's signal mapping table, without modifying other code.
[0068] Unified signal lifecycle management: SignalManager provides a global signal registry and a unified cleanup interface. Combined with ModuleManager's batch module operations, it can ensure the consistency of all signals and module states in critical scenarios such as power mode switching, fundamentally eliminating the problem of data residue.
[0069] Multi-strategy signal update mechanism: SignalDataSet supports multiple strategies such as immediate update, change update, and periodic update, which can be flexibly configured according to signal characteristics. For example, vehicle speed signals can be set to "change update" to avoid redundant calculations, while alarm signals can be set to "immediate update" to ensure real-time response. This design can significantly reduce CPU usage in high-load scenarios.
[0070] Declarative signal subscription: Modules define signal subscription relationships through a declarative mapping table, resulting in concise and clear code. When the number of signals reaches hundreds, the declarative approach significantly improves development efficiency compared to procedural, one-by-one subscription, and the completeness can be checked at compile time.
[0071] Automated module management: Modules are automatically registered to the global manager when they are instantiated, eliminating the need to manually maintain the module list.
[0072] Framework-based extensibility: Adding new functional modules only requires inheriting the ModuleBase class, filling the signal mapping table, and implementing the virtual function interface to complete the integration. The framework automatically handles common logic such as signal binding and module registration, resulting in high development efficiency and fewer errors.
[0073] For the specific implementation scheme of this embodiment, please refer to the relevant descriptions in the above embodiments, which will not be repeated here.
[0074] It is understood that the same or similar parts in the above embodiments can be referred to each other, and the contents not described in detail in some embodiments can be referred to the same or similar contents in other embodiments.
[0075] It should be noted that in the description of this invention, the terms "first," "second," etc., are used for descriptive purposes only and should not be construed as indicating or implying relative importance. Furthermore, in the description of this invention, unless otherwise stated, "a plurality of" means at least two.
[0076] Any process or method description in the flowchart or otherwise herein can be understood as representing a module, segment, or portion of code comprising one or more executable instructions for implementing a particular logical function or process, and the scope of the preferred embodiments of the invention includes additional implementations in which functions may be performed not in the order shown or discussed, including substantially simultaneously or in reverse order depending on the functions involved, as will be understood by those skilled in the art to which embodiments of the invention pertain.
[0077] It should be understood that various parts of the present invention can be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented in software or firmware stored in memory and executed by a suitable instruction execution device. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (PGAs), field-programmable gate arrays (FPGAs), etc.
[0078] Those skilled in the art will understand that all or part of the steps of the methods in the above embodiments can be implemented by a program instructing related hardware. The corresponding program can be stored in a computer-readable storage medium. When the program is executed, it includes one or a combination of the steps of the method embodiments.
[0079] Furthermore, the functional units in the various embodiments of the present invention can be integrated into a processing module, or each unit can exist physically separately, or two or more units can be integrated into a module. The integrated module can be implemented in hardware or as a software functional module. If the integrated module is implemented as a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium.
[0080] The storage media mentioned above can be read-only memory, disk, or optical disk, etc.
[0081] In the description of this specification, references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of the invention. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples.
[0082] This invention employs a method, system, device, processor, and computer-readable storage medium for modular signal management and distribution in vehicle-mounted instrument clusters. By constructing a modular architecture comprising a signal management center layer, a module management layer, and a signal data unit layer, coupled with a collaborative mechanism of automatic module registration and declarative mapping tables, external data sources and functional modules are decoupled. Furthermore, a polymorphic update strategy is introduced within the signal data units for change detection. These technical means change the traditional highly coupled manual subscription mode, enabling conditional triggering and automatic binding of signals, and providing a unified state cleanup interface at the global level. Based on this, the system effectively reduces invalid and repetitive data processing operations, lowers the processor's computational load, and ensures high consistency of global data states during power mode switching and other scenarios, avoiding interface display anomalies caused by residual dirty data. Ultimately, this improves the operational stability and resource utilization of the vehicle-mounted instrument cluster system, and enhances the scalability and maintenance efficiency of the software architecture.
[0083] In this specification, the invention has been described with reference to specific embodiments thereof. However, it will be apparent that various modifications and variations can be made without departing from the spirit and scope of the invention. Therefore, the specification and drawings should be considered illustrative rather than restrictive.
Claims
1. A method for modular signal management and distribution of vehicle-mounted instruments, characterized in that, The method includes the following steps: (1) During the initialization phase, each functional module of the vehicle instrument is instantiated by inheriting the preset module base class, and a set of attention signals and the update strategy corresponding to each signal in the signal mapping table corresponding to the functional module are declared; the set of attention signals is registered with the globally unique signal management center through the module base class, and the connection relationship between the data change notification signal of each signal in the set of attention signals and the corresponding slot function in the functional module is established. (2) During the operation phase, receive signal data to be processed from external data sources; search for the signal data unit corresponding to the signal data to be processed in the global registry of the signal management center; determine whether the triggering condition is met based on the update strategy recorded in the found signal data unit; when the triggering condition is met, issue the corresponding data change notification signal through the signal data unit; the functional module that subscribes to the corresponding signal automatically receives the signal data to be processed through the slot function with the established connection relationship, and performs business logic processing based on the signal data to be processed.
2. The method for modular signal management and distribution of vehicle-mounted instruments according to claim 1, characterized in that, Step (1) of registering the set of signals of interest with the globally unique signal management center through the module base class specifically includes the following steps: The signal management center receives registration requests for signals of interest submitted by each of the aforementioned functional modules; For each requested signal, create a corresponding signal data unit; Each of the created signal data units is stored in the global registry of the signal management center with the signal name as the key; during the registration process, deduplication filtering is performed on request signals with the same signal name, so that only one signal data unit with the same signal name is maintained globally.
3. The method for modular signal management and distribution of vehicle-mounted instruments according to claim 1, characterized in that, Step (1) of establishing the connection relationship between the data change notification signals of each signal in the set of signals of interest and the corresponding slot functions in the functional module specifically includes the following steps: Iterate through the signal mapping table of the functional module and register all signals in the signal mapping table in batches with the signal management center; The binding relationship between the data change notification signal corresponding to each signal and the corresponding slot function inherited by the functional module from the module base class is automatically established through the module base class.
4. The method for modular signal management and distribution of vehicle-mounted instruments according to claim 1, characterized in that, The update strategy in step (1) includes at least one of the following: immediate update strategy, change update strategy, and periodic update strategy; The determination of whether the triggering condition is met based on the update strategy recorded in the found signal data unit is as follows: When the corresponding update strategy is the immediate update strategy, the triggering condition is unconditionally determined to be met. When the corresponding update strategy is the change update strategy, it is determined whether the value of the signal data to be processed has actually changed compared with the data value stored in the current signal data unit. If an actual change has occurred, the currently stored data value is updated and it is determined that the triggering condition is met. When the corresponding update strategy is the periodic update strategy, it is determined whether the preset update cycle has been reached. If it has been reached, the currently stored data value is updated and it is determined that the triggering condition is met.
5. The method for modular signal management and distribution of vehicle-mounted instruments according to claim 1, characterized in that, The functional module that subscribes to the corresponding signal in step (2) automatically receives the signal data to be processed through the slot function with the established connection, and performs business logic processing based on the signal data to be processed, specifically including the following steps: The corresponding slot function of the functional module is configured as a unified input callback entry, which receives the signal name, signal data value and data validity status as input parameters. The functional module, within the unified input callback entry, distributes the received signal data to be processed to the corresponding specific business processing function for execution based on the input signal name.
6. The method for modular signal management and distribution of vehicle-mounted instruments according to claim 1, characterized in that, After performing business logic processing based on the signal data to be processed in step (2), the following steps are also included: The data transmission management layer, configured using the singleton pattern, uniformly manages the sending channels of communication messages. The functional modules send response messages generated after executing business logic through the data transmission management layer.
7. The method for modular signal management and distribution of vehicle-mounted instruments according to claim 1, characterized in that, The method also includes an automatic module registration step, which specifically includes the following steps: During the instantiation and construction of each functional module, the constructor of the module base class automatically registers the instance of the current functional module to the module table of the globally unique module manager, and the module manager uniformly maintains the mapping relationship from module name to module instance pointer.
8. The method for modular signal management and distribution of vehicle-mounted instruments according to claim 1, characterized in that, The method also includes a cleanup phase processing step, specifically including the following steps: In response to the instrument power mode switching operation, a data cleanup command is triggered; The module manager is invoked to traverse all functional modules in the global module table and control each functional module to call its own configured data clearing interface to clear the module's business data. After cleaning up the business data of each of the aforementioned functional modules, the signal management center is invoked to traverse all signals in the global registry and reset the data values in the corresponding signal data units to their initial state to eliminate residual dirty data.
9. The method for modular signal management and distribution of vehicle-mounted instruments according to claim 1, characterized in that, The module base class defines a data initialization interface, a signal initialization interface, and a data clearing interface; the signal mapping table is configured and populated by the functional module when implementing the signal initialization interface; the data clearing interface is used by the functional module to clear its own business data.
10. The method for modular signal management and distribution of vehicle-mounted instruments according to claim 1, characterized in that, The signal data unit includes multiple attribute parameters, including signal name, current signal value, corresponding update strategy, and data validity status; the data validity status includes at least valid status, invalid status, and timeout status.
11. A system for implementing modular signal management and distribution of vehicle-mounted instruments according to any one of claims 1 to 10, characterized in that, The system includes: The module base class configuration unit is used to provide a basic operating framework for multiple functional modules, enabling each functional module to be instantiated through inheritance during the initialization phase and to declare the set of signals of interest and the corresponding update strategy in the corresponding signal mapping table. The module base class configuration unit is also used to automatically establish the connection relationship between the data change notification signal of the signal data unit and the slot function of the corresponding functional module, so that the functional module can automatically receive the signal data to be processed and execute business logic processing when the trigger condition is met. The signal management center is used to receive registration requests submitted by each of the functional modules through the module base class configuration unit, create and manage corresponding signal data units in the global registry using the signal name as the key; it is also used to receive signal data to be processed input from external data sources during the running phase, search for the corresponding signal data unit in the global registry according to the signal name, and forward the signal data to be processed to that signal data unit. The signal data unit corresponds to each of the globally registered signals and is used to carry signal data. It determines whether the triggering condition is met based on the corresponding update strategy and sends a data change notification signal when the triggering condition is met. The module manager is used to automatically register the instance of the current functional module to a globally unique module table during the construction process of instantiating each of the aforementioned functional modules.
12. The system for modular signal management and distribution of vehicle-mounted instruments according to claim 1, characterized in that, The system also includes a data transmission management layer, which is implemented using a singleton pattern. This layer is used to uniformly manage the sending configuration of controller area network packets and IP-based service-oriented middleware packets, providing a unified data sending channel for each of the functional modules.
13. The system for modular signal management and distribution of vehicle-mounted instruments according to claim 1, characterized in that, The update strategy includes at least one of an immediate update strategy, a variable update strategy, and a periodic update strategy; when the corresponding update strategy is the immediate update strategy, the signal data unit unconditionally determines that the trigger condition is met; when the corresponding update strategy is the variable update strategy, the currently stored data value is updated and the trigger condition is determined to be met only when the value of the signal data to be processed changes compared to the currently stored data value. When the corresponding update strategy is the periodic update strategy, the currently stored data value is updated periodically according to the preset update cycle, and it is determined that the triggering condition is met.
14. A device for realizing modular signal management and distribution of vehicle-mounted instruments, characterized in that, The device includes: A processor is configured to execute computer-executable instructions; The memory stores one or more computer-executable instructions, which, when executed by the processor, implement the steps of the method for implementing modular signal management and distribution of vehicle instruments as claimed in any one of claims 1 to 10.
15. A processor for implementing modular signal management and distribution of vehicle-mounted instruments, characterized in that, The processor is configured to execute computer-executable instructions, which, when executed by the processor, implement the steps of the method for implementing modular signal management and distribution of vehicle instrumentation as described in any one of claims 1 to 10.
16. A computer-readable storage medium, characterized in that, It stores a computer program that can be executed by a processor to implement the various steps of the method for implementing modular signal management and distribution of vehicle instrument as described in any one of claims 1 to 10.
