Skip to main content

Measuring magnetic field of washing machine motor using PocketLab

Submitted by PocketLab on Thu, 10/29/2015 - 23:39
Graph

PocketLab user Martin Isaksson used his PocketLab to measure the magnetic field generated by the motor of a washing machine. Check out his results below. Pretty cool! 
 

Washing apparatus ready detection

Martin Isaksson

Abstract

Using a PocketLab put on the top of a washing machine, we measure the magnetic field generated by the motor. The magnitude of this vector is used to detect if the motor is on, and when the motor has been off for some time, we say that the cycle is finished.

Checkpoint

Screenshot

 

Libraries

Screenshot

 

 

Read data

Read data from PocketLab CSV and calculate magnitude from x, y, and z components. Then use an Exponential Moving Average filter to remove the trend (seems like the sensor does not return to zero when the washing machine motor turns off).

Screenshot

 

 

 

 

 

time    x                     y                      z                    magnitude

0.00   0.0610352      0.0610352     -0.3051758     0.3171480

0.02   0.0610352     -0.0305176     -0.1220703    0.1398491

0.08   0.1525879      0.0915527      -0.3356934    0.3799408

0.16   0.0305176       0.1220703      0.0610352     0.1398491

0.26   0.0000000    0.0305176      -0.0305176    0.0431584

0.36   0.0000000    0.0000000    -0.3967285    0.3967285


 

Rearrange and plot x, y and z components.

Screenshot

 

 

Screenshot

 

 

 

 

 

 

 

Plot the magnitude

Screenshot

 

 

Screenshot

 

 

 

 

 

 

Plot the magnitude trend

Screenshot

 

 

Screenshot

 

 

 

 

 

 

Plot the adjusted magnitude (removed magnitude trend).

Screenshot

 

 

Screenshot

 

 

 

 

 

 

Plot the normalized absolute magnitude.

Screenshot

 

 

Screenshot

 

 

 

 

 

 

Using zero as a threshold, plot on or off status.

Screenshot

 

Screenshot