EP-4487551-B1 - METHODS AND APPARATUS FOR CONFIGURING A DEVICE TO READ DATA FROM A SENSOR
Inventors
- EVANS, TIMOTHY PAUL
Dates
- Publication Date
- 20260506
- Application Date
- 20230227
Claims (13)
- A method of configuring a device to read data from a sensor, the method comprising: determining that a sensor has been connected to an interface of the device and determining an address of the sensor, wherein the address of the sensor is indicative of a sensor type and is preconfigured or selected from multiple preconfigured addresses; based on the address of the sensor, identifying a sensor type of the sensor; sending a control script to the device, wherein the control script comprises a set of instructions that, when executed by a processor of the device, causes the device to read sensor data from the sensor via the interface, wherein the set of instructions is specific to the identified sensor type of the sensor.
- The method of claim 1, wherein identifying a sensor type of the sensor comprises: based on the address of the sensor, determining one or more possible candidate sensor types of the sensor; if the one or more possible candidate sensor types consists of exactly one candidate sensor type, determining that the sensor type of the sensor is the exactly one candidate sensor type; if the one or more possible candidate sensor types comprises a plurality of candidate sensor types, selecting a candidate sensor type of the plurality of candidate sensor types and: a) sending a test script to the device, wherein the test script comprises a set of instructions that, when executed by a processor of the device, causes the device to read data from the sensor via the interface, wherein the set of instructions is specific to sensors of the selected candidate sensor type; b) receiving data from the device, wherein the data is read from the sensor by the device during execution of the test script; c) based on the data read from the sensor during execution of the test script, determining whether the sensor type of the sensor is the selected candidate sensor type, d) selecting different candidate sensor types from the plurality of candidate sensor types and repeating steps a) to c) until the sensor type of the sensor has been identified.
- The method of claim 1 or claim 2, wherein determining that a sensor has been connected to the interface comprises: receiving a first list of addresses of one or more sensors connected to the device via the interface at a first time; receiving a second list of addresses of one or more sensors connected to the device via the interface at a second time; and comparing the first and second lists of addresses to determine that a sensor has been connected to the interface between the first time and the second time.
- The method of any preceding claim, further comprising: receiving the sensor data from the device; and performing data processing on the sensor data, wherein the processing is specific to the identified sensor type of the sensor.
- A method of configuring a device to read data from a sensor, wherein the device comprises an interface, wherein one or more sensors are connected to the device via the interface, the method comprising: providing an indication of one or more sensors connected to the device via the interface to a remote server, wherein providing an indication of one or more sensors connected to the device via the interface to a remote server comprises sending a list of address of the one or more sensors connected to the device via the interface to the remote server, wherein the address of each sensor is indicative of a sensor type and is preconfigured or selected from multiple preconfigured addresses; and receiving a control script from the remote server, wherein the control script comprises a set of instructions that, when executed by a processor of the device, causes the device to read sensor data from the sensor via the interface, wherein the set of instructions is specific to the sensor type of the sensor.
- The method of claim 5, wherein the method further comprises a) receiving a test script from the remote server, wherein the test script comprises a set of instructions that, when executed by a processor of the device, causes the device to read data from the sensor via the interface; b) executing the test script so that data is read from the sensor via the interface; and c) sending the data to the remote server.
- The method of claim 6, further comprising repeating steps a) to c) for a plurality of different test scripts received from the remote server.
- The method of any of claims 5 to 7, wherein providing an indication of one or more sensors connected to the device via the interface to a remote server further comprises: i) sending a polling message via the interface to the one or more sensors connected to the device via the interface; and ii) receiving addresses of the one or more sensors connected to the device via the interface.
- The method of claim 8, wherein steps i) to ii) are performed at a first time to provide a first list of addresses of one or more sensors connected to the device via the interface, wherein steps i) to ii) are further performed at a second time to provide a second list of addresses of one or more sensors connected to the device via the interface.
- The method of any of claims 5 to 9, further comprising: executing the control script so that sensor data is read from the sensor via the interface; and sending the sensor data to the remote server.
- A server configured to perform the method of any of claims 1 to 4.
- A device comprising: a processor; and an interface, communicatively coupled to the processor configured to be one or more sensors, wherein the device is configured to perform the method of any of claims 5 to 9.
- A system comprising: one or more a devices according to claim 12; and a server according to claim 11, wherein the server is remote form the device and in communication with the device via a mobile data network.
Description
Field of the invention The present invention relates to software for flexibly interfacing with sensor devices. More specifically, the invention relates to detecting connected sensors and provisioning software for obtaining sensor data from the connected sensors in a low-power system. Background New communications technologies have emerged that focus on energy efficient transmission of small, infrequent data. Using these, it is realistic to create cheap sensors and collections of sensors that communicate with remote severs (possibly across the internet) to allow collection of data or control of actuators. The data could be used by researchers, government bodies, commercial entities, consumers or private individuals to determine a wide range of parameters e.g. temperature, location, pressure flow, gas concentrations or control actuators e.g. relays, displays, locks. The development of secure, battery efficient, reliable, cost effective devices, and systems to make best use of the available technologies is a difficult problem and requires a wide range of expertise. Currently developments making use of these emerging technologies are restricted to large organisations that are able to fund large-scale research projects with uncertain benefits and justify the associated risks. It is common for sensor devices to be constrained in the amount of data that can be communicated and the frequency at which the data may be communicated (e.g. number of times per day), so that an appropriate battery life or communication bandwidth limit for the device can be met. Such devices are also likely to have constrained memory due to cost and power drain. As these sensor devices have a communication channel, it is possible for them to be administrated from a remote server. Such a communications channel may be 3GPP NB-loT. It is common for sensors to communicate with a "reading device" such as a microprocessor using analogue voltage levels, pulses or through a serial bus (such as I2C, SPI, RS485 or UART) or a parallel interface. Many sensors use I2C to communicate with a processor that is local to the device. It is possible for some devices to have multiple selectable address so that multiple sensors of that type can be placed on the same bus but be individually addressable. These addresses may be set using either hardware or software means depending on the sensor. It is also typical for devices to have more than one bus to communicate with sensors, to reduce interface issues and allow multiple sensors with the same I2C address to be connected to the same device. I2C is an example of a serial bus that allows many I2C devices to be connected in parallel with each other. Each device on the I2C bus has a unique I2C address that allows it to be selected using the I2C interface alone. The I2C interface is characterised by a common basic protocol upon which a sensor / actuator specific protocol is built. This means that few, if any, sensors have the same sensor / actuator specific protocol requiring the connected device to have methods to identify and interface to each individual type of sensor. To enable entities with less technical knowledge to create their own sensor platforms that communicate in a secure, battery efficient, reliable and cost effective way, a tested and optimised, pre-developed device / server combination is desirable. Such a device would be limited by the sensor or actuator devices known at the time of development and may require a large amount of resources (such as memory) to cope with the wide range of sensor devices that could be connected. It is therefore desirable to provide devices that collect sensor data and communicate said data in small, infrequent, secure data packets. Development and provisioning of software and hardware for such sensors is difficult and requires not only hardware and software skills but experience in other areas such as: low power devices, device originated protocols, secure devices, Sensor communication, sensor operation, server design, system design and testing. As each sensor requires its own specific sensor driver in the device, any developer of a common sensor platform needs to address the amount of drivers required, the memory space these drivers take up, and how to interface new devices that were not know when the device software was developed. It is known and is possible to download firmware either at the device or over the air to manage or add new firmware to a device, thus adding the drivers for a new sensor to a device. However such a solution introduces security holes into the device that may be exploited by hackers and potentially requires significant memory and large data transmission. CN 113 259 888 A discloses a sensor configuration method and device, the method comprising acquiring connection configuration information generated based on user input. The connection configuration information comprises a sensor identifier and a communication port identifier. US 2019/0273737 A1