A cross-domain synchronization system and method for non-real-time AI decision and real-time control

CN123011779APending Publication Date: 2026-10-30深圳市海科技术有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611283566.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-08-24
Publication Date
2026-10-30

AI Technical Summary

Technical Problem

[0004]本发明正是基于上述问题,提出了一种非实时AI决策与实时控制的跨域同步系统及方法,能够有效解决AI决策耗时波动所引起的控制律失稳或系统失控问题

Benefits of technology

[0015]本发明提出了一种非实时AI决策与实时控制的跨域同步系统及方法,通过在非实时决策域和硬实时控制域建立统一的全局时间戳基准;非实时决策域根据本次决策任务的决策内容、场景动态性以及本次决策任务的决策时长,自适应估计本次决策的预测有效时长;生成包含预测有效时长、推理开始时间戳、推理完成时间戳以及决策值的决策四元组写入可编程逻辑器件的物理传输模块;硬实时控制域以固定周期从所述可编程逻辑器件的物理传输模块中读取最新的决策四元组,计算硬实时控制域的当前时间与所述推理完成时间戳的差值,根据当前时间与所述推理完成时间戳的差值执行对应的动态补偿策略,能够有效解决AI决策耗时波动所引起的控制律失稳或系统失控问题。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123011779A_ABST
    Figure CN123011779A_ABST
Patent Text Reader

Abstract

The application provides a non-real-time AI decision and real-time control cross-domain synchronization system and method, a unified global timestamp benchmark is established in a non-real-time decision domain and a hard real-time control domain; the non-real-time decision domain adaptively estimates a prediction effective duration of the current decision according to a decision content of the current decision task, scene dynamics and a decision duration of the current decision task; a decision four-tuple containing the prediction effective duration, a reasoning start timestamp, a reasoning completion timestamp and a decision value is generated and written into a physical transmission module of a programmable logic device; the hard real-time control domain reads the latest decision four-tuple from the physical transmission module of the programmable logic device at a fixed period, calculates a difference value between a current time of the hard real-time control domain and the reasoning completion timestamp, and executes a corresponding dynamic compensation strategy according to the difference value between the current time and the reasoning completion timestamp, so that the problem of control law instability or system out-of-control caused by time consumption fluctuation of AI decision can be effectively solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of flight control system technology, and in particular to a cross-domain synchronization system and method for non-real-time AI decision-making and real-time control. Background Technology

[0002] With the increasing demands for intelligence in the avionics and flight control systems of low-altitude aircraft, heterogeneous multi-core flight control systems have become the mainstream architecture for handling complex flight control tasks. A heterogeneous multi-core flight control system typically includes a high-performance application processor and a high-real-time controller. The high-performance application processor runs a general-purpose operating system to handle complex AI perception and decision-making tasks, while the high-real-time controller runs a bare-metal or real-time operating system to perform high-frequency, high-reliability hard real-time control law calculations. To ensure that the AI ​​decision results output by the general-purpose operating system can be acquired, verified, and executed by the real-time control logic in a defined time sequence, an efficient cross-domain communication mechanism needs to be established between the two systems.

[0003] However, in practical applications, the computation time of AI inference tasks typically varies dynamically with the complexity of the input data, making it difficult to maintain a fixed periodic output. Furthermore, due to the influence of non-deterministic factors in general-purpose operating systems, such as task scheduling jitter, interrupt masking, and page faults, the time required from input decision conditions to output decision results fluctuates significantly. This uncertainty in decision output time makes real-time operating systems susceptible to control law instability or system malfunction when faced with slow decision frames or data delays, as they passively wait for the latest decision. Summary of the Invention

[0004] Based on the above problems, this invention proposes a cross-domain synchronization system and method for non-real-time AI decision-making and real-time control, which can effectively solve the problems of control law instability or system runaway caused by the fluctuation of AI decision-making time.

[0005] In view of this, a first aspect of the present invention proposes a cross-domain synchronization system for non-real-time AI decision-making and real-time control, comprising: A non-real-time decision domain, consisting of a general-purpose operating system running on a non-real-time processor, is used to handle high-load perception tasks and output non-periodic AI decision data. The hard real-time control domain, consisting of a bare-metal or hard real-time operating system running on a real-time processor, is used to calculate high-frequency, fixed-cycle control laws and drive actuators. A cross-domain synchronous intermediate layer composed of programmable logic devices is used to provide a high-speed asynchronous data exchange channel between the non-real-time domain and the real-time domain. The programmable logic device of the cross-domain synchronization intermediate layer includes a clock management module for maintaining the master clock counter, a clock synchronization module for generating and broadcasting synchronization pulse signals to the two processors, and a physical transmission module for transmitting the non-real-time AI decision data output by the non-real-time decision domain.

[0006] A second aspect of the present invention proposes a cross-domain synchronization method for non-real-time AI decision-making and real-time control, comprising: Establish a unified global timestamp benchmark for both the non-real-time decision domain and the hard real-time control domain; The non-real-time decision domain adaptively estimates the effective prediction duration of the current decision based on the decision content, scenario dynamism, and decision duration of the current decision task. ; Generate a dataset containing the predicted effective duration. The decision quadruple, which also includes an inference start timestamp. Reasoning completion timestamp and decision value ; The decision quadruple is written into the physical transmission module of the programmable logic device; The hard real-time control domain reads the latest decision quadruple from the physical transmission module of the programmable logic device at fixed intervals; Extract the reasoning completion timestamp from the decision quadruple. Calculate the current time of the hard real-time control domain. With the reasoning completion timestamp The difference ; Hard real-time control domain based on current time With the reasoning completion timestamp The difference Execute the corresponding dynamic compensation strategy.

[0007] Optionally, the non-real-time decision domain adaptively estimates the effective prediction duration of the current decision based on the decision content, scenario dynamism, and decision duration of the current decision task. The specific steps include: Get the pre-configured basic validity period ; Obtain real-time quantitative parameters of the decision content, scenario dynamics, and decision duration of this decision-making task; Based on the real-time quantitative parameters, a content factor reflecting the intensity of the decision-making action is calculated. Dynamic factors reflecting the rate of environmental change and performance factors reflecting system stability ; Calculate the effective duration of the prediction: .

[0008] Optionally, a content factor reflecting the intensity of the decision-making action can be calculated based on the real-time quantification parameters. The specific steps include: Read the pre-configured sensitivity coefficient to changes in decision values ; Construct the decision vector for the current decision task The decision vector of the previous decision task ; Decision vector for the current decision task The decision vector of the previous decision task Perform difference operations: ; Calculate the content factor: .

[0009] Optionally, a dynamic factor reflecting the rate of environmental change can be calculated based on the real-time quantization parameters. The specific steps include: Read the pre-configured environmental dynamic sensitivity coefficient ; Identify at least one obstacle or reference point in the surrounding environment; Calculate the relative rate of the environment The relative rate of the environment The angular velocity of the obstacle or reference object relative to the aircraft. or radial distance change rate ; Calculate the dynamic factor: .

[0010] Optionally, a performance factor reflecting system stability can be calculated based on the real-time quantization parameters. The specific steps include: Read the pre-configured performance protection lower limit and the discreteness reference threshold ; Build Decision time deviation sequence within each control cycle: ; Calculate the dispersion of the decision time deviation sequence. ; Calculate the performance factor: .

[0011] Optional, build The specific steps involved in the decision time deviation sequence within a control cycle include: Read the pre-configured ideal time ; Based on the current control cycle, work backwards Each control cycle is used to calculate the current control cycle. Decision duration for each decision task: ; Order No. The decision time deviation for each control cycle is: .

[0012] Optionally, the hard real-time control domain is based on the current time. With the reasoning completion timestamp The difference The specific steps for implementing the corresponding dynamic compensation strategy include: The difference With the predicted effective duration Compare; when At that time, the decision frame is determined to be in a normal state; When the decision frame is in a normal state, linear interpolation or polynomial extrapolation is performed on the decision value to correct the control target in real time.

[0013] Optionally, the steps for establishing a unified global timestamp reference in the non-real-time decision domain and the hard real-time control domain specifically include: The programmable logic device sends a unified synchronization pulse signal to the non-real-time processor and the real-time processor; The non-real-time processor captures the synchronization pulse signal via an interrupt; The local clock in the non-real-time decision domain is calculated and maintained in the general operating system, and the clock offset of the synchronization pulse signal is calculated. Using the clock offset as a compensation value, the timestamps of AI decision-making tasks in the general operating system are mapped to the global clock.

[0014] Optionally, after the step of the programmable logic device sending a unified synchronization pulse signal to the non-real-time processor and the real-time processor, the method further includes the real-time processor connecting the synchronization pulse signal to a hardware timer as the global clock of the hard real-time control domain.

[0015] This invention proposes a cross-domain synchronization system and method for non-real-time AI decision-making and real-time control. It establishes a unified global timestamp benchmark between the non-real-time decision domain and the hard real-time control domain. The non-real-time decision domain adaptively estimates the effective prediction duration of the current decision based on the decision content, scenario dynamics, and decision duration. A decision quadruple containing the effective prediction duration, inference start timestamp, inference completion timestamp, and decision value is generated and written to the physical transmission module of the programmable logic device. The hard real-time control domain reads the latest decision quadruple from the physical transmission module of the programmable logic device at fixed intervals, calculates the difference between the current time of the hard real-time control domain and the inference completion timestamp, and executes a corresponding dynamic compensation strategy based on this difference. This effectively solves the problem of control law instability or system runaway caused by fluctuations in AI decision-making time. Attached Figure Description

[0016] Figure 1 This is a schematic block diagram of a cross-domain synchronization system for non-real-time AI decision-making and real-time control provided in one embodiment of the present invention; Figure 2 This is a flowchart of a cross-domain synchronization method for non-real-time AI decision-making and real-time control provided in one embodiment of the present invention. Detailed Implementation

[0017] To better understand the above-mentioned objectives, features, and advantages of the present invention, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be noted that, unless otherwise specified, the embodiments and features described in these embodiments can be combined with each other.

[0018] Many specific details are set forth in the following description in order to provide a full understanding of the invention. However, the invention may also be practiced in other ways different from those described herein, and therefore the scope of protection of the invention is not limited to the specific embodiments disclosed below.

[0019] In the description of this invention, the term "multiple" refers to two or more. Unless otherwise explicitly defined, the terms "upper," "lower," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, and are only for the convenience of describing the invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the invention. The terms "connect," "install," "fix," etc., should be interpreted broadly. For example, "connect" can be a fixed connection, a detachable connection, or an integral connection; it can be a direct connection or an indirect connection through an intermediate medium. Those skilled in the art can understand the specific meaning of the above terms in this invention according to the specific circumstances. Furthermore, the terms "first," "second," etc., are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined with "first," "second," etc., may explicitly or implicitly include one or more of that feature. In the description of this invention, unless otherwise stated, "multiple" means two or more.

[0020] In the description of this specification, the terms "one embodiment," "some implementations," "specific embodiment," etc., refer to a specific feature, structure, material, or characteristic described in connection with that embodiment or example, which is included in at least one embodiment or example of the present 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.

[0021] The following description, with reference to the accompanying drawings, illustrates a cross-domain synchronization system and method for non-real-time AI decision-making and real-time control according to some embodiments of the present invention.

[0022] like Figure 1 As shown, the first aspect of the present invention proposes a cross-domain synchronization system for non-real-time AI decision-making and real-time control, comprising: A non-real-time decision domain, consisting of a general-purpose operating system running on a non-real-time processor, is used to handle high-load perception tasks and output non-periodic AI decision data. The hard real-time control domain, consisting of a bare-metal or hard real-time operating system running on a real-time processor, is used to calculate high-frequency, fixed-cycle control laws and drive actuators. A cross-domain synchronous intermediate layer composed of programmable logic devices is used to provide a high-speed asynchronous data exchange channel between the non-real-time domain and the real-time domain. The programmable logic device of the cross-domain synchronization intermediate layer includes a clock management module for maintaining the master clock counter, a clock synchronization module for generating and broadcasting synchronization pulse signals to the two processors, and a physical transmission module for transmitting the non-real-time AI decision data output by the non-real-time decision domain.

[0023] Specifically, the general-purpose operating system is an operating system that achieves high task concurrency and high throughput through complex scheduling algorithms, capable of running and managing a large number of processes simultaneously, such as the Linux operating system. The non-real-time processor can be a high-performance RISC-V processor such as the K3 X100. The general-purpose operating system runs on the non-real-time processor, leveraging its high-performance characteristics to support the execution of AI inference tasks and the output of AI decision data.

[0024] Because AI algorithms rely on extremely complex mathematical libraries, file systems, memory management, and network protocol stacks, AI inference often requires calling high-performance instruction sets such as the RVV vector extension instruction set. General-purpose operating systems such as Linux provide mature drivers and middleware to support this heavy computation.

[0025] Bare metal refers to a program running directly on the hardware without any operating system layer. The program code directly manipulates registers and controls interrupts, handling events through hardware interrupts, resulting in very high real-time performance. A hard real-time operating system (RTOS) is a lightweight operating system that uses a highly optimized scheduler and preemptive kernel to ensure that high-priority tasks can interrupt low-priority tasks in a very short time, also exhibiting very high real-time performance. The real-time processor can be a RISC-V MCU or similar real-time processor. The bare metal or hard real-time operating system runs on the real-time processor and is used to perform control law calculations at fixed intervals.

[0026] In practical applications, the control law of an aircraft must be executed once within a specific control cycle, such as 1 ms. If any calculation is delayed, the aircraft may experience severe vibrations or even crash. Therefore, using a high-real-time bare-metal system or RTOS to calculate the control law ensures that the control kernel obtains the control law data at a predetermined time and drives the actuators to perform the corresponding actions. Furthermore, the implementation of this invention decouples AI decision-making and control law calculation, effectively improving development efficiency.

[0027] The time clock management module of the programmable logic device includes a core timing logic circuit driven by the system master clock, such as an external crystal oscillator or a high-frequency clock multiplied by an internal PLL, used for precise timing, frequency division, timing control, or measurement of signals. It maintains a unified system time (global clock) by accumulating and counting the number of clock pulses. In the technical solution of this invention, the unified system time maintained by the time clock management module serves as the standard time for the entire heterogeneous system.

[0028] The clock synchronization module of the programmable logic device physically sends synchronization pulse signals to the non-real-time processor and the real-time processor based on the unified system time.

[0029] Furthermore, the physical transmission module of the programmable logic device includes a dual-port RAM for connecting the non-real-time processor and the real-time processor. The dual-port RAM is a special memory block allocated within the programmable logic device, possessing two independent physical ports, allowing two processors to simultaneously read and write to the same memory address without software handshaking.

[0030] like Figure 2 As shown, a second aspect of the present invention proposes a cross-domain synchronization method for non-real-time AI decision-making and real-time control, comprising: Establish a unified global timestamp benchmark for both the non-real-time decision domain and the hard real-time control domain; The non-real-time decision domain adaptively estimates the effective prediction duration of the current decision based on the decision content, scenario dynamism, and decision duration of the current decision task. ; Generate a dataset containing the predicted effective duration. The decision quadruple, which also includes an inference start timestamp. Reasoning completion timestamp and decision value ; The decision quadruple is written into the physical transmission module of the programmable logic device; The hard real-time control domain reads the latest decision quadruple from the physical transmission module of the programmable logic device at fixed intervals; Extract the reasoning completion timestamp from the decision quadruple. Calculate the current time of the hard real-time control domain. With the reasoning completion timestamp The difference ; Hard real-time control domain based on current time With the reasoning completion timestamp The difference Execute the corresponding dynamic compensation strategy.

[0031] In the decision quadruple, the inference start timestamp and the reasoning completion timestamp These are timestamp data generated before and after the inference work is completed, based on the unified system time.

[0032] The decision value The structured control command data of the aircraft is obtained by reasoning about the decision content in the non-real-time decision domain. The structured control command data includes, but is not limited to, expected targets and reference data such as expected trajectory, expected acceleration, and expected yaw angle.

[0033] The prediction validity period It is the effective duration of the decision data predicted by the non-real-time decision domain based on the decision content, scenario dynamism, and decision duration of the current decision task.

[0034] The decision content of this decision-making task is the rate of change or state characteristic of the instruction vector output by the AI ​​model relative to the instruction at the previous moment, which is used to describe the change characteristics of the decision value data in the decision quadruple. In some embodiments, the decision content of this decision-making task may include target changes such as changes in heading angle, changes in target distance, etc. Scene dynamics refers to the frequency and complexity of changes in the current perceived environment, which can be quantified by parameters such as the approach speed of obstacles relative to the drone, the number of dynamic targets detected in the current field of view, and sensor noise levels / environmental disturbances such as current wind speed fluctuations or image blur. The decision duration of this decision refers to the timestamp of the completion of the inference of the decision quadruple of the AI ​​inference task in the current frame. and the time stamp of the start of reasoning The time interval between them.

[0035] In some embodiments of the present invention, the decision quadruple further includes a CRC (Cyclic Redundancy Check) code for verifying the data integrity of the decision quadruple. After reading the latest decision quadruple from the physical transmission module of the programmable logic device, the hard real-time control domain uses the CRC code to verify the data integrity of the decision quadruple.

[0036] Current time of the hard real-time control domain It refers to the unified system time maintained in the hard real-time control domain after establishing a unified global timestamp benchmark.

[0037] In the step of reading the latest decision quadruplet from the physical transmission module of the programmable logic device at a fixed period in the hard real-time control domain, the fixed period is a preset high-frequency period. For example, the hard real-time control domain may use a 1kHz period as the fixed period to read the latest decision quadruplet from the dual-port RAM.

[0038] Optionally, the non-real-time decision domain adaptively estimates the effective prediction duration of the current decision based on the decision content, scenario dynamism, and decision duration of the current decision task. The specific steps include: Get the pre-configured basic validity period ; Obtain real-time quantitative parameters of the decision content, scenario dynamics, and decision duration of this decision-making task; Based on the real-time quantitative parameters, a content factor reflecting the intensity of the decision-making action is calculated. Dynamic factors reflecting the rate of environmental change and performance factors reflecting system stability ; Calculate the effective duration of the prediction: .

[0039] Specifically, the basic effective duration This is a baseline value set based on the system's minimum control cycle. The system's minimum control cycle refers to the time interval required for the real-time processor to perform one complete control law calculation; the basic effective duration... It is configured as an integer multiple of the minimum control cycle of the system, and the multiple is an empirical value that takes into account the average latency of AI inference and the inertial time of the physical motion of the aircraft.

[0040] The real-time quantification parameters corresponding to the decision content of this decision-making task in this embodiment of the invention include, but are not limited to, target changes such as changes in heading angle and changes in target distance. The real-time quantification parameters of the scene dynamics include, but are not limited to, the relative angular velocity and relative approach velocity of environmental obstacles.

[0041] In the technical solution of the above embodiments, the content factor The dynamic factor and the performance factor All The coefficients between the content factors, wherein The closer the value of the dynamic factor is to 1, the more reliable its decision-making; The closer the value is to 1, the more stable the environment; the performance factor The closer the value of a factor is to 1, the more efficient the system is, and the longer the validity period of its decision value. Conversely, the closer the value of any of the above factors is to 0, the greater the risk, and the shorter the validity period of its decision value needs to be.

[0042] In other implementations, the predicted effective duration can also be... Configured as follows: ; in, This is a limiting function used to... The range of values ​​is limited to Within the range. For the pre-configured lower limit of the control cycle, The pre-configured physical limit.

[0043] Optionally, a content factor reflecting the intensity of the decision-making action can be calculated based on the real-time quantification parameters. The specific steps include: Read the pre-configured sensitivity coefficient to changes in decision values ; Construct the decision vector for the current decision task The decision vector of the previous decision task ; Decision vector for the current decision task The decision vector of the previous decision task Perform difference operations: ; Calculate the content factor: .

[0044] In the above embodiments, The sensitivity coefficient for changes in decision values ​​is a pre-configured value, which reflects the sensitivity of the control system to changes in commands.

[0045] Specifically, the decision vector for the current decision-making task. This refers to the decision value for the current decision-making task. In an implementation where the decision value consists of flight speed and heading, the following is an example of its decision vector: .

[0046] Decision vector for the current decision task The decision vector of the previous decision task Output of the difference operation This refers to the decision content of this decision-making task, which reflects the changing characteristics of the decision value data.

[0047] The content of this decision-making task It is the Euclidean distance between the decision vector of the current frame and the decision vector of the previous frame. If the instruction changes drastically, such as from a straight flight to a sharp turn, it indicates that a sudden situation may have occurred in the current environment, which is reflected in the content factor. The numerical value is made closer to 0, thereby controlling the reduction of the effective time of the decision value.

[0048] Optionally, a dynamic factor reflecting the rate of environmental change can be calculated based on the real-time quantization parameters. The specific steps include: Read the pre-configured environmental dynamic sensitivity coefficient ; Identify at least one obstacle or reference point in the surrounding environment; Calculate the relative rate of the environment The relative rate of the environment The angular velocity of the obstacle or reference object relative to the aircraft. or radial distance change rate ; Calculate the dynamic factor: .

[0049] In the above embodiments, The pre-configured environmental dynamics sensitivity coefficient reflects the weight of the rate of environmental change on the effectiveness of decision-making.

[0050] In the step of identifying at least one obstacle or reference object in the surrounding environment, objects within a specific distance range can be selected as obstacles or reference objects for determining the relative motion rate of the environment, based on the real-time flight speed of the aircraft.

[0051] The above implementation method uses the relative motion rate of the environment. Such as the angular velocity of the obstacle or reference point relative to the aircraft. or radial distance change rate The dynamics of the scene are reflected by the environmental motion features fed back by the perception layer, such as the approach speed of obstacles, to measure the rate of environmental change.

[0052] If the rate of environmental change is extremely rapid, it will be reflected in the dynamic factors mentioned above. Numerically, this involves bringing the value closer to zero, thereby controlling the reduction of the effective time of the decision value. In this case, even if the current decision value is correct, it will become invalid in a very short time. Conversely, if the rate of environmental change is slow, it will be reflected in the dynamic factor. The numerical value is made closer to 1, thereby increasing the effective time of the decision value.

[0053] Optionally, a performance factor reflecting system stability can be calculated based on the real-time quantization parameters. The specific steps include: Read the pre-configured performance protection lower limit and the discreteness reference threshold ; Build Decision time deviation sequence within each control cycle: ; Calculate the dispersion of the decision time deviation sequence. ; Calculate the performance factor: .

[0054] Specifically, A pre-configured performance protection lower limit is used to prevent the performance factor from being... An excessively small value could lead to an extreme case where the validity period becomes 0. The aforementioned dispersion reference threshold... These are pre-configured empirical values, which can be the statistical average of the dispersion of a large number of decision time deviation sequences obtained in the test environment or other empirical values.

[0055] The dispersion of the decision time deviation sequence It can be the variance or standard deviation of the decision time deviation sequence, or other numerical values ​​that can reflect the dispersion of the time deviation sequence.

[0056] In the performance factor In the calculation formula, This is a limiting function used to restrict the output to a certain value. Within the range of values, that is: when fall into When the interval is, ; when ,make ; when ,make .

[0057] Optional, build The specific steps involved in the decision time deviation sequence within a control cycle include: Read the pre-configured ideal time ; Based on the current control cycle, work backwards Each control cycle is used to calculate the current control cycle. Decision duration for each decision task: ; Order No. The decision time deviation for each control cycle is: .

[0058] In the technical solution of the embodiments of the present invention This is a preset, relatively small value, for example, a number between 3 and 10, allowing the system to recognize a shorter time frame. The performance factor is calculated based on the fluctuation of the decision value within each control cycle. .

[0059] The ideal time consumption The standard time taken for a pre-configured AI inference model under the current aircraft hardware configuration.

[0060] The above implementation measures the reliability of the inference system based on the fluctuation of the actual time taken for AI inference on the Linux side over a period of time compared with the preset ideal time. If the AI ​​inference slows down due to system scheduling, or if the computation time fluctuates drastically, it indicates that the computation chain is unreliable and the validity period must be shortened.

[0061] Optionally, the hard real-time control domain is based on the current time. With the reasoning completion timestamp The difference The specific steps for implementing the corresponding dynamic compensation strategy include: The difference With the predicted effective duration Compare; when At that time, the decision frame is determined to be in a normal state; When the decision frame is in a normal state, linear interpolation or polynomial extrapolation is performed on the decision value to correct the control target in real time.

[0062] In the above embodiments, when When the decision value in the decision quadruple is within the expected validity period, it indicates that the decision value in the decision quadruple is still within the expected validity period. When the decision frame is in a normal state, the decision value in the decision quadruple can be smoothly extended along the time axis to the current control cycle by linear interpolation / extrapolation or low-order polynomial extrapolation. In some implementations, when the difference When the difference is... Close to the predicted effective duration ,Right now and When the difference approaches zero, it automatically switches to extrapolation mode.

[0063] Furthermore, in the case of the difference With the predicted effective duration Following the comparison step, the following also includes: when At that time, the decision frame is determined to be in the extrapolation state; When the decision frame is in the extrapolation state, extrapolation continues based on historical trends, and the actuator output limit is reduced to ensure the stable state of the aircraft.

[0064] Furthermore, in the case of the difference With the predicted effective duration Following the comparison step, the following also includes: when At that time, the decision frame is determined to be in a conservative state; When the decision frame is in a conservative state, switch to the preset conservative flight strategy, such as keeping the aircraft in its current attitude or controlling the aircraft to hover.

[0065] in It is a preset safety threshold, which is a safety boundary set based on the maximum tolerable control delay of the aircraft or battery / power redundancy. Its typical value range is 500ms~2s.

[0066] Furthermore, in the case of the difference With the predicted effective duration Following the comparison step, the following also includes: when When the decision frame is in an emergency state, it is determined that the decision frame is in an emergency state. If the decision frame is in an emergency state, trigger the emergency landing procedure.

[0067] Optionally, the steps for establishing a unified global timestamp reference in the non-real-time decision domain and the hard real-time control domain specifically include: The programmable logic device sends a unified synchronization pulse signal to the non-real-time processor and the real-time processor; The non-real-time processor captures the synchronization pulse signal via an interrupt; The local clock in the non-real-time decision domain is calculated and maintained in the general operating system, and the clock offset of the synchronization pulse signal is calculated. Using the clock offset as a compensation value, the timestamps of AI decision-making tasks in the general operating system are mapped to the global clock.

[0068] In this embodiment of the invention, the synchronization pulse signal is a PPS signal, which is used to synchronize the local clock of the cross-domain synchronization intermediate layer to the non-real-time decision domain and the hard real-time control domain as a global clock.

[0069] In this embodiment of the invention, the system unified time maintained by the local clock of the cross-domain synchronization intermediate layer is used as the global clock, so that the non-real-time decision domain and the hard real-time control domain can synchronize decision data based on the global clock.

[0070] After the non-real-time processor captures the synchronization pulse signal via an interrupt, it obtains the local clock information maintained by its internal clock within the general operating system, compares it with the time of the synchronization pulse signal to obtain the corresponding clock offset, and uses the clock offset to map the local clock to the global clock.

[0071] Optionally, after the step of the programmable logic device sending a unified synchronization pulse signal to the non-real-time processor and the real-time processor, the method further includes the real-time processor connecting the synchronization pulse signal to a hardware timer as the global clock of the hard real-time control domain.

[0072] For the non-real-time decision domain, the clock synchronization module of the programmable logic device sends a pulse synchronization signal to trigger an interrupt in the kernel driver of the general operating system. The kernel driver of the general operating system records the local current system clock at the moment the interrupt occurs. By calculating the offset between the local clock and the pulse synchronization signal, the kernel maintains a compensation mechanism so that the timestamp of the process running by the general operating system can be mapped to the global hardware clock.

[0073] For the hard real-time control domain, the clock synchronization module of the programmable logic device sends a pulse synchronization signal directly to the hardware timer input of the real-time processor. Since the hardware signal has almost no software processing delay, the clock of the real-time core is almost synchronized with the main clock of the programmable logic device.

[0074] It should be noted that, in this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0075] As described above, these embodiments of the present invention do not exhaustively cover all details, nor do they limit the invention to the specific embodiments described. Clearly, many modifications and variations can be made based on the above description. This specification selects and specifically describes these embodiments to better explain the principles and practical applications of the invention, thereby enabling those skilled in the art to effectively utilize the invention and its modifications. The invention is limited only by the claims and their full scope and equivalents.

Claims

1. A cross-domain synchronization system for non-real-time AI decision-making and real-time control, characterized in that, include: A non-real-time decision domain, consisting of a general-purpose operating system running on a non-real-time processor, is used to handle high-load perception tasks and output non-periodic AI decision data. The hard real-time control domain, consisting of a bare-metal or hard real-time operating system running on a real-time processor, is used to calculate high-frequency, fixed-cycle control laws and drive actuators. A cross-domain synchronous intermediate layer composed of programmable logic devices is used to provide a high-speed asynchronous data exchange channel between the non-real-time domain and the real-time domain. The programmable logic device of the cross-domain synchronization intermediate layer includes a clock management module for maintaining the master clock counter, a clock synchronization module for generating and broadcasting synchronization pulse signals to the two processors, and a physical transmission module for transmitting the non-real-time AI decision data output by the non-real-time decision domain.

2. A cross-domain synchronization method applied to a cross-domain synchronization system for non-real-time AI decision-making and real-time control as described in claim 1, characterized in that, include: Establish a unified global timestamp benchmark for both the non-real-time decision domain and the hard real-time control domain; The non-real-time decision domain adaptively estimates the effective prediction duration of the current decision based on the decision content, scenario dynamism, and decision duration of the current decision task. ; Generate a dataset containing the predicted effective duration. The decision quadruple, which also includes an inference start timestamp. Reasoning completion timestamp and decision value ; The decision quadruple is written into the physical transmission module of the programmable logic device; The hard real-time control domain reads the latest decision quadruple from the physical transmission module of the programmable logic device at fixed intervals; Extract the reasoning completion timestamp from the decision quadruple. Calculate the current time of the hard real-time control domain. With the reasoning completion timestamp The difference ; Hard real-time control domain based on current time With the reasoning completion timestamp The difference Execute the corresponding dynamic compensation strategy.

3. The cross-domain synchronization method according to claim 2, characterized in that, The non-real-time decision domain adaptively estimates the effective prediction duration of the current decision based on the decision content, scenario dynamism, and decision duration of the current decision task. The specific steps include: Get the pre-configured basic validity period ; Obtain real-time quantitative parameters of the decision content, scenario dynamics, and decision duration of this decision-making task; Based on the real-time quantitative parameters, a content factor reflecting the intensity of the decision-making action is calculated. Dynamic factors reflecting the rate of environmental change and performance factors reflecting system stability ; Calculate the effective duration of the prediction: 。 4. The cross-domain synchronization method according to claim 3, characterized in that, Based on the real-time quantitative parameters, a content factor reflecting the intensity of the decision-making action is calculated. The specific steps include: Read the pre-configured sensitivity coefficient to changes in decision values ; Construct the decision vector for the current decision task The decision vector of the previous decision task ; Decision vector for the current decision task The decision vector of the previous decision task Perform difference operations: ; Calculate the content factor: 。 5. The cross-domain synchronization method according to claim 3, characterized in that, A dynamic factor reflecting the rate of environmental change is calculated based on the real-time quantitative parameters. The specific steps include: Read the pre-configured environmental dynamic sensitivity coefficient ; Identify at least one obstacle or reference point in the surrounding environment; Calculate the relative rate of the environment The relative rate of the environment The angular velocity of the obstacle or reference object relative to the aircraft. or radial distance change rate ; Calculate the dynamic factor: 。 6. The cross-domain synchronization method according to claim 3, characterized in that, The performance factor reflecting system stability is calculated based on the real-time quantization parameters. The specific steps include: Read the pre-configured performance protection lower limit and the discreteness reference threshold ; Build Decision time deviation sequence within each control cycle: ; Calculate the dispersion of the decision time deviation sequence. ; Calculate the performance factor: 。 7. The cross-domain synchronization method according to claim 6, characterized in that, Build The specific steps involved in the decision time deviation sequence within a control cycle include: Read the pre-configured ideal time ; Based on the current control cycle, work backwards Each control cycle is used to calculate the current control cycle. Decision duration for each decision task: ; Order No. The decision time deviation for each control cycle is: 。 8. The cross-domain synchronization method according to claim 2, characterized in that, Hard real-time control domain based on current time With the reasoning completion timestamp The difference The specific steps for implementing the corresponding dynamic compensation strategy include: The difference With the predicted effective duration Compare; when At that time, the decision frame is determined to be in a normal state; When the decision frame is in a normal state, linear interpolation or polynomial extrapolation is performed on the decision value to correct the control target in real time.

9. The cross-domain synchronization method according to claim 2, characterized in that, The specific steps for establishing a unified global timestamp benchmark in both the non-real-time decision domain and the hard real-time control domain include: The programmable logic device sends a unified synchronization pulse signal to the non-real-time processor and the real-time processor; The non-real-time processor captures the synchronization pulse signal via an interrupt; The local clock in the non-real-time decision domain is calculated and maintained in the general operating system, and the clock offset of the synchronization pulse signal is calculated. Using the clock offset as a compensation value, the timestamps of AI decision-making tasks in the general operating system are mapped to the global clock.

10. The cross-domain synchronization method according to claim 9, characterized in that, After the step of the programmable logic device sending a unified synchronization pulse signal to the non-real-time processor and the real-time processor, the method further includes the real-time processor connecting the synchronization pulse signal to a hardware timer as the global clock of the hard real-time control domain.