Zephyr API Documentation 4.3.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
bt_avrcp_ct_cb Struct Reference

#include <zephyr/bluetooth/classic/avrcp.h>

Data Fields

void(* connected )(struct bt_conn *conn, struct bt_avrcp_ct *ct)
 An AVRCP CT connection has been established.
void(* disconnected )(struct bt_avrcp_ct *ct)
 An AVRCP CT connection has been disconnected.
void(* browsing_connected )(struct bt_conn *conn, struct bt_avrcp_ct *ct)
 An AVRCP CT browsing connection has been established.
void(* browsing_disconnected )(struct bt_avrcp_ct *ct)
 An AVRCP CT browsing connection has been disconnected.
void(* get_caps )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)
 Callback function for bt_avrcp_get_caps().
void(* unit_info_rsp )(struct bt_avrcp_ct *ct, uint8_t tid, struct bt_avrcp_unit_info_rsp *rsp)
 Callback function for bt_avrcp_get_unit_info().
void(* subunit_info_rsp )(struct bt_avrcp_ct *ct, uint8_t tid, struct bt_avrcp_subunit_info_rsp *rsp)
 Callback function for bt_avrcp_get_subunit_info().
void(* passthrough_rsp )(struct bt_avrcp_ct *ct, uint8_t tid, bt_avrcp_rsp_t result, const struct bt_avrcp_passthrough_rsp *rsp)
 Callback function for bt_avrcp_passthrough().
void(* browsed_player_rsp )(struct bt_avrcp_ct *ct, uint8_t tid, struct net_buf *buf)
 Callback function for bt_avrcp_ct_set_browsed_player().
void(* notification )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, uint8_t event_id, struct bt_avrcp_event_data *data)
 Callback function for Event Notification response (CT).
void(* list_player_app_setting_attrs )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)
 Callback for PDU ID LIST_PLAYER_APP_SETTING_ATTRS.
void(* list_player_app_setting_vals )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)
 Callback for PDU ID LIST_PLAYER_APP_SETTING_VALS.
void(* get_curr_player_app_setting_val )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)
 Callback for PDU ID GET_CURR_PLAYER_APP_SETTING_VAL.
void(* set_player_app_setting_val )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)
 Callback for PDU ID SET_PLAYER_APP_SETTING_VAL.
void(* get_player_app_setting_attr_text )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)
 Callback for PDU ID GET_PLAYER_APP_SETTING_ATTR_TEXT.
void(* get_player_app_setting_val_text )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)
 Callback for PDU ID GET_PLAYER_APP_SETTING_VAL_TEXT.
void(* inform_displayable_char_set )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)
 Callback for PDU ID INFORM_DISPLAYABLE_CHAR_SET.
void(* inform_batt_status_of_ct )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)
 Callback for PDU ID INFORM_BATT_STATUS_OF_CT.
void(* set_absolute_volume )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, uint8_t absolute_volume)
 Callback function for Set Absolute Volume response (CT).
void(* get_element_attrs )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)
 Callback for PDU ID GET_ELEMENT_ATTRS.
void(* get_play_status )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)
 Callback for PDU ID GET_PLAY_STATUS.
void(* set_addressed_player )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)
 Callback for PDU ID SET_ADDRESSED_PLAYER.
void(* play_item )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)
 Callback for PDU ID PLAY_ITEM.
void(* add_to_now_playing )(struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)
 Callback for PDU ID ADD_TO_NOW_PLAYING.

Field Documentation

◆ add_to_now_playing

void(* bt_avrcp_ct_cb::add_to_now_playing) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)

Callback for PDU ID ADD_TO_NOW_PLAYING.

Called when the response for ADD_TO_NOW_PLAYING is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation. bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.

◆ browsed_player_rsp

void(* bt_avrcp_ct_cb::browsed_player_rsp) (struct bt_avrcp_ct *ct, uint8_t tid, struct net_buf *buf)

Callback function for bt_avrcp_ct_set_browsed_player().

Called when the set browsed player process is completed.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the response.
bufThe response buffer containing the set browsed player response data. The application can parse this payload according to the format defined in bt_avrcp_set_browsed_player_rsp. Note that the data is encoded in big-endian format.

◆ browsing_connected

void(* bt_avrcp_ct_cb::browsing_connected) (struct bt_conn *conn, struct bt_avrcp_ct *ct)

An AVRCP CT browsing connection has been established.

This callback notifies the application of an avrcp browsing connection, i.e., an AVCTP browsing L2CAP connection.

Parameters
connConnection object.
ctAVRCP CT connection object.

◆ browsing_disconnected

void(* bt_avrcp_ct_cb::browsing_disconnected) (struct bt_avrcp_ct *ct)

An AVRCP CT browsing connection has been disconnected.

This callback notifies the application that an avrcp browsing connection has been disconnected.

Parameters
ctAVRCP CT connection object.

◆ connected

void(* bt_avrcp_ct_cb::connected) (struct bt_conn *conn, struct bt_avrcp_ct *ct)

An AVRCP CT connection has been established.

This callback notifies the application of an avrcp connection, i.e., an AVCTP L2CAP connection.

Parameters
connConnection object.
ctAVRCP CT connection object.

◆ disconnected

void(* bt_avrcp_ct_cb::disconnected) (struct bt_avrcp_ct *ct)

An AVRCP CT connection has been disconnected.

This callback notifies the application that an avrcp connection has been disconnected.

Parameters
ctAVRCP CT connection object.

◆ get_caps

void(* bt_avrcp_ct_cb::get_caps) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)

Callback function for bt_avrcp_get_caps().

Called when the get capabilities process is completed.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the response.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.
bufThe response buffer containing the BT_AVRCP_PDU_ID_GET_CAPS payload returned by the TG. The application can parse this payload according to the format, defined in bt_avrcp_get_caps_rsp. If status is in the range BT_AVRCP_STATUS_INVALID_COMMAND to BT_AVRCP_STATUS_ADDRESSED_PLAYER_CHANGED, and is not equal to BT_AVRCP_STATUS_OPERATION_COMPLETED, it indicates that the AVRCP response code is an AV/C REJECTED response, and buf is NULL. Note that all multi-octet fields are encoded in big-endian format.

◆ get_curr_player_app_setting_val

void(* bt_avrcp_ct_cb::get_curr_player_app_setting_val) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)

Callback for PDU ID GET_CURR_PLAYER_APP_SETTING_VAL.

Called when the response for GET_CURR_PLAYER_APP_SETTING_VAL is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.
bufThe response buffer containing the GET_CURR_PLAYER_APP_SETTING_VAL payload returned by the TG. The application can parse this payload according to the format defined in bt_avrcp_get_curr_player_app_setting_val_rsp. If status is in the range BT_AVRCP_STATUS_INVALID_COMMAND to BT_AVRCP_STATUS_ADDRESSED_PLAYER_CHANGED, and is not equal to BT_AVRCP_STATUS_OPERATION_COMPLETED, it indicates that the AVRCP response code is an AV/C REJECTED response, and buf is NULL. Note that all multi-octet fields are encoded in big-endian format.

◆ get_element_attrs

void(* bt_avrcp_ct_cb::get_element_attrs) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)

Callback for PDU ID GET_ELEMENT_ATTRS.

Called when the response for GET_ELEMENT_ATTRS is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.
bufThe response buffer containing the GET_ELEMENT_ATTRS payload returned by the TG, formatted as bt_avrcp_get_element_attrs_rsp. If status is in the range BT_AVRCP_STATUS_INVALID_COMMAND to BT_AVRCP_STATUS_ADDRESSED_PLAYER_CHANGED, and is not equal to BT_AVRCP_STATUS_OPERATION_COMPLETED, it indicates that the AVRCP response code is an AV/C REJECTED response, and buf is NULL. Note that all multi-octet fields are encoded in big-endian format.

◆ get_play_status

void(* bt_avrcp_ct_cb::get_play_status) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)

Callback for PDU ID GET_PLAY_STATUS.

Called when the response for GET_PLAY_STATUS is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.
bufThe response buffer containing the GET_PLAY_STATUS payload returned by the TG, formatted as bt_avrcp_get_play_status_rsp. If status is in the range BT_AVRCP_STATUS_INVALID_COMMAND to BT_AVRCP_STATUS_ADDRESSED_PLAYER_CHANGED, and is not equal to BT_AVRCP_STATUS_OPERATION_COMPLETED, it indicates that the AVRCP response code is an AV/C REJECTED response, and buf is NULL. Note that all multi-octet fields are encoded in big-endian format.

◆ get_player_app_setting_attr_text

void(* bt_avrcp_ct_cb::get_player_app_setting_attr_text) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)

Callback for PDU ID GET_PLAYER_APP_SETTING_ATTR_TEXT.

Called when the response for GET_PLAYER_APP_SETTING_ATTR_TEXT is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.
bufThe response buffer containing the GET_PLAYER_APP_SETTING_ATTR_TEXT payload returned by the TG, formatted as bt_avrcp_get_player_app_setting_attr_text_rsp. If status is in the range BT_AVRCP_STATUS_INVALID_COMMAND to BT_AVRCP_STATUS_ADDRESSED_PLAYER_CHANGED, and is not equal to BT_AVRCP_STATUS_OPERATION_COMPLETED, it indicates that the AVRCP response code is an AV/C REJECTED response, and buf is NULL. Note that all multi-octet fields are encoded in big-endian format.

◆ get_player_app_setting_val_text

void(* bt_avrcp_ct_cb::get_player_app_setting_val_text) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)

Callback for PDU ID GET_PLAYER_APP_SETTING_VAL_TEXT.

Called when the response for GET_PLAYER_APP_SETTING_VAL_TEXT is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.
bufThe response buffer containing the GET_PLAYER_APP_SETTING_VAL_TEXT payload returned by the TG, formatted as bt_avrcp_get_player_app_setting_val_text_rsp. If status is in the range BT_AVRCP_STATUS_INVALID_COMMAND to BT_AVRCP_STATUS_ADDRESSED_PLAYER_CHANGED, and is not equal to BT_AVRCP_STATUS_OPERATION_COMPLETED, it indicates that the AVRCP response code is an AV/C REJECTED response, and buf is NULL. Note that all multi-octet fields are encoded in big-endian format.

◆ inform_batt_status_of_ct

void(* bt_avrcp_ct_cb::inform_batt_status_of_ct) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)

Callback for PDU ID INFORM_BATT_STATUS_OF_CT.

Called when the response for INFORM_BATT_STATUS_OF_CT is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.

◆ inform_displayable_char_set

void(* bt_avrcp_ct_cb::inform_displayable_char_set) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)

Callback for PDU ID INFORM_DISPLAYABLE_CHAR_SET.

Called when the response for INFORM_DISPLAYABLE_CHAR_SET is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.

◆ list_player_app_setting_attrs

void(* bt_avrcp_ct_cb::list_player_app_setting_attrs) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)

Callback for PDU ID LIST_PLAYER_APP_SETTING_ATTRS.

Called when the response for LIST_PLAYER_APP_SETTING_ATTRS is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.
bufThe response buffer containing the LIST_PLAYER_APP_SETTING_ATTRS payload returned by the TG. The application can parse this payload according to the format defined in bt_avrcp_list_app_setting_attr_rsp. If status is in the range BT_AVRCP_STATUS_INVALID_COMMAND to BT_AVRCP_STATUS_ADDRESSED_PLAYER_CHANGED, and is not equal to BT_AVRCP_STATUS_OPERATION_COMPLETED, it indicates that the AVRCP response code is an AV/C REJECTED response, and buf is NULL. Note that all multi-octet fields are encoded in big-endian format.

◆ list_player_app_setting_vals

void(* bt_avrcp_ct_cb::list_player_app_setting_vals) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, struct net_buf *buf)

Callback for PDU ID LIST_PLAYER_APP_SETTING_VALS.

Called when the response for LIST_PLAYER_APP_SETTING_VALS is received.`

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.
bufThe response buffer containing the LIST_PLAYER_APP_SETTING_VALS payload returned by the TG. The application can parse this payload according to the format defined in bt_avrcp_list_player_app_setting_vals_rsp. If status is in the range BT_AVRCP_STATUS_INVALID_COMMAND to BT_AVRCP_STATUS_ADDRESSED_PLAYER_CHANGED, and is not equal to BT_AVRCP_STATUS_OPERATION_COMPLETED, it indicates that the AVRCP response code is an AV/C REJECTED response, and buf is NULL. Note that all multi-octet fields are encoded in big-endian format.

◆ notification

void(* bt_avrcp_ct_cb::notification) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, uint8_t event_id, struct bt_avrcp_event_data *data)

Callback function for Event Notification response (CT).

Called when the AVRCP Target (TG) sends a response to a previously registered event (Register Notification). This callback reports the event type, the response phase (e.g., Interim), and the event-specific payload.

Parameters
ctAVRCP Controller (CT) connection context.
tidTransaction label that correlates this notification with the original Register Notification request.
statusTG status/phase code (BT_AVRCP_STATUS_*). Typically BT_AVRCP_STATUS_SUCCESS for an interim notification. Error codes may be returned for invalid parameters or unsupported events.
event_idThe AVRCP event identifier. bt_avrcp_event_data This corresponds to one of the AVRCP event types such as EVENT_PLAYBACK_STATUS_CHANGED, EVENT_TRACK_CHANGED, etc.
dataPointer to bt_avrcp_event_data structure containing the event-specific data. The content of the union depends on the event_id.
Note
This callback is only invoked for interim notifications and error statuses from the TG. For CHANGED event notifications, the event must first be registered using bt_avrcp_notify_changed_cb_t.

◆ passthrough_rsp

void(* bt_avrcp_ct_cb::passthrough_rsp) (struct bt_avrcp_ct *ct, uint8_t tid, bt_avrcp_rsp_t result, const struct bt_avrcp_passthrough_rsp *rsp)

Callback function for bt_avrcp_passthrough().

Called when a passthrough response is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the response.
resultThe result of the operation.
rspThe response for PASS THROUGH command.

◆ play_item

void(* bt_avrcp_ct_cb::play_item) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)

Callback for PDU ID PLAY_ITEM.

Called when the response for PLAY_ITEM is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation. bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.

◆ set_absolute_volume

void(* bt_avrcp_ct_cb::set_absolute_volume) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status, uint8_t absolute_volume)

Callback function for Set Absolute Volume response (CT).

Called when the Set Absolute Volume response is received from the TG.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the response.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.
absolute_volumeThe absolute volume value (0x00-0x7F).

◆ set_addressed_player

void(* bt_avrcp_ct_cb::set_addressed_player) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)

Callback for PDU ID SET_ADDRESSED_PLAYER.

Called when the response for SET_ADDRESSED_PLAYER is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation. bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.

◆ set_player_app_setting_val

void(* bt_avrcp_ct_cb::set_player_app_setting_val) (struct bt_avrcp_ct *ct, uint8_t tid, uint8_t status)

Callback for PDU ID SET_PLAYER_APP_SETTING_VAL.

Called when the response for SET_PLAYER_APP_SETTING_VAL is received.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the request.
statusThe status code returned by the TG, indicating the result of the operation, bt_avrcp_status_t. Typically corresponds to BT_AVRCP_STATUS_* values such as BT_AVRCP_STATUS_SUCCESS or BT_AVRCP_STATUS_INVALID_PARAMETER.

◆ subunit_info_rsp

void(* bt_avrcp_ct_cb::subunit_info_rsp) (struct bt_avrcp_ct *ct, uint8_t tid, struct bt_avrcp_subunit_info_rsp *rsp)

Callback function for bt_avrcp_get_subunit_info().

Called when the get subunit info process is completed.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the response.
rspThe response for SUBUNIT INFO command.

◆ unit_info_rsp

void(* bt_avrcp_ct_cb::unit_info_rsp) (struct bt_avrcp_ct *ct, uint8_t tid, struct bt_avrcp_unit_info_rsp *rsp)

Callback function for bt_avrcp_get_unit_info().

Called when the get unit info process is completed.

Parameters
ctAVRCP CT connection object.
tidThe transaction label of the response.
rspThe response for UNIT INFO command.

The documentation for this struct was generated from the following file: