Energy-harvesting sensors for Assisted Living

In this project, a wireless energy harvesting sensor network monitors key locations to ensure safety of users in need of assisted living.

Similar projects worth following
In this project, a system will be proposed which is composed of a server and small
wireless energy-harvesting sensor modules, providing the user with safety in their own
home by monitoring key locations while at the same time not being invasive to the user’s
privacy. This is achieved through various passive sensors which gather just enough data
to make decisions about whether the user is in need of help.

To gather enough data, the following areas will be logged by sensors:
• Presence in bed
• Usage of toilet and water taps
• Usage of electric appliances, in particular ones that could pose a hazard

This is achieved with a Panasonic AMG8831 infrared grid array (presence detection), temperature sensors (water flow detection) and a custom inductive current sensor which will be described in detail here.

In this project, wireless energy-harvesting sensor nodes are developed on top of EnOcean STM3xx modules. The modules provide the energy-harvesting circuit, a battery, a solar cell and an 8051-compatible microcontroller.

The modules developed are:

  1. Water flow detection module
    This module works by measuring the temperature change in water pipes using a temperature sensor (details here)
  2. Current detection module
    This module attaches to power cables and detects current flow without any need to split cables. (details here)
  3. Infrared sensor array module
    This module can be both used for presence detection as well as monitoring of devices that generate heat. It is based on a Panasonic AMG8831 Grid-Eye MEMS sensor array. (details here)

Most of the technical details are in the project logs!

The picture above shows an example setup using the modules for monitoring presence as well as different devices. Using this data, the system can make decisions about whether the user is in need of help.

A big focus of this project is being non-invasive in 3 ways:

  • Any measurement done by sensors should be non-invasive and require no alteration of the devices (such as putting an adapter between a device and the power plug)
  • The sensors should be visually non-invasive and require no cables.
  • The privacy of the user has priority, ruling out things like video processing for presence detection.

The sensors send their data to a EnOcean USB300 module connected to a small server, which processes the input and makes decisions. These decisions will largely depend on which devices the sensors monitor.

A more detailed view of the system setup can be seen below.

Panasonic AMGXX Grid-Eye Sensor.skp

SketchUp model of the AMG88XX Grid-Eye sensor. Used for designing a prototype case.

SSEYO Koan Play File - 110.46 kB - 10/03/2016 at 21:52


CurrentSensor Charts.ods

Annotated raw data collected with the current sensor.

spreadsheet - 128.07 kB - 10/03/2016 at 21:51


Simple Serial logger written in python, used to collect data from the Arduino test setups

py - 522.00 bytes - 10/03/2016 at 21:50


Test program for gathering values from the current sensor.

x-zip - 1.48 kB - 10/03/2016 at 21:11


Test program for getting values from the AMG8831 and sending them to the PC. Also includes a library I made for interfacing an Arduino with the AMG8831

x-zip - 2.93 kB - 10/03/2016 at 21:11


View all 6 files

  • 1 × MCP6231 Amplifier and Linear ICs / Operational Amplifiers
  • 1 × TMP75B I²C 1.8V compatible Temperature sensor
  • 3 × EnOcean STM330 Energy harvesting ultra-low-power wireless modules
  • 1 × EnOcean USB300
  • 1 × Panasonic AMG8831 Grid-Eye infrared sensor array

View all 8 components

  • The current state of the project

    karpour10/03/2016 at 22:17 0 comments

    The main 3 problems have been tackled, with the current detector being particularly tricky. What remains is connecting the sensors to EnOcean modules rather than an ATMega. As the firmware is very small, this will be trivial, however the big question that remains is whether all of the modules will be able to operare on battery power alone.

    With the Grid-Eye module the answer is clearly no. The module consumes too much current while needing too much time to produce clear images (reading an image after the suggested wait time of 50ms after start up still produced a very noisy image). Therefore, this module will have a backup battery.

    (left) The current Arduino setup. (right) A 3d printed prototype case that houses a AA-sized 3.6V Lithium battery. (The final module will likely use a smaller battery than the AA-sized one shown here)

    For the current detector, a smaller form factor prototype was made which can be attached to cables more easily. Using SMD parts, the size of the circuit can be further reduced to create a module barely bigger than the STM330 module itself.

    Current detector, attached to a 3-wire 230V power cable.

  • Presence detection using the AMG8831 infrared sensor array

    karpour10/03/2016 at 21:47 0 comments

    Via an I²C-capable level shifter based on BSS138 FETs, a test setup was built, with the AMG8831 being connected to an ATMega328 AVR microcontroller. The level shifter was used to allow I²C communication between the AVR (with a logic level of 5V) and the AMG8831 (With a logic level of 3.3V). Even though the logic levels are different, the same logic level shifter will be used in the final prototype as it is also capable of enabling communication between 1.8V and 3.3V logic levels.

    A test program was written which initializes the AMG8831 and sets configuration registers. Whenever the PC requests them, the AVR program retrieves the 64 12-bit (11 bits + sign) temperature values from the AMG8831, converts them into human-readable format and transmits them to the PC, along with the internal thermistor temperature.

    In the process, an AMG88xx library was created which should be easily portable to other platforms, an excerpt can be seen below. (The full source code can be downloaded here)

     * Writes the temperature values in °C into a float array.
     * @param result Float array of the size 64 used for storing results
    void readValues(float result[]){
    	byte pixelAddrL = AMG_REGISTER_T01L;
    	for (int pixel = 0; pixel < 64; pixel++) {
    		Wire.requestFrom(amg_addr, 2);
    		byte lowerLevel =;
    		byte upperLevel =;
    		int temperature = ((upperLevel << 8) | lowerLevel);
    		if (temperature > 2047) {
    			temperature = temperature - 4096;
    		result[pixel] = temperature * 0.25;
    		pixelAddrL +=2;
    On the PC side, Java programs were developed to store the received data in log files, analyze and visualize it. For all further heatmaps in this chapter, the corresponding gradient seen below

    is used

    The first data gathered were readings with the sensor pointing at a wall with a uniform temperature to test the noise level of the sensor. According to the data sheet, temperature readings have an accuracy of

    ±2.5°C. The connected computer was configured to acquire a reading of all pixel temperatures and the thermistor value every 30 seconds. Out of 380 measurements, the average values for each pixel were calculated.

    In the above Graph the fluctuations in temperature of 20 pixels can be seen over a duration of 1000 seconds. The fluctuations for each single pixel typically stay within ±0.5°C and the difference between the average temperature readings of the pixels was up to 2.5°C. It has to be noted that these measurements were not taken in a highly controlled environment. From the collected data, a calibration table was generated which was applied to further readings by the professing software.

    For testing presence detection, the sensor was mounted above a bed with a 2m x 1m mattress at a height of 65cm and an angle of 45°C, as seen in the Figure below. Over the course of a night, readings were acquired every 30 minutes well before going to bed and until a while after getting out of bed.

    Initial test setup showing the location of the sensor, the field of view and the covered area

    Initial test setup showing the location of the sensor, the field of view and the covered area

    Examples of the readings can be seen below.

    Sensor readings: empty bed (a), occupied bed (b)(c)(d)

    Sensor readings: empty bed (a), occupied bed (b)(c)(d)

    The readings were processed and for each set of 64 temperature values the maximum temperature, the average temperature were calculated. These values, along with the thermistor value were plotted. While it was fairly obvious on the chart which times the bed was occupied, it was difficult to set a threshold value to decide whether the bed was occupied or not. Since large parts of the body are covered when lying in bed leaving possibly only the head partially exposed, simply setting a temperature threshold for the maximum value would not work reliably. The change in average temperature in an occupied bed on the other hand is too small to make a definite decision.
    The variance of all values should be very low when the...

    Read more »

  • Mounting the infrared sensor

    karpour10/03/2016 at 00:15 0 comments

    For mounting the module, the fact that the ideal mounting position most likely will not be available has to be considered when gathering data. The module therefore has to be able to work in ideal situations just as well as non-ideal ones.
    For both bed and cooking plate, the ideal mounting position would be directly above the area of interest with a vertical optical axis, not covering any areas that might influence the measurements.
    In a real-world scenario, the sensor will most likely view the area of interest at an angle, leading to either the full area of interest not being fully covered or additional area being covered, introducing a possible source of wrong readings.
    The Figure below shows 3 different possible configurations for a mounded sensor over a bed, with the ideal configuration covering only the area of interest. Since this is unlikely to be possible, experiments will be performed with the configurations (b) and (c).

  • Creating a breakout board for the AMG88xx

    karpour10/03/2016 at 00:11 0 comments

    Since the AMG8831 comes in a package similar to DFN (Dual Flat No-leads) packages, a breakout board was necessary. An additional requirement for the breakout board was that it would be usable in a prototype of the module, requiring a small footprint.

    The suggested minimal surrounding circuit for the AMG88xx (see Figure above) was used to design a circuit board with a footprint of 13mm x 14.4mm and a row of 100mil spaced pads for the I²C and voltage supply pins for easy prototyping. Since no more than one of the sensors will be used, the configurable I²C device address was set to 1101000 via the AD_SELECT pin.

    Eagle was used to design a breakout board and a bunch of them were ordered at DirtyPCB, because I'm cheap.

    (Download the eagle files here)

    Since the AMG88xx data sheet recommends reflow soldering, I used a reflow oven for the first time in my life and found out the thermocoupler was broken, luckily without the AMG88xx attached.

    This turned out a bit too crispy.

    Using a different reflow oven, it worked. In the end the AMG88xx was attached with hand soldering (using the instructions in the data sheet) as the reflow oven could not manage to comply with the strict reflow profile from the data sheet.

    In the end, everything worked out and I ended up with this small-footprint breadboard-compatible breakout board.

  • Choice of infrared grid sensor

    karpour10/02/2016 at 23:58 0 comments

    Available sensor modules

    A recent addition to the available sensors for use in AAL environments are MEMS infrared sensor arrays, which allow contactless temperature measurement of multiple areas at the same time. Sensors with a resolution of up to 8 x 8 pixels pixels are available within a reasonable price range for applications discussed in this paper. All of the discussed sensors use MEMS (Microelectromechanical systems) technology. The models of sensors which have been considered for use can be seen in the Table below

    SensorMelexis MLX90621Omron D6T44Panasonic AMG8831
    Pixel resolution16 x 44 x 4
    8 x 8
    Temperature range-20°C to 300°C5°C to 50°C
    -20°C to 80°C
    Operating voltage
    2.6V4.4 to 5.5V
    Data interface
    Current consumption
    Field of view60° x 15°,
    40° x 10°,
    120° x 30°
    44.2° x 44.2°60° x 60°

    The Omron D6T44 was not chosen due to the high operating voltage and power consumption. The Omron D6T1616 was a promising alternative, operating on 3.3V and, providing the best pixel resolution of all the considered sensors. (16 x 16) However, the D6T1616 was only produced in small quantities for developers and the manufacturer stopped development on this product, therefore it was of little use to try obtaining a sample for evaluation. The Melexis MLX90621 is a sensor mainly intended to be used in automobiles where the wide aspect radio of 1:4 allows tracking of 2 passengers.
    In the end, the AMG8831 was chosen for offering a decent resolution and 3.3V operation. While the power usage of neither sensors fits the requirements of an ultra-low-power application, it offers the best trade-off of resolution and power consumption.

    An AMG8831 module. It's pretty small (and hard to solder)

    Evaluation of the AMG8831

    The AMG8831 is a 3.3V logic high-gain 8x8 pixel infrared grid array with a measuring range of 0°C-80°C per pixel. The pixel data is transferred over I²C, with one pixel temperature being transferred in 12 bits (11 bits + sign) spread over 2 bytes. The temperature resolution is 0.0625°C.

  • Water Flow Detection

    karpour10/02/2016 at 15:56 0 comments

    A contact temperature sensor has been chosen for this module. One or two of these sensors are attached to the warm and/or cold water pipe(s) to detect water flow by measuring changes in pipe temperature. Other sensors, such as a piezoelectric vibration sensor and a capacitor microphone have been unable to provide usable data. While ultrasonic flow measurement would be the most accurate method of measuring water flow, it has not been chosen due to the high price, low availability and possibly requirements in terms of power usage and supply voltage that the module would not be able to fulfill.

    The TMP75B temperature sensor provides a resolution 0f 0.0625°C/LSB and accepts supply voltages between 1.4V and 3.6V, making it ideal for operation in the test setup in a 3.3V environment while being able to connect to the STM3xx module without the need of level shifting. The TMP75B offers an alert signal with a configurable threshold, this feature cannot be used on one of the WAKE pins of the STM3xx module due to the power supply for periphery shutting down when the module is in sleep mode.

    In a test setup, the temperature sensor was attached to a pipe connected to a toilet water tank and an ATMega328 was used to collect readings once per second over 1600 seconds. The readings clearly show a sharp drop in temperature every time the toilet was flushed. Over time, the pipe temperature returns to approximately room temperature. A simple threshold can be used to detect water flow and maxima in the differential can be used to pinpoint times when the water starts flowing.

  • Water Flow detection - Failed Experiments

    karpour10/02/2016 at 15:46 0 comments

    The water flow detector module is supposed to be attached to water pipes (hot and cold) and accurately detect when water is flowing through the pipes. Non-invasive water flow measurement modules exist in the form of ultrasonic transmitters and receivers. The transmitter and receiver are placed on the pipe and depending on speed the water flow the transmission time will differ since the flowing water carries the waves emitted be the transmitter. Problem is, these sensors are not easy to get and anything but cheap, as well as not suitable for an ultra-low power module.

    Since it's not necessary to measure the exact flow rate but rather whether the water is flowing or not, a simpler solution will do. The first experiments were conducted with a piezoelectric vibration sensor and an electret microphone, both attached to water pipes in hopes of measuring vibrations caused by the water flow.

    Data collected from a piezoelectric vibration sensor and a capacitor microphone attached to a metal water tap

    Data collected from a piezoelectric vibration sensor and a capacitor microphone attached to a metal water tap

    The graph makes obvious that the difference between flowing and not flowing water is minimal. In addition, the sensors would also measure any other sound/vibration caused by other sources. With little hope of getting usable data with this setup, the idea was scrapped and other possibilities were explored.

    On a brighter note, I discovered that piezoelectric vibration sensors do a great job at measuring heart rate. (

  • Non-invasive current detection

    karpour10/02/2016 at 10:23 2 comments

    As part of a complete monitoring system, it is important to consider the usage of specific devices in a household, specifically devices that could pose a risk of harming the user if incorrectly used or malfunctioning. This includes mostly devices that draw a large current when used, such as toasters, water boilers and blow-dryers. Being able to measure the time and duration these devices are turned on is useful for two reasons: If devices are not used for a long time, it can be an indicator that something is wrong. On the other hand, if devices are turned on for too long are a possible safety hazard, for example a water cooker that is turned on for over 10 minutes.

    The following criteria should be met by the sensor node:
    • Being able to tell whether a device connected on a power line is turned on or off with good accuracy
    • Non-invasive current detection
    • Attachable to any power cable
    • No required alterations to the existing setup

    The method for non-invasive inductive current detection presented in this section works by filtering and amplifying the tiny currents created in an inductor placed near a 2-wire or 3-wire power cable carrying alternating current. Measuring the currents is challenging as the electric fields of the phase and neutral wires almost completely cancel each other out, an issue that does not exist when measuring on a single conductor. However, with large enough amplification of the much weaker current the inductor provides when measuring on a 2-wire or 2-wire power cable, it is still possible to detect the electric field which corresponds to the amount of current in the conductors.
    All further tests are performed with power cables carrying 230V AC.

    Circuit design

    The initial circuit design is roughly based on the circuit in the Extech DA30 non-contact AC current detector. It was determined that the detection circuit consisted of an inductor with a connected operational amplifier and low-pass filter.

    Sensor circuit

    Circuit DesignPlacement of inductor in relation to power cablePlacement of inductor in relation to power cable


    Goal of the following experiments is to find out ideal configuration of the circuit for an ideal measurement of the load using the 10-bit ADC of an ATMEGA328.
    The first test was performed with the following values:

    • VCC = 3.3V
    • L1 = 100µH
    • R3 = 1kΩ
    • R4 = 470kΩ
    • Load = 1000W

    The gain Aᵥ of the initial configuration is therefore:

    Results of the first test with a 1000W load. (Aᵥ=470, L=100µH). The Load is turned on for 20 seconds.

    Results of the first test with a 1000W load. (Aᵥ=470, L=100µH). The Load is turned on for 20 seconds.

    For a load of 1000W, the results were clear but very weak with a Vₚₚ of about 25mV. The Figure above shows the measurements of a 1000W load being turned on for 20 seconds with a reading once per second. To increase the accuracy of the measurements, the gain was increased to Aᵥ=1424.24 by changing R3 to a 330Ω resistor.

    Results of the second test with a 1000W load. (Aᵥ=1424.24, L=100µH). The Load is turned on for 20 seconds again.Results of the second test with a 1000W load. (Aᵥ=1424.24, L=100µH).The Load is turned on for 20 seconds again.Measurements with a load of 1000W: (1) Aᵥ=470, L=100µH, (2) Aᵥ=1424.24, L=100µH, (3) Aᵥ=1424.24, L=10mHMeasurements with a load of 1000W: (1) Aᵥ=470, L=100µH, (2) Aᵥ=1424.24, L=100µH, (3) Aᵥ=1424.24, L=10mH

    With optimal placement, the circuit is able to detect loads of 15W and up accurately by setting a simple threshold. For each device, the threshold has to be set separately as the output value is largely influenced by the location of the sensor and the type of power cable. Once the sensor is mounted in a fixed position, readings are consistent. The amount of load corresponding to the sensor output has been determined to be non-linear. This has been tested by placing the sensor on the cable of a power distributor and connecting loads between 4W and 1160W. A graph of the results can be seen in the Figure below.

    Different loads with the corresponding sensor output on a logarithmic graph

    Different loads with the corresponding sensor output on a logarithmic graph

    Influence of sensor location

    In previous tests, it was obvious that the location of the sensor relative to the power cable has greatly influences the output of the circuit. this is due to the different positions of the phase and neutral wires in...

    Read more »

  • What EnOcean is any why this project is based on it

    karpour10/01/2016 at 12:15 0 comments

    EnOcean provides a family of energy-harvesting wireless modules (STM3xy) and has been chosen for this project as an underlying technology to develop sensor modules on. Specifically, STM3xx family modules are used as base for the wireless sensor nodes, along with a USB-300 transceiver which houses a TCM310 transceiver module. STM3xy modules are only able to transmit data periodically and are severely limited in doing so by the amount of ambient light, with the default time between 2 successive packet
    transmissions being 15 minutes.

    EnOcean STM330 Module

    Due to the ultra-low-power nature of the EnOcean module family, certain limitationsapply to this project:

    Connecting additional sensors introduces an additional strain to the already very limited amount of power a STMxx module runs on, leading to energy conservation being the most critical problem in designing these modules.
    Communication between digital sensors and the EO3000I microcontroller are only possible with a logic level of 1.8V, requiring logic level conversion and introducing additional current consumption.
    Due to the very limited availability of energy, the intervals between measurements and transmission of data have to be minimized.

    Block Diagram of the EO3000I SoC, used on the STM3xy module family.

    EnOcean STM3xy modules are small wireless nodes containing a processor which is specifically targeted at ultra-low-power applications. Specifically, a module
    contains an 8051 compatible microcontroller with the following specifications:
    32kb Flash, 2kB RAM
    16MHz clock speed
    Integrated RF transceiver with a data rate of 125kbit/s
    Integrated ADCs and DACs
    11 GPIO pins available through 20-pin connector
    UART and SPI

    Apart from the EO3000I microcontroller the STM3xx modules contain periphery, makingthem into stand-alone systems:

    Energy source (typically a solar cell, other sources such peltier elements possible)
    A 250mF Goldcap capacitor
    A charging circuit capable with the option of connecting an additional backup battery

    Power usage during a measurement and transmit cycle of an STM330 module

    At a minimum, an STM3xx module without additional circuitry uses 220nA when in deep sleep mode. (typical power usage of an STM3xx in different sleep states can be seen Table 2.1. It can be woken by either a watchdog or external events. While many sensors
    provide the option to set thresholds and trigger pins of a connected microcontroller, this
    can not be used if the sensor is powered by the voltage regulator on the STM3xx since
    EnOcean modules don’t provide power to external sensors while in deep sleep mode. The
    watchdog provides periodic wake-up signals between 10ms and 46.6h.

View all 9 project logs

Enjoy this project?



Similar Projects

Does this project spark your interest?

Become a member to follow this project and never miss any updates