Communication management machine system based on domestic single-chip microcomputer

By dynamic memory allocation, simulated communication serial port, configuration information solidification and time dual-synchronous management on the communication management machine, the existing communication management machine system has solved the problems of high cost and low cost performance, and the effect of efficient operation on the GD32F103 platform is achieved.

CN119807129AActive Publication Date: 2025-04-11BEIJING HUAFUJUNENG SCI & TECH
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202510300193.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-14
Publication Date
2025-04-11
Estimated Expiration
2045-03-14

AI Technical Summary

Technical Problem

The existing communication management machine systems are generally based on Linux operating systems, requiring high microcontroller main frequency and memory capacity, resulting in higher costs. At the same time, the development of equipment requires higher cost investment and technical level, and the cost-effectiveness is not high.

Method used

By dynamically allocating and managing memory resources when the communication management machine is running, ordinary IO ports are simulated to process the communication serial port, customize and solidify configuration information, and use the RC oscillator inside the microcontroller to perform dual-synchronization time management with software time.

Benefits of technology

The communication management machine is realized to run on the more cost-effective GD32F103 platform, avoiding the use of unnecessary peripherals, reducing costs and complexity, significantly reducing memory usage and resource consumption, and improving system efficiency and stability.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119807129A_ABST
    Figure CN119807129A_ABST
Patent Text Reader

Abstract

The invention discloses a communication management machine system based on a domestic single-chip microcomputer, and relates to the technical field of communication management machine systems, which comprises the following steps of: dynamically allocating and managing memory resources of a communication management machine when the communication management machine runs; performing analog communication serial port processing on the common IO port to obtain an analog communication serial port, and managing the analog communication serial port; performing customized solidification processing on the configuration information of the communication management machine; an RC oscillator in the single-chip microcomputer is used and software time is combined to carry out time double-synchronization management; the method is used for solving the problem that an existing communication management machine system is generally based on a Linux operating system, high single-chip microcomputer dominant frequency and memory capacity are needed, and cost performance is not high.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of communication management machine systems, in particular to a communication management machine system based on a domestic single chip microcomputer. Background Art

[0002] The communication management machine system is an intelligent device system used to realize data transmission and conversion between different communication protocols and different types of equipment; it usually acts as an intermediate bridge, connecting various devices with different communication interfaces and protocols to achieve efficient, accurate and reliable data transmission and interaction.

[0003] The current communication management machine system is generally based on the Linux operating system, which requires a higher main microcontroller frequency and memory capacity, resulting in higher costs; in addition, the development of these devices also requires a high cost investment; however, the functions implemented by these devices are relatively simple, mainly focusing on data collection, processing and forwarding; and by eliminating some non-core additional functions and peripherals, and optimizing program algorithms, the space occupancy and resource consumption are significantly reduced; such an optimization strategy enables the communication management machine to run on the more cost-effective GD32F103 platform; the existing communication management machine system is generally based on the Linux operating system, which requires a higher main microcontroller frequency and memory capacity, resulting in higher costs; at the same time, the development of these devices not only requires a high cost investment, but also requires developers to have a high level of technology; however, the functions implemented by these devices are relatively simple, mainly focusing on data collection, processing and forwarding, resulting in low cost performance. Summary of the invention

[0004] The present invention aims to solve at least one of the technical problems in the prior art to a certain extent, by dynamically allocating and managing the memory resources of a communication management machine when the communication management machine is running; simulating communication serial port processing on ordinary IO ports to obtain simulated communication serial ports, and managing the simulated communication serial ports; customizing and solidifying the configuration information of the communication management machine; utilizing the RC oscillator inside a single-chip microcomputer and combining it with software time to perform dual-synchronous time management; so as to solve the problem that the existing communication management machine systems are generally based on the Linux operating system, requiring a higher single-chip microcomputer main frequency and memory capacity, which leads to higher costs.

[0005] To achieve the above-mentioned purpose, in the first aspect, the present application provides a communication management machine system based on a domestic single-chip microcomputer, including a space optimization module, a serial port simulation module, a configuration management module and a time synchronization module; The space optimization module is used to dynamically allocate and manage the memory resources of the communication management machine when the communication management machine is running; The serial port simulation module simulates the communication serial port processing on the common IO port to obtain the simulated communication serial port, and manages the simulated communication serial port; The configuration management module is used to customize and solidify the configuration information of the communication management machine; The time synchronization module utilizes the RC oscillator inside the single-chip microcomputer and combines the software time to perform time dual synchronization management.

[0006] Furthermore, the space optimization module is configured with a space optimization strategy, which includes: During the operation of the communication management machine, the size of the memory pool of the microcontroller is counted at a first time interval within a first time period, and is sorted from small to large, marked as periodic memory size information, and recorded as GAi=[R1, R2, R3, ..., Rn], where i represents the i-th first time period; the first time period is T0, and the first time interval is t1.

[0007] Furthermore, the space optimization strategy also includes: Set the first time window to c2, and divide the periodic memory size information with the first time window. For any first time window in the divided periodic memory size information, select the size of the largest memory pool in the first time window, denoted as RM, and calculate q0*RM; and mark q0*RM as the reference size of the corresponding first time window. After completion, the reference memory size information is obtained, denoted as GBi, where q0 is the proportional coefficient q0∈[0.5, 1].

[0008] Furthermore, the space optimization strategy also includes: During the operation of the communication management machine, if the operation of the communication management machine enters a new first time window, according to the reference size of the first time window corresponding to the previous first time period, it is recorded as BR i-1 , and the reference size of the first time window corresponding to the previous first time period, denoted as BR i-2 , the predicted reference size is calculated by the first reference formula; the first reference formula is as follows: , where BRi represents the predicted reference size, q1 and q2 are weight coefficients, q1+q2=1, and q1>0, q2>0; and adjust the size of the memory pool to the predicted reference size; Otherwise, collect the utilization of the memory pool. When the utilization of the memory pool in K0 consecutive first time intervals is greater than K1, increase the memory pool. When the utilization of the memory pool is less than K2, reduce the memory pool. K0 is the set threshold number, and K1 and K2 are the set threshold utilizations.

[0009] Furthermore, the serial port simulation module is configured with a serial port simulation strategy, and the serial port simulation strategy includes: For the common IO ports of the single-chip microcomputer, select A1 common IO ports and sort them, with k being an even number; pair the IO port with an odd number in the sorting sequence with the next IO port with an even number in the sorting sequence, and record them as paired IO ports. For the paired IO ports, select the IO port with an odd number in the sorting sequence as the sending pin, and select the IO port with an even number in the sorting sequence as the receiving pin, and mark them as analog communication serial ports; use a timer to control the baud rate of the analog communication serial port, and use time-division multiplexing technology, and use one timer to manage multiple analog communication serial ports.

[0010] Furthermore, the configuration management module is configured with a configuration management strategy, and the configuration management strategy includes: Based on the Flash of the single-chip microcomputer, the Flash of the single-chip microcomputer is divided into a configuration data partition, a configuration backup partition, a default configuration partition and a configuration diary partition; a copy of the default configuration data is stored in the default configuration partition; Divide the configuration data of the microcontroller into common configuration data and sensitive configuration data; When new MCU configuration data is received, it is recorded as the first configuration data, the check value of the first configuration data is calculated, and the version number of the first configuration data is defined, and then it is determined whether the new configuration data is sensitive configuration data. If so, the new configuration data is encrypted, if not, it is not encrypted; after completion, the second configuration data is obtained.

[0011] Furthermore, the configuration management strategy also includes: The second configuration data is written into the configuration backup partition together with the corresponding check value; and the data integrity of the configuration backup partition is verified. If the verification fails, a write error warning is issued; if the verification passes, the configuration data of the configuration data partition is erased, and the second configuration data of the configuration backup partition is copied to the configuration data partition; and the configuration update log of the configuration diary partition is updated to record the time and version number of the new configuration data update.

[0012] Furthermore, the configuration management strategy also includes: When reading configuration data, the corresponding check value is recalculated according to the read configuration data and compared with the stored check value. If they are the same, the reading is successful. If they are not the same, an error warning is issued; If the configuration data of the configuration data partition causes the communication management machine system to be abnormal, the corresponding configuration data will be rolled back to the corresponding previous version according to the configuration update log and the data of the configuration backup partition.

[0013] Furthermore, the time synchronization module is configured with a time synchronization strategy, which includes: Obtain an accurate timestamp through an external high-precision clock source, record it as external time P1, and use the timer driven by the RC oscillator inside the microcontroller to record the current time; record it as internal time P2; and use the frequency deviation formula to calculate the frequency deviation PC; the frequency deviation formula is as follows: ; Calibrate the frequency of the RC oscillator based on the frequency deviation; Setting a calibration trigger cycle includes: calibrating the frequency of the RC oscillator when the communication management machine system starts; calibrating the frequency of the RC oscillator at a second time interval, the second time interval is t2; setting a temperature change threshold and a voltage change threshold, and calibrating the frequency of the RC oscillator when the temperature change exceeds the temperature change threshold or the voltage change exceeds the voltage change threshold.

[0014] Furthermore, the time synchronization strategy also includes: Generate a high-precision time base based on the hardware timer of the single-chip microcomputer, which is recorded as the first base time; and use a 32-bit variable to record the microsecond time, which is recorded as the second base time; Each time the communication manager communicates or an event occurs, the current timestamp is recorded, the local time is synchronized using the first reference time and the second reference time at a third time interval, and time is synchronized with other devices through the communication interface of the microcontroller. The third time interval is t3.

[0015] Beneficial effects of the present invention: The present invention dynamically allocates and manages the memory resources of the communication management machine when the communication management machine is running; simulates the communication serial port processing of the common IO port to obtain the simulated communication serial port, and manages the simulated communication serial port; customizes and solidifies the configuration information of the communication management machine; utilizes the RC oscillator inside the single-chip microcomputer and combines the software time to perform time dual synchronization management; the communication management machine can be operated on the GD32F103 platform with higher cost-effectiveness. By accurately matching the actual needs of the communication management machine, we can avoid using unnecessary peripherals and further reduce costs and complexity; The present invention dynamically adjusts the memory pool of the single-chip microcomputer, and has the advantages of avoiding memory waste caused by static allocation by allocating and releasing resources on demand; significantly reducing memory occupancy and resource consumption; further improving system efficiency and stability; using common IO ports to simulate communication serial ports, and expanding communication serial ports to solve the problem of insufficient serial port resources; storing configuration data in Flash and performing backup and partition management, and having the advantages of avoiding the cost of expanding external memory, while improving the reliability and startup speed of the system, and improving the flexibility, reliability and security of configuration data; using an RC oscillator and software time for time synchronization; and realizing high-precision time synchronization in a single-chip microcomputer with limited resources; not only saving hardware costs, but also improving the flexibility and reliability of the system. BRIEF DESCRIPTION OF THE DRAWINGS

[0016] Figure 1 It is a functional block diagram of the system of the present invention. DETAILED DESCRIPTION

[0017] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0018] Example 1, please refer to Figure 1 As shown, the present application provides a communication management system based on a domestic single-chip microcomputer, including a space optimization module, a serial port simulation module, a configuration management module and a time synchronization module; The space optimization module is used to dynamically allocate and manage the memory resources of the communication management machine when the communication management machine is running; The space optimization module is configured with a space optimization strategy, which includes: during the operation of the communication management machine, the size of the memory pool of the single-chip microcomputer is counted at a first time interval within a first time period, and sorted from small to large according to the size, marked as period memory size information, recorded as GAi=[R1, R2, R3, ..., Rn], where i represents the i-th first time period; where the first time period is T0, and the first time interval is t1; in this embodiment, the first time period T0 is one day, 24 hours, and the first time interval t1 is 5 minutes; Set the first time window to c2, divide the periodic memory size information by the first time window, for any first time window in the divided periodic memory size information, select the size of the largest memory pool in the first time window, record it as RM, calculate q0*RM; and mark q0*RM as the reference size of the corresponding first time window, and after completion, obtain the reference memory size information, record it as GBi, where q0 is the proportional coefficient q0∈[0.5,1]; for example, in this embodiment, the first time window c2 is 1 hour, and q0 is 0.9; that is, select the maximum value of the data collected within one hour and multiply it by 0.9 as the reference size of this hour; During the operation of the communication management machine, if the operation of the communication management machine enters a new first time window, according to the reference size of the first time window corresponding to the previous first time period, it is recorded as BR i-1 , and the reference size of the first time window corresponding to the previous first time period, denoted as BR i-2 , the predicted reference size is calculated by the first reference formula; the first reference formula is as follows: , where BRi represents the predicted reference size, q1 and q2 are weight coefficients, q1+q2=1, and q1>0, q2>0; and the size of the memory pool is adjusted to the predicted reference size; in this embodiment, q1=0.6, q2=0.4; Otherwise, collect the utilization of the memory pool. When the utilization of the memory pool in K0 consecutive first time intervals is greater than K1, increase the memory pool. When the utilization of the memory pool is less than K2, reduce the memory pool. K0 is the number of set thresholds, K1 and K2 are the set threshold utilizations. In this embodiment, K0=3, K1=90%, K3=0.3 In the specific implementation process, the purpose of setting the proportional coefficient q0 is to prevent the reference size from becoming larger and larger instead of changing according to actual usage; dynamic resource management can significantly reduce memory usage and resource consumption by allocating and releasing resources on demand; and further improve the efficiency and stability of the system.

[0019] The serial port simulation module simulates the communication serial port processing of the common IO port to obtain the simulated communication serial port and manages the simulated communication serial port; The serial port simulation module is configured with a serial port simulation strategy, which includes: for the common IO ports of the single-chip microcomputer, select A1 common IO ports and sort them, k is an even number; pair the IO port with an odd number in the sorting sequence with the next IO port with an even number in the sorting sequence, and record them as paired IO ports. For the paired IO ports, select the IO port with an odd number in the sorting sequence as the sending pin, select the IO port with an even number in the sorting sequence as the receiving pin, and mark it as a simulated communication serial port; use a timer to control the baud rate of the simulated communication serial port, and use time-division multiplexing technology, and use one timer to manage multiple simulated communication serial ports; For example, simulation is based on the UART communication protocol. The UART communication protocol is an asynchronous serial communication protocol, and its data frame format includes: start bit, 1 low level; data bit, usually 8 bits, can also be 5, 6, 7 or 9 bits; check bit, 1 bit, optional odd check, even check or no check; stop bit, 1 or 2 high levels; In the specific implementation process, through software simulation of the communication serial port, the serial port function can be realized by using the ordinary GPIO port, thereby expanding the hardware serial port resources; combined with multi-channel simulated serial port management technology, the parallel operation of multiple serial ports can be realized on the resource-constrained microcontroller platform; the key to this method lies in precise timing control and efficient time-sharing multiplexing mechanism, which is suitable for embedded systems that are cost-sensitive and have insufficient serial port resources.

[0020] The configuration management module is used to customize and solidify the configuration information of the communication management machine; The configuration management module is configured with a configuration management strategy, which includes: based on the Flash of the single-chip microcomputer, the Flash of the single-chip microcomputer is divided into a configuration data partition, a configuration backup partition, a default configuration partition and a configuration diary partition; a default configuration data is stored in the default configuration partition; when the configuration data is damaged or invalid, the system is started using the default configuration; the size of each partition is determined according to the actual needs of the configuration data; Divide the configuration data of the microcontroller into common configuration data and sensitive configuration data; When new MCU configuration data is received, it is recorded as the first configuration data, and the check value of the first configuration data is calculated, for example, CRC16; and the version number of the first configuration data is defined to identify the version of the configuration data; then it is determined whether the new configuration data is sensitive configuration data, if so, the new configuration data is encrypted, if not, it is not encrypted; after completion, the second configuration data is obtained; encryption can use a lightweight encryption algorithm, such as AES-128 or XOR encryption; Write the second configuration data together with the corresponding check value into the configuration backup partition; and verify the data integrity of the configuration backup partition. If the verification fails, issue a write error warning; if the verification passes, erase the configuration data of the configuration data partition, and then copy the second configuration data of the configuration backup partition to the configuration data partition; and update the configuration update log of the configuration diary partition to record the time and version number of the new configuration data update; When reading configuration data, the corresponding check value is recalculated according to the read configuration data and compared with the stored check value. If they are the same, the reading is successful. If they are not the same, an error warning is issued. When reading configuration data, the version number is also checked to ensure compatibility with the current system. If the configuration data of the configuration data partition causes the communication management machine system to be abnormal, the corresponding configuration data will be rolled back to the corresponding previous version according to the configuration update log and the data of the configuration backup partition; In the specific implementation process, the integrity and consistency of configuration data are ensured through double backup and verification mechanisms; the use of storage space can be optimized through data partition management; the security of configuration data can be protected through data encryption; by storing configuration data in Flash, the cost of expanding external storage is avoided, while improving the reliability and startup speed of the system; combined with optimization strategies such as data verification, encryption and version management, the security and integrity of configuration data can be further ensured.

[0021] The time synchronization module uses the RC oscillator inside the microcontroller and combines it with the software time to perform dual time synchronization management; The time synchronization module is configured with a time synchronization strategy, which includes: obtaining an accurate timestamp through an external high-precision clock source, such as GPS, NTP, or an external crystal oscillator; recording it as external time P1, and using a timer driven by an RC oscillator inside the microcontroller to record the current time; recording it as internal time P2; and using the frequency deviation formula to calculate the frequency deviation PC; the frequency deviation formula is as follows: ; Calibrate the frequency of the RC oscillator based on the frequency deviation, that is, adjust the calibration parameters of the internal RC oscillator according to the frequency deviation; Setting a calibration trigger cycle includes: calibrating the frequency of the RC oscillator when the communication management machine system is started; calibrating the frequency of the RC oscillator at a second time interval, the second time interval being t2; setting a temperature change threshold and a voltage change threshold, and calibrating the frequency of the RC oscillator when the temperature change exceeds the temperature change threshold or the voltage change exceeds the voltage change threshold; because the frequency of the RC oscillator is greatly affected by temperature and voltage, it needs to be calibrated in time when the temperature change and voltage change are too large; Generate a high-precision time base based on the hardware timer of the microcontroller, such as TIM2, which is recorded as the first base time; and use a 32-bit variable to record the microsecond time, such as system_time_us, which is recorded as the second base time; system_time_us needs to be updated in the timer interrupt; Each time the communication management machine communicates or an event occurs, the current timestamp is recorded, the local time is synchronized using the first reference time and the second reference time at a third time interval, and the time is synchronized with other devices through the communication interface of the single-chip microcomputer, and the third time interval is t3; In the specific real-time process, the use of internal RC oscillators to achieve high-precision time synchronization is a low-cost solution for accurate time management in resource-constrained microcontrollers; although the accuracy of internal RC oscillators is usually not as good as that of external crystal oscillators, high-precision time synchronization can still be achieved through calibration and software optimization; the accuracy and reliability of time synchronization are improved through dynamic calibration, temperature compensation, time synchronization and optimization strategies.

[0022] In the embodiments provided in the present application, it should be understood that the disclosed system or method can be implemented in other ways. The embodiments described above are merely schematic. For example, the division of modules or units is only a logical function division. There may be other division methods in actual implementation. For example, multiple modules or units can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some communication interfaces, and the indirect coupling or communication connection of systems, modules and units can be electrical, mechanical or other forms.

[0023] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present application, rather than to limit it. Although the present application has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application.

Claims

1. The communication management system based on domestic single chip microcomputer is characterized by: Including space optimization module, serial port simulation module, configuration management module and time synchronization module; The space optimization module is used to dynamically allocate and manage the memory resources of the communication management machine when the communication management machine is running; The serial port simulation module simulates the communication serial port processing on the common IO port to obtain the simulated communication serial port, and manages the simulated communication serial port; The configuration management module is used to customize and solidify the configuration information of the communication management machine; The time synchronization module utilizes the RC oscillator inside the single-chip microcomputer and combines the software time to perform time dual synchronization management.

2. The communication management system based on a domestic single-chip microcomputer according to claim 1 is characterized in that: The space optimization module is configured with a space optimization strategy, which includes: During the operation of the communication management machine, the size of the memory pool of the microcontroller is counted at a first time interval within a first time period, and is sorted from small to large, marked as periodic memory size information, and recorded as GAi=[R1, R2, R3, ..., Rn], where i represents the i-th first time period; the first time period is T0, and the first time interval is t1.

3. The communication management system based on a domestic single-chip microcomputer according to claim 2 is characterized in that: Space optimization strategies include: Set the first time window to c2, and divide the periodic memory size information with the first time window. For any first time window in the divided periodic memory size information, select the size of the largest memory pool in the first time window, denoted as RM, and calculate q0*RM; and mark q0*RM as the reference size of the corresponding first time window. After completion, the reference memory size information is obtained, denoted as GBi, where q0 is the proportional coefficient q0∈[0.5, 1].

4. The communication management system based on a domestic single-chip microcomputer according to claim 3 is characterized in that: Space optimization strategies also include: During the operation of the communication management machine, if the operation of the communication management machine enters a new first time window, according to the reference size of the first time window corresponding to the previous first time period, it is recorded as BR i-1 , and the reference size of the first time window corresponding to the previous first time period, denoted as BR i-2 , the predicted reference size is calculated by the first reference formula; the first reference formula is as follows: , where BRi represents the predicted reference size, q1 and q2 are weight coefficients, q1+q2=1, and q1>0, q2>0; and adjust the size of the memory pool to the predicted reference size; Otherwise, collect the utilization of the memory pool. When the utilization of the memory pool in K0 consecutive first time intervals is greater than K1, increase the memory pool. When the utilization of the memory pool is less than K2, reduce the memory pool. K0 is the set threshold number, and K1 and K2 are the set threshold utilizations.

5. The communication management system based on domestic single chip microcomputer according to claim 4 is characterized in that: The serial port simulation module is configured with serial port simulation strategies, which include: For the common IO ports of the single-chip microcomputer, select A1 common IO ports and sort them, with k being an even number; pair the IO port with an odd number in the sorting sequence with the next IO port with an even number in the sorting sequence, and record them as paired IO ports. For the paired IO ports, select the IO port with an odd number in the sorting sequence as the sending pin, and select the IO port with an even number in the sorting sequence as the receiving pin, and mark them as analog communication serial ports; use a timer to control the baud rate of the analog communication serial port, and use time-division multiplexing technology, and use one timer to manage multiple analog communication serial ports.

6. The communication management system based on a domestic single-chip microcomputer according to claim 5 is characterized in that: The configuration management module is configured with configuration management strategies, which include: Based on the Flash of the single-chip microcomputer, the Flash of the single-chip microcomputer is divided into a configuration data partition, a configuration backup partition, a default configuration partition and a configuration diary partition; a copy of the default configuration data is stored in the default configuration partition; Divide the configuration data of the microcontroller into common configuration data and sensitive configuration data; When new MCU configuration data is received, it is recorded as the first configuration data, the check value of the first configuration data is calculated, and the version number of the first configuration data is defined, and then it is determined whether the new configuration data is sensitive configuration data. If so, the new configuration data is encrypted, if not, it is not encrypted; after completion, the second configuration data is obtained.

7. The communication management system based on a domestic single-chip microcomputer according to claim 6 is characterized in that: Configuration management strategies also include: The second configuration data is written into the configuration backup partition together with the corresponding check value; and the data integrity of the configuration backup partition is verified. If the verification fails, a write error warning is issued; if the verification passes, the configuration data of the configuration data partition is erased, and the second configuration data of the configuration backup partition is copied to the configuration data partition; and the configuration update log of the configuration diary partition is updated to record the time and version number of the new configuration data update.

8. The communication management system based on a domestic single-chip microcomputer according to claim 7 is characterized in that: Configuration management strategies also include: When reading configuration data, the corresponding check value is recalculated according to the read configuration data and compared with the stored check value. If they are the same, the reading is successful. If they are not the same, an error warning is issued; If the configuration data of the configuration data partition causes the communication management machine system to be abnormal, the corresponding configuration data will be rolled back to the corresponding previous version according to the configuration update log and the data of the configuration backup partition.

9. The communication management system based on a domestic single-chip microcomputer according to claim 8 is characterized in that: The time synchronization module is configured with a time synchronization strategy, which includes: Obtain an accurate timestamp through an external high-precision clock source, record it as external time P1, and use the timer driven by the RC oscillator inside the microcontroller to record the current time; record it as internal time P2; and use the frequency deviation formula to calculate the frequency deviation PC; the frequency deviation formula is as follows: ; Calibrate the frequency of the RC oscillator based on the frequency deviation; Setting a calibration trigger cycle includes: calibrating the frequency of the RC oscillator when the communication management machine system starts; calibrating the frequency of the RC oscillator at a second time interval, the second time interval is t2; setting a temperature change threshold and a voltage change threshold, and calibrating the frequency of the RC oscillator when the temperature change exceeds the temperature change threshold or the voltage change exceeds the voltage change threshold.

10. The communication management system based on a domestic single-chip microcomputer according to claim 9 is characterized in that: The time synchronization strategy also includes: Generate a high-precision time base based on the hardware timer of the single-chip microcomputer, which is recorded as the first base time; and use a 32-bit variable to record the microsecond time, which is recorded as the second base time; Each time the communication manager communicates or an event occurs, the current timestamp is recorded, the local time is synchronized using the first reference time and the second reference time at a third time interval, and time is synchronized with other devices through the communication interface of the microcontroller. The third time interval is t3.

Citation Information

Patent Citations

  • Communication managing machine capable of being comprehensively realized based on extensible markup language and dynamic library

    CN102685134A

  • Multi-channel serial port communication method and system based on software simulation

    CN114253879A

  • High-precision calibration method for high-precision active RC oscillator

    CN115833752A

  • Device and method for outputting BIOS running log based on virtual serial port

    CN119336687A

  • Data interaction method of embedded virtualization platform based on shared memory

    CN119576607A