Configurable multi-slave-station frequency conversion communication system based on Modbus communication
By designing a configurable multi-slave frequency conversion communication system based on Modbus communication, the problems of low communication efficiency, complex configuration and difficult debugging in the existing system are solved, and the system flexibility, reliability and efficient data transmission are realized.
Patent Information
- Application Number
- CN202510102178.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-22
- Publication Date
- 2025-05-16
AI Technical Summary
The existing inverter communication system based on Modbus communication has problems such as low communication efficiency, complex configuration and difficult debugging, and it is difficult to meet the efficient control needs of multiple inverters.
A configurable multi-slave frequency conversion communication system based on Modbus communication is designed. Through the combination of upper computer, Modbus communication module and lower computer, the standardized processing of the Modbus communication protocol is realized, the configuration and control of multiple slave devices are supported, and the communication diagnosis module is introduced for real-time monitoring and fault location.
It realizes the high flexibility of the system, can freely configure communication parameters, improves system reliability and stability, improves data transmission speed, and supports centralized control and highly scalable communication systems.
Smart Images

Figure CN120017438A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of industrial automation control, and in particular to a configurable multi-slave station variable frequency communication system based on Modbus communication. Background Art
[0002] With the continuous development of industrial automation technology, variable frequency speed regulation technology has become an important development direction in the field of motor control. In industrial automation control, traditional variable frequency communication systems usually adopt a one-to-one communication mode, that is, a main controller communicates with a frequency converter. However, with the improvement of industrial automation, there are more and more cases where multiple frequency converters need to be controlled simultaneously. This one-to-one communication mode is inefficient and complex to configure. In addition, traditional debugging methods often require manual work one by one, which is time-consuming, labor-intensive, and prone to errors. In addition, traditional variable frequency speed regulation systems often have problems such as inconsistent communication protocols, low data transmission efficiency, and poor system scalability. As a widely used serial communication protocol, the Modbus communication protocol has the advantages of being simple, reliable, and easy to implement, and is particularly suitable for industrial automation control systems. However, in the existing variable frequency communication system based on Modbus communication, there are still problems such as low communication efficiency, complex configuration, and difficult debugging. Therefore, a configurable multi-slave variable frequency communication system based on Modbus communication is urgently needed to solve the existing technical problems. Summary of the invention
[0003] In view of the above problems, the present invention is proposed to provide a configurable multi-slave variable frequency communication system based on Modbus communication, which overcomes the above problems or at least partially solves the above problems.
[0004] In order to solve the above technical problems, the embodiments of the present application disclose the following technical solutions:
[0005] The embodiment of the present invention discloses a configurable multi-slave station frequency conversion communication system based on Modbus communication, which is characterized by comprising: an upper computer, a Modbus communication module and a lower computer; wherein: the upper computer and the lower computer communicate with each other through the Modbus communication module, and the upper computer constructs and sends a command frame to the lower computer according to the Modbus communication protocol specification; after receiving the command frame from the upper computer, the lower computer parses the command frame, performs corresponding operations according to the command frame parsing result, and encapsulates a response frame and returns it to the upper computer; after receiving the response frame from the lower computer, the upper computer parses the response frame and parses the required data.
[0006] Furthermore, the host computer acts as a Modbus master station, which is used to send control instructions and read data. The host computer converts the control instructions through an RS485 circuit, and the RS485 circuit supports the standard Modbus protocol. The control instructions sent by the Modbus field bus are output to the lower computer as serial data information via the RS485 circuit; the lower computer acts as a Modbus slave station, with a built-in RS485 communication interface, which receives the control instructions of the host computer and returns corresponding data or status information. The lower computer is a slave device suitable for multiple Modbus protocols. The host computer performs lower control operations on multiple slave devices. Each slave device is configured with a unique slave device address with a value between 1-247, and the slave device address is used to distinguish different devices.
[0007] Furthermore, when the upper computer is initially configured, the factory default configuration of the lower computer can be displayed. The upper computer is connected to the lower computer according to the default configuration. After the upper computer and the lower computer are successfully connected, the upper computer can reconfigure the address, baud rate, timeout period, and number of timeout retries of the lower computer.
[0008] Furthermore, the upper computer constructs and sends a command frame to the lower computer according to the Modbus communication protocol specification, and the command frame includes at least a slave address, a function code, a data address and data length information, wherein the function code is used to indicate the type of operation performed by the lower computer, and the operation type includes at least reading a register and writing a register.
[0009] Furthermore, the lower computer performs corresponding operations according to the parsing result of the command frame, and encapsulates a response frame and returns it to the upper computer. The response frame usually includes at least the slave address, function code, data and check code information; after receiving the response frame from the lower computer, the upper computer parses the response frame and parses the required data; the upper computer performs CRC check and error processing on the data, and the upper computer sends a data frame to read the data of the readable register of the inverter slave station and write the data of the writable register of the slave station, thereby enabling the upper computer to read and control the inverter status.
[0010] Furthermore, the host computer and the slave computer communicate through the RTU message frame of Modbus communication, and the RTU message frame includes an address code, a protocol data unit and a CRC check. The first byte of the RTU message frame represents the address of the slave station. The second byte represents the function of reading register data and writing register data. The CRC check has a low byte in front and a high byte in the back. The data area sent by the host computer includes the base address of the read or write data, the number of read and write registers, and the data content written to the register. The data area content returned to the host computer includes the base address of the read or write data, the number of registers, and the data content read or written to the register.
[0011] Furthermore, the upper computer and the lower computer use interrupt mode and FIFO mode for data transmission. When the amount of data in the buffer reaches a preset threshold, an interrupt signal is generated to notify the CPU to process the data; when data needs to be sent or received, the data is first stored in the buffer, and then the SCI module automatically handles the sending or receiving of the data.
[0012] Furthermore, a configurable multi-slave variable frequency communication system based on Modbus communication also includes a communication diagnostic module, which is used to monitor the communication status and communication quality of the host computer and the slave computer in real time, and locate and troubleshoot faults through diagnostic parameters obtained by the host computer.
[0013] Furthermore, the diagnostic parameters include at least the drive communication status, the number of received messages, the number of slave station messages, the number of broadcast messages, the number of other messages, the number of normal responses, the number of abnormal responses, the sum check error count, the frame length abnormal count and the port reset time.
[0014] The beneficial effects of the above technical solution provided by the embodiment of the present invention include at least:
[0015] The embodiment of the present invention discloses a configurable multi-slave station frequency conversion communication system based on Modbus communication, comprising: an upper computer, a Modbus communication module and a lower computer; wherein: the upper computer and the lower computer communicate with each other through the Modbus communication module, the upper computer constructs and sends a command frame to the lower computer according to the Modbus communication protocol specification; after receiving the command frame from the upper computer, the lower computer parses the command frame, performs corresponding operations according to the command frame parsing result, and encapsulates a response frame and returns it to the upper computer; after receiving the response frame from the lower computer, the upper computer parses the response frame and parses the required data.
[0016] The beneficial effects of the present invention are as follows:
[0017] 1. High flexibility: The present invention can freely configure communication parameters, such as communication baud rate, inverter slave address, timeout period, timeout retry times, etc., which can be configured according to the needs of application scenarios to meet diverse debugging needs.
[0018] 2. Improve system reliability: The present invention has developed a complete communication diagnostic module that can monitor the communication status and communication quality in real time, which is conducive to rapid fault location and troubleshooting, and improves the reliability and stability of the communication system.
[0019] 3. Save resources, efficient and easy to expand: When constructing the parameter system of the present invention, the host computer, multi-function keyboard, etc. all follow the Modbus protocol to directly perform read and write operations on all parameters. The parameter code is used as the register address, and the parameter value is the register value. The flexibility of free parameter programming is retained, which is more intuitive and easy to expand and maintain, and greatly saves chip resources, improving system operation efficiency and overall performance.
[0020] 4. Improve data transmission speed: When performing data transmission, the present invention adopts interrupt mode and FIFO for data transmission. Compared with the direct query method, the FIFO mode can significantly reduce the sending time, improve the data transmission speed, and reduce the number of CPU interventions. Therefore, it can reduce the overall overhead of the system, and can realize real-time data processing and response, further improving the performance and reliability of the system.
[0021] 5. Centralized control and strong scalability: The host computer, as a centralized control system, can control multiple slave devices, debug and produce more efficiently, and easily add new devices without changing the structure of the entire system.
[0022] The technical solution of the present invention is further described in detail below through the accompanying drawings and embodiments. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] The accompanying drawings are used to provide a further understanding of the present invention and constitute a part of the specification. Together with the embodiments of the present invention, they are used to explain the present invention and do not constitute a limitation of the present invention. In the accompanying drawings:
[0024] Figure 1 This is a structural diagram of a configurable multi-slave station variable frequency communication system based on Modbus communication in Example 1 of the present invention;
[0025] Figure 2 The present invention is an overall framework diagram of a configurable multi-slave station variable frequency communication system based on Modbus communication in Embodiment 1 of the present invention;
[0026] Figure 3 This is a connection configuration diagram of the host computer in Embodiment 1 of the present invention;
[0027] Figure 4 This is a schematic diagram of an RTU message frame in Example 1 of the present invention. DETAILED DESCRIPTION
[0028] The exemplary embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present disclosure are shown in the accompanying drawings, it should be understood that the present disclosure can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided to enable a more thorough understanding of the present disclosure and to fully convey the scope of the present disclosure to those skilled in the art.
[0029] In order to solve the problems existing in the prior art, an embodiment of the present invention provides a configurable multi-slave station variable frequency communication system based on Modbus communication.
[0030] Example 1
[0031] The present invention discloses a configurable multi-slave frequency conversion communication system based on Modbus communication, such as Figure 1 , including: a host computer, a Modbus communication module and a slave computer; wherein: the host computer and the slave computer communicate with each other through the Modbus communication module, and the host computer constructs and sends a command frame to the slave computer according to the Modbus communication protocol specification; after receiving the command frame from the host computer, the slave computer parses the command frame, performs corresponding operations according to the command frame parsing result, and encapsulates a response frame and returns it to the host computer; after receiving the response frame from the slave computer, the host computer parses the response frame and parses the required data.
[0032] In this embodiment, the host computer acts as a Modbus master station, which is used to send control instructions and read data. The host computer converts the control instructions through the RS485 circuit, and the RS485 circuit supports the standard Modbus protocol. The control instructions sent by the Modbus field bus are output to the slave computer as serial data information via the RS485 circuit; the slave computer acts as a Modbus slave station, with a built-in RS485 communication interface, which receives the control instructions of the host computer and returns corresponding data or status information. The slave computer is a slave device suitable for multiple Modbus protocols. The host computer performs lower control operations on multiple slave devices. Each slave device is configured with a unique slave device address with a value between 1-247, and the slave device address is used to distinguish different devices.
[0033] Specifically, Figure 2, the lower computer adopts a frequency converter, and the lower computer (frequency converter) is used as a slave station, with a built-in RS485 communication interface, which receives the instructions of the upper computer and returns corresponding data or status information. It is suitable for communication between multiple Modbus protocol devices (frequency converter devices in the present invention) and the upper computer device, and the upper computer can perform lower control operations on multiple slave devices. Each slave device is configured as a unique slave device address with a value between 1-247, which is used to distinguish different devices. When sending a command, the upper computer needs to specify the target slave address and send instructions and other information to the slave of the corresponding address.
[0034] In this embodiment, the hardware connection requirements of the host computer Modbus configuration system are as follows: open the host computer, connect the USB port of the USB to 485 adapter board to the PC, connect the A of the 485 port to the A of the inverter control board, and connect the B of the inverter control board. Install the driver of the USB to 485 adapter board, and then check which port is occupied in the device manager, and select the corresponding port during configuration. Use shielded twisted pair for RS485 connection to reduce signal interference.
[0035] In this embodiment, when the upper computer is initially configured, the factory default configuration of the lower computer can be displayed. The upper computer is connected to the lower computer according to the default configuration. After the upper computer and the lower computer are successfully connected, the upper computer can reconfigure the address, baud rate, timeout time, and timeout retry times of the lower computer. Specifically, when the upper computer is opened for configuration for the first time, the factory default configuration of the inverter control board will be displayed, and the connection will be made according to the default configuration. After the upper computer is successfully connected, Figure 3 We can see that the slave address is 1, the baud rate is 115200, the data frame format is 8 data bits, no parity, 1 stop bit, the writable register base address is 0x0000, and the readable register base address is 0x0064, as shown in Table 1. The parameters are the factory default configurations of the control board. The inverter address, baud rate, timeout time, timeout retry times, etc. can be reconfigured through the host computer. The writable register and read-only register base addresses can also be modified. The corresponding relationship between the register address and the corresponding register under the default setting is shown in the following table. After modifying the base address, it can be calculated by analogy and arranged in order.
[0036] Table 1 Register address and register correspondence table
[0037]
[0038]
[0039] In this embodiment, the user can freely configure the baud rate, check bit, and register base address communication parameters according to actual needs, so that the system can adapt to various complex industrial automation scenarios, ensure effective communication between the host computer and the slave device, and improve the compatibility and flexibility of the system.
[0040] In this embodiment, the Modbus communication module is responsible for implementing the Modbus communication protocol and exchanging data with the host computer; specifically, the host computer constructs and sends a command frame to the slave computer according to the Modbus communication protocol specification, and the command frame includes at least the slave address, function code, data address and data length information, wherein the function code is used to indicate the type of operation performed by the slave computer, and the operation type includes at least reading registers and writing registers. The slave computer performs corresponding operations according to the command frame parsing result, and encapsulates a response frame and returns it to the host computer, and the response frame usually includes at least the slave address, function code, data and check code information; after receiving the response frame from the slave computer, the host computer parses the response frame and parses the required data; the host computer performs CRC check and error processing on the data, and the host computer sends a data frame to read the data of the readable register of the inverter slave station and write the data of the writable register of the slave station, thereby realizing the host computer to read and control the inverter state.
[0041] In this embodiment, the host computer and the slave computer communicate through the RTU message frame of Modbus communication, and the RTU message frame includes an address code, a protocol data unit and a CRC check. The first byte of the RTU message frame represents the address of the slave station. The second byte represents the function of reading register data and writing register data. The CRC check has the low byte in front and the high byte in the back. The data area sent by the host computer includes the base address of the read or write data, the number of read and write registers, and the data content written to the register. The data area content returned to the host computer includes the base address of the read or write data, the number of registers, and the data content read or written to the register.
[0042] Specifically, the format of the Modbus communication RTU data frame is as follows Figure 4 As shown, the RTU message includes the address code, PDU (Protocol Data Unit) and CRC[2] checksum, with the low byte of the CRC checksum in front and the high byte in the back. The first byte represents the address of the slave station. The second byte represents the function of reading register data and writing register data. The function code for reading a single register is 0x03, the function code for writing a single register data is 0x06, and the function code for writing multiple register data is 0x10. The data area sent by the host computer includes the base address of the read or write data, the number of read and write registers, and the data content written to the register. The data area returned to the host computer includes the base address of the read or write data, the number of registers, and the data content read or written to the register.
[0043] When designing the parameter system of the system disclosed in the present invention, all parameters in the communication are read and written using the Modbus protocol, the parameter encoding is the register address, and the parameter value is the register value. For the interconnection parameter, the parameter value is the connector number, which greatly retains the flexibility of free programming, saves resources, and improves the system operation efficiency.
[0044] For example, in Table 2, the parameter coding example is F1-05, where F1 indicates the parameter group and 05 indicates the pointer of the parameter in the F1 group. Data can be read and written by function code number. When the host computer sends 0103F1050001A6 F7, it will receive 01030200023985, where 02 is the value corresponding to the code F105, i.e. the value of the register with register address 105.
[0045] Table 2 Schematic diagram of parameter coding
[0046]
[0047] In this embodiment, the upper computer and the lower computer use interrupt mode and FIFO mode for data transmission. When the amount of data in the buffer reaches a preset threshold, an interrupt signal is generated to notify the CPU to process the data; when data needs to be sent or received, the data is first stored in the buffer, and then the SCI module automatically processes the sending or receiving of the data. Compared with the direct query method, the FIFO mode disclosed in this implementation does not require the CPU to continuously query the status flag. This greatly reduces the CPU's occupancy time and improves communication efficiency. Especially when sending a large amount of data, the FIFO mode can significantly reduce the sending time and increase the data transmission speed. Since the FIFO mode reduces the number of CPU interventions, the overall system overhead can be reduced. It helps to save system resources and improve the stability and reliability of the system. The use of the interrupt mode can achieve real-time data processing and response, further improving the performance and reliability of the system.
[0048] In some preferred embodiments, a configurable multi-slave station variable frequency communication system based on Modbus communication also includes a communication diagnostic module, which is used to monitor the communication status and communication quality of the host computer and the slave computer in real time, and locate and troubleshoot the fault through the diagnostic parameters obtained by the host computer. Specifically, the diagnostic parameters are shown in Table 3, and the diagnostic parameters at least include the drive communication status, the number of received messages, the number of slave station messages, the number of broadcast messages, the number of other messages, the number of normal responses, the number of abnormal responses, and the check error meter, the frame length abnormal count and the port reset time. The communication diagnostic parameters can directly reflect the performance of the communication system. The communication status can be monitored by the above-mentioned diagnostic parameters to ensure the establishment and conduct of communication. In addition, when a fault occurs in the communication system, the communication diagnostic parameters are an important basis for troubleshooting and locating the fault. By analyzing these parameters, the cause and location of the fault can be determined.
[0049] Table 3 Meaning of Modbus communication diagnostic parameters
[0050]
[0051] The present embodiment discloses a configurable multi-slave variable frequency communication system based on Modbus communication, which has the following beneficial effects compared with the prior art:
[0052] 1. High flexibility: The present invention can freely configure communication parameters, such as communication baud rate, inverter slave address, timeout period, timeout retry times, etc., which can be configured according to the needs of application scenarios to meet diverse debugging needs.
[0053] 2. Improve system reliability: The present invention has developed a complete communication diagnostic module that can monitor the communication status and communication quality in real time, which is conducive to rapid fault location and troubleshooting, and improves the reliability and stability of the communication system.
[0054] 3. Save resources, efficient and easy to expand: When constructing the parameter system of the present invention, the host computer, multi-function keyboard, etc. all follow the Modbus protocol to directly perform read and write operations on all parameters. The parameter code is used as the register address, and the parameter value is the register value. The flexibility of free parameter programming is retained, which is more intuitive and easy to expand and maintain, and greatly saves chip resources, improving system operation efficiency and overall performance.
[0055] 4. Improve data transmission speed: When performing data transmission, the present invention adopts interrupt mode and FIFO for data transmission. Compared with the direct query method, the FIFO mode can significantly reduce the sending time, improve the data transmission speed, and reduce the number of CPU interventions. Therefore, it can reduce the overall overhead of the system, and can realize real-time data processing and response, further improving the performance and reliability of the system.
[0056] 5. Centralized control and strong scalability: The host computer, as a centralized control system, can control multiple slave devices, debug and produce more efficiently, and easily add new devices without changing the structure of the entire system.
[0057] The system disclosed in the present invention has been applied to products. Experimental verification shows that the communication function of this communication system is normal and can operate stably and efficiently. There is no frame loss or communication disconnection during operation, and it has high reliability and stability.
[0058] It should be understood that the specific order or hierarchy of steps in the disclosed process is an example of an exemplary method. Based on design preferences, it should be understood that the specific order or hierarchy of steps in the process can be rearranged without departing from the scope of protection of the present disclosure. The attached method claims present the elements of the various steps in an exemplary order and are not intended to be limited to the specific order or hierarchy described.
[0059] In the above detailed description, various features are grouped together in a single embodiment to simplify the disclosure. This method of disclosure should not be interpreted as reflecting an intention that the embodiments of the claimed subject matter require more features than are clearly stated in each claim. On the contrary, as reflected in the appended claims, the invention is in a state of having less than all the features of the disclosed individual embodiments. Therefore, the appended claims are hereby expressly incorporated into the detailed description, with each claim standing on its own as a separate preferred embodiment of the invention.
[0060] Those skilled in the art will also appreciate that the various illustrative logic blocks, modules, circuits, and algorithmic steps described in conjunction with the embodiments herein can all be implemented as electronic hardware, computer software, or a combination thereof. In order to clearly illustrate the interchangeability between hardware and software, various illustrative components, blocks, modules, circuits, and steps are generally described above around their functions. Whether such functions are implemented as hardware or software depends on specific applications and the design constraints imposed on the entire system. A skilled person can implement the described functions in an alternative manner for each specific application, but such implementation decisions should not be interpreted as departing from the scope of protection of the present disclosure.
[0061] The steps of the method or algorithm described in conjunction with the embodiments herein may be directly embodied as hardware, a software module executed by a processor, or a combination thereof. The software module may be located in a RAM memory, a flash memory, a ROM memory, an EPROM memory, an EEPROM memory, a register, a hard disk, a mobile disk, a CD-ROM, or any other form of storage medium well known in the art. An exemplary storage medium is connected to the processor so that the processor can read information from the storage medium and can write information to the storage medium. Of course, the storage medium may also be an integral part of the processor. The processor and the storage medium may be located in an ASIC. The ASIC may be located in a user terminal. Of course, the processor and the storage medium may also be present in a user terminal as discrete components.
[0062] For software implementation, the techniques described in this application can be implemented with modules (e.g., procedures, functions, etc.) that perform the functions described in this application. These software codes can be stored in a memory unit and executed by a processor. The memory unit can be implemented within the processor or outside the processor. In the latter case, it is coupled to the processor in a communication manner via various means, which are well known in the art.
[0063] The above description includes examples of one or more embodiments. Of course, it is impossible to describe all possible combinations of components or methods for the purpose of describing the above embodiments, but it should be recognized by those skilled in the art that the various embodiments may be further combined and arranged. Therefore, the embodiments described herein are intended to cover all such changes, modifications and variations that fall within the scope of protection of the appended claims. In addition, with respect to the term "comprising" used in the specification or claims, the word is covered in a manner similar to the term "including", just as "including," is explained as a transitional word in the claims. In addition, any term "or" used in the specification of the claims is intended to mean "non-exclusive or".
Claims
1. A configurable multi-slave variable frequency communication system based on Modbus communication, characterized in that: include: A host computer, a Modbus communication module and a slave computer; wherein: the host computer and the slave computer communicate with each other through the Modbus communication module, the host computer constructs and sends a command frame to the slave computer according to the Modbus communication protocol specification; after receiving the command frame from the host computer, the slave computer parses the command frame, performs corresponding operations according to the command frame parsing result, and encapsulates a response frame and returns it to the host computer; after receiving the response frame from the slave computer, the host computer parses the response frame and parses the required data.
2. A configurable multi-slave frequency conversion communication system based on Modbus communication as claimed in claim 1, characterized in that: The host computer is used as a Modbus master station to send control instructions and read data. The host computer converts the control instructions through the RS485 circuit. The RS485 circuit supports the standard Modbus protocol. The control instructions sent by the Modbus field bus are output to the slave computer as serial data information via the RS485 circuit; The lower computer acts as a Modbus slave with a built-in RS485 communication interface. It receives control instructions from the upper computer and returns corresponding data or status information. The lower computer is a slave device suitable for multiple Modbus protocols. The upper computer performs lower control operations on multiple slave devices. Each slave device is configured with a unique slave device address with a value between 1 and 247. The slave device address is used to distinguish different devices.
3. A configurable multi-slave station variable frequency communication system based on Modbus communication as claimed in claim 1, characterized in that: When the upper computer is initially configured, the factory default configuration of the lower computer can be displayed. The upper computer is connected to the lower computer according to the default configuration. After the upper computer and the lower computer are successfully connected, the upper computer can reconfigure the address, baud rate, timeout period, and timeout retry times of the lower computer.
4. A configurable multi-slave station variable frequency communication system based on Modbus communication as claimed in claim 1, characterized in that: The upper computer constructs and sends a command frame to the lower computer according to the Modbus communication protocol specification. The command frame includes at least a slave address, a function code, a data address and data length information. The function code is used to indicate the type of operation performed by the lower computer. The operation type includes at least reading a register and writing a register.
5. A configurable multi-slave station variable frequency communication system based on Modbus communication as claimed in claim 1, characterized in that: The lower computer performs corresponding operations according to the parsing results of the command frame, and encapsulates a response frame and returns it to the upper computer. The response frame usually includes at least the slave address, function code, data and check code information; after receiving the response frame from the lower computer, the upper computer parses the response frame and parses the required data; the upper computer performs CRC check and error processing on the data, and the upper computer sends a data frame to read the data of the readable register of the inverter slave station and write the data of the writable register of the slave station, thereby enabling the upper computer to read and control the inverter status.
6. A configurable multi-slave station variable frequency communication system based on Modbus communication as claimed in claim 1, characterized in that: The upper computer and the lower computer communicate through the RTU message frame of Modbus communication. The RTU message frame includes an address code, a protocol data unit and a CRC check. The first byte of the RTU message frame represents the address of the slave station. The second byte represents the functions of reading register data and writing register data. The CRC checksum has the low byte in front and the high byte in the back. The data area sent by the host computer includes the base address of the read or write data, the number of read and write registers, and the data content written to the register. The data area returned to the host computer includes the base address of the read or write data, the number of registers, and the data content read or written to the register.
7. A configurable multi-slave station variable frequency communication system based on Modbus communication as claimed in claim 1, characterized in that: The upper and lower computers use interrupt mode and FIFO mode for data transmission. When the amount of data in the buffer reaches the preset threshold, an interrupt signal is generated to notify the CPU to process the data. When data needs to be sent or received, the data is first stored in the buffer, and then the SCI module automatically handles the sending or receiving of the data.
8. A configurable multi-slave station variable frequency communication system based on Modbus communication as claimed in claim 1, characterized in that: It also includes a communication diagnosis module, which is used to monitor the communication status and communication quality of the upper computer and the lower computer in real time, and locate and troubleshoot faults through diagnostic parameters obtained by the upper computer.
9. A configurable multi-slave station variable frequency communication system based on Modbus communication as claimed in claim 8, characterized in that: The diagnostic parameters include at least the drive communication status, the number of received messages, the number of slave station messages, the number of broadcast messages, the number of other messages, the number of normal responses, the number of abnormal responses, the sum check error count, the frame length abnormal count and the port reset time.
Citation Information
Cited By
Software and hardware combined data interaction method and system based on Modbus communication component
CN120723695A
Reading method for extended display identifier, electronic equipment and storage medium
CN120780262A
Communication method and system based on J-Link, electronic equipment and storage medium
CN120909814A
J-Link-based communication methods, systems, electronic devices, and storage media
CN120909814B