Android Hardware Abstraction Layer
Data Structures | Macros | Typedefs | Enumerations
bt_rc.h File Reference

Go to the source code of this file.

Data Structures

struct  btrc_player_settings_t
 
union  btrc_register_notification_t
 
struct  btrc_player_setting_text_t
 
struct  btrc_element_attr_val_t
 
struct  btrc_callbacks_t
 
struct  btrc_interface_t
 

Macros

#define BTRC_MAX_ATTR_STR_LEN   255
 
#define BTRC_UID_SIZE   8
 
#define BTRC_MAX_APP_SETTINGS   8
 
#define BTRC_MAX_FOLDER_DEPTH   4
 
#define BTRC_MAX_APP_ATTR_SIZE   16
 
#define BTRC_MAX_ELEM_ATTR_SIZE   7
 

Typedefs

typedef uint8_t btrc_uid_t [BTRC_UID_SIZE]
 
typedef void(* btrc_remote_features_callback )(bt_bdaddr_t *bd_addr, btrc_remote_features_t features)
 
typedef void(* btrc_get_play_status_callback )()
 
typedef void(* btrc_list_player_app_attr_callback )()
 
typedef void(* btrc_list_player_app_values_callback )(btrc_player_attr_t attr_id)
 
typedef void(* btrc_get_player_app_value_callback )(uint8_t num_attr, btrc_player_attr_t *p_attrs)
 
typedef void(* btrc_get_player_app_attrs_text_callback )(uint8_t num_attr, btrc_player_attr_t *p_attrs)
 
typedef void(* btrc_get_player_app_values_text_callback )(uint8_t attr_id, uint8_t num_val, uint8_t *p_vals)
 
typedef void(* btrc_set_player_app_value_callback )(btrc_player_settings_t *p_vals)
 
typedef void(* btrc_get_element_attr_callback )(uint8_t num_attr, btrc_media_attr_t *p_attrs)
 
typedef void(* btrc_register_notification_callback )(btrc_event_id_t event_id, uint32_t param)
 
typedef void(* btrc_volume_change_callback )(uint8_t volume, uint8_t ctype)
 
typedef void(* btrc_passthrough_cmd_callback )(int id, int key_state)
 

Enumerations

enum  btrc_remote_features_t { BTRC_FEAT_NONE = 0x00, BTRC_FEAT_METADATA = 0x01, BTRC_FEAT_ABSOLUTE_VOLUME = 0x02, BTRC_FEAT_BROWSE = 0x04 }
 
enum  btrc_play_status_t {
  BTRC_PLAYSTATE_STOPPED = 0x00, BTRC_PLAYSTATE_PLAYING = 0x01, BTRC_PLAYSTATE_PAUSED = 0x02, BTRC_PLAYSTATE_FWD_SEEK = 0x03,
  BTRC_PLAYSTATE_REV_SEEK = 0x04, BTRC_PLAYSTATE_ERROR = 0xFF
}
 
enum  btrc_event_id_t {
  BTRC_EVT_PLAY_STATUS_CHANGED = 0x01, BTRC_EVT_TRACK_CHANGE = 0x02, BTRC_EVT_TRACK_REACHED_END = 0x03, BTRC_EVT_TRACK_REACHED_START = 0x04,
  BTRC_EVT_PLAY_POS_CHANGED = 0x05, BTRC_EVT_APP_SETTINGS_CHANGED = 0x08
}
 
enum  btrc_notification_type_t { BTRC_NOTIFICATION_TYPE_INTERIM = 0, BTRC_NOTIFICATION_TYPE_CHANGED = 1 }
 
enum  btrc_player_attr_t { BTRC_PLAYER_ATTR_EQUALIZER = 0x01, BTRC_PLAYER_ATTR_REPEAT = 0x02, BTRC_PLAYER_ATTR_SHUFFLE = 0x03, BTRC_PLAYER_ATTR_SCAN = 0x04 }
 
enum  btrc_media_attr_t {
  BTRC_MEDIA_ATTR_TITLE = 0x01, BTRC_MEDIA_ATTR_ARTIST = 0x02, BTRC_MEDIA_ATTR_ALBUM = 0x03, BTRC_MEDIA_ATTR_TRACK_NUM = 0x04,
  BTRC_MEDIA_ATTR_NUM_TRACKS = 0x05, BTRC_MEDIA_ATTR_GENRE = 0x06, BTRC_MEDIA_ATTR_PLAYING_TIME = 0x07
}
 
enum  btrc_player_repeat_val_t { BTRC_PLAYER_VAL_OFF_REPEAT = 0x01, BTRC_PLAYER_VAL_SINGLE_REPEAT = 0x02, BTRC_PLAYER_VAL_ALL_REPEAT = 0x03, BTRC_PLAYER_VAL_GROUP_REPEAT = 0x04 }
 
enum  btrc_player_shuffle_val_t { BTRC_PLAYER_VAL_OFF_SHUFFLE = 0x01, BTRC_PLAYER_VAL_ALL_SHUFFLE = 0x02, BTRC_PLAYER_VAL_GROUP_SHUFFLE = 0x03 }
 
enum  btrc_status_t {
  BTRC_STS_BAD_CMD = 0x00, BTRC_STS_BAD_PARAM = 0x01, BTRC_STS_NOT_FOUND = 0x02, BTRC_STS_INTERNAL_ERR = 0x03,
  BTRC_STS_NO_ERROR = 0x04
}
 

Macro Definition Documentation

#define BTRC_MAX_APP_ATTR_SIZE   16

Definition at line 27 of file bt_rc.h.

#define BTRC_MAX_APP_SETTINGS   8

Definition at line 25 of file bt_rc.h.

#define BTRC_MAX_ATTR_STR_LEN   255

Definition at line 23 of file bt_rc.h.

#define BTRC_MAX_ELEM_ATTR_SIZE   7

Definition at line 28 of file bt_rc.h.

#define BTRC_MAX_FOLDER_DEPTH   4

Definition at line 26 of file bt_rc.h.

#define BTRC_UID_SIZE   8

Definition at line 24 of file bt_rc.h.

Typedef Documentation

typedef void(* btrc_get_element_attr_callback)(uint8_t num_attr, btrc_media_attr_t *p_attrs)

Callback to fetch the get element attributes of the current song num_attr: specifies the number of attributes requested in p_attrs

Definition at line 158 of file bt_rc.h.

typedef void(* btrc_get_play_status_callback)()

Callback for play status request

Definition at line 129 of file bt_rc.h.

typedef void(* btrc_get_player_app_attrs_text_callback)(uint8_t num_attr, btrc_player_attr_t *p_attrs)

Callback for getting the player application settings attributes' text num_attr: specifies the number of attribute ids contained in p_attrs

Definition at line 145 of file bt_rc.h.

typedef void(* btrc_get_player_app_value_callback)(uint8_t num_attr, btrc_player_attr_t *p_attrs)

Callback for getting the current player application settings value num_attr: specifies the number of attribute ids contained in p_attrs

Definition at line 140 of file bt_rc.h.

typedef void(* btrc_get_player_app_values_text_callback)(uint8_t attr_id, uint8_t num_val, uint8_t *p_vals)

Callback for getting the player application settings values' text num_attr: specifies the number of value ids contained in p_vals

Definition at line 150 of file bt_rc.h.

typedef void(* btrc_list_player_app_attr_callback)()

Callback for list player application attributes (Shuffle, Repeat,...)

Definition at line 132 of file bt_rc.h.

typedef void(* btrc_list_player_app_values_callback)(btrc_player_attr_t attr_id)

Callback for list player application attributes (Shuffle, Repeat,...)

Definition at line 135 of file bt_rc.h.

typedef void(* btrc_passthrough_cmd_callback)(int id, int key_state)

Callback for passthrough commands

Definition at line 172 of file bt_rc.h.

typedef void(* btrc_register_notification_callback)(btrc_event_id_t event_id, uint32_t param)

Callback for register notification (Play state change/track change/...) param: Is only valid if event_id is BTRC_EVT_PLAY_POS_CHANGED

Definition at line 163 of file bt_rc.h.

typedef void(* btrc_remote_features_callback)(bt_bdaddr_t *bd_addr, btrc_remote_features_t features)

Callback for the controller's supported feautres

Definition at line 125 of file bt_rc.h.

typedef void(* btrc_set_player_app_value_callback)(btrc_player_settings_t *p_vals)

Callback for setting the player application settings values

Definition at line 153 of file bt_rc.h.

typedef uint8_t btrc_uid_t[BTRC_UID_SIZE]

Definition at line 30 of file bt_rc.h.

typedef void(* btrc_volume_change_callback)(uint8_t volume, uint8_t ctype)

Callback for volume change on CT volume: Current volume setting on the CT (0-127)

Definition at line 169 of file bt_rc.h.

Enumeration Type Documentation

Enumerator
BTRC_EVT_PLAY_STATUS_CHANGED 
BTRC_EVT_TRACK_CHANGE 
BTRC_EVT_TRACK_REACHED_END 
BTRC_EVT_TRACK_REACHED_START 
BTRC_EVT_PLAY_POS_CHANGED 
BTRC_EVT_APP_SETTINGS_CHANGED 

Definition at line 48 of file bt_rc.h.

Enumerator
BTRC_MEDIA_ATTR_TITLE 
BTRC_MEDIA_ATTR_ARTIST 
BTRC_MEDIA_ATTR_ALBUM 
BTRC_MEDIA_ATTR_TRACK_NUM 
BTRC_MEDIA_ATTR_NUM_TRACKS 
BTRC_MEDIA_ATTR_GENRE 
BTRC_MEDIA_ATTR_PLAYING_TIME 

Definition at line 69 of file bt_rc.h.

Enumerator
BTRC_NOTIFICATION_TYPE_INTERIM 
BTRC_NOTIFICATION_TYPE_CHANGED 

Definition at line 57 of file bt_rc.h.

Enumerator
BTRC_PLAYSTATE_STOPPED 
BTRC_PLAYSTATE_PLAYING 
BTRC_PLAYSTATE_PAUSED 
BTRC_PLAYSTATE_FWD_SEEK 
BTRC_PLAYSTATE_REV_SEEK 
BTRC_PLAYSTATE_ERROR 

Definition at line 39 of file bt_rc.h.

Enumerator
BTRC_PLAYER_ATTR_EQUALIZER 
BTRC_PLAYER_ATTR_REPEAT 
BTRC_PLAYER_ATTR_SHUFFLE 
BTRC_PLAYER_ATTR_SCAN 

Definition at line 62 of file bt_rc.h.

Enumerator
BTRC_PLAYER_VAL_OFF_REPEAT 
BTRC_PLAYER_VAL_SINGLE_REPEAT 
BTRC_PLAYER_VAL_ALL_REPEAT 
BTRC_PLAYER_VAL_GROUP_REPEAT 

Definition at line 79 of file bt_rc.h.

Enumerator
BTRC_PLAYER_VAL_OFF_SHUFFLE 
BTRC_PLAYER_VAL_ALL_SHUFFLE 
BTRC_PLAYER_VAL_GROUP_SHUFFLE 

Definition at line 86 of file bt_rc.h.

Enumerator
BTRC_FEAT_NONE 
BTRC_FEAT_METADATA 
BTRC_FEAT_ABSOLUTE_VOLUME 
BTRC_FEAT_BROWSE 

Definition at line 32 of file bt_rc.h.

Enumerator
BTRC_STS_BAD_CMD 
BTRC_STS_BAD_PARAM 
BTRC_STS_NOT_FOUND 
BTRC_STS_INTERNAL_ERR 
BTRC_STS_NO_ERROR 

Definition at line 92 of file bt_rc.h.