Android Hardware Abstraction Layer
Data Structures | Macros
lights.h File Reference
#include <stdint.h>
#include <sys/cdefs.h>
#include <sys/types.h>
#include <hardware/hardware.h>

Go to the source code of this file.

Data Structures

struct  light_state_t
 
struct  light_device_t
 

Macros

#define LIGHTS_HARDWARE_MODULE_ID   "lights"
 
#define LIGHT_ID_BACKLIGHT   "backlight"
 
#define LIGHT_ID_KEYBOARD   "keyboard"
 
#define LIGHT_ID_BUTTONS   "buttons"
 
#define LIGHT_ID_BATTERY   "battery"
 
#define LIGHT_ID_NOTIFICATIONS   "notifications"
 
#define LIGHT_ID_ATTENTION   "attention"
 
#define LIGHT_ID_BLUETOOTH   "bluetooth"
 
#define LIGHT_ID_WIFI   "wifi"
 
#define LIGHT_FLASH_NONE   0
 
#define LIGHT_FLASH_TIMED   1
 
#define LIGHT_FLASH_HARDWARE   2
 
#define BRIGHTNESS_MODE_USER   0
 
#define BRIGHTNESS_MODE_SENSOR   1
 

Macro Definition Documentation

#define BRIGHTNESS_MODE_SENSOR   1

Light brightness is managed by a light sensor.

Definition at line 82 of file lights.h.

#define BRIGHTNESS_MODE_USER   0

Light brightness is managed by a user setting.

Definition at line 77 of file lights.h.

#define LIGHT_FLASH_HARDWARE   2

To flash the light using hardware assist, set flashMode to the hardware mode.

Definition at line 72 of file lights.h.

#define LIGHT_FLASH_NONE   0

Definition at line 58 of file lights.h.

#define LIGHT_FLASH_TIMED   1

To flash the light at a given rate, set flashMode to LIGHT_FLASH_TIMED, and then flashOnMS should be set to the number of milliseconds to turn the light on, followed by the number of milliseconds to turn the light off.

Definition at line 66 of file lights.h.

#define LIGHT_ID_ATTENTION   "attention"

Definition at line 44 of file lights.h.

#define LIGHT_ID_BACKLIGHT   "backlight"

Definition at line 39 of file lights.h.

#define LIGHT_ID_BATTERY   "battery"

Definition at line 42 of file lights.h.

#define LIGHT_ID_BLUETOOTH   "bluetooth"

Definition at line 51 of file lights.h.

#define LIGHT_ID_BUTTONS   "buttons"

Definition at line 41 of file lights.h.

#define LIGHT_ID_KEYBOARD   "keyboard"

Definition at line 40 of file lights.h.

#define LIGHT_ID_NOTIFICATIONS   "notifications"

Definition at line 43 of file lights.h.

#define LIGHT_ID_WIFI   "wifi"

Definition at line 52 of file lights.h.

#define LIGHTS_HARDWARE_MODULE_ID   "lights"

The id of this module

Definition at line 31 of file lights.h.