Conversion device of communication protocol format of sensor and conversion method thereof
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- BRILLIAN NETWORK & AUTOMATION INTEGRATED SYST
- Filing Date
- 2025-02-17
- Publication Date
- 2026-08-04
AI Technical Summary
[0006] In summary, the sensor communication protocol format conversion device and the sensor communication protocol format conversion method provided in this embodiment of the invention, when connected between the sensor and the host, enable the host to easily read sensors from different brands and quickly switch between different brands of sensors.
Smart Images

Figure CN122513488A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to a sensor, and more particularly to a device and method for converting the communication protocol format of a sensor. Background Technology
[0002] Existing temperature and humidity sensors can be categorized into analog and digital output sensors based on their output method. Digital output sensors typically transmit data via specific communication interfaces (such as I2C, SPI, and UART). When reading the sensed data, the signal needs to be converted according to the sensor's communication protocol, and sometimes mathematical calculations are required to convert the raw data into specific temperature and humidity values. If sensors from different brands use the same communication interface, the differences in their communication protocols and data formats necessitate adjustments to the communication interface settings and mathematical conversion methods based on the specific brand's technical specifications to successfully read the sensed data. Summary of the Invention
[0003] To solve the above-mentioned technical problems, the present invention provides a sensor communication protocol format conversion device and a sensor communication protocol format conversion method.
[0004] This invention provides a sensor communication protocol format conversion device, including a first communication interface, a second communication interface, and a control circuit. The control circuit is electrically connected to the first communication interface and the second communication interface; the control circuit identifies the sensor connected to the first communication interface, obtains sensing data of the sensor in a first communication protocol format according to the identification result, converts the first communication protocol format sensing data into second communication protocol format sensing data, and outputs the second communication protocol format sensing data through the second communication interface.
[0005] This invention provides a method for converting the communication protocol format of a sensor, comprising: when a sensor is connected to a first communication interface of a conversion device, the control circuit of the conversion device identifies the communication protocol format of the sensor; the control circuit obtains sensing data of the sensor in the first communication protocol format according to the identification result; and the control circuit converts the sensing data in the first communication protocol format into sensing data in the second communication protocol format, so that the second communication interface of the conversion device outputs the sensing data in the second communication protocol format.
[0006] In summary, the sensor communication protocol format conversion device and the sensor communication protocol format conversion method provided in this embodiment of the invention, when connected between the sensor and the host, enable the host to easily read sensors from different brands and quickly switch between different brands of sensors.
[0007] To further understand the features and technical content of the present invention, please refer to the following detailed description and drawings of the present invention. However, the drawings provided are for reference and illustration only and are not intended to limit the present invention. Attached Figure Description
[0008] Figure 1 A schematic diagram of the usage architecture of the conversion device is provided for an embodiment of the present invention.
[0009] Figure 2 An exploded view of the conversion device is provided for an embodiment of the present invention.
[0010] Figure 3 A functional block diagram of the conversion device is provided for embodiments of the present invention.
[0011] Figure 4 A functional block diagram of the control circuit is provided for embodiments of the present invention.
[0012] Figure 5A and 5B A control flowchart is provided for a method of converting the communication protocol format of a sensor in an embodiment of the present invention.
[0013] Figure 6 The control flowchart of the identification sensor provided in the embodiment of the present invention. Detailed Implementation
[0014] The following specific embodiments illustrate the implementation of the present invention. Those skilled in the art can understand the advantages and effects of the present invention from the content provided in this specification. The present invention can be implemented or applied through other different specific embodiments, and various details in this specification can also be modified and changed based on different viewpoints and applications without departing from the concept of the present invention. Furthermore, the accompanying drawings of the present invention are for simple illustrative purposes only and are not depictions of actual dimensions, as stated beforehand. The following embodiments will further describe the relevant technical content of the present invention in detail, but the provided embodiments are not intended to limit the scope of this disclosure.
[0015] It should be understood that while terms such as "first," "second," and "third" may be used in this document to describe various components or signals, these components or signals should not be limited by these terms. These terms are primarily used to distinguish one component from another, or one signal from another. Furthermore, the term "or" as used in this document should be interpreted to include, as appropriate, any combination of one or more of the related listed items.
[0016] This invention provides a sensor communication protocol format conversion device and method. The sensor communication protocol format conversion device (hereinafter referred to as the conversion device) integrates the relevant control command sets required by multiple sensors from different brands, enabling the conversion device to support and automatically identify sensors from the same brand. Furthermore, the conversion device can convert the data into a format readable by the device (such as a host) that requires the sensing data. Therefore, this conversion device simplifies the design burden of the host for reading different sensor brands and also enables the rapid switching of different sensor brands, thereby effectively improving the convenience and accuracy of the host reading sensors from different brands via the conversion device.
[0017] [Example of the architecture for using a sensor communication protocol format conversion device]
[0018] Please refer to Figure 1 , Figure 2 and Figure 3 , Figure 1 A schematic diagram of the usage architecture of the conversion device is provided for embodiments of the present invention. Figure 2 An exploded view of the conversion device is provided for an embodiment of the present invention. Figure 3 A functional block diagram of the conversion device is provided for embodiments of the present invention. The conversion device 1 described in this embodiment is provided with multiple communication interfaces, for example, a first communication interface 12 and a second communication interface 14 are used in this illustration. In other words, the conversion device 1 connects to the sensor 3 via the first communication interface 12 and to the host 5 via the second communication interface 14. After obtaining the sensing data from the sensor 3 through the first communication interface 12, the conversion device 1 converts this sensing data into a format readable by the host 5, and finally outputs the sensing data from the sensor 3 to the host 5 through the second communication interface 14.
[0019] In one embodiment, the conversion device 1 is as follows: Figure 2 A motherboard 10 is provided inside the housing C, and this motherboard 10 is provided with a first communication interface 12 and a second communication interface 14. The first communication interface 12 and the second communication interface 14 are, for example, a first I2C communication interface and a second I2C communication interface, respectively, allowing the sensor 3 and the host 5 to be directly connected to the first I2C communication interface or the second I2C communication interface via a transmission line. Furthermore, the first I2C communication interface and the second I2C communication interface can be respectively located on both sides of the housing C. The housing C includes an upper cover C1 and a lower cover C2, which are assembled together. The motherboard 10 is located in the receiving portion C3 within the housing C.
[0020] It should be noted here that, as Figure 3The motherboard 10 also includes a control circuit 101, which is electrically connected to the first communication interface 12 and the second communication interface 14. Furthermore, when the sensor 3 is connected to the first communication interface 12 and the host 5 is connected to the second communication interface 14, the control circuit 101 can identify the sensor 3 connected to the first communication interface 12, obtain the sensor data in the first communication protocol format based on the identification result, convert the first communication protocol format sensor data into second communication protocol format sensor data, and output the second communication protocol format sensor data through the second communication interface 14.
[0021] In one embodiment, the communication transmission interfaces used by the first communication interface 12 and the second communication interface 14 may be, for example, I2C (Inter-Integrated Circuit), I3C (Improved Inter-Integrated Circuit), SPI (Serial Peripheral Interface), CAN bus (Controller Area Network), UART (Universal Asynchronous Receiver / Transmitter), RS-232 / RS-485 or GPIO (General Purpose Input / Output), Lin (Local Interconnect Network), USB (Universal Serial Bus), Ethernet, analog interfaces, but are not limited thereto, and the transmission interfaces used by the first communication interface 12 and the second communication interface 14 may be the same or different.
[0022] It should be noted that the first communication interface 12 and the second communication interface 14 can be one type of communication transmission interface, or two or more types of communication transmission interfaces.
[0023] For an embodiment relating to the control circuit 101, please refer to... Figure 4 , Figure 4 A functional block diagram of a control circuit is provided for embodiments of the present invention. The control circuit 101 includes, for example, a processor 1011, a database 1013, and a memory 1015, with the processor 1011 connected to the database 1013 and the memory 1015.
[0024] The database 1013 stores multiple command sets with different communication protocol formats, each corresponding to a different brand of sensor 3. For ease of explanation, this example uses four sets: the first set corresponds to sensor A and uses communication protocol A; the second set corresponds to sensor B and uses communication protocol B; the third set corresponds to sensor C and uses communication protocol C; and the fourth set corresponds to sensor D and uses communication protocol D. Therefore, the processor 1011 can identify the communication protocol used by different brand sensors 3 based on these command sets.
[0025] For example, processor 1011 can select one set of commands from multiple sets of commands in database 1013 at a time to identify sensor 3 connected to the first communication interface 12, and determine which set of commands can successfully identify sensor 3 based on the identification result. Here, processor 1011 successfully identifying sensor 3 means that processor 1011 can successfully obtain the response signal of sensor 3. Further, processor 1011 selects one set of commands from the multiple sets of commands based on the identification result as an input command set for successfully identifying the sensor, and then processor 1011 outputs this input command set through the first communication interface 12 to obtain sensor 3's first communication protocol format sensing data.
[0026] It should be noted that after the processor 1011 obtains the sensing data in the first communication protocol format, the processor 1011 will further convert the sensing data in the first communication protocol format into sensing data in the second communication protocol format that can be read by the host 5. Specifically, the processor 1011 selects one set of commands from multiple command sets as the output command set, and the processor 1011 converts the sensing data in the first communication protocol format into sensing data in the second communication protocol format according to the output command set, so that the host 5 can read this sensing data in the second communication protocol format through the second communication interface 14.
[0027] In one embodiment, the input command set and output command set used by the processor 1011 may be the same or different command sets. For example, the input command set may be the signal command set of the sensor model SENSIRION SHT85 and the output command set may also be the signal command set of SENSIRION SHT85; or the input command set may be the signal command set of the sensor model SENSIRION SHT85 and the output command set may be the signal command set of the sensor model Texas Instruments HDC1080.
[0028] In one embodiment, the processor 1011 may store the sensing data in the first communication protocol format and the sensing data in the second communication protocol format in the memory 1015.
[0029] In one embodiment, when the processor 1011 receives a read instruction from the host 5 through the second communication interface 14, the processor 1011 outputs the second communication protocol format sensing data in the memory 1015 to the second communication interface 14 according to the read instruction, so that the host 5 can obtain the second communication protocol format sensing data.
[0030] In one embodiment, when the processor 1011 receives an update instruction from the host 5 through the second communication interface 14, the processor 1011 updates the contents of the database 1013 according to the update instruction. For example, it can update multiple command sets stored in the database 1013 to command sets that use sensors from other brands.
[0031] In one embodiment, sensor 3 may be a temperature sensor, a humidity sensor, or a temperature and humidity sensor.
[0032] In one embodiment, the sensing data output by sensor 3 is a digital signal or an analog signal.
[0033] In one embodiment, database 1013 is storable memory.
[0034] [Example of a method for converting the communication protocol format of a sensor]
[0035] Reference Figure 5A and 5B , Figure 5A and 5B A control flowchart is provided for a method of converting the communication protocol format of a sensor in an embodiment of the present invention. Figure 5A and 5B The processes shown include, but are not limited to, the steps described below, and can be used in conjunction with a communication protocol format conversion device for the sensors described in the foregoing embodiments.
[0036] Step S501: System startup. When the conversion device 1 is connected to the host 5 through the second communication interface 14, the conversion device 1 can obtain power supply from the host 5 to start the system.
[0037] Step S503: Initialization. After the converter 1 is started, the initialization function can be performed to ensure that the converter 1 can operate smoothly in both software and hardware.
[0038] Step S505: Determine whether sensor 3 is connected. Here, the conversion device 1 determines whether sensor 3 is further connected via the first communication interface 12. If step S505 determines yes, proceed to step S507; if step S505 determines no, proceed to step S503.
[0039] Step S507: Identify the sensor 3 model. The conversion device 1 identifies whether the sensor 3 model can be successfully identified by the conversion device 1 based on multiple command sets in the database 1013, one by one. Detailed identification methods related to step S507 will be discussed later. Figure 6 Please provide an explanation.
[0040] Step S509: Transmit the input command set to sensor 3. Based on the identification result of step S507, it can be determined which command set in database 1013 can successfully identify sensor 3 currently connected to the first communication interface 12. Therefore, the conversion device 1 will use this command set as the input command set. Specifically, after the conversion device 1 learns of the input command set, the control circuit 101 of the conversion device 1 will output this input command set to sensor 3 through the first communication interface 12 to control sensor 3 to start sensing according to this input command set.
[0041] Step S511: Wait for calculation time. When sensor 3 starts sensing, sensor 3 will perform a calculation period, and conversion device 1 will synchronously wait for this calculation period to coordinate with the sensing action of sensor 3.
[0042] Step S513: Obtain sensing data in the first communication protocol format. After the sensor 3 performs a certain amount of calculation, the sensing result of the sensor 3 will be sent back to the first communication interface 12. For the conversion device 1, the sensing result of the sensor 3 can be obtained through the first communication interface 12. This sensing result is the sensing data in the first communication protocol format.
[0043] In one embodiment, the control circuit 101 outputs a read packet to the first communication interface 12 according to the input command set, so as to control the sensor 3 to perform a sensing calculation according to the read packet, and after a waiting calculation time, the control circuit 101 can obtain the sensing data in the first communication protocol format returned by the sensor 3.
[0044] In one embodiment, after the control circuit 101 obtains the sensing data in the first communication protocol format, it can then perform calculations on the sensing data in the first communication protocol format using the conversion formula of the corresponding brand sensor 3. Examples of the conversion formulas used for different brand sensors 3 are explained below.
[0045] For example, the temperature and humidity conversion formulas for sensor model 3, Texas Instruments HDC1080, can be shown in formulas 1 and 2 below:
[0046] Temperature(℃)=((TEMPERATURE[15:00]) / 2^16)x165-40...Formula 1
[0047] Relative Humidity(%RH)=(HUMIDITY[15:00] / 2^16)x100...Formula 2
[0048] For example, the temperature and humidity conversion formulas for sensor model 3, such as TEXAS INSTRUMENTS HDC3020, can be shown in formulas 3 and 4 below:
[0049] Temperature(℃)=((TEMPERATURE[15:00]) / 2^16-1)x175-45...Formula 3
[0050] Relative Humidity(%RH)=(HUMIDITY[15:00] / 2^16-1)x100...Formula 4
[0051] For example, the temperature and humidity conversion formulas for the SENSIRION SHT45 sensor model 3 can be shown in formulas 5 and 6 below:
[0052] Temperature(℃)=((TEMPERATURE[15:00]) / 2^16-1)x175-45...Formula 5
[0053] Relative Humidity(%RH)=(HUMIDITY[15:00] / 2^16-1)x100...Formula 6
[0054] For example, the temperature and humidity conversion formulas for sensor 3 can be shown in formulas 7 and 8 below:
[0055] Temperature (°C) = (Type D temperature digital signal) × A + B ... Formula 7, where A and B are constants.
[0056] Relative Humidity (%RH) = (Type D humidity digital signal) ÷ C + D conversion... Formula 8, where C and D are constants.
[0057] Step S515: Convert the first communication protocol format sensing data to the second communication protocol format sensing data according to the output command set. After the conversion device 1 obtains the first communication protocol format sensing data, the conversion device 1 will use one of the multiple command sets in the database 1013 as the output command set, and the control circuit 101 of the conversion device 1 will convert the first communication protocol format sensing data to the second communication protocol format sensing data according to the output command set. That is, the second communication protocol format sensing data is compatible with the data reading format used by the host 5, so that the host 5 can know the sensing result of the sensor 3 by recognizing the second communication protocol format sensing data.
[0058] In one embodiment, the control circuit 101 converts the sensing data in the first communication protocol format into sensing data in the second communication protocol format according to the conversion formula and conversion compensation corresponding to the output command set. For example, when the input command set is a command set using digital signals for the sensor model TEXAS INSTRUMENTS HDC1080, and the output command set is a reading format of MODBUS digital signals used by the host, the conversion formula and conversion compensation used by the control circuit 101 can be expressed by the following formula 9:
[0059] (((TEXAS INSTRUMENTS HDC1080 temperature digital signal)×A+BD)÷C+Error value generated by conversion = MODBUS temperature digital signal……Formula 9
[0060] In other embodiments, the input command set and output command set may also be command sets used by other different brands of sensors, such as the sensor model Texas Instruments HDC3020, SENSIRION SHT45, or other commercially available sensor products, but the present invention is not limited thereto.
[0061] Step S517: Determine whether to execute the calibration procedure. When the conversion device 1 completes the conversion of the sensing data in the second communication protocol format, the conversion device 1 determines whether to execute the calibration procedure through the second communication interface 14. For example, when the control circuit 101 obtains the calibration function provided by an external device (such as a host) through the second communication interface 14, it can execute the subsequent calibration procedure. If step S517 determines yes, proceed to step S519; if step S517 determines no, proceed to step S521.
[0062] Step S519: Calibrate the second communication protocol format sensing data. Performing this calibration procedure means that the control circuit 101 calibrates the second communication protocol format sensing data according to a calibration function. For example, under normal conditions, the humidity accuracy of sensor 3 is approximately ±2%, but in extreme environments (relatively high or low temperatures), the accuracy of sensor 3 will be affected. Therefore, this calibration function can calibrate the humidity curve based on the data from the original sensor 3 and verification tests using a dew point meter, allowing each sensor 3 to perform more stably in some extreme environments.
[0063] Step S521: Store the first communication protocol format sensing data and the second communication protocol format sensing data. After acquiring the first communication protocol format sensing data and the second communication protocol format sensing data, the conversion device 1 can store them in the memory 1015 by the control circuit 101 for later retrieval.
[0064] Step S523: Determine the host connected to the corresponding communication interface. When the second communication interface 14 of the conversion device 1 is connected to an external device (such as a host), the control circuit 101 can further determine whether the communication interface used by the host 5 can be supported by the conversion device 1. If step S523 determines yes, proceed to step S525; if step S523 determines no, proceed to step S509.
[0065] Step S525: Use the corresponding communication protocol format. When the control circuit 101 determines that the host 5 currently connected to the second communication interface 14 belongs to a supported communication protocol format, the control circuit 101 will use the corresponding communication protocol format to transmit data with the host 5. For example, this conversion device 1 can support various communication interfaces such as I2C, I3C, SPI, CAN, UART, RS-232 / RS-485, GPIO, Lin, USB, Ethernet, and analog interfaces. When the control circuit 101 determines that the communication interface used by the host 5 is I2C, the control circuit 101 will use the I2C communication protocol format to transmit data with the host 5; or when the control circuit 101 determines that the communication interface used by the host 5 is RS-485, the control circuit 101 will use the RS-485 communication protocol format to transmit data with the host 5, and so on.
[0066] Step S527: Determine whether a read command has been received. Here, the control circuit 101 determines whether the second communication interface 14 has received a read command from the host 5. If step S527 determines yes, step S533 is executed; if step S527 determines no, step S529 is executed.
[0067] Step S529: Determine whether to perform an update. Here, the control circuit 101 determines whether the second communication interface 14 has received an update command from the host 5. If step S529 determines yes, step S535 is executed; if step S529 determines no, step S531 is executed.
[0068] Step S531: Determine whether to perform other functions. In this step, the control circuit 101 determines whether the second communication interface 14 has received other instructions from the host 5. If step S531 determines yes, step S537 is executed; if step S531 determines no, step S509 is executed.
[0069] Step S533: Return to host. The control circuit 101 outputs the second communication protocol format sensing data in the memory 1015 to the second communication interface 14 according to the read instruction, so that the host 5 can obtain the second communication protocol format sensing data.
[0070] Step S535: Update database 1013. The control circuit 101 updates the multiple sets of command sets with different communication protocol formats stored in the database 1013 of the conversion device 1 according to the update instruction.
[0071] Step S537: Execute other instructions. The control circuit 101 performs other functional operations on the conversion device according to other instructions.
[0072] Reference Figure 6 , Figure 6 This is a control flowchart of the identification sensor provided in an embodiment of the present invention. Figure 6 It is aimed at Figure 5A Step S507 further explains that the conversion device 1 can identify the model of sensor 3 through the following steps.
[0073] Step S5071: Model Identification. When the control circuit 101 learns that the first communication interface 12 is connected to the sensor 3, the control circuit 101 can initiate the model identification of the sensor 3. For example, in this case, the control circuit 101 will use one of the multiple command sets in the database 1013 to identify the sensor 3 one by one.
[0074] Step S5073: Execute the first set of commands. Here, the control circuit 101 selects the first set of commands to identify the sensor 3. For example, when the control circuit 101 executes the first set of commands, it can output the relevant instructions of the first set of commands through the first communication interface 12 to identify the sensor 3.
[0075] Step S5075: Determine if there is a response. The control circuit 101 determines whether the sensor 3 is compatible with the first set of command sets by judging whether the first communication interface 12 has received a response message from the sensor 3. If step S5075 determines yes, proceed to step S5089; if step S5075 determines no, proceed to step S5077.
[0076] Step S5077: Execute the second set of commands. Here, the control circuit 101 selects the second set of commands to identify the sensor 3. For example, when the control circuit 101 executes the second set of commands, it can output the relevant instructions of the second set of commands through the first communication interface 12 to identify the sensor 3.
[0077] Step S5079: Response. The control circuit 101 determines whether the sensor 3 is compatible with the second set of command sets by judging whether the first communication interface 12 has received a response message from the sensor 3. If step S5079 determines yes, step S5089 is executed; if step S5079 determines no, step S5081 is executed.
[0078] Step S5081: Execute the third set of commands. Here, the control circuit 101 selects the third set of commands to identify the sensor 3. For example, when the control circuit 101 executes the third set of commands, it can output the relevant instructions of the third set of commands through the first communication interface 12 to identify the sensor 3.
[0079] Step S5083: Response. The control circuit 101 determines whether the sensor 3 is compatible with the third set of command sets by judging whether the first communication interface 12 has received a response message from the sensor 3. If step S5083 determines yes, step S5089 is executed; if step S5083 determines no, step S5085 is executed.
[0080] Step S5085: Execute the fourth set of commands. In this case, the control circuit 101 selects the fourth set of commands to identify the sensor 3. For example, when the control circuit 101 executes the fourth set of commands, it can output the relevant instructions of the fourth set of commands through the first communication interface 12 to identify the sensor 3.
[0081] Step S5087: Response. The control circuit 101 determines whether the sensor 3 is compatible with the fourth command set by judging whether the first communication interface 12 has received a response message from the sensor 3. If step S5087 determines yes, step S5089 is executed; if step S5087 determines no, step S5071 is executed.
[0082] Step S5089: Model Confirmation. Here, control circuit 101 confirms the model of sensor 3 based on whether sensor 3 responds to a message. For example, if step S5075 determines yes, control circuit 101 identifies sensor 3 as being applicable to the first command set; or if step S5079 determines yes, control circuit 101 identifies sensor 3 as being applicable to the second command set; or if step S5083 determines yes, control circuit 101 identifies sensor 3 as being applicable to the third command set; or if step S5087 determines yes, control circuit 101 identifies sensor 3 as being applicable to the fourth command set.
[0083] In one embodiment, the control circuit 101 may be, for example, one or any combination of an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), a digital signal processor (DSP), or a system-on-a-chip (SoC), and may be used in conjunction with other related circuit components and firmware to implement the above-mentioned functional steps.
[0084] [Beneficial Effects of the Examples]
[0085] This invention provides a sensor communication protocol format conversion device and a conversion method. The conversion device is connected to the sensor and the host computer, enabling the host computer to easily read sensors from different brands. This device retains the original communication format without requiring modification of the original hardware and software settings, thus providing diverse product expandability.
[0086] The above-described content is merely a preferred embodiment of the present invention and is not intended to limit the scope of the claims. Therefore, any equivalent technical changes made based on the description and drawings of the present invention are included in the claims of the present invention.
Claims
1. A sensor communication protocol format conversion device, characterized by, include: First communication interface; A second communication interface; as well as A control circuit, wherein the control circuit is electrically connected to the first communication interface and the second communication interface; The control circuit identifies a sensor connected to the first communication interface, obtains sensor data in a first communication protocol format based on the identification result, converts the first communication protocol format sensor data into a second communication protocol format sensor data, and outputs the second communication protocol format sensor data through the second communication interface.
2. The conversion device of a communication protocol format of a sensor according to claim 1, characterized by, The control circuit includes a processor and a database. The database stores multiple sets of command sets with different communication protocol formats. The processor identifies the communication protocol of the sensor based on the multiple sets of command sets.
3. The conversion device of a communication protocol format of a sensor according to claim 2, characterized by, When the sensor is connected to the first communication interface, the processor selects one set of commands from multiple sets of commands based on the recognition result as an input command set for successfully recognizing the sensor, and obtains the sensor's first communication protocol format sensing data through the input command set.
4. The conversion device of a communication protocol format of a sensor according to claim 3, characterized by, The processor selects one set of commands from multiple command sets as an output command set, and the processor converts the first communication protocol format sensing data into the second communication protocol format sensing data according to the output command set.
5. The conversion device of a communication protocol format of a sensor according to claim 4, characterized by, The input command set and the output command set can be the same or different command sets.
6. The conversion device of a communication protocol format of a sensor according to claim 2, wherein, The control circuit further includes a memory that stores the first communication protocol format sensing data and the second communication protocol format sensing data.
7. The conversion device of a communication protocol format of a sensor according to claim 6, wherein, When the processor receives a read instruction from a host through the second communication interface, the processor outputs the second communication protocol format sensing data in the memory to the second communication interface according to the read instruction, so that the host can obtain the second communication protocol format sensing data.
8. The sensor communication protocol format conversion device as described in claim 2, characterized in that, When the processor receives an update instruction from a host through the second communication interface, the processor updates the contents of the database according to the update instruction.
9. The sensor communication protocol format conversion device as described in claim 1, characterized in that, The first communication interface and the second communication interface may be the same or different communication interfaces.
10. The sensor communication protocol format conversion device as described in claim 1, characterized in that, The control circuit is disposed on a motherboard, the motherboard is disposed in a receiving part of a housing, and the first communication interface and the second communication interface are respectively disposed on one side of the housing.
11. A method for converting the communication protocol format of a sensor, characterized in that, include: When a sensor is connected to a first communication interface of a conversion device, a control circuit of the conversion device identifies the communication protocol format of the sensor. The control circuit obtains sensor data in a first communication protocol format from the sensor based on the recognition result. as well as The control circuit converts the first communication protocol format sensing data into a second communication protocol format sensing data, and the second communication interface of the conversion device outputs the second communication protocol format sensing data.
12. The method for converting the communication protocol format of a sensor as described in claim 11, characterized in that, Also includes: When the sensor is connected to the first communication interface, the control circuit identifies the communication protocol format of the sensor according to multiple sets of different command formats in the conversion device; The control circuit selects one set of commands from multiple command sets as an input command set for successfully identifying the communication protocol of the sensor based on the recognition result. The control circuit obtains the sensor's sensing data in the first communication protocol format according to the input command set.
13. The method for converting the communication protocol format of a sensor as described in claim 12, characterized in that, The control circuit outputs a read packet to the first communication interface according to the input command set, so as to control the sensor to perform a sensing calculation according to the read packet, and after a waiting calculation time, the control circuit obtains the sensing data in the first communication protocol format returned by the sensor.
14. The method for converting the communication protocol format of a sensor as described in claim 12, characterized in that, Also includes: The control circuit selects one set of commands from multiple sets of commands as an output command set. The control circuit converts the first communication protocol format sensing data into the second communication protocol format sensing data according to the output command set. The sensing data in the second communication protocol format is stored in a memory of the conversion device.
15. The method for converting the communication protocol format of a sensor as described in claim 14, characterized in that, The control circuit converts the first communication protocol format sensing data into the second communication protocol format sensing data according to a conversion formula and a conversion compensation corresponding to the output command set.
16. The method for converting the communication protocol format of a sensor as described in claim 14, characterized in that, Also includes: Determine whether to perform a correction procedure; If the control circuit determines that it is not, it stores the second communication protocol format sensing data in the memory; and When the control circuit determines that it is correct, it corrects the second communication protocol format sensing data according to a correction function and stores the corrected second communication protocol format sensing data in the memory.
17. The method for converting the communication protocol format of a sensor as described in claim 14, characterized in that, Also includes: When the second communication interface receives a read command from a host, the control circuit outputs the second communication protocol format sensing data in the memory to the second communication interface according to the read command, so that the host can obtain the second communication protocol format sensing data.
18. The method for converting the communication protocol format of a sensor as described in claim 12, characterized in that, Also includes: When the second communication interface receives an update command from a host, the control circuit updates the multiple sets of command sets with different communication protocol formats stored in the database of the conversion device according to the update command.