Skip to Content
Android Sensor Programming By Example
book

Android Sensor Programming By Example

by Varun Nagpal
April 2016
Intermediate to advanced content levelIntermediate to advanced
194 pages
4h 37m
English
Packt Publishing
Content preview from Android Sensor Programming By Example

What just happened?

We just created three small applications using three different sensors. The first one detects physical shakes using the accelerometer sensor, the second one tells the earth's magnetic direction using the orientation sensor, and the third one uses the fingerprint sensor to authenticate the user. A few important points to note are that the orientation sensor has been deprecated, so in place of it we should use the getRotationMatrix()and getOrientation() APIs to get the orientation values. Fingerprint APIs were introduced in Android Marshmallow (API Level 23), which uses both runtime and install time permissions. Thus, to use the fingerprint sensor, we should include both runtime and install time permissions.

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Android High Performance Programming

Android High Performance Programming

Enrique López Mañas, Diego Grancini
Android Things Projects

Android Things Projects

Francesco Azzola
Learning Embedded Android N Programming

Learning Embedded Android N Programming

Ivan Morgillo, Stefano Viola

Publisher Resources

ISBN: 9781785285509Supplemental Content