Zephyr API Documentation  3.6.99
A Scalable Open Source RTOS
Loading...
Searching...
No Matches
media_proxy.h
Go to the documentation of this file.
1/*
2 * Copyright (c) 2019 - 2021 Nordic Semiconductor ASA
3 *
4 * SPDX-License-Identifier: Apache-2.0
5 */
6
7#ifndef ZEPHYR_INCLUDE_BLUETOOTH_AUDIO_MEDIA_PROXY_H_
8#define ZEPHYR_INCLUDE_BLUETOOTH_AUDIO_MEDIA_PROXY_H_
9
39#include <stdint.h>
40#include <stdbool.h>
41
43
44/* TODO: Remove dependency on mcs.h */
45#include "mcs.h"
46
47#ifdef __cplusplus
48extern "C" {
49#endif
50
51
55struct mpl_cmd {
59};
60
67};
68
72struct mpl_sci {
76};
77
81struct mpl_search {
83 char search[SEARCH_LEN_MAX]; /* Concatenated search control items */
84}; /* - (type, length, param) */
85
91#define MEDIA_PROXY_PLAYBACK_SPEED_MIN -128
92#define MEDIA_PROXY_PLAYBACK_SPEED_QUARTER -128
93#define MEDIA_PROXY_PLAYBACK_SPEED_HALF -64
94#define MEDIA_PROXY_PLAYBACK_SPEED_UNITY 0
95#define MEDIA_PROXY_PLAYBACK_SPEED_DOUBLE 64
96#define MEDIA_PROXY_PLAYBACK_SPEED_MAX 127
97
105#define MEDIA_PROXY_SEEKING_SPEED_FACTOR_MAX 64
106#define MEDIA_PROXY_SEEKING_SPEED_FACTOR_MIN 4
107#define MEDIA_PROXY_SEEKING_SPEED_FACTOR_ZERO 0
108
112#define MEDIA_PROXY_PLAYING_ORDER_SINGLE_ONCE 0x01
113#define MEDIA_PROXY_PLAYING_ORDER_SINGLE_REPEAT 0x02
114#define MEDIA_PROXY_PLAYING_ORDER_INORDER_ONCE 0x03
115#define MEDIA_PROXY_PLAYING_ORDER_INORDER_REPEAT 0x04
116#define MEDIA_PROXY_PLAYING_ORDER_OLDEST_ONCE 0x05
117#define MEDIA_PROXY_PLAYING_ORDER_OLDEST_REPEAT 0x06
118#define MEDIA_PROXY_PLAYING_ORDER_NEWEST_ONCE 0x07
119#define MEDIA_PROXY_PLAYING_ORDER_NEWEST_REPEAT 0x08
120#define MEDIA_PROXY_PLAYING_ORDER_SHUFFLE_ONCE 0x09
121#define MEDIA_PROXY_PLAYING_ORDER_SHUFFLE_REPEAT 0x0a
122
129#define MEDIA_PROXY_PLAYING_ORDERS_SUPPORTED_SINGLE_ONCE BIT(0)
130#define MEDIA_PROXY_PLAYING_ORDERS_SUPPORTED_SINGLE_REPEAT BIT(1)
131#define MEDIA_PROXY_PLAYING_ORDERS_SUPPORTED_INORDER_ONCE BIT(2)
132#define MEDIA_PROXY_PLAYING_ORDERS_SUPPORTED_INORDER_REPEAT BIT(3)
133#define MEDIA_PROXY_PLAYING_ORDERS_SUPPORTED_OLDEST_ONCE BIT(4)
134#define MEDIA_PROXY_PLAYING_ORDERS_SUPPORTED_OLDEST_REPEAT BIT(5)
135#define MEDIA_PROXY_PLAYING_ORDERS_SUPPORTED_NEWEST_ONCE BIT(6)
136#define MEDIA_PROXY_PLAYING_ORDERS_SUPPORTED_NEWEST_REPEAT BIT(7)
137#define MEDIA_PROXY_PLAYING_ORDERS_SUPPORTED_SHUFFLE_ONCE BIT(8)
138#define MEDIA_PROXY_PLAYING_ORDERS_SUPPORTED_SHUFFLE_REPEAT BIT(9)
139
143#define MEDIA_PROXY_STATE_INACTIVE 0x00
144#define MEDIA_PROXY_STATE_PLAYING 0x01
145#define MEDIA_PROXY_STATE_PAUSED 0x02
146#define MEDIA_PROXY_STATE_SEEKING 0x03
147#define MEDIA_PROXY_STATE_LAST 0x04
148
152#define MEDIA_PROXY_OP_PLAY 0x01
153#define MEDIA_PROXY_OP_PAUSE 0x02
154#define MEDIA_PROXY_OP_FAST_REWIND 0x03
155#define MEDIA_PROXY_OP_FAST_FORWARD 0x04
156#define MEDIA_PROXY_OP_STOP 0x05
157
158#define MEDIA_PROXY_OP_MOVE_RELATIVE 0x10
159
160#define MEDIA_PROXY_OP_PREV_SEGMENT 0x20
161#define MEDIA_PROXY_OP_NEXT_SEGMENT 0x21
162#define MEDIA_PROXY_OP_FIRST_SEGMENT 0x22
163#define MEDIA_PROXY_OP_LAST_SEGMENT 0x23
164#define MEDIA_PROXY_OP_GOTO_SEGMENT 0x24
165
166#define MEDIA_PROXY_OP_PREV_TRACK 0x30
167#define MEDIA_PROXY_OP_NEXT_TRACK 0x31
168#define MEDIA_PROXY_OP_FIRST_TRACK 0x32
169#define MEDIA_PROXY_OP_LAST_TRACK 0x33
170#define MEDIA_PROXY_OP_GOTO_TRACK 0x34
171
172#define MEDIA_PROXY_OP_PREV_GROUP 0x40
173#define MEDIA_PROXY_OP_NEXT_GROUP 0x41
174#define MEDIA_PROXY_OP_FIRST_GROUP 0x42
175#define MEDIA_PROXY_OP_LAST_GROUP 0x43
176#define MEDIA_PROXY_OP_GOTO_GROUP 0x44
177
181#define MEDIA_PROXY_OPCODES_SUPPORTED_LEN 4
182
186#define MEDIA_PROXY_OP_SUP_PLAY BIT(0)
187#define MEDIA_PROXY_OP_SUP_PAUSE BIT(1)
188#define MEDIA_PROXY_OP_SUP_FAST_REWIND BIT(2)
189#define MEDIA_PROXY_OP_SUP_FAST_FORWARD BIT(3)
190#define MEDIA_PROXY_OP_SUP_STOP BIT(4)
191
192#define MEDIA_PROXY_OP_SUP_MOVE_RELATIVE BIT(5)
193
194#define MEDIA_PROXY_OP_SUP_PREV_SEGMENT BIT(6)
195#define MEDIA_PROXY_OP_SUP_NEXT_SEGMENT BIT(7)
196#define MEDIA_PROXY_OP_SUP_FIRST_SEGMENT BIT(8)
197#define MEDIA_PROXY_OP_SUP_LAST_SEGMENT BIT(9)
198#define MEDIA_PROXY_OP_SUP_GOTO_SEGMENT BIT(10)
199
200#define MEDIA_PROXY_OP_SUP_PREV_TRACK BIT(11)
201#define MEDIA_PROXY_OP_SUP_NEXT_TRACK BIT(12)
202#define MEDIA_PROXY_OP_SUP_FIRST_TRACK BIT(13)
203#define MEDIA_PROXY_OP_SUP_LAST_TRACK BIT(14)
204#define MEDIA_PROXY_OP_SUP_GOTO_TRACK BIT(15)
205
206#define MEDIA_PROXY_OP_SUP_PREV_GROUP BIT(16)
207#define MEDIA_PROXY_OP_SUP_NEXT_GROUP BIT(17)
208#define MEDIA_PROXY_OP_SUP_FIRST_GROUP BIT(18)
209#define MEDIA_PROXY_OP_SUP_LAST_GROUP BIT(19)
210#define MEDIA_PROXY_OP_SUP_GOTO_GROUP BIT(20)
211
215#define MEDIA_PROXY_CMD_SUCCESS 0x01
216#define MEDIA_PROXY_CMD_NOT_SUPPORTED 0x02
217#define MEDIA_PROXY_CMD_PLAYER_INACTIVE 0x03
218#define MEDIA_PROXY_CMD_CANNOT_BE_COMPLETED 0x04
219
223#define MEDIA_PROXY_SEARCH_TYPE_TRACK_NAME 0x01
224#define MEDIA_PROXY_SEARCH_TYPE_ARTIST_NAME 0x02
225#define MEDIA_PROXY_SEARCH_TYPE_ALBUM_NAME 0x03
226#define MEDIA_PROXY_SEARCH_TYPE_GROUP_NAME 0x04
227#define MEDIA_PROXY_SEARCH_TYPE_EARLIEST_YEAR 0x05
228#define MEDIA_PROXY_SEARCH_TYPE_LATEST_YEAR 0x06
229#define MEDIA_PROXY_SEARCH_TYPE_GENRE 0x07
230#define MEDIA_PROXY_SEARCH_TYPE_ONLY_TRACKS 0x08
231#define MEDIA_PROXY_SEARCH_TYPE_ONLY_GROUPS 0x09
232
236#define MEDIA_PROXY_SEARCH_SUCCESS 0x01
237#define MEDIA_PROXY_SEARCH_FAILURE 0x02
238
239/* Group object object types */
240#define MEDIA_PROXY_GROUP_OBJECT_TRACK_TYPE 0x00
241#define MEDIA_PROXY_GROUP_OBJECT_GROUP_TYPE 0x01
242
243
247struct media_player;
248
249/* PUBLIC API FOR CONTROLLERS */
250
256
268 void (*local_player_instance)(struct media_player *player, int err);
269
270#ifdef CONFIG_MCTL_REMOTE_PLAYER_CONTROL
282 void (*discover_player)(struct media_player *player, int err);
283#endif /* CONFIG_MCTL_REMOTE_PLAYER_CONTROL */
284
296 void (*player_name_recv)(struct media_player *player, int err, const char *name);
297
309 void (*icon_id_recv)(struct media_player *player, int err, uint64_t id);
310
322 void (*icon_url_recv)(struct media_player *player, int err, const char *url);
323
333 void (*track_changed_recv)(struct media_player *player, int err);
334
346 void (*track_title_recv)(struct media_player *player, int err, const char *title);
347
359 void (*track_duration_recv)(struct media_player *player, int err, int32_t duration);
360
373 void (*track_position_recv)(struct media_player *player, int err, int32_t position);
374
386 void (*track_position_write)(struct media_player *player, int err, int32_t position);
387
400 void (*playback_speed_recv)(struct media_player *player, int err, int8_t speed);
401
413 void (*playback_speed_write)(struct media_player *player, int err, int8_t speed);
414
426 void (*seeking_speed_recv)(struct media_player *player, int err, int8_t speed);
427
439 void (*track_segments_id_recv)(struct media_player *player, int err, uint64_t id);
440
453 void (*current_track_id_recv)(struct media_player *player, int err, uint64_t id);
454
466 void (*current_track_id_write)(struct media_player *player, int err, uint64_t id);
467
480 void (*next_track_id_recv)(struct media_player *player, int err, uint64_t id);
481
493 void (*next_track_id_write)(struct media_player *player, int err, uint64_t id);
494
506 void (*parent_group_id_recv)(struct media_player *player, int err, uint64_t id);
507
520 void (*current_group_id_recv)(struct media_player *player, int err, uint64_t id);
521
533 void (*current_group_id_write)(struct media_player *player, int err, uint64_t id);
534
547 void (*playing_order_recv)(struct media_player *player, int err, uint8_t order);
548
560 void (*playing_order_write)(struct media_player *player, int err, uint8_t order);
561
573 void (*playing_orders_supported_recv)(struct media_player *player, int err,
574 uint16_t orders);
575
588 void (*media_state_recv)(struct media_player *player, int err, uint8_t state);
589
601 void (*command_send)(struct media_player *player, int err, const struct mpl_cmd *cmd);
602
614 void (*command_recv)(struct media_player *player, int err,
615 const struct mpl_cmd_ntf *result);
616
628 void (*commands_supported_recv)(struct media_player *player, int err, uint32_t opcodes);
629
641 void (*search_send)(struct media_player *player, int err, const struct mpl_search *search);
642
659 void (*search_recv)(struct media_player *player, int err, uint8_t result_code);
660
672 void (*search_results_id_recv)(struct media_player *player, int err, uint64_t id);
673
685 void (*content_ctrl_id_recv)(struct media_player *player, int err, uint8_t ccid);
686};
687
696
714int media_proxy_ctrl_discover_player(struct bt_conn *conn);
715
723int media_proxy_ctrl_get_player_name(struct media_player *player);
724
740int media_proxy_ctrl_get_icon_id(struct media_player *player);
741
749int media_proxy_ctrl_get_icon_url(struct media_player *player);
750
758int media_proxy_ctrl_get_track_title(struct media_player *player);
759
770int media_proxy_ctrl_get_track_duration(struct media_player *player);
771
783int media_proxy_ctrl_get_track_position(struct media_player *player);
784
799int media_proxy_ctrl_set_track_position(struct media_player *player, int32_t position);
800
818int media_proxy_ctrl_get_playback_speed(struct media_player *player);
819
839int media_proxy_ctrl_set_playback_speed(struct media_player *player, int8_t speed);
840
857int media_proxy_ctrl_get_seeking_speed(struct media_player *player);
858
874int media_proxy_ctrl_get_track_segments_id(struct media_player *player);
875
891int media_proxy_ctrl_get_current_track_id(struct media_player *player);
892
906int media_proxy_ctrl_set_current_track_id(struct media_player *player, uint64_t id);
907
920int media_proxy_ctrl_get_next_track_id(struct media_player *player);
921
934int media_proxy_ctrl_set_next_track_id(struct media_player *player, uint64_t id);
935
953int media_proxy_ctrl_get_parent_group_id(struct media_player *player);
954
970int media_proxy_ctrl_get_current_group_id(struct media_player *player);
971
985int media_proxy_ctrl_set_current_group_id(struct media_player *player, uint64_t id);
986
994int media_proxy_ctrl_get_playing_order(struct media_player *player);
995
1006int media_proxy_ctrl_set_playing_order(struct media_player *player, uint8_t order);
1007
1018int media_proxy_ctrl_get_playing_orders_supported(struct media_player *player);
1019
1029int media_proxy_ctrl_get_media_state(struct media_player *player);
1030
1044int media_proxy_ctrl_send_command(struct media_player *player, const struct mpl_cmd *command);
1045
1056int media_proxy_ctrl_get_commands_supported(struct media_player *player);
1057
1077int media_proxy_ctrl_send_search(struct media_player *player, const struct mpl_search *search);
1078
1095int media_proxy_ctrl_get_search_results_id(struct media_player *player);
1096
1109
1110
1111/* PUBLIC API FOR PLAYERS */
1112
1118
1124 const char *(*get_player_name)(void);
1125
1138
1146 const char *(*get_icon_url)(void);
1147
1153 const char *(*get_track_title)(void);
1154
1164
1175
1187 void (*set_track_position)(int32_t position);
1188
1205
1223
1239
1252
1265
1275
1285
1294
1309
1322
1332
1339
1349
1360
1370
1380 void (*send_command)(const struct mpl_cmd *command);
1381
1392
1402 void (*send_search)(const struct mpl_search *search);
1403
1417
1428};
1429
1444
1445/* Initialize player - TODO: Move to player header file */
1447
1448/* TODO: Find best location for this call, and move this one also */
1449struct bt_ots *bt_mcs_get_ots(void);
1450
1451/* Callbacks from the player to the media proxy */
1459void media_proxy_pl_name_cb(const char *name);
1460
1468void media_proxy_pl_icon_url_cb(const char *url);
1469
1476
1485
1497
1514
1523
1532
1542
1551
1560
1569
1578
1587
1597void media_proxy_pl_command_cb(const struct mpl_cmd_ntf *cmd_ntf);
1598
1607
1621
1631
1632#ifdef __cplusplus
1633}
1634#endif
1635 /* End of group bt_media_proxy */
1637
1638#endif /* ZEPHYR_INCLUDE_BLUETOOTH_AUDIO_MEDIA_PROXY_H_ */
Bluetooth subsystem core APIs.
#define SEARCH_PARAM_MAX
Definition: mcs.h:171
#define SEARCH_LEN_MAX
Definition: mcs.h:169
int media_proxy_ctrl_get_playing_orders_supported(struct media_player *player)
Read Playing Orders Supported.
int media_proxy_ctrl_send_search(struct media_player *player, const struct mpl_search *search)
Set Search.
void media_proxy_pl_name_cb(const char *name)
Player name changed callback.
int media_proxy_ctrl_get_parent_group_id(struct media_player *player)
Read Parent Group Object ID.
int media_proxy_ctrl_get_commands_supported(struct media_player *player)
Read Commands Supported.
void media_proxy_pl_playback_speed_cb(int8_t speed)
Playback speed callback.
int media_proxy_ctrl_get_track_segments_id(struct media_player *player)
Read Current Track Segments Object ID.
int media_proxy_ctrl_get_player_name(struct media_player *player)
Read Media Player Name.
uint8_t media_proxy_ctrl_get_content_ctrl_id(struct media_player *player)
Read Content Control ID.
int media_proxy_ctrl_get_current_group_id(struct media_player *player)
Read Current Group Object ID.
int media_proxy_ctrl_get_playback_speed(struct media_player *player)
Get Playback Speed.
int media_proxy_ctrl_get_playing_order(struct media_player *player)
Read Playing Order.
int media_proxy_ctrl_register(struct media_proxy_ctrl_cbs *ctrl_cbs)
Register a controller with the media_proxy.
void media_proxy_pl_search_results_id_cb(uint64_t id)
Search Results object ID callback.
int media_proxy_ctrl_set_next_track_id(struct media_player *player, uint64_t id)
Set Next Track Object ID.
int media_proxy_ctrl_get_track_duration(struct media_player *player)
Read Track Duration.
void media_proxy_pl_track_changed_cb(void)
Track changed callback.
int media_proxy_ctrl_get_search_results_id(struct media_player *player)
Read Search Results Object ID.
int media_proxy_ctrl_send_command(struct media_player *player, const struct mpl_cmd *command)
Send Command.
int media_proxy_ctrl_discover_player(struct bt_conn *conn)
Discover a remote media player.
int media_proxy_ctrl_get_icon_id(struct media_player *player)
Read Icon Object ID.
void media_proxy_pl_track_position_cb(int32_t position)
Track position callback.
void media_proxy_pl_parent_group_id_cb(uint64_t id)
Parent group object ID callback.
void media_proxy_pl_command_cb(const struct mpl_cmd_ntf *cmd_ntf)
Command callback.
void media_proxy_pl_commands_supported_cb(uint32_t opcodes)
Commands supported callback.
int media_proxy_ctrl_set_track_position(struct media_player *player, int32_t position)
Set Track Position.
void media_proxy_pl_track_duration_cb(int32_t duration)
Track duration callback.
int media_proxy_ctrl_get_seeking_speed(struct media_player *player)
Get Seeking Speed.
void media_proxy_pl_media_state_cb(uint8_t state)
Media state callback.
void media_proxy_pl_search_cb(uint8_t result_code)
Search callback.
int media_proxy_ctrl_get_media_state(struct media_player *player)
Read Media State.
void media_proxy_pl_track_title_cb(char *title)
Track title callback.
void media_proxy_pl_playing_order_cb(uint8_t order)
Playing order callback.
int media_proxy_ctrl_set_playing_order(struct media_player *player, uint8_t order)
Set Playing Order.
int media_proxy_pl_init(void)
int media_proxy_ctrl_get_icon_url(struct media_player *player)
Read Icon URL.
int media_proxy_ctrl_set_playback_speed(struct media_player *player, int8_t speed)
Set Playback Speed.
int media_proxy_ctrl_get_track_title(struct media_player *player)
Read Track Title.
int media_proxy_pl_register(struct media_proxy_pl_calls *pl_calls)
Register a player with the media proxy.
void media_proxy_pl_current_group_id_cb(uint64_t id)
Current group object ID callback.
void media_proxy_pl_current_track_id_cb(uint64_t id)
Current track object ID callback.
void media_proxy_pl_icon_url_cb(const char *url)
Player icon URL changed callback.
int media_proxy_ctrl_get_track_position(struct media_player *player)
Read Track Position.
int media_proxy_ctrl_get_next_track_id(struct media_player *player)
Read Next Track Object ID.
int media_proxy_ctrl_set_current_group_id(struct media_player *player, uint64_t id)
Set Current Group Object ID.
int media_proxy_ctrl_set_current_track_id(struct media_player *player, uint64_t id)
Set Current Track Object ID.
void media_proxy_pl_seeking_speed_cb(int8_t speed)
Seeking speed callback.
int media_proxy_ctrl_get_current_track_id(struct media_player *player)
Read Current Track Object ID.
void media_proxy_pl_next_track_id_cb(uint64_t id)
Next track object ID callback.
struct bt_ots * bt_mcs_get_ots(void)
static void cmd(uint32_t command)
Execute a display list command by co-processor engine.
Definition: ft8xx_reference_api.h:153
state
Definition: parser_state.h:29
__UINT32_TYPE__ uint32_t
Definition: stdint.h:90
__INT32_TYPE__ int32_t
Definition: stdint.h:74
__UINT64_TYPE__ uint64_t
Definition: stdint.h:91
__UINT8_TYPE__ uint8_t
Definition: stdint.h:88
__UINT16_TYPE__ uint16_t
Definition: stdint.h:89
__INT8_TYPE__ int8_t
Definition: stdint.h:72
Callbacks to a controller, from the media proxy.
Definition: media_proxy.h:255
void(* search_recv)(struct media_player *player, int err, uint8_t result_code)
Search result code receive callback.
Definition: media_proxy.h:659
void(* commands_supported_recv)(struct media_player *player, int err, uint32_t opcodes)
Commands supported receive callback.
Definition: media_proxy.h:628
void(* next_track_id_write)(struct media_player *player, int err, uint64_t id)
Next Track Object ID write callback.
Definition: media_proxy.h:493
void(* content_ctrl_id_recv)(struct media_player *player, int err, uint8_t ccid)
Content Control ID receive callback.
Definition: media_proxy.h:685
void(* seeking_speed_recv)(struct media_player *player, int err, int8_t speed)
Seeking Speed receive callback.
Definition: media_proxy.h:426
void(* parent_group_id_recv)(struct media_player *player, int err, uint64_t id)
Parent Group Object ID receive callback.
Definition: media_proxy.h:506
void(* icon_url_recv)(struct media_player *player, int err, const char *url)
Media Player Icon URL receive callback.
Definition: media_proxy.h:322
void(* track_position_write)(struct media_player *player, int err, int32_t position)
Track Position write callback.
Definition: media_proxy.h:386
void(* next_track_id_recv)(struct media_player *player, int err, uint64_t id)
Next Track Object ID receive callback.
Definition: media_proxy.h:480
void(* playback_speed_recv)(struct media_player *player, int err, int8_t speed)
Playback Speed receive callback.
Definition: media_proxy.h:400
void(* current_track_id_write)(struct media_player *player, int err, uint64_t id)
Current Track Object ID write callback.
Definition: media_proxy.h:466
void(* playing_order_write)(struct media_player *player, int err, uint8_t order)
Playing Order write callback.
Definition: media_proxy.h:560
void(* track_position_recv)(struct media_player *player, int err, int32_t position)
Track Position receive callback.
Definition: media_proxy.h:373
void(* playing_orders_supported_recv)(struct media_player *player, int err, uint16_t orders)
Playing Orders Supported receive callback.
Definition: media_proxy.h:573
void(* current_group_id_recv)(struct media_player *player, int err, uint64_t id)
Current Group Object ID receive callback.
Definition: media_proxy.h:520
void(* track_duration_recv)(struct media_player *player, int err, int32_t duration)
Track Duration receive callback.
Definition: media_proxy.h:359
void(* command_send)(struct media_player *player, int err, const struct mpl_cmd *cmd)
Command send callback.
Definition: media_proxy.h:601
void(* command_recv)(struct media_player *player, int err, const struct mpl_cmd_ntf *result)
Command result receive callback.
Definition: media_proxy.h:614
void(* playing_order_recv)(struct media_player *player, int err, uint8_t order)
Playing Order receive callback.
Definition: media_proxy.h:547
void(* player_name_recv)(struct media_player *player, int err, const char *name)
Media Player Name receive callback.
Definition: media_proxy.h:296
void(* current_track_id_recv)(struct media_player *player, int err, uint64_t id)
Current Track Object ID receive callback.
Definition: media_proxy.h:453
void(* track_segments_id_recv)(struct media_player *player, int err, uint64_t id)
Track Segments Object ID receive callback.
Definition: media_proxy.h:439
void(* icon_id_recv)(struct media_player *player, int err, uint64_t id)
Media Player Icon Object ID receive callback.
Definition: media_proxy.h:309
void(* track_title_recv)(struct media_player *player, int err, const char *title)
Track Title receive callback.
Definition: media_proxy.h:346
void(* current_group_id_write)(struct media_player *player, int err, uint64_t id)
Current Group Object ID write callback.
Definition: media_proxy.h:533
void(* media_state_recv)(struct media_player *player, int err, uint8_t state)
Media State receive callback.
Definition: media_proxy.h:588
void(* playback_speed_write)(struct media_player *player, int err, int8_t speed)
Playback Speed write callback.
Definition: media_proxy.h:413
void(* track_changed_recv)(struct media_player *player, int err)
Track changed receive callback.
Definition: media_proxy.h:333
void(* search_send)(struct media_player *player, int err, const struct mpl_search *search)
Search send callback.
Definition: media_proxy.h:641
void(* search_results_id_recv)(struct media_player *player, int err, uint64_t id)
Search Results Object ID receive callback See also media_proxy_ctrl_get_search_results_id()
Definition: media_proxy.h:672
void(* local_player_instance)(struct media_player *player, int err)
Media Player Instance callback.
Definition: media_proxy.h:268
Available calls in a player, that the media proxy can call.
Definition: media_proxy.h:1117
void(* set_track_position)(int32_t position)
Set Track Position.
Definition: media_proxy.h:1187
int32_t(* get_track_position)(void)
Read Track Position.
Definition: media_proxy.h:1174
uint64_t(* get_parent_group_id)(void)
Read Parent Group Object ID.
Definition: media_proxy.h:1308
int32_t(* get_track_duration)(void)
Read Track Duration.
Definition: media_proxy.h:1163
void(* send_search)(const struct mpl_search *search)
Set Search.
Definition: media_proxy.h:1402
void(* set_current_track_id)(uint64_t id)
Set Current Track Object ID.
Definition: media_proxy.h:1274
void(* set_current_group_id)(uint64_t id)
Set Current Group Object ID.
Definition: media_proxy.h:1331
uint8_t(* get_content_ctrl_id)(void)
Read Content Control ID.
Definition: media_proxy.h:1427
uint8_t(* get_media_state)(void)
Read Media State.
Definition: media_proxy.h:1369
void(* set_playback_speed)(int8_t speed)
Set Playback Speed.
Definition: media_proxy.h:1222
uint64_t(* get_current_track_id)(void)
Read Current Track Object ID.
Definition: media_proxy.h:1264
uint64_t(* get_track_segments_id)(void)
Read Current Track Segments Object ID.
Definition: media_proxy.h:1251
uint8_t(* get_playing_order)(void)
Read Playing Order.
Definition: media_proxy.h:1338
uint64_t(* get_current_group_id)(void)
Read Current Group Object ID.
Definition: media_proxy.h:1321
uint16_t(* get_playing_orders_supported)(void)
Read Playing Orders Supported.
Definition: media_proxy.h:1359
void(* send_command)(const struct mpl_cmd *command)
Send Command.
Definition: media_proxy.h:1380
void(* set_next_track_id)(uint64_t id)
Set Next Track Object ID.
Definition: media_proxy.h:1293
uint64_t(* get_icon_id)(void)
Read Icon Object ID.
Definition: media_proxy.h:1137
void(* set_playing_order)(uint8_t order)
Set Playing Order.
Definition: media_proxy.h:1348
uint64_t(* get_search_results_id)(void)
Read Search Results Object ID.
Definition: media_proxy.h:1416
uint32_t(* get_commands_supported)(void)
Read Commands Supported.
Definition: media_proxy.h:1391
int8_t(* get_playback_speed)(void)
Get Playback Speed.
Definition: media_proxy.h:1204
int8_t(* get_seeking_speed)(void)
Get Seeking Speed.
Definition: media_proxy.h:1238
uint64_t(* get_next_track_id)(void)
Read Next Track Object ID.
Definition: media_proxy.h:1284
Media command notification.
Definition: media_proxy.h:64
uint8_t result_code
Definition: media_proxy.h:66
uint8_t requested_opcode
Definition: media_proxy.h:65
Media player command.
Definition: media_proxy.h:55
uint8_t opcode
Definition: media_proxy.h:56
bool use_param
Definition: media_proxy.h:57
int32_t param
Definition: media_proxy.h:58
Search control item.
Definition: media_proxy.h:72
uint8_t type
MEDIA_PROXY_SEARCH_TYPE_<...>
Definition: media_proxy.h:74
uint8_t len
Length of type and parameter.
Definition: media_proxy.h:73
char param[62]
Search parameter.
Definition: media_proxy.h:75
Search.
Definition: media_proxy.h:81
uint8_t len
Definition: media_proxy.h:82
char search[64]
Definition: media_proxy.h:83