Zephyr API 3.6.99
|
ISO Channel operations structure. More...
#include <iso.h>
Data Fields | |
void(* | connected )(struct bt_iso_chan *chan) |
Channel connected callback. | |
void(* | disconnected )(struct bt_iso_chan *chan, uint8_t reason) |
Channel disconnected callback. | |
struct net_buf *(* | alloc_buf )(struct bt_iso_chan *chan) |
Channel alloc_buf callback. | |
void(* | recv )(struct bt_iso_chan *chan, const struct bt_iso_recv_info *info, struct net_buf *buf) |
Channel recv callback. | |
void(* | sent )(struct bt_iso_chan *chan) |
Channel sent callback. | |
ISO Channel operations structure.
struct net_buf *(* bt_iso_chan_ops::alloc_buf) (struct bt_iso_chan *chan) |
Channel alloc_buf callback.
If this callback is provided the channel will use it to allocate buffers to store incoming data.
chan | The channel requesting a buffer. |
void(* bt_iso_chan_ops::connected) (struct bt_iso_chan *chan) |
Channel connected callback.
If this callback is provided it will be called whenever the connection completes.
For a peripheral, the QoS values (see bt_iso_chan_io_qos) are set when this is called. The peripheral does not have any information about the RTN though.
chan | The channel that has been connected |
void(* bt_iso_chan_ops::disconnected) (struct bt_iso_chan *chan, uint8_t reason) |
Channel disconnected callback.
If this callback is provided it will be called whenever the channel is disconnected, including when a connection gets rejected or when setting security fails.
chan | The channel that has been Disconnected |
reason | BT_HCI_ERR_* reason for the disconnection. |
void(* bt_iso_chan_ops::recv) (struct bt_iso_chan *chan, const struct bt_iso_recv_info *info, struct net_buf *buf) |
Channel recv callback.
chan | The channel receiving data. |
buf | Buffer containing incoming data. |
info | Pointer to the metadata for the buffer. The lifetime of the pointer is linked to the lifetime of the net_buf. Metadata such as sequence number and timestamp can be provided by the bluetooth controller. |
void(* bt_iso_chan_ops::sent) (struct bt_iso_chan *chan) |
Channel sent callback.
This callback will be called once the controller marks the SDU as completed. When the controller does so is implementation dependent. It could be after the SDU is enqueued for transmission, or after it is sent on air or flushed.
chan | The channel which has sent data. |