Signal transmission method and device of IO module, computer device and storage medium
Patent Information
- Application Number
- CN202610919728.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-24
- Publication Date
- 2026-10-30
AI Technical Summary
[0006]本申请实施例的目的在于提出一种IO模块的信号传输方法、装置、计算机设备及存储介质,以解决IO端子台与多个分散接线盒并联时,因接线顺序错乱导致信号错误的技术问题
本申请公开的IO模块的信号传输方法,通过预设的读取时间片轮询各个接线盒,能够形成接线盒对应的目标身份标识序列,减少多接线盒同时反馈产生的信号干扰。接着依据目标身份标识序列可以确定接线端口与接线盒之间的当前映射关系,直观反映现场接线的实际布局。然后获取接线端口与接线盒之间的标准映射关系,能够为接线关系的校正提供固定的参照标准。最后依据标准映射关系调整当前映射关系,可以修正接线顺序错乱引发的映射偏差。形成的目标映射关系能够让接线端口与接线盒正常进行信号传输,避免接线顺序错乱导致信号传输出现错误。
Smart Images

Figure CN123020262A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of industrial control technology, and in particular to a signal transmission method, apparatus, computer equipment, and storage medium for an I / O module. Background Technology
[0002] With the rapid development of industrial automation and intelligent manufacturing technologies, automated production lines such as semiconductor equipment, lithium battery production lines, and intelligent warehousing generally adopt a distributed IO control architecture that connects remote input / output (IO) terminal blocks and multiple distributed junction boxes in parallel to meet the needs of multi-point, distributed signal acquisition and control of equipment. The convenience of on-site wiring and the stability of signal transmission have become industry requirements.
[0003] The current remote I / O terminal block is pre-configured with a fixed mapping relationship between physical ports and junction boxes. On-site construction personnel complete the junction box connection according to the preset sequence, identify the junction box through hardware identification, and then realize signal distribution and transmission. This solution can meet the basic distributed I / O control functions.
[0004] However, manual wiring on-site is prone to errors in the connection sequence of junction boxes, leading to incorrect signal attribution and equipment malfunction. It also results in difficulties in on-site debugging, low maintenance efficiency, and frequent equipment downtime.
[0005] In view of the above, this application is hereby submitted. Summary of the Invention
[0006] The purpose of this application is to provide a signal transmission method, apparatus, computer device, and storage medium for an I / O module, so as to solve the technical problem of signal errors caused by incorrect wiring sequence when I / O terminal blocks are connected in parallel with multiple distributed junction boxes.
[0007] To address the aforementioned technical problems, this application provides a signal transmission method for an I / O module, employing the technical solution described below. The I / O module includes multiple wiring ports, with each wiring port connected to a junction box, comprising: According to the preset reading time slice, each of the junction boxes is polled to obtain the target identity sequence composed of all the junction boxes; Based on the target identity sequence, determine the current mapping relationship between each of the wiring ports and each of the junction boxes; Obtain the standard mapping relationship between each of the wiring ports and each of the junction boxes; Based on multiple standard mapping relationships, the current mapping relationship is adjusted to obtain a target mapping relationship, so that the wiring port can transmit signals with the junction box based on the target mapping relationship.
[0008] Furthermore, the step of polling each of the junction boxes according to a preset reading time slice to obtain a target identity sequence composed of all the junction boxes includes: Obtain the port number of each of the wiring ports, allocate the reading time slice to each of the wiring ports according to the port number, and control each of the wiring ports to send reading instructions to each of the junction boxes in the order in which each of the wiring ports receives the reading time slice; Receive feedback information returned by each of the junction boxes based on the read command, and extract the identity identifier of each junction box from the feedback information; The target identity sequence is generated based on the identity identifier of each junction box.
[0009] Furthermore, generating the target identity sequence based on the identity identifiers of each of the junction boxes includes: The identification identifiers of each junction box are sorted to obtain an initial identification identifier sequence; The initial identity sequence is detected to obtain detection results, which include identity anomalies and identity normalities. Based on the detection results, the initial identity sequence is updated to obtain the target identity sequence.
[0010] Furthermore, the step of detecting the initial identity sequence to obtain the detection result includes: If any one of the junction box identifiers in the initial identifier sequence does not meet the preset conditions, then the detection result is determined to be that the identifier is abnormal; If all the junction box identifiers in the initial identifier sequence meet the preset conditions, then the detection result is determined to be that the identifier is normal.
[0011] Furthermore, updating the initial identity sequence based on the detection result to obtain the target identity sequence includes: When the detection result indicates that the identity identifier is normal, the initial identity identifier sequence is determined as the target identity identifier sequence; When the detection result indicates that the identity identifier is abnormal, the junction box corresponding to the abnormal identity identifier is identified, a preset temporary identity identifier is assigned to the junction box corresponding to the abnormal identity identifier, and the initial identity identifier sequence is updated according to the temporary identity identifier to obtain the target identity identifier sequence.
[0012] Furthermore, adjusting the current mapping relationship based on multiple standard mapping relationships to obtain the target mapping relationship includes: Based on multiple standard mapping relationships, determine whether the current mapping relationship is an abnormal mapping relationship; If the current mapping relationship is the abnormal mapping relationship, then the abnormal junction box is determined according to the abnormal mapping relationship, and the target wiring port corresponding to the abnormal junction box is determined according to the standard mapping relationship corresponding to the abnormal junction box. Based on the target wiring port corresponding to the abnormal junction box, the abnormal mapping relationship is adjusted to obtain the target mapping relationship.
[0013] Furthermore, after adjusting the current mapping relationship according to multiple standard mapping relationships to obtain a target mapping relationship, so that the wiring port can transmit signals with the junction box based on the target mapping relationship, the method further includes: Monitor the level signal of each of the wiring ports, and determine whether each of the wiring ports and each of the junction boxes is in a disconnected state based on the level signal; If either the connection port or the junction box is in the disconnected state, the target mapping relationship between the connection port and the junction box in the disconnected state will be adjusted to a preset standard mapping relationship.
[0014] To address the aforementioned technical problems, this application also provides a signal transmission device for an I / O module, employing the following technical solution: A signal transmission device for an I / O module, the I / O module including multiple wiring ports, one of the wiring ports connecting to a junction box including: The polling module is used to poll each of the junction boxes according to a preset reading time slice to obtain a target identity sequence composed of all the junction boxes; The determining module is used to determine the current mapping relationship between each of the wiring ports and each of the junction boxes based on the target identity sequence; The acquisition module is used to acquire the standard mapping relationship between each of the wiring ports and each of the junction boxes; The adjustment module is used to adjust the current mapping relationship according to multiple standard mapping relationships to obtain a target mapping relationship, so that the wiring port can transmit signals with the junction box based on the target mapping relationship.
[0015] To address the aforementioned technical problems, this application also provides a computer device that employs the following technical solution: A computer device includes a memory and a processor, wherein the memory stores computer-readable instructions, and the processor executes the computer-readable instructions to implement the steps of the signal transmission method of the I / O module as described above.
[0016] To address the aforementioned technical problems, this application also provides a computer-readable storage medium, employing the technical solution described below: A computer-readable storage medium storing computer-readable instructions, which, when executed by a processor, implement the steps of the signal transmission method of the I / O module as described above.
[0017] Compared with the prior art, this application has the following main advantages: The signal transmission method for the IO module disclosed in this application polls each junction box using a preset reading time slice, forming a target identification sequence corresponding to each junction box and reducing signal interference caused by simultaneous feedback from multiple junction boxes. Then, based on the target identification sequence, the current mapping relationship between the wiring port and the junction box can be determined, intuitively reflecting the actual layout of the wiring on site. Next, a standard mapping relationship between the wiring port and the junction box is obtained, providing a fixed reference standard for correcting the wiring relationship. Finally, the current mapping relationship is adjusted based on the standard mapping relationship, correcting mapping deviations caused by incorrect wiring sequence. The formed target mapping relationship allows the wiring port and junction box to transmit signals normally, avoiding signal transmission errors caused by incorrect wiring sequence. Attached Figure Description
[0018] To more clearly illustrate the solutions in this application, the accompanying drawings used in the description of the embodiments of this application will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0019] Figure 1 This is an exemplary system architecture diagram to which this application can be applied; Figure 2 This is a flowchart of an embodiment of the signal transmission method of the IO module according to this application; Figure 3 This is a schematic diagram of a structure of an embodiment of the signal transmission device of the IO module according to this application; Figure 4 This is a schematic diagram of the structure of one embodiment of the computer device according to this application. Detailed Implementation
[0020] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application pertains; the terminology used herein in the specification of the application is for the purpose of describing particular embodiments only and is not intended to be limiting of the application; the terms "comprising" and "having," and any variations thereof, in the specification, claims, and foregoing drawings of this application are intended to cover non-exclusive inclusion. The terms "first," "second," etc., in the specification, claims, or foregoing drawings of this application are used to distinguish different objects, not to describe a particular order.
[0021] In this document, the term "embodiment" means that a particular feature, structure, or characteristic described in connection with an embodiment may be included in at least one embodiment of this application. The appearance of this phrase in various places throughout the specification does not necessarily refer to the same embodiment, nor is it a mutually exclusive, independent, or alternative embodiment. It will be explicitly and implicitly understood by those skilled in the art that the embodiments described herein can be combined with other embodiments.
[0022] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings.
[0023] like Figure 1 As shown, the system architecture 100 may include a first terminal device 101, a second terminal device 102, a third terminal device 103, a network 104, and a server 105. The network 104 serves as a medium for providing communication links between the first terminal device 101, the second terminal device 102, the third terminal device 103, and the server 105. The network 104 may include various connection types, such as wired or wireless communication links, or fiber optic cables, etc.
[0024] Users can use the first terminal device 101, the second terminal device 102, and the third terminal device 103 to interact with the server 105 via the network 104 to receive or send messages, etc. Various communication client applications can be installed on the first terminal device 101, the second terminal device 102, and the third terminal device 103, such as web browser applications, shopping applications, search applications, instant messaging tools, email clients, social platform software, etc.
[0025] The first terminal device 101, the second terminal device 102, and the third terminal device 103 can be various electronic devices with displays and support web browsing, including but not limited to smartphones, tablets, e-book readers, MP3 (Moving Picture Experts Group Audio Layer Ⅲ) players, MP4 (Moving Picture Experts Group Audio Layer IV) players, laptops, and desktop computers, etc.
[0026] Server 105 can be a server that provides various services, such as a backend server that supports the pages displayed on the first terminal device 101, the second terminal device 102, and the third terminal device 103.
[0027] It should be noted that the signal transmission method of the IO module provided in this application embodiment is generally executed by the terminal device, and correspondingly, the signal transmission device of the IO module is generally located in the terminal device.
[0028] It should be understood that Figure 1 The number of terminal devices, networks, and servers shown is merely illustrative. Depending on implementation needs, any number of terminal devices, networks, and servers can be included.
[0029] Continue to refer to Figure 2 The diagram illustrates a flowchart of an embodiment of a signal transmission method for an I / O module according to this application. The signal transmission method for the I / O module includes the following steps: Step S201: According to the preset reading time slice, each of the junction boxes is polled to obtain the target identity sequence composed of all the junction boxes.
[0030] In this embodiment, the signal transmission method of the IO module operates on an electronic device (e.g., Figure 1 The terminal device shown can send or receive data via wired or wireless connection. It should be noted that the aforementioned wireless connection methods may include, but are not limited to, 3G / 4G / 5G connections, Wi-Fi connections, Bluetooth connections, WiMAX connections, Zigbee connections, UWB (ultra-wide band) connections, and other currently known or future wireless connection methods.
[0031] In this embodiment, the reading time slice refers to the time period during which each junction box of the remote IO terminal block is allocated an independent identity identifier for reading. Each time slice is allocated a uniform fixed duration (which can be 5ms or 10ms), and the duration is sufficient for only one identity identifier (ID) reading and feedback. This avoids communication collisions caused by multiple junction boxes simultaneously feeding back signals, ensuring the stability and uniqueness of identity reading. A junction box refers to a passive extension unit of the remote IO terminal block, carrying identity identifier information, used for nearby connection to industrial sensors to achieve distributed wiring at various points. The target identity identifier sequence refers to the ordered set of all online junction box identity identifiers collected by the terminal block after polling.
[0032] Specifically, the 32-point remote I / O terminal block is installed at the center of the equipment motion control platform. Depending on the type of field sensors, three-wire or two-wire junction boxes are placed near the sensors and at the end of the equipment. The sensor signal and power lines are directly connected to the nearest junction box, eliminating the need for long-distance single-wire cabling. Multi-core cables are used to connect all junction boxes to the terminals of the 32-point remote I / O terminal block, with all junction boxes serving as passive I / O extension units for the terminal block. The remote I / O terminal block allocates an independent and equal-length read time slice to each physical terminal based on its hardware number. These time slices are arranged sequentially by port, without overlap, and an ordered polling read is performed on all junction boxes, ultimately obtaining an initial identity sequence composed of all junction box identifiers. This initial identity sequence is then checked for completeness and validity, and the results are used to update the initial sequence, ultimately yielding a stable and valid target identity sequence.
[0033] Step S202: Determine the current mapping relationship between each of the wiring ports and each of the junction boxes based on the target identity sequence.
[0034] In this embodiment, the current mapping relationship refers to the binding relationship between each physical connection port of the remote IO terminal block and the actual junction box connected to that port on site. The identity identifiers in the target identity identifier sequence are matched sequentially with the connection ports of the same sequence number. The first identity identifier in the sequence corresponds to connection port number one, the second identity identifier corresponds to connection port number two, and so on, completing the matching of all ports and identity identifiers. The resulting port-to-junction box correspondence is the current mapping relationship determined in this process. For example, if the target identity identifier sequence is junction box b, junction box d, junction box c, and junction box a, according to the above matching method, connection port 1 corresponds to junction box b, connection port 2 corresponds to junction box d, connection port 3 corresponds to junction box c, and connection port 4 corresponds to junction box a, ultimately obtaining the complete current mapping relationship.
[0035] Step S203: Obtain the standard mapping relationship between each of the wiring ports and each of the junction boxes.
[0036] In this embodiment, the standard mapping relationship refers to the ideal correspondence between physical connection ports and standard junction box identifiers pre-configured by the remote I / O terminal block before system initialization. For example, the preset standard mapping relationship is as follows: connection port 1 corresponds to junction box a, connection port 2 corresponds to junction box b, connection port 3 corresponds to junction box c, and connection port 4 corresponds to junction box d. This set of correspondences is the recognized correct wiring standard. Under normal wiring conditions, signals will be transmitted between the connection ports and junction boxes based on the standard mapping relationship.
[0037] Step S204: Adjust the current mapping relationship according to the multiple standard mapping relationships to obtain a target mapping relationship, so that the wiring port can transmit signals with the junction box based on the target mapping relationship.
[0038] In this embodiment, the connection ports with the same number in the standard mapping relationship and the current mapping relationship are used as the basis for comparison, and the identification of the junction box corresponding to each port is matched one by one. By comparing and identifying the corresponding deviations in the current mapping relationship, abnormal mapping relationships and corresponding abnormal junction boxes are located. Then, based on the standard mapping relationship, the target connection port corresponding to each abnormal junction box is determined, and the correspondence relationship of the abnormal mapping relationship is adjusted accordingly. The part of the current mapping relationship that is consistent with the standard mapping relationship is retained, and the abnormal part is replaced with the correct relationship corresponding to the standard, and finally a target mapping relationship without deviation is formed. Based on this target mapping relationship, the remote IO terminal block clearly identifies the junction box corresponding to each connection port, thereby realizing normal signal transmission between the connection port and the junction box and avoiding signal error problems caused by incorrect wiring sequence.
[0039] This application polls each junction box using a preset reading time slice, forming a target identification sequence for each junction box and reducing signal interference caused by simultaneous feedback from multiple junction boxes. Then, based on the target identification sequence, the current mapping relationship between the wiring port and the junction box can be determined, intuitively reflecting the actual layout of the wiring on site. Next, the standard mapping relationship between the wiring port and the junction box is obtained, providing a fixed reference standard for correcting wiring relationships. Finally, the current mapping relationship is adjusted based on the standard mapping relationship, correcting mapping deviations caused by incorrect wiring sequence. The formed target mapping relationship allows the wiring port and junction box to transmit signals normally, avoiding signal transmission errors caused by incorrect wiring sequence.
[0040] In some optional implementations of this embodiment, the step of polling each of the junction boxes according to a preset reading time slice to obtain the target identity sequence composed of all the junction boxes includes: Obtain the port number of each of the wiring ports, allocate the reading time slice to each of the wiring ports according to the port number, and control each of the wiring ports to send reading instructions to each of the junction boxes in the order in which each of the wiring ports receives the reading time slice; Receive feedback information returned by each of the junction boxes based on the read command, and extract the identity identifier of each junction box from the feedback information; The target identity sequence is generated based on the identity identifier of each junction box.
[0041] In this embodiment, the port number of each connection port is a unique serial number assigned to each physical connection port by the remote IO terminal block, used to distinguish different connection ports. The identification identifier of the connection box is the unique identification information of the connection box, used to distinguish different connection boxes. Specifically, the terminal block allocates independent and non-overlapping read time slices to each connection port based on the order of the port numbers. The time slices are arranged sequentially according to the port number order. The terminal block sends a read command to the connection box connected to the connection port corresponding to the current time slice within the time period corresponding to the allocated read time slice. After receiving the read command sent by the terminal block within its corresponding read time slice, the connection box generates and returns feedback information to the terminal block according to a preset communication format. The terminal block parses the received feedback information, filters and extracts the identification data specifically used to identify the connection box from the fixed fields of the feedback information, and obtains the identification identifier corresponding to the connection box.
[0042] This application assigns independent reading time slices to each wiring port by port numbering, which avoids signal interference caused by simultaneous feedback from multiple junction boxes. By issuing reading commands and receiving feedback information according to the time slice sequence, stable information exchange between the terminal block and the junction box can be achieved. Extracting identification identifiers and generating sequences from the feedback information provides complete data support for subsequently determining the mapping relationship between the wiring ports and junction boxes.
[0043] In some optional implementations of this embodiment, the step of generating the target identity sequence based on the identity identifiers of each junction box includes: The identification identifiers of each junction box are sorted to obtain an initial identification identifier sequence; The initial identity sequence is detected to obtain detection results, which include identity anomalies and identity normalities. Based on the detection results, the initial identity sequence is updated to obtain the target identity sequence.
[0044] In this embodiment, the terminal block first arranges all extracted junction box identifiers sequentially according to a preset order to form an initial identifier sequence. This preset order can be ascending order based on the physical number of the junction port or the chronological order of the read time slices. The terminal block then performs status checks on all identifiers within the initial identifier sequence to determine if any identifiers are abnormal, obtaining a detection result indicating whether the identifiers are normal or abnormal. Abnormal identifiers may include: multiple junction boxes having identical identifiers (identifier duplication); some junction ports not reporting valid identifiers (identifier missing); incorrect identifier formats from the junction boxes, preventing proper system recognition; or identifier content not matching the system's preset legal encoding range. The terminal block then processes the initial sequence based on the detection results. If the detection result is normal, the initial sequence content is directly used; if the detection result is abnormal, the abnormal identifiers in the sequence are corrected. After sequence optimization, the target identifier sequence is obtained.
[0045] This application sorts the identifiers of the junction boxes to form a regular initial identifier sequence, providing an ordered data foundation for subsequent testing. Performing state checks on the initial sequence can promptly identify any anomalies in the identifiers. Updating the sequence based on the check results can correct these anomalies, ensuring that the generated target identifier sequence meets the usage requirements and guaranteeing the stable progress of subsequent processes.
[0046] In some optional implementations of this embodiment, the step of detecting the initial identity sequence and obtaining the detection result includes: If any one of the junction box identifiers in the initial identifier sequence does not meet the preset conditions, then the detection result is determined to be that the identifier is abnormal; If all the junction box identifiers in the initial identifier sequence meet the preset conditions, then the detection result is determined to be that the identifier is normal.
[0047] In this embodiment, the detection results include abnormal and normal identification identifiers. Abnormal identification identifiers include at least duplicate identifiers, missing identifiers, incorrect identifier formats, and identifiers exceeding a preset valid encoding range. Specifically, the preset condition for duplicate identifiers is that each junction box's identifier is unique in the sequence and appears only once. If an identifier appears more than once in the sequence, it is determined to be an abnormal type of duplicate identifier. The preset condition for missing identifiers is that each junction port returns a valid identifier, and there are no gaps in the sequence. If a junction port returns a gap, it is determined to be an abnormal type of missing identifier. The preset condition for incorrect identifier formats is that the identifier's encoding format completely matches the system's preset parsing format. If there is a mismatch in encoding formats, it is determined to be an abnormal type of incorrect identifier format. If all the junction box identifiers in the initial identifier sequence meet the above preset conditions, the detection result is determined to be that the identification identifier is normal.
[0048] This application detects identity identifiers by setting multiple preset conditions, which can comprehensively identify various anomalies in the sequence and clearly distinguish between normal and abnormal states of identity identifiers. This detection method can intuitively reflect the data quality of the sequence, providing a clear basis for judgment in subsequent sequence update operations and avoiding the impact of identifier issues on the progress of subsequent related processes.
[0049] In some optional implementations of this embodiment, the step of updating the initial identity sequence based on the detection result to obtain the target identity sequence includes: When the detection result indicates that the identity identifier is normal, the initial identity identifier sequence is determined as the target identity identifier sequence; When the detection result indicates that the identity identifier is abnormal, the junction box corresponding to the abnormal identity identifier is identified, a preset temporary identity identifier is assigned to the junction box corresponding to the abnormal identity identifier, and the initial identity identifier sequence is updated according to the temporary identity identifier to obtain the target identity identifier sequence.
[0050] In this embodiment, the temporary identity identifier is a pre-configured backup identifier used to replace any abnormal identifiers in the initial identity identifier sequence, ensuring the integrity and usability of the sequence content. If the result is that the identity identifier is normal, the initial identity identifier sequence is directly determined as the target identity identifier sequence. If the result is that the identity identifier is abnormal, the terminal block first identifies the junction box corresponding to the abnormal identity identifier, assigns a preset temporary identity identifier to the junction box, and then uses the temporary identity identifier to replace the abnormal identity identifier in the initial sequence. After completing the sequence update, the target identity identifier sequence is obtained. For example, if there are abnormalities such as duplicate, missing, or incorrectly formatted identifiers in the initial identity identifier sequence, the terminal block locates the corresponding junction box and assigns a temporary identity identifier, replacing the abnormal content to form the target identity identifier sequence. If the sequence is normal, the initial sequence is directly used.
[0051] This application updates the initial identity sequence based on the detection results, allowing for flexible adjustment of the sequence content according to actual conditions. When the identifier is anomaly-free, directly determining the target sequence simplifies the processing flow. When anomalies exist, replacing the temporary identity identifier eliminates the abnormal content in the sequence, ensuring the generated target sequence remains intact and valid, thus avoiding impact on subsequent mapping relationship determination.
[0052] In some optional implementations of this embodiment, the step of adjusting the current mapping relationship according to multiple standard mapping relationships to obtain the target mapping relationship includes: Based on multiple standard mapping relationships, determine whether the current mapping relationship is an abnormal mapping relationship; If the current mapping relationship is the abnormal mapping relationship, then the abnormal junction box is determined according to the abnormal mapping relationship, and the target wiring port corresponding to the abnormal junction box is determined according to the standard mapping relationship corresponding to the abnormal junction box. Based on the target wiring port corresponding to the abnormal junction box, the abnormal mapping relationship is adjusted to obtain the target mapping relationship.
[0053] In this embodiment, misconnection of junction boxes and junction ports is prone to occur during actual wiring. The terminal block obtains the current mapping relationship formed by the actual wiring on site by reading instructions. This relationship is not a preset standard mapping relationship and cannot be directly matched according to the standard mapping relationship. Therefore, it is necessary to first compare and identify the anomaly, and then adjust and correct it. Here, the standard mapping relationship refers to the preset one-to-one mapping relationship between each junction port and each junction box. That is, junction port 1 corresponds to junction box a, which is a standard mapping relationship. Multiple standard mapping relationships refer to the unique standard mapping relationship between multiple junction ports and their respective junction boxes. Specifically, the terminal block compares the current mapping relationship with multiple preset standard mapping relationships one by one, identifies the ports where the corresponding combination of junction port and junction box is inconsistent, determines the mapping relationship between the junction port and the connected junction box as an abnormal mapping relationship, locates the corresponding abnormal junction box based on the abnormal mapping relationship, and then queries the standard mapping relationship to determine the target junction port corresponding to each abnormal junction box. The terminal block first locates the configuration item corresponding to the abnormal mapping relationship, deletes the current incorrect port binding relationship with the junction box identity, and then re-establishes the binding relationship between the target wiring port corresponding to the abnormal junction box in the standard mapping relationship and the junction box identity. Simultaneously, it updates the internal mapping configuration table to ultimately form the correct target mapping relationship. For example, the standard mapping relationship is: wiring port 1 corresponds to junction box a, port 2 corresponds to junction box b, port 3 corresponds to junction box c, and port 4 corresponds to junction box d. If a field worker makes a wiring error, the terminal block will actually collect the current mapping relationship as: port 1 corresponds to junction box b, port 2 corresponds to junction box d, port 3 corresponds to junction box c, and port 4 corresponds to junction box a. After comparison, the terminal block determines that the binding relationship of ports 1, 2, and 4 is abnormal. It then queries the standard mapping to determine the correct ports for each junction box, modifies the incorrect binding item in the mapping configuration table within the system, correcting it to the correct relationship corresponding to the standard. The target mapping relationship can be obtained without modifying the physical wiring on site.
[0054] This application, by comparing the standard mapping relationship with the current mapping relationship, can quickly identify abnormal wiring correspondences and locate the abnormal junction box and its corresponding correct port. Adjustments can be made by modifying the mapping configuration table within the system, without altering the physical wiring on site. This quickly corrects wiring errors and restores the correct correspondence between ports and junction boxes.
[0055] In some optional implementations of this embodiment, after the step of adjusting the current mapping relationship according to multiple standard mapping relationships to obtain a target mapping relationship, so that the wiring port can transmit signals with the junction box based on the target mapping relationship, the method further includes: Monitor the level signal of each of the wiring ports, and determine whether each of the wiring ports and each of the junction boxes is in a disconnected state based on the level signal; If either the connection port or the junction box is in the disconnected state, the target mapping relationship between the connection port and the junction box in the disconnected state will be adjusted to a preset standard mapping relationship.
[0056] In this embodiment, the voltage level signal reflects the physical connection status between the wiring port and the junction box. Based on a pre-set stable reference voltage level range under the connection status, it determines whether each wiring port and each junction box is in a disconnected state. The terminal block continuously collects the real-time voltage level signal of each wiring port and compares the real-time voltage level with the preset reference voltage level. If the real-time voltage level is stable within the preset reference voltage level, it is determined to be a normal connection. If the real-time voltage level is lower than the preset reference voltage level, it is determined that the wiring port and the corresponding junction box are in a disconnected state. The preset reference voltage level can be DC 5V, and the corresponding stable reference range can be in the range of [4.5, 5.5]. Exceeding the reference range means that the real-time voltage level is less than 4.5V. If a wiring port and junction box are detected to be in a disconnected state, the terminal block readjusts the target mapping relationship between this set of disconnected ports and junction boxes to the preset standard mapping relationship. After the line is disconnected, the original mapping relationship will lose its practical function. Restoring it to the standard mapping relationship allows the wiring port and junction box to be matched directly according to the preset correct mapping relationship when the line is subsequently reconnected.
[0057] This application can promptly determine the connection status between the port and the junction box by monitoring the level signal of the wiring port. If a disconnection is detected, the corresponding mapping relationship will be restored to the standard mapping relationship. When the line is reconnected, the two can be correctly matched to avoid the mapping relationship from becoming chaotic and ensure that subsequent signal transmission can proceed smoothly.
[0058] The embodiments of this application can acquire and process relevant data based on artificial intelligence technology. Artificial intelligence (AI) refers to the theories, methods, technologies, and application systems that use digital computers or machines controlled by digital computers to simulate, extend, and expand human intelligence, perceive the environment, acquire knowledge, and use that knowledge to obtain optimal results.
[0059] Foundational technologies for artificial intelligence generally include sensors, dedicated AI chips, cloud computing, distributed storage, big data processing, operating / interactive systems, and mechatronics. AI software technologies mainly encompass computer vision, robotics, biometrics, speech processing, natural language processing, and machine learning / deep learning.
[0060] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by instructing related hardware through computer-readable instructions. These computer-readable instructions can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above methods. The aforementioned storage medium can be a non-volatile storage medium such as a magnetic disk, optical disk, or read-only memory (ROM), or random access memory (RAM).
[0061] It should be understood that although the steps in the flowcharts of the accompanying figures are shown sequentially as indicated by the arrows, these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least some steps in the flowcharts of the accompanying figures may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily completed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be performed alternately or in turn with other steps or at least some of the sub-steps or stages of other steps.
[0062] Further reference Figure 3 As a response to the above Figure 2 The implementation of the method shown in this application provides an embodiment of a signal transmission device for an I / O module, which is similar to... Figure 2 Corresponding to the method embodiments shown, this device can be specifically applied to various electronic devices.
[0063] like Figure 3 As shown, the signal transmission device 300 of the IO module in this embodiment includes: a polling module 301, a determining module 302, an acquiring module 303, and an adjusting module 304. Wherein: The polling module 301 is used to poll each of the junction boxes according to a preset reading time slice to obtain a target identity sequence composed of all the junction boxes; The determining module 302 is used to determine the current mapping relationship between each of the wiring ports and each of the junction boxes based on the target identity sequence; The acquisition module 303 is used to acquire the standard mapping relationship between each of the wiring ports and each of the junction boxes; The adjustment module 304 is used to adjust the current mapping relationship according to multiple standard mapping relationships to obtain a target mapping relationship, so that the wiring port can transmit signals with the junction box based on the target mapping relationship.
[0064] The signal transmission device of the IO module provided in this application polls each junction box through a preset reading time slice, forming a target identification sequence corresponding to the junction box, reducing signal interference caused by simultaneous feedback from multiple junction boxes. Then, based on the target identification sequence, the current mapping relationship between the wiring port and the junction box can be determined, intuitively reflecting the actual layout of the wiring on site. Next, the standard mapping relationship between the wiring port and the junction box is obtained, providing a fixed reference standard for correcting the wiring relationship. Finally, the current mapping relationship is adjusted based on the standard mapping relationship, correcting mapping deviations caused by incorrect wiring sequence. The formed target mapping relationship allows the wiring port and junction box to transmit signals normally, avoiding signal transmission errors caused by incorrect wiring sequence.
[0065] In some optional implementations of this embodiment, the polling module 301 is further configured to: Obtain the port number of each of the wiring ports, allocate the reading time slice to each of the wiring ports according to the port number, and control each of the wiring ports to send reading instructions to each of the junction boxes in the order in which each of the wiring ports receives the reading time slice; Receive feedback information returned by each of the junction boxes based on the read command, and extract the identity identifier of each junction box from the feedback information; The target identity sequence is generated based on the identity identifier of each junction box.
[0066] The signal transmission device for the IO module provided in this application allocates independent reading time slices to each wiring port through port numbering, which can avoid signal interference caused by simultaneous feedback from multiple junction boxes. By issuing reading commands and receiving feedback information according to the time slice sequence, information exchange between the terminal block and the junction box can be stably completed. Extracting identification identifiers and generating sequences from the feedback information provides complete data support for subsequently determining the mapping relationship between the wiring ports and junction boxes.
[0067] In some optional implementations of this embodiment, the polling module 301 is further configured to: The identification identifiers of each junction box are sorted to obtain an initial identification identifier sequence; The initial identity sequence is detected to obtain detection results, which include identity anomalies and identity normalities. Based on the detection results, the initial identity sequence is updated to obtain the target identity sequence.
[0068] The signal transmission device for the IO module provided in this application can form a regular initial identifier sequence by sorting the identifiers of the junction box, providing an orderly data foundation for subsequent detection work. Performing status detection on the initial sequence can promptly identify any anomalies in the identifiers, and updating the sequence based on the detection results can correct these anomalies, ensuring that the generated target identifier sequence meets the usage conditions and guaranteeing the stable progress of subsequent processes.
[0069] In some optional implementations of this embodiment, the polling module 301 is further configured to: If any one of the junction box identifiers in the initial identifier sequence does not meet the preset conditions, then the detection result is determined to be that the identifier is abnormal; If all the junction box identifiers in the initial identifier sequence meet the preset conditions, then the detection result is determined to be that the identifier is normal.
[0070] The signal transmission device of the IO module provided in this application can detect identity identifiers by setting multiple preset conditions, comprehensively identifying various abnormal situations in the sequence and clearly distinguishing between normal and abnormal states of identity identifiers. This detection method can intuitively reflect the data quality of the sequence, providing a clear basis for judgment for subsequent sequence update operations and avoiding the impact of identifier problems on the progress of subsequent related processes.
[0071] In some optional implementations of this embodiment, the polling module 301 is further configured to: When the detection result indicates that the identity identifier is normal, the initial identity identifier sequence is determined as the target identity identifier sequence; When the detection result indicates that the identity identifier is abnormal, the junction box corresponding to the abnormal identity identifier is identified, a preset temporary identity identifier is assigned to the junction box corresponding to the abnormal identity identifier, and the initial identity identifier sequence is updated according to the temporary identity identifier to obtain the target identity identifier sequence.
[0072] The signal transmission device of the IO module provided in this application can flexibly adjust the sequence content according to the actual situation by updating the initial identity sequence based on the detection results. When there is no abnormality in the identifier, the target sequence can be directly determined, which simplifies the processing flow. When there is an abnormality in the identifier, the abnormal content in the sequence can be eliminated by replacing the temporary identity, so that the generated target sequence remains complete and valid, and avoids affecting the determination of subsequent mapping relationships.
[0073] In some optional implementations of this embodiment, the adjustment module 304 is further configured to: Based on multiple standard mapping relationships, determine whether the current mapping relationship is an abnormal mapping relationship; If the current mapping relationship is the abnormal mapping relationship, then the abnormal junction box is determined according to the abnormal mapping relationship, and the target wiring port corresponding to the abnormal junction box is determined according to the standard mapping relationship corresponding to the abnormal junction box. Based on the target wiring port corresponding to the abnormal junction box, the abnormal mapping relationship is adjusted to obtain the target mapping relationship.
[0074] The signal transmission device for the IO module provided in this application can quickly identify abnormal wiring correspondences by comparing the standard mapping relationship with the current mapping relationship, and locate the abnormal junction box and its corresponding correct port. Adjustments can be made by modifying the mapping configuration table within the system, without altering the physical wiring on site. This allows for rapid correction of wiring errors and restores the correct correspondence between ports and junction boxes.
[0075] In some optional implementations of this embodiment, the adjustment module 304 is further configured to: Monitor the level signal of each of the wiring ports, and determine whether each of the wiring ports and each of the junction boxes is in a disconnected state based on the level signal; If either the connection port or the junction box is in the disconnected state, the target mapping relationship between the connection port and the junction box in the disconnected state will be adjusted to a preset standard mapping relationship.
[0076] The signal transmission device of the IO module provided in this application can promptly determine the connection status between the port and the junction box by monitoring the level signal of the wiring port. After detecting a disconnection, it restores the corresponding mapping relationship to the standard mapping relationship, so that the two can be correctly matched when the line is reconnected, avoiding the mapping relationship from becoming chaotic and ensuring that subsequent signal transmission can proceed smoothly.
[0077] To address the aforementioned technical problems, embodiments of this application also provide a computer device. Please refer to [link / reference needed]. Figure 4 , Figure 4 This is a basic structural block diagram of the computer device in this embodiment.
[0078] The computer device 4 includes a memory 41, a processor 42, and a network interface 43 that are interconnected via a system bus. It should be noted that only the computer device 4 with components 41, 42, and 43 is shown in the figure; however, it should be understood that it is not required to implement all the shown components, and more or fewer components can be implemented alternatively. Those skilled in the art will understand that the computer device described here is a device capable of automatically performing numerical calculations and / or information processing according to pre-set or stored instructions, and its hardware includes, but is not limited to, microprocessors, application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), digital signal processors (DSPs), embedded devices, etc.
[0079] The computer device can be a desktop computer, laptop, handheld computer, or cloud server, etc. The computer device can interact with the user via a keyboard, mouse, remote control, touchpad, or voice control.
[0080] The memory 41 includes at least one type of readable storage medium, including flash memory, hard disk, multimedia card, card-type memory (e.g., SD or DX memory), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, the memory 41 may be an internal storage unit of the computer device 4, such as the hard disk or memory of the computer device 4. In other embodiments, the memory 41 may also be an external storage device of the computer device 4, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc., equipped on the computer device 4. Of course, the memory 41 may include both the internal storage unit and its external storage device of the computer device 4. In this embodiment, the memory 41 is typically used to store the operating system and various application software installed on the computer device 4, such as computer-readable instructions for signal transmission methods of the I / O module. In addition, the memory 41 can also be used to temporarily store various types of data that have been output or will be output.
[0081] In some embodiments, the processor 42 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chip. The processor 42 is typically used to control the overall operation of the computer device 4. In this embodiment, the processor 42 is used to execute computer-readable instructions stored in the memory 41 or to process data, for example, to execute computer-readable instructions for the signal transmission method of the I / O module.
[0082] The network interface 43 may include a wireless network interface or a wired network interface, which is typically used to establish communication connections between the computer device 4 and other electronic devices.
[0083] The computer equipment provided in this application polls each junction box through a preset reading time slice, forming a target identification sequence corresponding to each junction box, reducing signal interference caused by simultaneous feedback from multiple junction boxes. Then, based on the target identification sequence, the current mapping relationship between the wiring port and the junction box can be determined, intuitively reflecting the actual layout of the wiring on site. Next, the standard mapping relationship between the wiring port and the junction box is obtained, providing a fixed reference standard for correcting the wiring relationship. Finally, the current mapping relationship is adjusted based on the standard mapping relationship, correcting mapping deviations caused by incorrect wiring sequence. The formed target mapping relationship allows the wiring port and junction box to transmit signals normally, avoiding signal transmission errors caused by incorrect wiring sequence.
[0084] This application also provides another embodiment, namely, providing a computer-readable storage medium storing computer-readable instructions that can be executed by at least one processor to cause the at least one processor to perform the steps of the signal transmission method of the IO module as described above.
[0085] The computer-readable storage medium provided in this application polls each junction box through a preset reading time slice, forming a target identification sequence corresponding to the junction box, reducing signal interference caused by simultaneous feedback from multiple junction boxes. Then, based on the target identification sequence, the current mapping relationship between the wiring port and the junction box can be determined, intuitively reflecting the actual layout of the wiring on site. Next, the standard mapping relationship between the wiring port and the junction box is obtained, providing a fixed reference standard for correcting the wiring relationship. Finally, adjusting the current mapping relationship based on the standard mapping relationship can correct mapping deviations caused by incorrect wiring sequence. The formed target mapping relationship allows the wiring port and junction box to transmit signals normally, avoiding signal transmission errors caused by incorrect wiring sequence.
[0086] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in the various embodiments of this application.
[0087] Obviously, the embodiments described above are only some embodiments of this application, not all embodiments. The accompanying drawings show preferred embodiments of this application, but do not limit the patent scope of this application. This application can be implemented in many different forms; rather, these embodiments are provided to provide a more thorough and comprehensive understanding of the disclosure of this application. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing specific embodiments, or make equivalent substitutions for some of the technical features. Any equivalent structures made using the content of this application's specification and drawings, directly or indirectly applied to other related technical fields, are similarly within the scope of patent protection of this application.
Claims
1. A signal transmission method for an I / O module, characterized in that, The IO module includes multiple wiring ports, one of which is connected to a junction box. The method includes: According to the preset reading time slice, each of the junction boxes is polled to obtain the target identity sequence composed of all the junction boxes; Based on the target identity sequence, determine the current mapping relationship between each of the wiring ports and each of the junction boxes; Obtain the standard mapping relationship between each of the wiring ports and each of the junction boxes; Based on multiple standard mapping relationships, the current mapping relationship is adjusted to obtain a target mapping relationship, so that the wiring port can transmit signals with the junction box based on the target mapping relationship.
2. The signal transmission method of the IO module according to claim 1, characterized in that, The step of polling each of the junction boxes according to a preset reading time slice to obtain a target identity sequence composed of all the junction boxes includes: Obtain the port number of each of the wiring ports, allocate the reading time slice to each of the wiring ports according to the port number, and control each of the wiring ports to send reading instructions to each of the junction boxes in the order in which each of the wiring ports receives the reading time slice; Receive feedback information returned by each of the junction boxes based on the read command, and extract the identity identifier of each junction box from the feedback information; The target identity sequence is generated based on the identity identifier of each junction box.
3. The signal transmission method for the I / O module according to claim 2, characterized in that, The step of generating the target identity sequence based on the identity identifier of each junction box includes: The identification identifiers of each junction box are sorted to obtain an initial identification identifier sequence; The initial identity sequence is detected to obtain detection results, which include identity anomalies and identity normalities. Based on the detection results, the initial identity sequence is updated to obtain the target identity sequence.
4. The signal transmission method of the IO module according to claim 3, characterized in that, The step of detecting the initial identity sequence to obtain the detection result includes: If any one of the junction box identifiers in the initial identifier sequence does not meet the preset conditions, then the detection result is determined to be that the identifier is abnormal; If all the junction box identifiers in the initial identifier sequence meet the preset conditions, then the detection result is determined to be that the identifier is normal.
5. The signal transmission method for the I / O module according to claim 3, characterized in that, The step of updating the initial identity sequence based on the detection result to obtain the target identity sequence includes: When the detection result indicates that the identity identifier is normal, the initial identity identifier sequence is determined as the target identity identifier sequence; When the detection result indicates that the identity identifier is abnormal, the junction box corresponding to the abnormal identity identifier is identified, a preset temporary identity identifier is assigned to the junction box corresponding to the abnormal identity identifier, and the initial identity identifier sequence is updated according to the temporary identity identifier to obtain the target identity identifier sequence.
6. The signal transmission method for the I / O module according to claim 1, characterized in that, The step of adjusting the current mapping relationship based on multiple standard mapping relationships to obtain the target mapping relationship includes: Based on multiple standard mapping relationships, determine whether the current mapping relationship is an abnormal mapping relationship; If the current mapping relationship is the abnormal mapping relationship, then the abnormal junction box is determined according to the abnormal mapping relationship, and the target wiring port corresponding to the abnormal junction box is determined according to the standard mapping relationship corresponding to the abnormal junction box. Based on the target wiring port corresponding to the abnormal junction box, the abnormal mapping relationship is adjusted to obtain the target mapping relationship.
7. The signal transmission method of the IO module according to any one of claims 1 to 6, characterized in that, After adjusting the current mapping relationship according to multiple standard mapping relationships to obtain a target mapping relationship, so that the wiring port can transmit signals with the junction box based on the target mapping relationship, the method further includes: Monitor the level signal of each of the wiring ports, and determine whether each of the wiring ports and each of the junction boxes is in a disconnected state based on the level signal; If either the connection port or the junction box is in the disconnected state, the target mapping relationship between the connection port and the junction box in the disconnected state will be adjusted to a preset standard mapping relationship.
8. A signal transmission device for an I / O module, characterized in that, The IO module includes multiple wiring ports, each wiring port connecting to a junction box, including: The polling module is used to poll each of the junction boxes according to a preset reading time slice to obtain a target identity sequence composed of all the junction boxes; The determining module is used to determine the current mapping relationship between each of the wiring ports and each of the junction boxes based on the target identity sequence; The acquisition module is used to acquire the standard mapping relationship between each of the wiring ports and each of the junction boxes; The adjustment module is used to adjust the current mapping relationship according to multiple standard mapping relationships to obtain a target mapping relationship, so that the wiring port can transmit signals with the junction box based on the target mapping relationship.
9. A computer device, characterized in that, The device includes a memory and a processor, wherein the memory stores computer-readable instructions, and the processor executes the computer-readable instructions to implement the steps of the signal transmission method of the I / O module as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores computer-readable instructions, which, when executed by a processor, implement the steps of the signal transmission method of the I / O module as described in any one of claims 1 to 7.
