avrcp.h (0c436f0b86b5555c47a1fff53cd311520d951b75) avrcp.h (c3b8c0a2ef52262b8ac0ada052c4f8297106104e)
1/*
2 * Copyright (C) 2016 BlueKitchen GmbH
3 *
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions
6 * are met:
7 *
8 * 1. Redistributions of source code must retain the above copyright

--- 97 unchanged lines hidden (view full) ---

106
107typedef enum {
108 AVRCP_SINGLE_PACKET= 0,
109 AVRCP_START_PACKET ,
110 AVRCP_CONTINUE_PACKET ,
111 AVRCP_END_PACKET
112} avrcp_packet_type_t;
113
1/*
2 * Copyright (C) 2016 BlueKitchen GmbH
3 *
4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions
6 * are met:
7 *
8 * 1. Redistributions of source code must retain the above copyright

--- 97 unchanged lines hidden (view full) ---

106
107typedef enum {
108 AVRCP_SINGLE_PACKET= 0,
109 AVRCP_START_PACKET ,
110 AVRCP_CONTINUE_PACKET ,
111 AVRCP_END_PACKET
112} avrcp_packet_type_t;
113
114
114typedef enum {
115typedef enum {
116 AVCTP_SINGLE_PACKET= 0,
117 AVCTP_START_PACKET ,
118 AVCTP_CONTINUE_PACKET ,
119 AVCTP_END_PACKET
120} avctp_packet_type_t;
121
122typedef enum {
115 AVRCP_COMMAND_FRAME = 0,
116 AVRCP_RESPONSE_FRAME
117} avrcp_frame_type_t;
118
119
120typedef enum {
121 AVRCP_CAPABILITY_ID_COMPANY = 0x02,
122 AVRCP_CAPABILITY_ID_EVENT = 0x03

--- 247 unchanged lines hidden (view full) ---

370
371// BROWSING
372typedef struct {
373 uint16_t l2cap_browsing_cid;
374
375 avctp_connection_state_t state;
376 bool wait_to_send;
377 uint8_t transaction_label;
123 AVRCP_COMMAND_FRAME = 0,
124 AVRCP_RESPONSE_FRAME
125} avrcp_frame_type_t;
126
127
128typedef enum {
129 AVRCP_CAPABILITY_ID_COMPANY = 0x02,
130 AVRCP_CAPABILITY_ID_EVENT = 0x03

--- 247 unchanged lines hidden (view full) ---

378
379// BROWSING
380typedef struct {
381 uint16_t l2cap_browsing_cid;
382
383 avctp_connection_state_t state;
384 bool wait_to_send;
385 uint8_t transaction_label;
378 // used for AVCTP fragmentation
386 // used for fragmentation
379 uint8_t num_packets;
380 uint16_t bytes_to_send;
381
382 uint8_t *ertm_buffer;
383 uint32_t ertm_buffer_size;
384 l2cap_ertm_config_t ertm_config;
385
386 // players

--- 163 unchanged lines hidden (view full) ---

550 uint8_t addressed_player_changed;
551 uint16_t addressed_player_id;
552 uint16_t uid_counter;
553 // PTS requires definition of max num fragments
554 uint8_t max_num_fragments;
555 uint8_t num_received_fragments;
556
557 uint8_t accept_response;
387 uint8_t num_packets;
388 uint16_t bytes_to_send;
389
390 uint8_t *ertm_buffer;
391 uint32_t ertm_buffer_size;
392 l2cap_ertm_config_t ertm_config;
393
394 // players

--- 163 unchanged lines hidden (view full) ---

558 uint8_t addressed_player_changed;
559 uint16_t addressed_player_id;
560 uint16_t uid_counter;
561 // PTS requires definition of max num fragments
562 uint8_t max_num_fragments;
563 uint8_t num_received_fragments;
564
565 uint8_t accept_response;
566
567#ifdef ENABLE_AVCTP_FRAGMENTATION
568 uint16_t avctp_reassembly_size;
569 uint8_t avctp_reassembly_buffer[200];
570#endif
571
558} avrcp_connection_t;
559
560typedef struct {
561 avrcp_role_t role;
562 btstack_packet_handler_t avrcp_callback;
563 btstack_packet_handler_t packet_handler;
564
565 bool (*set_addressed_player_callback)(uint16_t player_id);

--- 88 unchanged lines hidden ---
572} avrcp_connection_t;
573
574typedef struct {
575 avrcp_role_t role;
576 btstack_packet_handler_t avrcp_callback;
577 btstack_packet_handler_t packet_handler;
578
579 bool (*set_addressed_player_callback)(uint16_t player_id);

--- 88 unchanged lines hidden ---