Response delay configuration method based on communication bus and related device
By acquiring and analyzing communication status data and adjusting the response delay of the main device to match the current communication status, the response delay problem caused by environmental changes in vehicle communications is solved, and the reliability and stability of data transmission are improved.
Patent Information
- Application Number
- CN202410858419.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-28
- Publication Date
- 2025-09-26
- Estimated Expiration
- 2044-06-28
AI Technical Summary
Existing technologies cannot simply and effectively solve the problem of long or short host-side response delays in vehicle-mounted communications caused by environmental influences, resulting in waste of hardware resources or data transmission failure.
By obtaining data related to the communication status between the master device and the slave device, the target response delay is determined, and the response delay is adjusted to match the current communication status to avoid the response delay being too long or too short.
It achieves accurate adjustment of response delay without adding hardware or modifying the protocol, solves the response delay problem caused by environmental changes, and improves the reliability and stability of data transmission.
Smart Images

Figure CN118740623B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of communication technology, and in particular to a response delay configuration method based on a communication bus and related devices. Background Art
[0002] Response latency refers to the waiting time between a master device receiving a request signal from a slave device and sending a response signal. The configuration of this response latency can affect the reliability and stability of data transmission. In in-vehicle communications, the host typically uses a fixed response latency to handle read and write operations from slave devices connected to the communication bus. However, the internal environment of a vehicle during operation is complex, and the signal transmission speed and processing speed of different slave devices can fluctuate due to environmental influences, resulting in the host's response latency being too long or too short. Excessively long response latency can cause the host to wait unnecessarily, wasting hardware resources. Excessively short response latency can lead to data transmission failures and communication timeouts.
[0003] Currently, solutions to the problem of host-side response delays being too long or too short due to environmental influences include introducing long-term bus occupancy during transmission to avoid response timeouts, introducing communication bus recovery mechanisms at the hardware level, and introducing slave device responses in the bus idle state to improve communication bus response stability. However, these solutions require either modifying the standard communication bus protocol, introducing additional hardware, or adding new bus states, all of which complicate the communication bus hardware or protocol.
[0004] In summary, the existing technology cannot simply and effectively solve the problem of the host-side response delay being too long or too short due to environmental influences. Summary of the Invention
[0005] The embodiments of the present application provide a communication bus-based response delay configuration method and related devices, which are used to simply and effectively solve the problem of the host-side response delay being too long or too short due to environmental influences.
[0006] In a first aspect, an embodiment of the present application provides a communication bus-based response delay configuration method, which is applied to a processor of a master device, wherein the master device is located in a preset network architecture, and the preset network architecture also includes at least one slave device, and the slave device is connected to the master device via a communication bus. The method includes:
[0007] Obtain data related to the communication status of the current monitoring cycle between the master device and the slave device;
[0008] Determining a target response delay of the master device to the slave device based on data related to the communication status of the current monitoring cycle between the master device and the slave device; the target response delay is a response delay that matches the current communication status between the master device and the slave device;
[0009] The response delay of the master device to the slave device is adjusted to the target response delay.
[0010] In one possible implementation, before determining the target response delay of the master device to the slave device based on the communication status-related data of the current monitoring cycle between the master device and the slave device, the method further includes:
[0011] Acquire data related to the communication status of a historical monitoring period between the master device and the slave device; the historical monitoring period is a monitoring period before the current monitoring period;
[0012] Determine whether the response delay of the master device to the slave device needs to be adjusted based on the communication status related data of the historical monitoring cycle and the current monitoring cycle between the master device and the slave device.
[0013] In one possible implementation, determining whether a response delay of the master device to the slave device needs to be adjusted based on data related to communication status between the master device and the slave device in historical monitoring cycles and a current monitoring cycle includes:
[0014] In response to any indicator in the communication status related data, if a fluctuation value from the historical monitoring period to the current monitoring period is greater than a corresponding fluctuation threshold, it is determined that a response delay of the master device to the slave device needs to be adjusted.
[0015] In one possible implementation, the communication status-related data includes at least one of communication quality information and communication environment information; the communication bus includes a serial clock line and a serial data line; the serial clock line is used to achieve clock synchronization between the master device and the slave device, and the serial data line is used for data transmission between the master device and the slave device;
[0016] Obtain data related to the communication status between the master device and the slave device, including:
[0017] determining whether a set monitoring period has been reached according to a clock signal on the serial clock line;
[0018] In response to reaching the set monitoring period, at least one of the following is performed:
[0019] Calculating the communication quality information based on the data sent and received by the serial data line within a set monitoring period;
[0020] Acquire the collected communication environment information.
[0021] In a possible implementation, adjusting the response delay of the master device to the slave device to the target response delay includes:
[0022] Determining a controller corresponding to a communication bus having a communication connection relationship with the slave device, wherein the controller is located in a processor of the master device;
[0023] The response delay parameter stored in the instruction register of the corresponding controller is adjusted to the target response delay.
[0024] In one possible implementation, determining a target response delay of the master device to the slave device based on data related to the communication status of the master device and the slave device in a current monitoring cycle includes:
[0025] The communication status related data of the current monitoring cycle between the master device and the slave device is input into the trained target response delay calculation model, and the trained target response delay calculation model is used to calculate and output the target response delay.
[0026] In one possible implementation, the trained target response delay calculation model is obtained using the following method:
[0027] Obtaining data related to a preferred communication state between a master device and a slave device, in which a data transmission error rate is lower than a transmission error rate screening threshold, and a response delay from the master device to the slave device corresponding to the preferred communication state data;
[0028] Using each indicator in each of the preferred communication state-related data, a linear regression fitting is performed on the response delay of the master device to the slave device corresponding to each of the preferred communication state-related data, to obtain a linear regression fitting model between each indicator in each of the preferred communication state-related data and the response delay of the master device to the slave device corresponding to each of the preferred communication state-related data;
[0029] The linear regression fitting model is determined as the trained target response delay calculation model.
[0030] In a possible implementation, after acquiring the communication status-related data between the master device and the slave device in a historical monitoring period, the method further includes:
[0031] Determine whether the working conditions between the master device and the slave device have changed based on the communication status data between the master device and the slave device in the historical monitoring cycle and the current monitoring cycle;
[0032] If it is determined that the working condition between the master device and the slave device has changed, the length of the monitoring period is adjusted according to the current working condition corresponding to the communication status related data of the current monitoring period.
[0033] In a possible implementation, the communication status related data includes: at least one of communication quality information or communication environment information;
[0034] The communication quality information includes at least one of the following indicators: data transmission accuracy, data transmission error rate, average data length, and average response time of the slave device;
[0035] The communication environment information includes at least one of the following indicators: a voltage value of the communication bus and an ambient temperature of the slave device.
[0036] In a second aspect, an embodiment of the present application provides a communication bus-based response delay configuration device, which is applied to a processor of a master device, wherein the master device is located in a preset network architecture, and the preset network architecture also includes at least one slave device, and the slave device is connected to the master device via a communication bus, and the device includes:
[0037] An acquisition module is used to obtain data related to the communication status of the current monitoring cycle between the master device and the slave device;
[0038] a determination module for determining a target response delay of the master device to the slave device based on data related to the communication status of the master device and the slave device during a current monitoring cycle; the target response delay being a response delay that matches the current communication status between the master device and the slave device;
[0039] The adjustment module is used to adjust the response delay of the master device to the slave device to the target response delay.
[0040] In a possible implementation, the determination module is further configured to:
[0041] Acquire data related to the communication status of a historical monitoring period between the master device and the slave device; the historical monitoring period is a monitoring period before the current monitoring period;
[0042] Determine whether the response delay of the master device to the slave device needs to be adjusted based on the communication status related data of the historical monitoring cycle and the current monitoring cycle between the master device and the slave device.
[0043] In a possible implementation, the determination module is further configured to:
[0044] In response to any indicator in the communication status related data, if a fluctuation value from the historical monitoring period to the current monitoring period is greater than a corresponding fluctuation threshold, it is determined that a response delay of the master device to the slave device needs to be adjusted.
[0045] In one possible implementation, the communication status-related data includes at least one of communication quality information and communication environment information; the communication bus includes a serial clock line and a serial data line; the serial clock line is used to achieve clock synchronization between the master device and the slave device, and the serial data line is used for data transmission between the master device and the slave device;
[0046] The acquisition module is specifically used for:
[0047] determining whether a set monitoring period has been reached according to a clock signal on the serial clock line;
[0048] In response to reaching the set monitoring period, at least one of the following is performed:
[0049] Calculating the communication quality information based on the data sent and received by the serial data line within a set monitoring period;
[0050] Acquire the collected communication environment information.
[0051] In a possible implementation, the adjustment module is specifically configured to:
[0052] Determining a controller corresponding to a communication bus having a communication connection relationship with the slave device, wherein the controller is located in a processor of the master device;
[0053] The response delay parameter stored in the instruction register of the corresponding controller is adjusted to the target response delay.
[0054] In a possible implementation, the determination module is specifically configured to:
[0055] The communication status related data of the current monitoring cycle between the master device and the slave device is input into the trained target response delay calculation model, and the trained target response delay calculation model is used to calculate and output the target response delay.
[0056] In a possible implementation, the response delay configuration device further includes a fitting module, which is configured to:
[0057] Obtaining data related to a preferred communication state between a master device and a slave device, in which a data transmission error rate is lower than a transmission error rate screening threshold, and a response delay from the master device to the slave device corresponding to the preferred communication state data;
[0058] Using each indicator in each of the preferred communication state-related data, a linear regression fitting is performed on the response delay of the master device to the slave device corresponding to each of the preferred communication state-related data, to obtain a linear regression fitting model between each indicator in each of the preferred communication state-related data and the response delay of the master device to the slave device corresponding to each of the preferred communication state-related data;
[0059] The linear regression fitting model is determined as the trained target response delay calculation model.
[0060] In a possible implementation, the adjustment module is further configured to:
[0061] Determine whether the working conditions between the master device and the slave device have changed based on the communication status data between the master device and the slave device in the historical monitoring cycle and the current monitoring cycle;
[0062] If it is determined that the working condition between the master device and the slave device has changed, the length of the monitoring period is adjusted according to the current working condition corresponding to the communication status related data of the current monitoring period.
[0063] In a third aspect, an embodiment of the present application provides an electronic device, comprising: a memory, and a processor communicatively connected to the memory;
[0064] The memory stores computer-executable instructions;
[0065] The processor executes the computer-executable instructions stored in the memory, so that the processor executes the communication bus-based response delay configuration method provided in the first aspect and / or various possible implementations of the first aspect.
[0066] In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, which stores computer-executable instructions. When the computer-executable instructions are executed by a processor, they are used to implement the communication bus-based response delay configuration method provided in the first aspect and / or various possible implementations of the first aspect.
[0067] In a fifth aspect, an embodiment of the present application provides a computer program product, including a computer program, which, when executed by a processor, implements the communication bus-based response delay configuration method provided in the first aspect and / or various possible implementations of the first aspect.
[0068] The communication bus-based response delay configuration method and related device provided in the embodiments of the present application obtain communication status-related data of the current monitoring cycle between the master device and the slave device; the communication status-related data of the current monitoring cycle can reflect the communication status between the master device and the slave device, and then, based on the communication status-related data of the current monitoring cycle between the master device and the slave device, determine the target response delay of the master device to the slave device; the target response delay is the response delay that matches the current communication status between the master device and the slave device; therefore, the response delay that matches the current communication status between the master device and the slave device can be accurately determined, and then, the response delay of the master device to the slave device is adjusted to the target response delay, which can achieve the effect of simply and effectively solving the problem of the host-side response delay being too long or too short due to environmental influences. BRIEF DESCRIPTION OF THE DRAWINGS
[0069] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0070] Figure 1 A schematic diagram of an application scenario of the communication bus-based response delay configuration method provided in an embodiment of the present application;
[0071] Figure 2 Schematic diagram of the process of configuring the response delay based on the communication bus provided in the embodiment of the present application Figure 1 ;
[0072] Figure 3 Schematic diagram of the process of configuring the response delay based on the communication bus provided in the embodiment of the present application Figure 2 ;
[0073] Figure 4 A schematic diagram of the structure of a communication bus-based response delay configuration device provided in an embodiment of the present application;
[0074] Figure 5 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application.
[0075] The above drawings illustrate specific embodiments of the present application, which will be described in more detail below. These drawings and the textual description are not intended to limit the scope of the present application in any way, but rather to illustrate the concepts of the present application to those skilled in the art by reference to specific embodiments. DETAILED DESCRIPTION
[0076] Exemplary embodiments are described in detail herein, with examples illustrated in the accompanying drawings. When the following description refers to the drawings, identical numerals in different figures represent identical or similar elements unless otherwise indicated. The embodiments described in the following exemplary embodiments are not intended to represent all embodiments consistent with the present application. Rather, they are merely examples of apparatuses and methods consistent with certain aspects of the present application.
[0077] First, the terms involved in this application are explained.
[0078] Response delay: refers to the waiting time from receiving a request signal to sending a response signal.
[0079] Response time: refers to the waiting time from sending a request message to receiving a response signal.
[0080] Data transmission accuracy: refers to the proportion of data accurately transmitted from the sender to the receiver within the monitoring period.
[0081] Data transmission error rate: refers to the ratio of the data received by the receiving end to the data sent by the sending end due to various reasons during the monitoring period.
[0082] Average data length: refers to the average number of data bits contained in each transmission during the monitoring period.
[0083] Average response time of slave devices: refers to the average waiting time from when the master device sends a request message to when it receives a response signal from the slave device during the monitoring period.
[0084] Communication bus voltage value: refers to the voltage value of the communication bus connected between the master device and the slave device.
[0085] Ambient temperature of the slave device: refers to the temperature of the slave device's working environment.
[0086] First, the prior art involved in this application is described in detail.
[0087] In in-vehicle communications, the host typically uses a fixed response delay to process read and write operations from slave devices connected to the communication bus. This means that after receiving a request signal from a slave, the master waits for a fixed response delay before sending a response signal to the slave. However, the internal environment of a vehicle is complex, and signal transmission speeds and the processing speeds of different slave devices can fluctuate due to environmental influences. For example, changes in the ambient temperature of a slave device can affect its operating state, leading to fluctuations in signal transmission speed, processing speed, or data stability between the master and slave. In such situations, if the master still uses a fixed response delay, the host's response delay may be too long or too short. Excessively long response delays cause unnecessary waiting on the host side, wasting hardware resources, while too short response delays can lead to data transmission failures and communication timeouts. In in-vehicle communication applications, unnecessary waiting on the host side, data transmission failures, and communication timeouts can affect the responsiveness of the in-vehicle system and may even pose a potential threat to vehicle safety.
[0088] In the prior art, there are three main solutions to the problem of host-side response delays being too long or too short due to environmental influences. The first is to introduce a method of long-term bus occupation during the transmission process to avoid response timeouts. The second is to introduce a communication bus recovery mechanism at the hardware level. The third is to introduce a slave device bus idle state response. However, the first and third solutions require modifications to the communication bus protocol, and the second solution requires the introduction of additional hardware, which complicates the hardware or protocol of the communication bus, and neither is suitable for in-vehicle communication.
[0089] In summary, the existing technology cannot simply and effectively solve the problem of the host-side response delay being too long or too short due to environmental influences.
[0090] In response to the above problems in the prior art, the present application proposes the following inventive concept: a fixed response delay cannot adapt to the complex environmental changes in vehicle-mounted communication application scenarios. Therefore, if the response delay of the master device to the slave device can match the communication status between the master device and the slave device, then the problem of the master device's response delay being too long or too short can be avoided without adding hardware or modifying the communication protocol. Therefore, by monitoring the communication status between the master device and the slave device, it is possible to determine whether the master device's response delay to the slave device needs to be adjusted, and determine the target response delay based on the communication status-related data of the current monitoring cycle between the master device and the slave device. The target response delay is the response delay that matches the current communication status between the master device and the slave device, which can avoid the master device's response delay to the slave device being too long or too short, thereby simply and effectively solving the problem of the host side's response delay being too long or too short due to environmental influences.
[0091] Figure 1 Schematic diagram of an application scenario of the communication bus-based response delay configuration method provided in an embodiment of the present application, such as Figure 1 As shown, in an application scenario of the communication bus-based response delay configuration method provided in an embodiment of the present application, the method includes: a master device 11 and at least one slave device 12, and the master device 11 and the slave device 12 are connected via a communication bus 13. The master device 11 includes a processor.
[0092] The processor of the master device 11 obtains data related to the communication status of the current monitoring cycle between the master device 11 and the slave device 12.
[0093] The processor of the master device 11 determines the target response delay of the master device 11 to the slave device 12 based on the communication status related data of the current monitoring cycle between the master device 11 and the slave device 12; the target response delay is the response delay that matches the current communication status between the master device 11 and the slave device 12.
[0094] The processor of the master device 11 adjusts the response delay of the master device 11 to the slave device 12 to the target response delay.
[0095] The following specific embodiments describe in detail the technical solution of the present application and how the technical solution of the present application solves the above-mentioned technical problems. The following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be repeated in some embodiments. The embodiments of the present application will be described below in conjunction with the accompanying drawings.
[0096] The execution subject of the response delay configuration method based on the communication bus provided in the embodiment of the present application is a response delay configuration device, which is located in a processor, the processor is located in a master device, the master device is located in a preset network architecture, and the preset network architecture also includes at least one slave device, and the slave device is connected to the master device through a communication bus.
[0097] Figure 2 Schematic diagram of the process of configuring the response delay based on the communication bus provided in the embodiment of the present application Figure 1 .like Figure 2 As shown, the communication bus-based response delay configuration method provided in the embodiment of the present application includes S201 to S203.
[0098] S201, obtaining data related to the communication status of the current monitoring cycle between the master device and the slave device.
[0099] In this embodiment, a master device may refer to the device that performs the primary tasks in a communication or control system, and a slave device may refer to the device that is primarily controlled by the master device in the communication or control system. The master device may be responsible for coordinating and dividing tasks across the entire system, while the slave device may be responsible for executing specific tasks and responding to instructions from the master device. The master device exchanges data with the slave device via a communication bus, for example, sending control instructions and receiving status feedback.
[0100] In some application scenarios, the master device may also be responsible for managing the human-computer interaction interface, such as receiving user input and displaying information such as system status.
[0101] For example, in an in-vehicle communication scenario, for example, in a smart cockpit system, the master device may be a system-on-chip including a main control processor, and the slave devices may include a central control screen, an LCD instrument, and a head-up display HUD, etc.
[0102] In this embodiment, the processor may obtain data related to the communication status between the master device and the slave device according to a set monitoring period, and further obtain data related to the communication status of the current monitoring period.
[0103] Optionally, the communication status related data includes: at least one of communication quality information or communication environment information.
[0104] The communication quality information includes at least one of the following indicators: data transmission accuracy, data transmission error rate, average data length, and average response time of the slave device.
[0105] The communication environment information includes at least one of the following indicators: a voltage value of the communication bus and an ambient temperature of the slave device.
[0106] Among them, data transmission accuracy, data transmission error rate, average data length, and average response time of the slave device are indicators used to measure the communication quality between the master device and the slave device.
[0107] The data transmission accuracy rate is the probability that data transmitted between the master and slave devices is accurate within a monitoring cycle. The data transmission error rate is the probability that errors occur in data transmitted between the master and slave devices within a monitoring cycle. The average data length is the average number of bits in data transmitted between the master and slave devices within a monitoring cycle. The average slave response time is the average waiting time between the master sending a request and receiving a response from the slave within a monitoring cycle.
[0108] The voltage value of the communication bus and the ambient temperature of the slave device are indicators used to measure the communication environment between the master device and the slave device.
[0109] The voltage value of the communication bus refers to the voltage value of the communication bus connected between the master device and the slave device. The ambient temperature of the slave device refers to the temperature value of the working environment of the slave device.
[0110] S202, determining a target response delay of the master device to the slave device based on data related to the communication status of the current monitoring cycle between the master device and the slave device; the target response delay is a response delay that matches the current communication status between the master device and the slave device.
[0111] In this embodiment, the communication status related data may include at least one of the following indicators: data transmission accuracy, data transmission error rate, average data length, average response time of the slave device, voltage value of the communication bus, and ambient temperature of the slave device.
[0112] In this embodiment, a memory communicatively connected to the processor may store multiple first mapping relationships, each of which may be a mapping relationship between a preset communication state-related data set and a preferred response delay. The processor may retrieve the multiple first mapping relationships from the memory; determine the target communication state-related data set to which the communication state-related data of the current monitoring period belongs from the multiple first mapping relationships; and determine the target response delay as the preferred response delay associated with the target communication state-related data set.
[0113] Exemplarily, when the communication status related data includes the average data length and the ambient temperature of the slave device, the preset communication status related data set may include: communication status related data with the average data length ranging from a first length to a second length and the ambient temperature of the slave device ranging from a first temperature to a second temperature.
[0114] S203: Adjust the response delay of the master device to the slave device to the target response delay.
[0115] In this embodiment, the processor adjusts the response delay of the master device to the slave device to the target response delay, so that the response delay of the master device to the slave device can match the current communication status between the master device and the slave device, thereby avoiding the response delay of the master device to the slave device being too long or too short.
[0116] The communication bus-based response delay configuration method provided in this embodiment obtains data related to the communication status of the current monitoring cycle between the master device and the slave device; the communication status data of the current monitoring cycle can reflect the communication status between the master device and the slave device, and then, based on the communication status data of the current monitoring cycle between the master device and the slave device, determines the target response delay of the master device to the slave device; the target response delay is the response delay that matches the current communication status between the master device and the slave device; therefore, the response delay that matches the current communication status between the master device and the slave device can be accurately determined, and then the response delay of the master device to the slave device is adjusted to the target response delay, which can achieve the effect of simply and effectively solving the problem of the host-side response delay being too long or too short due to environmental influences.
[0117] Figure 3 Schematic diagram of the process of configuring the response delay based on the communication bus provided in the embodiment of the present application Figure 2 .like Figure 3 As shown, the communication bus-based response delay configuration method provided in the embodiment of the present application further includes S301 to S302 before S202.
[0118] S301, obtaining data related to the communication status between the master device and the slave device during a historical monitoring period.
[0119] In this embodiment, the communication status related data of the historical monitoring period may be the communication status related data of the previous monitoring period.
[0120] S302 : Determine whether a response delay of the master device to the slave device needs to be adjusted based on data related to the communication status of the master device and the slave device in historical monitoring cycles and a current monitoring cycle.
[0121] In this embodiment, the fluctuation of each indicator from the previous monitoring period to the current monitoring period can be calculated based on the values of each indicator in the communication status-related data of the previous monitoring period and the values of each indicator in the communication status-related data of the current monitoring period. Based on the fluctuation value of each indicator and the corresponding fluctuation threshold, it is determined whether the response delay of the master device to the slave device needs to be adjusted.
[0122] In this embodiment, the fluctuation value can be an increasing value, a decreasing value, or 0. The fluctuation threshold corresponding to each indicator can be different. The fluctuation threshold can include an increasing threshold or a decreasing threshold, and the increasing threshold and the decreasing threshold can be unequal or equal.
[0123] For example, if the data transmission error rate in the communication status data of a historical monitoring period is a, and the data transmission error rate in the communication status data of a current monitoring period is b, then the fluctuation value of the data transmission error rate from the historical monitoring period to the current monitoring period is ba. If a>b, the fluctuation value of the data transmission error rate is a decreasing value; if b>a, the fluctuation value of the data transmission error rate is an increasing value; if a=b, the fluctuation value of the data transmission error rate is 0.
[0124] In this embodiment, the fluctuation threshold corresponding to each indicator can be pre-stored in a memory that is communicatively connected to the processor. The processor can read the fluctuation threshold corresponding to each indicator from the memory, and then determine whether the response delay of the master device to the slave device needs to be adjusted based on the fluctuation value of each indicator.
[0125] As an optional implementation, when the communication status related data includes only one of the above indicators, it can be determined that the response delay of the master device to the slave device needs to be adjusted when the fluctuation value of the indicator is greater than or equal to the corresponding fluctuation threshold.
[0126] As an optional implementation, when the communication status-related data includes multiple indicators among the above-mentioned indicators, the indicators with fluctuation values greater than or equal to the corresponding fluctuation thresholds can be determined as fluctuation items, and the response delay of the master device to the slave device can be determined to need to be adjusted based on the number of fluctuation items. Exemplarily, it can be determined whether the response delay of the master device to the slave device needs to be adjusted when the number of fluctuation items is greater than or equal to the fluctuation item threshold. For example, when the communication status-related data includes at least 3 of the above-mentioned indicators and the fluctuation item threshold is 3, if only two of the multiple indicators included in the communication status-related data are determined to be fluctuation items, it can be determined that the response delay of the master device to the slave device does not need to be adjusted; if 3 of the multiple indicators included in the communication status-related data are determined to be fluctuation items, it can be determined that the response delay of the master device to the slave device needs to be adjusted.
[0127] The communication bus-based response delay configuration method provided in this embodiment can accurately determine whether the communication status between the master device and the slave device has changed through the communication status-related data and historical status-related data of the current monitoring cycle between the master device and the slave device, and further determine whether the response delay of the master device to the slave device needs to be adjusted.
[0128] Optionally, in the embodiment of the present application, S302 is refined to include S401.
[0129] S401 , in response to any indicator in the communication status related data, if the fluctuation value from the historical monitoring period to the current monitoring period is greater than the corresponding fluctuation threshold, it is determined that the response delay of the master device to the slave device needs to be adjusted.
[0130] In this embodiment, the communication status-related data includes at least one of communication quality information and communication environment information. The communication quality information includes at least one of the following indicators: data transmission accuracy rate, data transmission error rate, average data length, and average response time of the slave device. The communication environment information includes at least one of the following indicators: the voltage value of the communication bus and the ambient temperature of the slave device. The processor may determine that the response delay of the master device to the slave device needs to be adjusted when the fluctuation value of any of the indicators exceeds the corresponding fluctuation threshold.
[0131] When the fluctuation value of an indicator in the communication quality information exceeds the corresponding fluctuation threshold, it indicates that the communication quality between the master and slave devices has improved or deteriorated. Therefore, the response delay of the master device to the slave device needs to be adjusted. When the fluctuation value of an indicator in the communication environment information exceeds the corresponding fluctuation threshold, it indicates that the communication environment between the master and slave devices has changed. To adapt to the impact of this change on the communication status or communication quality, the response delay of the master device to the slave device also needs to be adjusted.
[0132] For example, if the communication status-related data includes a data transmission error rate and the ambient temperature of the slave device, and the communication status-related data for a historical monitoring period shows a data transmission error rate of 3‰ and a slave device ambient temperature of 25°C, and the communication status-related data for a current monitoring period shows a data transmission error rate of 6‰ and a slave device ambient temperature of 40°C, then the increase in the data transmission error rate is 3‰, and the increase in the slave device ambient temperature is 15°C.
[0133] If the data transmission error rate rising threshold is 5‰ and the slave device's ambient temperature rising threshold is 20°C, since 3‰ < 5‰ and 15°C < 20°C, it can be determined that the master device's response delay to the slave device does not need to be adjusted.
[0134] If the data transmission error rate rising threshold is 2‰, since 3‰>2‰, it can be determined that the response delay of the master device to the slave device needs to be adjusted.
[0135] If the rising threshold of the device's ambient temperature is 10°C, since 15°C > 10°C, it can be determined that the response delay of the master device to the slave device needs to be adjusted.
[0136] It should be understood that the fluctuation value in this embodiment is merely one form of indicating the change in the communication status between the master and slave devices from the previous monitoring period to the current monitoring period. The fluctuation value may also be expressed as a fluctuation ratio. Fluctuation values may include rising and falling values, and fluctuation thresholds may include rising and falling thresholds. Different indicators may correspond to different fluctuation thresholds, and the same indicator may correspond to different rising and falling thresholds.
[0137] The communication bus-based response delay configuration method provided in this embodiment determines that the response delay of the master device to the slave device needs to be adjusted when the fluctuation value of any indicator is greater than the corresponding fluctuation threshold. This can accurately determine whether the response delay of the master device to the slave device needs to be adjusted.
[0138] Optionally, in an embodiment of the present application, the communication status-related data includes at least one of communication quality information and communication environment information; the communication bus includes a serial clock line and a serial data line; the serial clock line is used to achieve clock synchronization between the master device and the slave device, and the serial data line is used for data transmission between the master device and the slave device; the step of "obtaining communication status-related data between the master device and the slave device" is refined to include S501 or S502.
[0139] S501 , determining whether a set monitoring period has been reached based on a clock signal on a serial clock line.
[0140] In this embodiment, the processor includes a controller that controls the serial clock line and serial data line of the communication bus. The serial clock line transmits the clock signal between the master device and the slave device. Therefore, changes in the environment will also affect the clock signal transmitted on the serial clock line. In order to accurately sample data related to the communication status, whether the set monitoring period is reached can be determined based on the clock signal on the serial clock line.
[0141] S502: In response to reaching a set monitoring period, perform at least one of the following:
[0142] Calculate communication quality information based on the data sent and received by the serial data line within a set monitoring period;
[0143] Get the collected communication environment information.
[0144] In this embodiment, since the communication status-related data includes at least one of communication quality information or communication environment information, when a set monitoring period is reached, the processor, corresponding to the communication status-related data including at least one of the communication quality information or communication environment information, performs at least one of the following: calculating the communication quality information based on data transmitted and received by the serial data line during the current monitoring period; or obtaining the collected communication environment information. Consequently, the processor is able to obtain at least one of the communication quality information or communication environment information.
[0145] In this embodiment, the controller in the processor can determine whether the data sent and received each time is correct, the data length of each data sent and received, and the average response time of the slave device each time data is sent and received during the process of controlling the serial data line to send and receive data. Therefore, the processor can calculate the data transmission accuracy, data transmission error rate, average data length and average response time of the slave device based on the data sent and received by the serial data line within a set monitoring period.
[0146] The voltage value of the communication bus can be measured using circuit principles, and the ambient temperature of the slave device can be measured by a temperature sensor installed at the slave device. The temperature sensor can also be a slave device connected to the master device, so the processor can obtain the ambient temperature of the slave device by communicating with the temperature sensor.
[0147] The communication bus-based response delay configuration method provided in this embodiment can accurately sample the signal on the serial data line by determining whether the set monitoring period has been reached based on the clock signal on the serial clock line. When obtaining communication status-related data, it can not affect the response of the master device to the slave device, thereby ensuring smooth data transmission.
[0148] Optionally, in the embodiment of the present application, S204 “adjusting the response delay of the master device to the slave device to the target response delay” is further refined to include S601 to S602.
[0149] S601, determining a controller corresponding to a communication bus having a communication connection relationship with a slave device, where the controller is located in a processor of a master device.
[0150] In this embodiment, since multiple master devices and multiple slave devices can be mounted on a communication bus, and a master device can correspond to multiple slave devices, the processor of the master device is connected to the communication bus via its controller. Therefore, when the processor adjusts the response delay of the master device to the slave device to the target response delay, it needs to first determine the controller corresponding to the communication bus that has a communication connection relationship with the slave device.
[0151] S602: Adjust the response delay parameter stored in the instruction register of the corresponding controller to the target response delay.
[0152] In this embodiment, the response delay of the master device to the slave device is controlled by the controller of the processor. The controller corresponding to the slave device controls the response delay of the master device to the slave device through the response delay parameter stored in its instruction register. Therefore, the processor first determines the controller corresponding to the communication bus connected to the slave device, and then adjusts the response delay parameter stored in the instruction register of the corresponding controller to the target response delay.
[0153] The communication bus-based response delay configuration method provided in this embodiment can quickly and accurately adjust the response delay of the master device to the slave device to the target response delay by adjusting the response delay parameter stored in the instruction register.
[0154] Optionally, in an embodiment of the present application, “determining a target response delay based on communication status related data of a current monitoring period” in S202 is further refined to include S701 to S702.
[0155] S701: Input the communication status related data of the current monitoring cycle between the master device and the slave device into the trained target response delay calculation model, and calculate and output the target response delay using the trained target response delay calculation model.
[0156] In this embodiment, the trained target response delay calculation model may be a convolutional neural network model, a linear fitting function, or the like.
[0157] When the trained target response delay calculation model is a convolutional neural network model, the input to the trained target response delay calculation model is multiple indicators included in the communication status related data of the current monitoring period. The convolutional neural network model processes the multiple indicators, calculates the target response delay and outputs it.
[0158] When the trained target response delay calculation model is a linear fitting function, the linear fitting function may include multiple independent variables, and the input to the linear fitting function is multiple indicators included in the communication status-related data of the current monitoring period. The linear fitting function uses the multiple indicators as independent variables, calculates the value of the dependent variable, and determines the calculated value of the dependent variable as the target response delay.
[0159] The communication bus-based response delay configuration method provided in this embodiment can quickly and accurately calculate the target response delay through a preset target response delay calculation function or a trained target response delay determination model.
[0160] Optionally, in an embodiment of the present application, the trained target response delay calculation model is obtained using methods such as S801 to S803.
[0161] S801, obtaining preferred communication status related data between the master device and the slave device, in which the data transmission error rate is lower than the transmission error rate screening threshold, and the response delay of the master device to the slave device corresponding to the preferred communication status related data.
[0162] In this embodiment, the communication status related data is preferably communication status related data between the master device and the slave device within a monitoring period, and the data transmission error rate is lower than the transmission error rate screening threshold.
[0163] In this embodiment, the communication between the master device and the slave device can be simulated in the laboratory, and the communication status data between the master device and the slave device can be obtained according to the set monitoring period. Furthermore, at least one preferred communication status-related data with a data transmission error rate lower than the transmission error rate screening threshold can be screened out from the communication status data of each monitoring period between the master device and the slave device, and the response delay of the master device to the slave device corresponding to each preferred communication status-related data can be obtained.
[0164] The sum of the data transmission error rate and the data transmission accuracy rate is 1. Therefore, at least one preferred communication status related data having a data transmission accuracy rate higher than the transmission error rate screening threshold can also be obtained.
[0165] It is understandable that the data transmission error rate of the communication status related data may preferably be equal to the transmission error rate screening threshold, or equal to the data transmission accuracy threshold.
[0166] In this embodiment, before selecting and selecting communication status-related data, the acquired communication status data between the master and slave devices may be cleaned and normalized. Data cleansing is used to remove outliers and noise from the communication status data between the master and slave devices. Normalization ensures that all indicators have the same magnitude.
[0167] S802, using each indicator in each preferred communication state related data, perform linear regression fitting on the response delay of the master device to the slave device corresponding to each preferred communication state related data, and obtain a linear regression fitting model between each indicator in each preferred communication state related data and the response delay of the master device to the slave device corresponding to each preferred communication state related data.
[0168] When the communication status related data includes only one indicator, the linear regression fitting is a single-parameter linear regression fitting; when the communication status related data includes multiple indicators, the linear regression fitting is a multi-parameter linear regression fitting. The linear regression fitting can be performed in the processor or in a fitting device connected to the processor. Moreover, the linear regression fitting can be performed before executing the response delay configuration method of the present application or can be performed continuously during the execution of the response delay configuration method of the present application to update the trained target response delay calculation model, which is not limited here.
[0169] S803: Determine the linear regression fitting model as the trained target response delay calculation model.
[0170] The communication bus-based response delay configuration method provided in this embodiment can simply and quickly obtain a trained target response delay calculation model through linear regression fitting.
[0171] As an optional implementation, after obtaining the communication status related data of the current monitoring cycle between the master device and the slave device, the trained target response delay determination model can be continuously trained and updated based on the communication status related data of the current monitoring cycle, the response delay of the master device to the slave device corresponding to the current monitoring cycle, the communication status related data of the historical monitoring cycle, and the response delay of the master device to the slave device corresponding to the historical monitoring cycle, so as to improve the accuracy of the target response delay calculated by the trained target response delay determination model, so that the target response delay can better match the current communication status between the master device and the slave device.
[0172] Optionally, in the embodiment of the present application, after S301 , S901 to S902 are also included.
[0173] S901 , determining whether the working condition between the master device and the slave device has changed based on data related to the communication status between the master device and the slave device in a historical monitoring period and a current monitoring period.
[0174] S902: If it is determined that the working condition between the master device and the slave device has changed, the length of the monitoring period is adjusted according to the current working condition corresponding to the communication status related data of the current monitoring period.
[0175] In this embodiment, the working conditions between the master device and the slave device can be determined based on one or more items of the communication status related data, and further, the working conditions between the master device and the slave device during the previous monitoring cycle and the working conditions between the master device and the slave device during the current monitoring cycle can be determined, and further, it can be determined whether the working conditions between the master device and the slave device have changed from the previous monitoring cycle to the current monitoring cycle.
[0176] When the working conditions between the master device and the slave device change, the duration of the monitoring period for acquiring communication status-related data can be adjusted to the duration matching the current working conditions corresponding to the communication status-related data of the current monitoring period. The duration matching each working condition can be a preset value.
[0177] In this embodiment, since acquiring data related to the communication status between the master and slave devices also consumes processor computing resources, the monitoring frequency can be determined based on the operating conditions between the master and slave devices. For example, in driving conditions, the monitoring frequency can be increased to avoid excessively long or short response delays from the master to the slave devices. In parking conditions, the monitoring frequency can be reduced to conserve processor computing resources.
[0178] The communication bus-based response delay configuration method provided in this embodiment can simply and effectively solve the problem of excessively long or short response delay on the host side due to environmental influences by adjusting the length of the monitoring cycle, while further saving hardware resources.
[0179] Optionally, in any of the above embodiments, the communication bus may be an IIC bus.
[0180] Figure 4 This is a schematic diagram of the structure of the communication bus-based response delay configuration device provided by this application, as shown in FIG. Figure 4 As shown, the communication bus-based response delay configuration device 40 provided in this embodiment is applied to the processor of the master device. The master device is located in a preset network architecture. The preset network architecture also includes at least one slave device. The slave device is connected to the master device through a communication bus. The response delay configuration device 40 includes: an acquisition module 41, a determination module 42 and an adjustment module 43.
[0181] The acquisition module 41 is used to acquire data related to the communication status between the master device and the slave device in the current monitoring cycle.
[0182] The determination module 42 determines a target response delay of the master device to the slave device based on the communication status related data of the current monitoring cycle between the master device and the slave device; the target response delay is the response delay that matches the current communication status between the master device and the slave device.
[0183] The adjustment module 43 is configured to adjust the response delay of the master device to the slave device to a target response delay.
[0184] In a possible implementation, the determination module is further configured to:
[0185] Obtaining data related to the communication status of the historical monitoring period between the master device and the slave device; the historical monitoring period is the monitoring period before the current monitoring period;
[0186] Determine whether the response delay of the master device to the slave device needs to be adjusted based on the communication status related data of the historical monitoring cycle and the current monitoring cycle between the master device and the slave device.
[0187] In a possible implementation, the determination module is further configured to:
[0188] In response to any indicator in the communication status related data, if the fluctuation value from the historical monitoring period to the current monitoring period is greater than the corresponding fluctuation threshold, it is determined that the response delay of the master device to the slave device needs to be adjusted.
[0189] In one possible implementation, the communication status-related data includes at least one of communication quality information and communication environment information; the communication bus includes a serial clock line and a serial data line; the serial clock line is used to achieve clock synchronization between the master device and the slave device, and the serial data line is used for data transmission between the master device and the slave device;
[0190] The acquisition module is specifically used for:
[0191] Determine whether the set monitoring period has been reached according to the clock signal on the serial clock line;
[0192] In response to reaching the set monitoring period, at least one of the following is performed:
[0193] Calculate communication quality information based on the data sent and received by the serial data line within a set monitoring period;
[0194] Get the collected communication environment information.
[0195] In a possible implementation, the adjustment module is specifically configured to:
[0196] Determine a controller corresponding to a communication bus having a communication connection relationship with the slave device, the controller being located in a processor of the master device;
[0197] The response delay parameter stored in the instruction register of the corresponding controller is adjusted to the target response delay.
[0198] In a possible implementation, the determination module is specifically configured to:
[0199] The communication status related data of the current monitoring cycle between the master device and the slave device is input into the trained target response delay calculation model, and the trained target response delay calculation model is used to calculate and output the target response delay.
[0200] In a possible implementation, the response delay configuration device further includes a fitting module, which is configured to:
[0201] Obtaining preferred communication status data between the master device and the slave device, in which the data transmission error rate is lower than the transmission error rate screening threshold, and a response delay from the master device to the slave device corresponding to the preferred communication status data;
[0202] Using various indicators in each preferred communication state-related data, linear regression fitting is performed on the response delay of the master device to the slave device corresponding to each preferred communication state-related data, to obtain a linear regression fitting model between various indicators in each preferred communication state-related data and the response delay of the master device to the slave device corresponding to each preferred communication state-related data;
[0203] The linear regression fitting model is determined as the trained target response delay calculation model.
[0204] In a possible implementation, the adjustment module is further configured to:
[0205] Determine whether the working conditions between the master device and the slave device have changed based on the communication status data between the master device and the slave device in the historical monitoring cycle and the current monitoring cycle;
[0206] If it is determined that the working condition between the master device and the slave device has changed, the time length of the monitoring period is adjusted according to the current working condition corresponding to the communication status related data of the current monitoring period.
[0207] The communication bus-based response delay configuration device provided in this embodiment can execute the method provided in the above method embodiment. Its implementation principle and technical effects are similar, and are not described in detail in this embodiment.
[0208] An embodiment of the present application further provides a processor, comprising: an input circuit, an output circuit, and a processing circuit.
[0209] The processing circuit is used to receive signals through the input circuit and send signals through the output circuit, so that the processing circuit executes the above method. The specific implementation process can be referred to the above method embodiment. Its implementation principle and technical effect are similar, and this embodiment will not be repeated here.
[0210] Figure 5 This is a schematic diagram of the structure of the electronic device provided in this application. Figure 5 As shown, the electronic device 50 provided in this embodiment includes: a processor 51 and a memory 52.
[0211] During the specific implementation process, the processor 51 executes the computer-executable instructions stored in the memory 52, so that the processor 51 performs the above method.
[0212] The specific implementation process of the processor 51 can be found in the above method embodiment. Its implementation principle and technical effects are similar and will not be repeated here in this embodiment.
[0213] In the above embodiments, it should be understood that the processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASICs), etc. A general-purpose processor may be a microprocessor or any conventional processor. The steps of the method disclosed in the present invention may be directly executed by a hardware processor or by a combination of hardware and software modules within the processor.
[0214] The memory may include random access memory (RAM) and may also include non-volatile memory (NVM), such as at least one disk storage.
[0215] A bus can be an Industry Standard Architecture (ISA) bus, a Peripheral Component Interconnect (PCI) bus, or an Extended Industry Standard Architecture (EISA) bus. Buses can be categorized as address buses, data buses, and control buses. For ease of illustration, the buses in the drawings of this application are not limited to just one bus or just one type of bus.
[0216] The present application also provides a computer-readable storage medium, in which computer-executable instructions are stored. When a processor executes the computer-executable instructions, the above method is implemented.
[0217] The present application also provides a computer program product, including a computer program, which implements the above method when executed by a processor.
[0218] The readable storage medium may be implemented by any type of volatile or non-volatile memory device, or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk. The readable storage medium may be any available medium that can be accessed by a general-purpose or special-purpose computer.
[0219] An exemplary readable storage medium is coupled to a processor so that the processor can read information from the readable storage medium and write information to the readable storage medium. Of course, the readable storage medium can also be an integral part of the processor. The processor and the readable storage medium can be located in an application specific integrated circuit (ASIC). Of course, the processor and the readable storage medium can also exist in the device as discrete components.
[0220] The division of units is merely a logical functional division; actual implementations may employ alternative divisions, such as combining or integrating multiple units or components into another system, or omitting or disabling certain features. Furthermore, any direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection between devices or units, either through an interface, electrical, mechanical, or other means.
[0221] Units described as separate components may or may not be physically separate, and components shown as units may or may not be physical units, that is, they may be located in one place or distributed across multiple network units. Some or all of these units may be selected to achieve the purpose of this embodiment according to actual needs.
[0222] In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
[0223] If a function is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the portion that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which can be a personal computer, server, or network device, etc.) to execute all or part of the steps of the various embodiments of the method of the present invention. The aforementioned storage medium includes various media that can store program code, such as USB flash drives, mobile hard drives, read-only memories (ROMs), random access memories (RAMs), magnetic disks, or optical disks.
[0224] Those skilled in the art will appreciate that all or part of the steps in the above-described method embodiments can be implemented using hardware associated with program instructions. The aforementioned program can be stored in a computer-readable storage medium. When executed, the program performs the steps of the above-described method embodiments. The aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks.
[0225] Finally, it should be noted that those skilled in the art will readily identify other embodiments of the present invention after considering the specification and practicing the invention disclosed herein. The present invention is intended to cover any variations, uses, or adaptations of the present invention that follow the general principles of the present invention and include common knowledge or customary techniques in the art not disclosed herein. The present invention is not limited to the precise structure described above and illustrated in the accompanying drawings, and various modifications and variations may be made without departing from the scope thereof. The scope of the present invention is limited solely by the appended claims.
Claims
1. A response delay configuration method based on a communication bus, characterized in that: A processor applied to a master device, the master device being located in a preset network architecture, the preset network architecture further comprising at least one slave device, the slave device being connected to the master device via a communication bus, the method comprising: Obtain data related to the communication status of the current monitoring cycle between the master device and the slave device; Inputting data related to the communication status of the current monitoring cycle between the master device and the slave device into a trained target response delay calculation model, and using the trained target response delay calculation model to calculate and output a target response delay from the master device to the slave device; the target response delay is the response delay that matches the current communication status between the master device and the slave device; the response delay is the waiting time from receiving a request signal to sending a response signal; Adjusting the response delay of the master device to the slave device to the target response delay; The trained target response delay calculation model is obtained by the following method: Obtaining data related to a preferred communication state between a master device and a slave device, in which a data transmission error rate is lower than a transmission error rate screening threshold, and a response delay from the master device to the slave device corresponding to the preferred communication state data; Using each indicator in each of the preferred communication state-related data, a linear regression fitting is performed on the response delay of the master device to the slave device corresponding to each of the preferred communication state-related data, to obtain a linear regression fitting model between each indicator in each of the preferred communication state-related data and the response delay of the master device to the slave device corresponding to each of the preferred communication state-related data; The linear regression fitting model is determined as the trained target response delay calculation model.
2. The method according to claim 1, characterized in that Before determining the target response delay of the master device to the slave device based on the communication status related data of the current monitoring cycle between the master device and the slave device, the method further includes: Acquire data related to the communication status of a historical monitoring period between the master device and the slave device; the historical monitoring period is a monitoring period before the current monitoring period; Determine whether the response delay of the master device to the slave device needs to be adjusted based on the communication status related data of the historical monitoring cycle and the current monitoring cycle between the master device and the slave device.
3. The method according to claim 2, characterized in that The determining whether a response delay of the master device to the slave device needs to be adjusted based on the communication status related data of the historical monitoring cycle and the current monitoring cycle between the master device and the slave device includes: In response to any indicator in the communication status related data, if a fluctuation value from the historical monitoring period to the current monitoring period is greater than a corresponding fluctuation threshold, it is determined that a response delay of the master device to the slave device needs to be adjusted.
4. The method according to claim 1, wherein The communication status related data includes at least one of communication quality information and communication environment information; the communication bus includes a serial clock line and a serial data line; the serial clock line is used to achieve clock synchronization between the master device and the slave device, and the serial data line is used for data transmission between the master device and the slave device; Obtain data related to the communication status between the master device and the slave device, including: determining whether a set monitoring period has been reached according to a clock signal on the serial clock line; In response to reaching the set monitoring period, at least one of the following is performed: Calculating the communication quality information based on the data sent and received by the serial data line within a set monitoring period; Acquire the collected communication environment information.
5. The method according to claim 1, wherein The adjusting the response delay of the master device to the slave device to the target response delay includes: Determining a controller corresponding to a communication bus having a communication connection relationship with the slave device, wherein the controller is located in a processor of the master device; The response delay parameter stored in the instruction register of the corresponding controller is adjusted to the target response delay.
6. The method according to claim 2 or 3, characterized in that After acquiring the communication status related data of the historical monitoring period between the master device and the slave device, the method further includes: Determine whether the working conditions between the master device and the slave device have changed based on the communication status data between the master device and the slave device in the historical monitoring cycle and the current monitoring cycle; If it is determined that the working condition between the master device and the slave device has changed, the length of the monitoring period is adjusted according to the current working condition corresponding to the communication status related data of the current monitoring period.
7. A communication bus-based response delay configuration device, the communication bus-based response delay configuration device is used to implement the communication bus-based response delay configuration method according to any one of claims 1 to 6, characterized in that: A processor applied to a master device, the master device being located in a preset network architecture, the preset network architecture further comprising at least one slave device, the slave device being connected to the master device via a communication bus, the apparatus comprising: An acquisition module is used to obtain data related to the communication status of the current monitoring cycle between the master device and the slave device; a determination module for determining a target response delay of the master device to the slave device based on data related to the communication status of the master device and the slave device during a current monitoring cycle; the target response delay being a response delay that matches the current communication status between the master device and the slave device; The adjustment module is used to adjust the response delay of the master device to the slave device to the target response delay.
8. An electronic device, characterized in that: include: a memory, and a processor communicatively connected to the memory; The memory stores computer-executable instructions; The processor executes the computer-executable instructions stored in the memory, so that the processor performs the method according to any one of claims 1 to 6.
9. A computer-readable storage medium, characterized in that The computer-readable storage medium stores computer-executable instructions, which are used to implement the method according to any one of claims 1 to 6 when executed by a processor.
10. A computer program product, comprising a computer program, wherein when the computer program is executed by a processor, the method according to any one of claims 1 to 6 is implemented.
Citation Information
Patent Citations
Parameter optimization method and device for communication equipment
CN106059834A
Polling frequency self-adaptive communication method and device, equipment and storage medium
CN111464388A