MCQs Test!! VB Basic Test !! Essentials of VB !! Creating User Services !! function !! Anatomy !! GK March-2019 !! DATA TYPES IN JAVA !! Classes ,Constructor ,Methods,Inheritance !! Ecology-I !! Biology 2019 !! Gk april 2019 !! Biology (living world) !! Plant anatomy !! CELL STRUCTURES AND FUNCTION !! General biology !! Human physiology !! Data structure !! Ecology-II !! GK TEST !! Reproduction in plants !! Human reproduction !! The ABC of C !! Operating system set1 !! Operating system set2 !! Gk and current affairs !! Animal kingdom !! Number system !! Animal kingdom-II !! Gk TEST-III !! Number series !! Microorganisms !! Interview question in c !! Time and Work !! Percentage !! General history !! Average !! Cells !! Locomotion and Movement !! paging !! Bacteriology !! Page replacement policy !! Secondary memory and Disk scheduling !! Introduction of Nervous System and neurons !! Plant harmones !! Transport and Mineral Nutrition in Plants !! Neurotransmitters !! Modern Indian History !! Photosynthesis in Plants !! Modern Indian History-II !! Plant respiration !! Environment & Biodiversity !! Environment & Biodiversity - II !! Algae, Bryophytes, Pteridophytes !! Area !! Cricket !! Days of the Year (India and the World) !! Plant Pathology - I !! Indian Transport System !! Plant Pathology - II !! Aptitude !! Biology !! Botany !! C language !! Computer Science !! Core Java !! Gate !! GK !! Mysql !! Operating system !! Physics !! VB-Visual Basic !! Zoology


Android API
Previous Home Next

Used Hardware API

android.hardware : With the help of android.hardware package, we gets support for hardware features, such as the camera and other sensors. but your application requires using the <uses-feature > manifest element because all Android-powered devices not support all hardware features.

Commanly Used class in android.hardware package

  1. android.hardware.Camera: This class is used to set image capture settings, start/stop preview, snap pictures, and retrieve frames for encoding for video. if we want to access the device camera, you must declare the CAMERA permission in your Android Manifest file.
  2. <uses-permission android:name="android.permission.CAMERA" />
     <uses-feature android:name="" />
     <uses-feature android:name="" />
  3. android.hardware.Camera.CameraInfo: This class have Information about a camera.
  4. android.hardware.Sensor class : Sensor Class representing a sensor. WE can get get the list of available Sensors by getSensorList(int).
  5. android.hardware.SensorManager : This class is used to access the device's sensors.

Commanly Used interface in android.hardware package :

  1. android.hardware.Camera.AutoFocusCallback: This interface is used to notify on completion of camera auto focus.
  2. android.hardware.Camera.ErrorCallback: This interface return error notification.
  3. android.hardware.Camera.OnZoomChangeListener: This is used for zoom changes during a smooth zoom operation.
  4. android.hardware.Camera.ShutterCallback: This interface used to signal the moment of actual image capture.
  5. android.hardware.SensorEventListener: This is used for receiving notifications when sensor values have changed.
  6. android.hardware.SensorListener: This interface is deprecated. Use SensorEventListener instead.
  7. android.hardware.usb : With the help of this package, we provides support to communicate with USB hardware peripherals that are connected to Android-powered devices.

Commanly Used class in android.hardware package :


  1. UsbManager: Used to access the state of the USB.
  2. UsbDevice : Used for communicate with the hardware peripheral if the Android-powered device is acting as the USB host.
  3. UsbAccessory: This class representing a USB accessory, which is an external hardware component that communicates with an android application over USB.
Previous Home Next