Data collection system, relay device, and communication device
The data collection system addresses the challenge of long-range data transmission by employing a relay device with distinct communication channels, ensuring reliable data collection beyond the radio wave reach, thus enhancing system applicability and data integrity.
Patent Information
- Application Number
- JP2024008027
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2024-01-23
- Publication Date
- 2025-08-04
AI Technical Summary
Existing data collection systems using sub-gigahertz frequency bands face challenges in reliably transmitting sensing data when the distance between sensor devices and the communication device exceeds the radio wave reach, and there is a lack of methods for allocating communication channels in systems using relay devices.
A data collection system comprising sensor devices, a communication device, and a relay device that uses different communication channels for relaying sensor data, where the relay device communicates with sensor devices using a first channel and with the communication device using a second channel, enabling reliable data transmission even when direct communication is not possible.
Ensures reliable collection of sensing data by allowing communication channels to be appropriately allocated, even in scenarios where direct communication is not feasible, thereby expanding the applicability of the system and ensuring data integrity.
Smart Images

Figure 2025113731000001_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to a data collection system, a relay device, and a communication device.
Background Art
[0002] A system for collecting sensing data measured by sensors included in a plurality of terminal devices is known. Such systems are used, for example, in temperature management in large-scale refrigeration (freezing) systems, smart grids, building lighting management, infrastructure monitoring, security systems, elderly care services, smart agriculture, and the like. In particular, wireless communication using a sub-gigahertz (Sub-GHz) frequency band (for example, a band around 920 MHz) is expected to be used in the above-described systems because radio waves propagate farther, are less affected by obstacles, and have less radio wave interference than Wi-Fi (registered trademark) or BLE (Bluetooth (registered trademark) Low Energy).
[0003] In the above-described system, in order to prevent interference during collection of sensing data, it is necessary to divide communication channels (ch) for each sensor device. Patent Document 1 below describes a method of allocating a frequency channel in which no wireless signal has been received to a predetermined electronic device constituting a system as a method of allocating communication channels to devices such as lighting fixtures and sensors.
Prior Art Documents
Patent Documents
[0004]
Patent Document 1
Summary of the Invention
Problems to be Solved by the Invention
[0005] The system described in Patent Document 1 mentioned above assumes that the distance between the controller and each device is within the reach of radio waves and that communication between devices is possible. Therefore, when the distance between the controller and each device is beyond the reach of radio waves, there is a problem that the technology described in Patent Document 1 cannot be applied. Also, when the distance between the controller and each device is beyond the reach of radio waves, it is conceivable to use a relay device that relays sensing data. However, Patent Document 1 does not describe a method for allocating communication channels in a data collection system using a relay device, and there is room for improvement from this perspective.
[0006] One object of the present invention is to provide a data collection system, a relay device, and a communication device that can appropriately allocate communication channels in a data collection system using a relay device and can reliably collect sensing data and the like.
Means for Solving the Problems
[0007] The present invention includes one or more sensor devices, a communication device, and a relay device that relays sensor data transmitted between the sensor device and the communication device, The sensor device includes a sensor that acquires sensing data included in the sensor data, and a first communication unit that transmits the sensor data. The communication device has a second communication unit that receives sensor data transmitted from a sensor device that cannot communicate with the communication device among one or more sensor devices from the relay device. The relay device has a third communication unit that receives sensor data transmitted from a sensor device that cannot communicate with the communication device and transmits the received sensor data to the communication device, wherein a first communication channel used by the relay device for communication with the sensor device is different from a second communication channel used by the relay device for communication with the communication device, which is a data collection system.
[0008] The present invention has a communication unit that receives sensor data transmitted from a sensor device that cannot communicate with a communication device and transmits the received sensor data to the communication device, and the communication unit communicates with the sensor device using a first communication channel and communicates with the communication device using a second communication channel different from the first communication channel. It is a relay device.
[0009] The present invention is a communication device capable of communicating with a sensor device that acquires sensor data and a relay device that relays the sensor data, wherein the sensor device capable of communicating with the communication device communicates using a first communication channel, and for the relay device, information indicating a second communication channel having a channel number larger than the channel number of the first communication channel is transmitted as information indicating the communication channel used by the relay device and the sensor device that cannot communicate with the communication device. It is a communication device.
Brief Description of Drawings
[0010]
Figure 1
Figure 2
Figure 3
Figure 4
Figure 5
Figure 6
Figure 7
Figure 8
Figure 9
Figure 10
Figure 11
Figure 12
Figure 13
Figure 14
Figure 15
Figure 16
Figure 17
Figure 18
Embodiments for Carrying Out the Invention
[0011] Hereinafter, embodiments of the present invention will be described with reference to the drawings. Note that the embodiments described below are preferred specific examples of the present invention, and the content of the present invention is not limited to these embodiments. The description will be made in the following order. <One Embodiment> <Modification Example>
[0012] <One Embodiment> [Configuration Example of General Data Collection System] First, to facilitate understanding of the present invention, a configuration example of a general data collection system for collecting data will be described.
[0013] FIG. 1 is a diagram showing a configuration example of a general data collection system (data collection system 100). The data collection system 100 has, for example, a plurality of sensor devices and a communication device 2. In the example shown in FIG. 1, four sensor devices (sensor devices 1A, 1B, 1C, 1D) are shown as the sensor devices. Of course, the number of sensor devices is not limited to four and can be any number. When it is not necessary to distinguish individual sensor devices, they are appropriately abbreviated as sensor device 1. The sensor device 1 has a sensor function and a communication function for transmitting sensor data including the sensing data acquired by the sensor function. The sensor device 1 transmits the sensor data to the communication device 2 (specifically, a gateway (GW) 2A described later) by wireless communication using, for example, a sub-gigahertz frequency band (hereinafter also appropriately referred to as sub-gigahertz communication). The sub-gigahertz frequency band means a frequency band less than 1 GHz.
[0014] The communication device 2 has, for example, a gateway 2A and an Internet connection device 2B. Communication based on a short-range wireless communication standard (for example, BLE described above) is performed between the gateway 2A and the Internet connection device 2B. The Internet connection device 2B communicates with a cloud computer 3 (an example of a server device) via a network such as the Internet. In this example, the communication device 2 is configured to include the gateway 2A and the Internet connection device 2B, but the communication device 2 may be configured by one communication device having the functions of the gateway 2A and the Internet connection device 2B.
[0015] The processing performed by the data collection system 100 will be outlined. The sensor device 1 transmits sensor data including sensing data to the gateway 2A. The gateway 2A receives the sensor data transmitted from the sensor device 1. Then, the gateway 2A transmits the received sensor data to the Internet-connected device 2B using, for example, BLE. The Internet-connected device 2B receives the sensor data transmitted from the gateway 2A. Then, the Internet-connected device 2B transmits the received sensor data to the cloud computer 3 based on communication standards such as LTE (Long Term Evolution), 4G (Generation) (4th generation mobile data collection system), 5G (5th generation mobile data collection system), etc.
[0016] The cloud computer 3 stores the sensor data transmitted from the Internet-connected device 2B. If an abnormality is found in the sensing data included in the sensor data, the sensor device 1 is inspected or repaired, or maintenance, inspection, etc. are performed according to the application to which the data collection system 100 is applied.
[0017] [Channel Automatic Scanning Process] Next, the channel automatic scanning process performed by the data collection system 100 will be described. The channel automatic scanning process is a process of automatically setting the communication channel used in the sub-GHz communication performed between the sensor device 1 and the gateway 2A. Communication is established between the sensor device 1 and the gateway 2A by the channel automatic scanning process.
[0018] First, a communication channel waiting to receive (hereinafter, appropriately referred to as the receive-waiting communication ch) is set for the gateway 2A. As an example, any communication channel from 1ch to 15ch can be set as the receive-waiting communication ch. In one embodiment, although it is described that there is no frequency overlap between each communication channel, it may be otherwise. The setting of the receive-waiting communication ch is performed, for example, by operating a physical switch such as a DIP switch provided in the gateway 2A.
[0019] The sensor device 1 that performs sub-gigahertz communication with the gateway 2A cannot identify the receive-waiting communication ch set for the gateway 2A. A method of manually setting the same channel as the receive-waiting communication ch for each sensor device 1 is also conceivable. However, with this method, there is a risk of misconfiguration, and furthermore, the more the number of sensor devices 1 increases, the more laborious it becomes, so it is not practical. Therefore, by performing the above-described automatic channel scanning process, each sensor device 1 automatically identifies the receive-waiting communication ch, and performs sub-gigahertz communication with the gateway 2A on the communication channel based on the identification result.
[0020] Referring to FIG. 2, a specific example of the automatic channel scanning process will be described. In this example, the receive-waiting communication ch set for the gateway 2A will be described as 3ch. Although one sensor device 1 is shown in FIG. 2, the same automatic channel scanning process is also performed for the other three sensor devices 1. The timing at which the automatic channel scanning process is performed is not particularly limited. As an example, it is performed at the timing when the power is turned on for the sensor device 1.
[0021] As shown in FIG. 2, the sensor device 1 sets the communication channel to 1ch, which is the smallest channel number, and transmits a predetermined communication packet (hereinafter also appropriately referred to as a patrol communication packet) by sub-gigahertz communication using 1ch as the communication channel. The patrol communication packet is transmitted as a broadcast that does not specify a specific destination address. The patrol communication packet is composed of a header and a payload, and is a communication packet (communication data) including sensing data and the like acquired by the sensor device 1. An example of the data structure of the patrol communication packet will be described later.
[0022] Here, since the reception waiting communication ch of the gateway 2A is 3ch, the gateway 2A does not receive the patrol communication packet. For this reason, no response is made from the gateway 2A to the sensor device 1 (step ST1).
[0023] If there is no response from the gateway 2A within a predetermined time, the sensor device 1 increments the communication channel and sets it to 2ch, and transmits a patrol communication packet by sub-gigahertz communication using 2ch as the communication channel. Here, since the reception waiting communication ch of the gateway 2A is 3ch, the gateway 2A does not receive the patrol communication packet. For this reason, no response is made from the gateway 2A to the sensor device 1 (step ST2).
[0024] If there is no response from the gateway 2A within a predetermined time, the sensor device 1 increments the communication channel and sets it to 3ch, and transmits a patrol communication packet by sub-gigahertz communication using 3ch as the communication channel (step ST3).
[0025] Here, since the communication channel ch waiting for reception at the gateway 2A is channel 3, the communication packet for round-robin is received at the gateway 2A. After interpreting the content of the communication packet for round-robin, the gateway 2A generates a communication packet (hereinafter also appropriately referred to as a response packet) indicating a response to the communication packet for round-robin. The destination address of the response packet is described with the MAC address of the source sensor device 1 described in the communication packet for round-robin. Note that an example of the data structure of the response packet will be described later. Then, the gateway 2A transmits the response packet to the sensor device 1 using communication channel 3.
[0026] The response packet transmitted from the gateway 2A is received by the sensor device 1 (step ST4). By receiving and interpreting such a response packet, the sensor device 1 identifies that the communication channel ch waiting for reception at the gateway 2A is channel 3. Also, the sensor device 1 identifies the MAC address of the gateway 2A as the source based on the MAC address included in the above-described response packet.
[0027] Thereafter, the sensor device 1 communicates with the gateway 2A by sub-gigahertz communication using communication channel 3. That is, the sensor device 1 transmits sensor data including sensing data to the gateway 2A by sub-gigahertz communication using communication channel 3 (step ST5). In response, a response is made from the gateway 2A to the sensor device 1 (step ST6). After step ST5, unicast communication is performed with communication channel 3 and a specific MAC address (the MAC address of the gateway 2A or the MAC address of the sensor device 1) described as the destination address.
[0028] The above-described channel automatic round-robin process is performed when the communication between the sensor device 1 and the gateway 2A is interrupted for any reason other than the timing when the power of the sensor device 1 is turned on, or when the power of the gateway 2A is turned off, etc., that is, when the response from the gateway 2A to the sensor device 1 disappears.
[0029] In addition, when there is no response from the gateway 2A (for example, in the above-described steps ST1 and ST2), a retry process may be performed in which the sensor device 1 transmits a polling communication packet again on the same communication channel. The number of retries can be set as appropriate, such as several times.
[0030] [Problems to be Considered in the Present Invention] Here, with reference to FIG. 3, the problems to be considered in the present invention will be described. The sub-gigahertz communication performed between the sensor device 1 and the gateway 2A has the advantage that radio waves can propagate relatively far as described above. However, depending on the installation environment of the sensor device 1, there may be a case where the sensor device 1 is installed in a location where it cannot communicate with the gateway 2A (a location where the communication packet cannot reach). Note that "not being able to communicate" includes not only the case where the physical distance is far and the radio wave cannot reach, but also the case where the physical distance is far and the communication becomes unstable (for example, when the RSSI (Received Signal Strength Indicator) is equal to or less than a predetermined value).
[0031] For example, as shown in FIG. 3, among the four sensor devices 1, there may be a case where the sensor device 1B is installed in a location where it cannot communicate with the gateway 2A. In this case, since the sensing data of the sensor device 1B cannot be transmitted to the gateway 2A, there is a risk of a problem occurring in the data collection system 100. On the other hand, if the sensor device 1 can only be installed in a location within the communicable range, the applicable field of the data collection system will be limited. With this point in mind, an embodiment of the present invention will be described.
[0032] [Data Collection System in One Embodiment] FIG. 4 shows a configuration example of a data collection system (data collection system 100A) according to the present embodiment. In the description of the present embodiment, the same or similar components as those in the above description are denoted by the same reference numerals, and redundant descriptions are omitted as appropriate.
[0033] The data collection system 100A has, as a plurality of sensor devices 1, for example, four sensor devices 1A, 1B, 1C, and 1D. However, the number of sensor devices can be any number. In FIG. 4, the sensor device 1 has a box-like shape, but the shape of the sensor device 1 can be an appropriate shape. Further, the data collection system 100A has a communication device 2. The communication device 2 has, for example, the above-described gateway 2A and the Internet connection device 2B.
[0034] In the present embodiment, as a specific example of the data collection system 100A, a cold storage temperature management system will be described. The sensor devices 1A, 1B, 1C, and 1D are each installed in a cold storage and sense the temperature inside the cold storage. In the data collection system 100A, generally, sensor data generated by the sensor device 1, which includes sensing data indicating temperature (hereinafter also appropriately referred to as temperature data), is transmitted from the sensor device 1 to the communication device 2. The communication device 2 transmits and uploads the sensor data transmitted from the sensor device 1 to the cloud computer 3.
[0035] On the cloud computer 3 side, the temperature data included in the uploaded sensor data is monitored. For example, when the temperature data is an abnormal value (a high value), it is determined that a failure or malfunction has occurred in the cooling function of the corresponding cold storage. In this case, contact is made with a maintenance contractor, or an alarm installed in the cold storage or the like sounds to notify the abnormality of the cold storage. With such a cold storage temperature management system, it becomes possible to always manage the items stored in the cold storage at a constant cold temperature. Note that, for ease of understanding, the cold storage temperature management system is described as an example, but the application examples of the data collection system 100A are not limited thereby.
[0036] Assume that among the sensor devices 1 that make up the data collection system 100A, the sensor device 1B is installed at a location where it cannot communicate with the gateway 2A. In this case, it is impossible to reliably transmit the sensor data including the temperature data sensed by the sensor device 1B to the gateway 2A. Therefore, the data collection system 100A according to one embodiment has a configuration including a relay device 5 installed between the sensor device 1B and the gateway 2A for relaying the sensor data. The relay device 5 relays the sensor data transmitted from the sensor device 1B and transmits it to the gateway 2A instead of the sensor device 1B. With such a configuration of the data collection system 100A, the sensor data transmitted from the sensor device 1B can be uploaded to the cloud computer 3 via the relay device 5 and the communication device 2. That is, the temperature data sensed by the sensor device 1B can be uploaded to the cloud computer 3, and it becomes possible to appropriately manage the temperature of the cold storage where the sensor device 1B is installed.
[0037] [Sensor device] (Configuration example of sensor device) FIG. 5 is a block diagram showing a configuration example of the sensor device 1. The sensor device 1 includes, for example, a sensor communication module 11 (an example of a first communication unit), a temperature sensor 12, a battery 13, and an antenna 14.
[0038] The sensor communication module 11 is a communication module that performs control (for example, modulation / demodulation processing and data generation processing for transmission and reception) for performing sub-gigahertz communication, and has a function of comprehensively controlling the sensor device 1. For example, the sensor communication module 11 has a detection circuit (not shown) for detecting the remaining capacity (voltage) of the battery 13.
[0039] The temperature sensor 12 is a sensor that acquires the temperature, which is one of the ambient environmental information. The temperature data acquired by the temperature sensor 12 is supplied to the sensor communication module 11. In this embodiment, a temperature sensor is taken as an example of the sensor. However, as the sensor, a humidity sensor, an acceleration sensor, an illuminance sensor, an environmental sensor that measures wind and humidity, a biosensor that measures biological information such as body temperature and pulse, etc. may also be applicable.
[0040] The battery 13 supplies power to the sensor device 1. The battery 13 may be a primary battery or a rechargeable secondary battery. Note that the sensor device 1 may be driven by a commercial power supply instead of the battery 13. However, considering that the sensor device 1 can be installed in various places, a battery-driven method is more preferable than driving by a commercial power supply that is easily restricted by the location of the power supply.
[0041] The antenna 14 is for transmitting and receiving data with the gateway 2A or the relay device 5. Examples of the antenna 14 include a printed antenna provided on the housing of the sensor device 1 or the like.
[0042] (Operation example of the sensor device) An operation example of the sensor device 1 will be schematically described. The sensor communication module 11 generates sensor data for transmission to the gateway 2A or the relay device 5. The sensor data includes an address indicating the destination of the communication partner, temperature data, remaining capacity data indicating the remaining capacity of the battery 13, etc. Note that a communication packet including sensor data packetized according to the communication standard is also appropriately referred to as a data transmission packet. An example of the data structure of the data transmission packet will be described later. The sensor communication module 11 transmits the generated data transmission packet via the antenna 14.
[0043] In addition to the above-described processing, the sensor communication module 11 executes controls related to the above-described channel automatic scanning processing, control for establishing communication with the relay device 5, etc. Details of these controls will be described later.
[0044] [Gateway] (Configuration example of the gateway) FIG. 6 is a block diagram showing a configuration example of the gateway 2A. The gateway 2A includes, for example, a first communication module 21 (an example of a second communication unit), a second communication module 22, and an antenna 23.
[0045] The first communication module 21 is a communication module that performs control for sub-gigahertz communication (for example, modulation / demodulation processing and data generation processing for transmission and reception). The second communication module 22 is a communication module that performs control for communication based on BLE (for example, modulation / demodulation processing and data generation processing for transmission and reception). The antenna 23 is for transmitting and receiving data to and from the sensor device 1 and the relay device 5. Examples of the antenna 23 include a rod antenna. Although not shown in the figure, the gateway 2A has a DIP switch. By operating the DIP switch, the reception-waiting communication channel ch of the gateway 2A can be set.
[0046] The gateway 2A is driven by, for example, a commercial power supply (AC (Alternating Current) power supply) 6. The gateway 2A may be configured to be driven by power supplied from a battery. However, since it is necessary to operate for a relatively long time, it is preferably driven by power supplied from the commercial power supply 6. However, by reducing the power consumption by making the operation of the gateway 2A an intermittent operation, the gateway 2A can also be driven by a battery.
[0047] (Operation example of the gateway) An operation example of gateway 2A will be outlined. A data transmission packet sent from sensor device 1 or relay device 5 is received by antenna 23. The received data transmission packet is supplied to the first communication module 21. The first communication module 21 generates response data for data reception for the sensor device 1 that sent the data transmission packet, and transmits the generated response data for data reception to the corresponding sensor device 1. The response data for data reception is packetized according to the communication standard. Also, the first communication module 21 supplies the data transmission packet to the second communication module 22. The second communication module 22 converts the sensor data into a data transmission packet conforming to the communication standard based on BLE, and transmits the converted data transmission packet to the Internet connection device 2B.
[0048] In addition to the above-described processing, the first communication module 21 executes control related to the above-described channel automatic scanning process and the like. Details of these controls will be described later.
[0049] [Internet connection device] (Configuration example of Internet connection device) FIG. 7 is a block diagram showing a configuration example of the Internet connection device 2B. The Internet connection device 2B includes, for example, a third communication module 24, a fourth communication module 25, and an antenna 26.
[0050] The third communication module 24 is a communication module that performs control for performing communication based on BLE (for example, modulation / demodulation processing and data generation processing for transmission / reception). Also, the fourth communication module 25 is a communication module that performs control for performing communication based on LTE (for example, modulation / demodulation processing and data generation processing for transmission / reception). The antenna 26 is for transmitting and receiving data with the gateway 2A and the cloud computer 3. Examples of the antenna 26 include a rod antenna.
[0051] The device 2B for Internet connection is driven by, for example, a commercial power supply 6. The device 2B for Internet connection may be configured to be driven by the power supplied from a battery, but since it needs to operate for a relatively long time, it is preferably driven by the power supplied from the commercial power supply 6. However, by reducing the power consumption by making the operation of the device 2B for Internet connection an intermittent operation, it is also possible to drive the device 2B for Internet connection with a battery.
[0052] (Operation example of the device for Internet connection) An operation example of the device 2B for Internet connection will be schematically described. A data transmission packet transmitted by communication based on BLE from the gateway 2A is received by the antenna 26. The received data transmission packet is supplied to the third communication module 24. In this case, the device 2B for Internet connection may send a reception response to the gateway 2A. Further, the third communication module 24 supplies the data transmission packet to the fourth communication module 25. The fourth communication module 25 converts the temperature data and the like included in the data transmission packet into a communication packet conforming to the LTE communication standard. The fourth communication module 25 transmits the converted communication packet to the cloud computer 3. The fourth communication module 25 may sequentially transmit the temperature data and the like from the plurality of sensor devices 1 to the cloud computer 3, or may transmit them collectively at predetermined intervals.
[0053] Note that, as described above, the communication device 2 may be one in which the gateway 2A and the device 2B for Internet connection are integrated. The communication device 2 in this case may have a configuration including, for example, an antenna 23, a first communication module 21, and a fourth communication module 25. In the case of such a configuration, the first communication module 21 and the fourth communication module 25 constitute a second communication unit.
[0054] [Relay device] FIG. 8 is a block diagram showing a configuration example of the relay device 5. The relay device 5 includes, for example, a fifth communication module 51 (an example of a third communication unit), a sixth communication module 52, and an antenna 53.
[0055] The fifth communication module 51 is a communication module that performs control (for example, modulation / demodulation processing and data generation processing for transmission and reception) for performing sub-gigahertz communication, for example. The sixth communication module 52 is a communication module that performs control (for example, modulation / demodulation processing and data generation processing for transmission and reception) for performing communication based on BLE. The antenna 53 is for transmitting and receiving data to and from the sensor device 1 and the gateway 2A. Examples of the antenna 53 include a rod antenna. Although not shown, the relay device 5 has a dip switch. By operating the dip switch, the reception standby communication ch of the relay device 5 can be set.
[0056] The relay device 5 is driven by, for example, a commercial power supply 6. The relay device 5 may be configured to be driven by power supplied from a battery, but since it is necessary to operate for a relatively long time, it is preferably driven by power supplied from the commercial power supply 6. However, by reducing the power consumption by making the operation of the relay device 5 an intermittent operation, it is also possible to drive the relay device 5 with a battery.
[0057] In the present embodiment, the hardware configuration of the relay device 5 is the same as the configuration of the gateway 2A (see FIG. 6). Also, the firmware of the relay device 5 is configured differently from that of the gateway 2A so as to execute the functions of the relay device 5 described later.
[0058] Note that the hardware configuration of the relay device 5 may be different from that of the gateway 2A. For example, the relay device 5 serves as a relay between the sensor device 1 and the gateway 2A and does not need to communicate with the Internet connection device 2B. Therefore, the relay device 5 may not have the components related to the sixth communication module 52. However, by making the hardware configuration of the relay device 5 the same as that of the gateway 2A, there is no need to newly prepare a relay device having a configuration different from that of the gateway 2A.
[0059] The communication modules in each of the above-described devices are configured by, for example, a microcomputer (MCU: Micro Controller Unit).
[0060] [Processing performed in the data collection system] Next, a specific example of the processing performed in the data collection system 100A will be described.
[0061] (Test communication processing) First, the test communication processing will be described. In order for the relay device 5 to function properly, it is essential that the relay device 5 be installed in a place where it can communicate with the gateway 2A. Therefore, before the relay device 5 communicates with the sensor device 1, test communication processing is performed, and as a result, the relay device 5 is installed at a location where it is determined that communication between the relay device 5 and the gateway 2A can be established. The test communication processing is performed, for example, when the relay device 5 is powered on. Hereinafter, an example of the test communication processing will be described.
[0062] FIG. 9 is a diagram for explaining the test communication processing. In this example, the reception waiting communication ch of the gateway 2A is described as 1ch. After setting the communication channel to the smallest 1ch, the relay device 5 broadcasts a predetermined communication packet for connection confirmation (hereinafter also appropriately referred to as a test packet) to the gateway 2A (step ST11). The generation and transmission control of the test packet are performed by the fifth communication module 51 of the relay device 5.
[0063] Since the communication channel ch waiting for reception of the gateway 2A is 1ch, the test packet transmitted from the relay device 5 is received by the gateway 2A. The gateway 2A interprets the content of the received test packet, generates a predetermined communication packet (hereinafter also appropriately referred to as a test response packet) in response to the reception of the test packet, and transmits it to the relay device 5 (step ST12). The interpretation of the test packet, the generation of the test response packet, and the transmission control are performed by the first communication module 21 of the gateway 2A. By the test communication process, the relay device 5 identifies the communication channel used in the communication with the gateway 2A. The relay device 5 appropriately stores the identified communication channel. In this way, the communication channel for the communication between the relay device 5 and the gateway 2A is set software-wise, not by a physical setting using a dip switch or the like.
[0064] When the communication channel ch waiting for reception has a channel number larger than 1ch (for example, 3ch), the test response packet is not transmitted from the gateway 2A to the relay device 5. When the test response packet is not transmitted for a certain period, the relay device 5 increments the channel number of the communication channel by 1 and then transmits the test packet again by broadcast. By repeating this process, when the relay device 5 sets the communication channel to 3ch, the test response packet is transmitted from the gateway 2A to the relay device 5.
[0065] FIG. 10 is a diagram for explaining an example of the data structure of a test packet. The test packet includes a header and a payload which is a data part other than the header. In the header, for example, "data ID" and "data length" are described. In the payload, for example, "sequence number", "source address", and "destination address" are described, and the other area is a "data area" in which various data are described.
[0066] The "sequence number" is a number that is incremented for each transmission. The "source address" describes the MAC address of the relay device 5 that transmits the test packet. The "destination address" describes all "F"s without specifying a specific address. As a result, the test packet is transmitted as a broadcast. In the "data area" of the test packet, a connection test flag indicating that it is a test communication is described. The other areas of the "data area" are unused areas (reserved areas).
[0067] FIG. 11 is a diagram for explaining an example of the data structure of a test response packet. The test response packet includes a header and a payload which is a data part other than the header. In the header, for example, "data ID" and "data length" are described. In the payload, for example, "sequence number", "source address", and "destination address" are described, and the other area is a "data area" where various data are described.
[0068] The "sequence number" describes the sequence number described in the test packet. That is, the sequence number when the gateway 2A receives the test packet is directly returned to the relay device 5. The "source address" describes the MAC address of the gateway 2A that transmits the test response packet. The "destination address" describes the MAC address of the relay device 5 described in the test packet. The "data area" is a reserved area.
[0069] (Process of directly transmitting sensor data) Next, the process of directly transmitting sensor data to the gateway 2A will be described. In the data collection system 100A, the sensor devices 1A, 1C, and 1D are installed in locations where they can communicate with the gateway 2A (see FIG. 4). In this case, the sensor data transmitted from each sensor device is directly transmitted to the gateway 2A without passing through the relay device 5.
[0070] For example, the sensor device 1A transmits a communication packet for polling to the gateway 2A by the above-described channel automatic polling process. When a response packet corresponding to the communication packet for polling is transmitted from the gateway 2A to the sensor device 1A, communication between the sensor device 1A and the gateway 2A is established. After the communication is established, the sensor device 1A transmits a data transmission packet including sensor data to the gateway 2A through a communication channel corresponding to the reception-waiting communication ch (1ch in this example) of the gateway 2A. The same processing is performed for the sensor devices 1C and 1D. Since one transmission is completed in about several tens of ms (milliseconds), it is extremely rare for the sensor devices 1 to start simultaneously and for the timings of transmitting the communication packets for polling to strictly overlap. Therefore, the possibility of a collision of the communication packets for polling is extremely low.
[0071] FIG. 12 is a diagram for explaining an example of the data structure of a communication packet for polling transmitted from the sensor device 1 to the gateway 2A in the channel automatic polling process. The generation and transmission control of such a communication packet for polling are performed by the sensor communication module 11.
[0072] As shown in FIG. 12, the communication packet for polling includes a header and a payload which is a data portion other than the header. For example, "data ID" and "data length" are described in the header. For example, "sequence number", "source address", and "destination address" are described in the payload, and the other area is a "data area" in which various data are described.
[0073] The "sequence number" is a number that is incremented each time a transmission is made. The "source address" describes the MAC address of the sensor device 1 that transmits the communication packet for the round-robin. As the "destination address", all "F"s without specifying a specific address are described. As a result, the communication packet for the round-robin is transmitted by broadcast. In the "data area" of the communication packet for the round-robin, sensor data is described. The sensor data includes temperature data measured by the temperature sensor 12, data indicating the remaining capacity of the battery 13, and the like.
[0074] FIG. 13 is a diagram for explaining an example of the data structure of a response packet for a communication packet for round-robin transmitted from the gateway 2A to the sensor device 1. The response packet includes a header and a payload which is a data part other than the header. In the header, for example, "data ID" and "data length" are described. In the payload, for example, "sequence number", "source address", and "destination address" are described, and the other area is a "data area" in which various data are described.
[0075] The "sequence number" describes the sequence number described in the communication packet for the round-robin. That is, the sequence number when the gateway 2A receives the communication packet for the round-robin is directly returned to the sensor device 1. The "source address" describes the MAC address of the gateway 2A that transmits the response packet. The "destination address" describes the MAC address of the sensor device 1 described in the communication packet for the round-robin. The "data area" is a reserved area.
[0076] FIG. 14 is a diagram for explaining an example of the data structure of a data transmission packet transmitted from the sensor device 1 to the gateway 2A after communication is established between the sensor device 1 and the gateway 2A by the channel automatic round-robin process. The generation and transmission control of such a data transmission packet are performed by the sensor communication module 11.
[0077] As shown in FIG. 14, the packet for data transmission includes a header and a payload which is a data part other than the header. In the header, for example, "data ID" and "data length" are described. In the payload, for example, "sequence number", "source address", and "destination address" are described, and the other area is a "data area" where various data are described.
[0078] The "sequence number" is a number incremented for each transmission. The "source address" describes the MAC address of the sensor device 1 that transmits the packet for data transmission. The sensor device 1 can recognize the MAC address of the gateway 2A described in the response packet by interpreting the response packet when transmitted from the gateway 2A. The "destination address" of the packet for data transmission describes the MAC address of the gateway 2A recognized based on the response packet. Thereby, the packet for data transmission is transmitted as a unicast specifying a specific destination. The "data area" in the packet for data transmission describes sensor data.
[0079] [Data Relay Processing] Next, with reference to FIG. 15, an example of data relay processing for relaying a packet for data transmission transmitted from a predetermined sensor device 1 by a relay device 5 and transmitting it to a gateway 2A will be described.
[0080] As shown in FIG. 15, let the reception waiting communication ch of the gateway 2A be 1ch. It is assumed that a connection is established by test communication between the gateway 2A and the relay device 5. The reception waiting communication ch of the relay device 5 is set to be different from the reception waiting communication ch of the gateway 2A. As an example, 3ch is set as the reception waiting communication ch of the relay device 5. The reception waiting communication ch of the relay device 5 is set, for example, by operating the dip switch of the relay device 5.
[0081] It is assumed that the sensor devices 1A, 1C, and 1D are installed within a range where they can communicate with the gateway 2A. After establishing communication with the gateway 2A through the above-described automatic channel scanning process, the sensor devices 1A, 1C, and 1D transmit data packets for data transmission (see FIG. 14) including sensor data to the gateway 2A. In this example, since the reception waiting communication ch of the relay device 5 is 3ch, the data packets for data transmission transmitted from the sensor devices 1A, 1C, and 1D are not received by the relay device 5. That is, the data packets for data transmission transmitted from the sensor devices 1A, 1C, and 1D are directly transmitted to the gateway 2A without being relayed by the relay device 5.
[0082] It is assumed that the sensor device 1B is installed in a location where it cannot communicate with the gateway 2A but can communicate with the relay device 5. The sensor device 1B also performs automatic channel scanning processing in the same manner as the sensor device 1A and the like. That is, the sensor device 1B broadcasts a scanning communication packet (see FIG. 12) using communication channel 1ch (step ST21). Here, since the sensor device 1B is installed in a location where it cannot communicate with the gateway 2A, no response packet (see FIG. 13) is transmitted from the gateway 2A to the sensor device 1B. Also, since the reception waiting communication ch of the relay device 5 is 3ch, the scanning communication packet is not received by the relay device 5. That is, no response packet is transmitted from the relay device 5 to the sensor device 1B.
[0083] If a response packet is not transmitted within the specified period, the sensor device 1B switches the communication channel from 1ch to 2ch and broadcasts a patrol communication packet (step ST22). Also in this case, since the sensor device 1B is installed in a location where it cannot communicate with the gateway 2A, no response packet is transmitted from the gateway 2A to the sensor device 1B. Further, since the communication ch waiting for reception by the relay device 5 is 3ch, the relay device 5 does not receive the patrol communication packet. That is, no response packet is transmitted from the relay device 5 to the sensor device 1B.
[0084] If a response packet is not transmitted within the specified period, the sensor device 1B switches the communication channel from 2ch to 3ch and broadcasts a patrol communication packet (step ST23). Also in this case, since the sensor device 1B is installed in a location where it cannot communicate with the gateway 2A, no response packet is transmitted from the gateway 2A to the sensor device 1B. However, since the communication ch waiting for reception by the relay device 5 is 3ch, the relay device 5 receives the patrol communication packet, and further, a response packet is transmitted from the relay device 5 to the sensor device 1B (step ST24). Thereby, communication is established between the sensor device 1B and the relay device 5.
[0085] Here, in the "source address" of the response packet transmitted from the relay device 5 to the sensor device 1B, the MAC address of the gateway 2A is described instead of the relay device 5. The relay device 5 identifies the MAC address of the gateway 2A by test communication processing. For this reason, the relay device 5 can describe the MAC address of the gateway 2A in the "source address" of the response packet transmitted to the sensor device 1B. Thereby, from the viewpoint of the sensor device 1B side, it seems as if the response packet is transmitted not from the relay device 5 but as if it is transmitted from the gateway 2A.
[0086] After the communication is established, the sensor device 1B transmits a data transmission packet using communication channel 3ch. In the "destination address" of the data transmission packet, the MAC address of the gateway 2A described in the "source address" of the response packet transmitted from the relay device 5 is described. In the "source address" of the data transmission packet, the MAC address of the sensor device 1B is described. The data transmission packet transmitted from the sensor device 1B is received by the relay device 5.
[0087] After switching the communication channel from 3ch to 1ch, the relay device 5 transmits the data transmission packet transmitted from the sensor device 1B to the gateway 2A. At this time, the relay device 5 basically does not change the content of the data transmission packet. That is, in the "source address" of the data transmission packet, the MAC address of the sensor device 1B remains described instead of the relay device 5. The data transmission packet transmitted from the relay device 5 is received by the gateway 2A. As described above, since the MAC address of the sensor device 1B is described in the "source address" of the data transmission packet, from the perspective of the gateway 2A side, it seems that the data transmission packet is transmitted from the sensor device 1B. In the above manner, the data transmission packet transmitted from the sensor device 1B is relayed and the relayed data transmission packet surely reaches the gateway 2A.
[0088] The relay device 5 receives a response packet from the gateway 2A due to transmitting the data transmission packet transmitted from the sensor device 1B to the gateway 2A. After receiving it, it switches (returns) the communication channel from 1ch to 3ch and becomes in a reception waiting state for a data transmission packet transmitted from the sensor device 1B at the next timing.
[0089] When the relay device 5 cannot receive a response packet from the gateway 2A, the relay device 5 transmits a packet for data transmission to the gateway 2A again (retry process). The retry process is performed, for example, about several times. Note that the retry process may not be performed. If the relay device 5 still cannot receive a response packet from the gateway 2A even after the retry process, the relay device 5 performs the channel automatic scanning process again to search for the gateway 2A and re - establish the connection with the gateway 2A. If the connection with the gateway 2A can be re - established (for example, on 1ch), the relay device 5 sets the communication channel to 3ch (the communication channel with the sensor device 1B). Then, the relay device 5 waits for reception of a packet for data transmission sent from the sensor device 1B at the next timing.
[0090] In this example, the relay device 5 discards the packet for data transmission that has failed to be transmitted to the gateway 2A without saving it. That is, even when the relay device 5 re - establishes the connection with the gateway 2A, instead of transmitting the packet for data transmission that has failed to be transmitted to the gateway 2A before, it transmits the packet for data transmission sent from the sensor device 1B at the next timing to the gateway 2A. Thereby, even if it takes time to re - establish the connection with the gateway 2A (even if the packet for data transmission that has failed to be transmitted becomes old information in terms of time), the relay device 5 can obtain the latest packet for data transmission and transmit it to the gateway 2A. Also, since there is no need to save the packet for data transmission that has failed to be transmitted, the used area of the memory can be saved, and processes such as reading the packet for data transmission from the memory can be eliminated. However, this does not prohibit the relay device 5 from saving the packet for data transmission that has failed to be transmitted in the memory and re - transmitting the saved packet for data transmission to the gateway 2A after re - establishing the connection with the gateway 2A. After the re - transmission of the packet for data transmission is successful, the relay device 5 waits for reception of a packet for data transmission sent from the sensor device 1B at the next timing.
[0091] [Effects Obtained by this Embodiment] According to the present embodiment described above, the following effects can be obtained. Sensor data transmitted from a sensor device 1 (for example, sensor device 1B) disposed in a location where communication with the gateway 2A is not possible can be reliably transmitted to the gateway 2A via the relay device 5. Then, the sensor data can be reliably transmitted to the cloud computer 3 via the gateway 2A and the Internet connection device 2B. By using the relay device 5, the sensor device 1 can be installed even in a certain location where communication with the gateway 2A is not possible. Thereby, the degree of freedom in designing the data collection system can be increased. In addition, the applicable applications of the data collection system can be expanded. The relay device 5 transmits the data transmission packet sent from the sensor device 1B to the gateway 2A as it is, except for changing the communication channel. Thereby, it is possible to extremely suppress an increase in the load of the processing performed by the relay device 5. The sensor device 1 may perform channel automatic polling processing and transmit a data transmission packet to the partner with which communication has been established in the processing. That is, there is no need to identify the presence of the relay device 5 or perform special processing on the relay device 5 (for example, processing to set the "destination address" to the relay device 5). The gateway 2A also does not need to identify the presence of the relay device 5. Therefore, there is no need to newly perform special processing or the like for identifying whether the data transmission destination is the sensor device 1 or the relay device 5. In this way, the processing described in one embodiment can be realized without substantially adding new processing.
[0092] In the above-described embodiment, the communication channel (first communication channel) used by the relay device 5 for communication with the sensor device 1 is different from the communication channel (second communication channel) used by the relay device 5 for communication with the communication device 2 (for example, gateway 2A). Specifically, the channel number of the reception waiting channel of the relay device 5 is made larger than the channel number of the reception waiting channel of the gateway 2A. The advantages obtained thereby will be described with reference to FIG. 16.
[0093] As shown in Fig. 16, the receiving standby channels of the gateway 2A are set to 3 channels. Also, the receiving standby channel of the relay device 5 is set to 1 channel. Assume that the sensor device 1 (for example, sensor device 1A) is installed at a location within a range where it can communicate with the gateway 2A and also with the relay device 5, unlike the sensor device 1B. Also assume that communication has been established between the gateway 2A and the relay device 5 through test communication processing.
[0094] As described above, the sensor device 1A performs channel automatic scanning processing. The search in the channel automatic scanning processing is performed in ascending order of the channel number so as to reliably detect the communication partner. That is, the sensor device 1A performs channel automatic scanning processing in order from channel number 1 channel.
[0095] In this example, the receiving standby communication channel of the gateway 2A is 3 channels, and the receiving standby communication channel of the relay device 5 is 1 channel. Therefore, when the sensor device 1A sets the communication channel to 1 channel and performs channel automatic scanning processing, communication is established first between the sensor device 1A and the relay device 5, rather than between the sensor device 1A and the gateway 2A.
[0096] After that, the sensor device 1A transmits a data transmission packet to the relay device 5, and the relay device 5 transmits the data transmission packet transmitted from the sensor device 1A to the gateway 2A.
[0097] Even when the channel number of the receiving standby communication channel of the gateway 2A is larger than the receiving standby channel number of the relay device 5, the data transmission packet transmitted from the sensor device 1A will ultimately reach the gateway 2A. However, by passing through the relay device 5, unnecessary data relay processing is originally performed. This causes an unnecessary delay when transmitting a data transmission packet. Also, as the communication route increases, the risk of data transmission packets being lost due to communication failures etc. increases. Furthermore, the installation of the originally unnecessary relay device 5 may lead to an increase in cost.
[0098] From the perspective of avoiding such inconveniences, it is preferable that the channel number of the communication channel used by the relay device 5 for communication with the sensor device 1 (the channel number of the first communication channel) is larger than the channel number of the communication channel (the channel number of the second communication channel) used by the relay device 5 for communication with the communication device 2 (for example, the gateway 2A).
[0099] <Modification Example> As described above, the embodiments of the present invention have been specifically described. However, the present invention is not limited to the above-described embodiments, and various modifications based on the technical idea of the present invention are possible. Hereinafter, modification examples will be described.
[0100] In the above-described one embodiment, an example in which one relay device is installed in the data collection system has been described. However, a plurality of relay devices may be installed in the data collection system. For example, as shown in FIG. 17, for example, two relay devices 5A (an example of the first relay device) and 5B (an example of the second relay device) may be installed in the data collection system.
[0101] Also, it is assumed that sensor devices 1A (an example of the first sensor device) and 1B (an example of the second sensor device) are arranged in locations where they cannot communicate with the communication device 2 (for example, the gateway 2A). The reception-waiting communication ch of the communication device 2 is set to 1ch. Between the communication device 2 and the relay devices 5A and 5B, a communication with a communication channel of 1ch has been established by test communication processing. It is assumed that the sensor devices 1C and 1D are arranged in locations where they can communicate with the communication device 2.
[0102] The channel numbers of the reception-waiting communication ch of each of the relay devices 5A and 5B are set to be different. For example, it is assumed that the channel number of the reception-waiting communication ch of the relay device 5A is set to 2ch, and the channel number of the reception-waiting communication ch of the relay device 5B is set to 3ch.
[0103] The fifth communication module 51 of the relay device 5A receives data transmission packets transmitted from the sensor device 1A through communication using two communication channels. The fifth communication module 51 of the relay device 5B performs communication using a third communication channel 3ch (an example of a third communication channel), which is different from the two communication channels used by the relay device 5A for communication with the sensor device 1A and the communication channel 1ch used by the relay devices 5A and 5B for communication with the communication device 2. Through such communication, the relay device 5B receives data transmission packets transmitted from the sensor device 1B. In this way, the relay device 5A relays the data transmission packets from the sensor device 1A, and the relay device 5B relays the data transmission packets transmitted from the sensor device 1B. Note that one relay device may relay data transmission packets transmitted from a plurality of sensor devices.
[0104] In the above-described test communication process, the gateway 2A may instruct the relay device 5 of the communication channel used by the relay device 5 for communication with the sensor device 1, specifically, the channel number of the reception-waiting communication ch of the relay device 5. For example, as shown in FIG. 18, the channel number of the communication channel used by the relay device 5 for communication with the sensor device 1 may be described in the payload of the test response packet transmitted from the gateway 2A to the relay device 5. The gateway 2A can identify the channel number of the reception-waiting communication ch set in itself. Therefore, the gateway 2A describes a channel number larger than the channel number of the reception-waiting communication ch set in itself as the channel number of the communication channel used by the relay device 5 for communication with the sensor device 1. The relay device 5 sets the channel number instructed by the gateway 2A as the reception-waiting communication ch.
[0105] Also, consider the case where a plurality of relay devices 5 are installed and the gateway 2A has already instructed a relay device 5 to wait for a communication ch to be received. In this case, the gateway 2A describes a channel number of a communication channel used for communication with the sensor device 1 that is later than the channel number of the communication channel already instructed to the relay device 5. By performing the above processing, the relay device 5 only needs to set the communication channel instructed by the gateway 2A as the communication ch waiting to be received, and can eliminate the need to search for which communication channel should be set. When there is an available communication channel for the relay device 5 to communicate with the sensor device 1, the gateway 2A may describe the channel number of the available communication channel as the channel number of the communication channel used by the relay device 5 to communicate with the sensor device 1.
[0106] In one embodiment, sensor data is transmitted by communication in the sub-gigahertz frequency band, but sensor data may be transmitted by communication using a frequency band different from the sub-gigahertz frequency band.
[0107] The configurations, methods, processes, shapes, materials, numerical values, etc. of the above-described embodiment can be combined with each other and replaced as long as they do not deviate from the gist of the present invention. Also, it is possible to divide one thing into two or more, and it is also possible to combine two or more things into one. Furthermore, it is possible to omit a part.
Explanation of Reference Numerals
[0108] 1, 1A, 1B, 1C, 1D ··· Sensor devices 2 ··· Communication device 2A ··· Gateway 2B ··· Device for Internet connection 3 ··· Cloud computer 5, 5A, 5B ··· Relay devices 11 ··· Sensor communication module 12 ··· Temperature sensor 21... The first communication module 51... The fifth communication module
Claims
1. One or more sensor devices, a communication device, and a relay device that relays sensor data transmitted between the sensor device and the communication device, wherein the sensor device includes a sensor that acquires sensing data included in the sensor data, and a first communication unit that transmits the sensor data, the communication device has a second communication unit that receives the sensor data transmitted from the sensor device that cannot communicate with the communication device among the one or more sensor devices from the relay device, the relay device has a third communication unit that receives the sensor data transmitted from the sensor device that cannot communicate with the communication device and transmits the received sensor data to the communication device, wherein a first communication channel used by the relay device for communication with the sensor device is different from a second communication channel used by the relay device for communication with the communication device, a data collection system.
2. The data collection system according to claim 1, wherein the channel number of the first communication channel is larger than the channel number of the second communication channel.
3. The second communication unit receives the sensor data transmitted from the sensor device that can communicate with the communication device among the one or more sensor devices by communication using the second communication channel. The data collection system according to claim 1 or 2.
4. The relay device establishes communication with the communication device by performing test communication with the communication device before communicating with the sensor device. The data collection system according to claim 1 or 2.
5. The second communication unit transmits the sensor data to a server device. The data collection system according to claim 1 or 2.
6. The sensor is a sensor that measures ambient environmental information. The data collection system according to claim 1 or 2.
7. including at least the first relay device, the second relay device, the first sensor device that cannot communicate with the communication device, and the second sensor device that cannot communicate with the communication device, the third communication unit of the first relay device receives the sensor data transmitted from the first sensor device by communication using the first communication channel, The third communication unit included in the second relay device receives the sensor data transmitted from the second sensor device through communication using a third communication channel different from the first and second communication channels. The data collection system according to claim 1 or 2.
8. It has a communication unit that receives sensor data transmitted from a sensor device that cannot communicate with a communication device and transmits the received sensor data to the communication device. The communication unit communicates with the sensor device using a first communication channel, and communicates with the communication device using a second communication channel different from the first communication channel. Relay device.
9. The channel number of the first communication channel is larger than the channel number of the second communication channel. The relay device according to claim 8.
10. A communication device capable of communicating with a sensor device that acquires sensor data and a relay device that relays the sensor data, The sensor device capable of communicating with the communication device communicates using a first communication channel. With respect to the relay device, as information indicating a communication channel used by the relay device and the sensor device that cannot communicate with the communication device, information indicating a second communication channel having a channel number larger than the channel number of the first communication channel is transmitted. Communication device.
Citation Information
Patent Citations
Control system and controller
JP2021174572A