MyShake is a free mobile app developed by scientists at the UC Berkeley Seismological Lab that uses smartphone sensors to detect movement caused by an earthquake. The app detects earthquakes as soon as they start and quickly sends the information to the central server. The lab can warn those farther away from the epicenter that shaking is on the way. It is a community driven global seismic network to help reduce earthquake damage.
Almost all smartphones come with accelerometers, that determine if the phone is being used vertically or horizontally. For example, this feature is used in steering wheel in a racing game. The mobile app ignores ordinary shaking and detects unique vibrations felt during earthquakes.
This app takes data only when it is in the steady state. It runs in the background and consumes very less power. When the shaking fits the vibrational profile of an earthquake, the app sends the anonymous information to the central system that confirms the location and magnitude of the quake.