Zephyr API 3.6.99
|
HCI RAW channel . More...
Data Structures | |
struct | bt_hci_raw_cmd_ext |
Macros | |
#define | BT_HCI_ERR_EXT_HANDLED 0xff |
#define | BT_HCI_RAW_CMD_EXT(_op, _min_len, _func) |
Helper macro to define a command extension. | |
Enumerations | |
enum | { BT_HCI_RAW_MODE_PASSTHROUGH = 0x00 , BT_HCI_RAW_MODE_H4 = 0x01 } |
Functions | |
int | bt_send (struct net_buf *buf) |
Send packet to the Bluetooth controller. | |
int | bt_hci_raw_set_mode (uint8_t mode) |
Set Bluetooth RAW channel mode. | |
uint8_t | bt_hci_raw_get_mode (void) |
Get Bluetooth RAW channel mode. | |
void | bt_hci_raw_cmd_ext_register (struct bt_hci_raw_cmd_ext *cmds, size_t size) |
Register Bluetooth RAW command extension table. | |
int | bt_enable_raw (struct k_fifo *rx_queue) |
Enable Bluetooth RAW channel: | |
HCI RAW channel .
#define BT_HCI_ERR_EXT_HANDLED 0xff |
#include <zephyr/bluetooth/hci_raw.h>
#define BT_HCI_RAW_CMD_EXT | ( | _op, | |
_min_len, | |||
_func ) |
#include <zephyr/bluetooth/hci_raw.h>
Helper macro to define a command extension.
_op | Opcode of the command. |
_min_len | Minimal length of the command. |
_func | Handler function to be called. |
anonymous enum |
#include <zephyr/bluetooth/hci_raw.h>
int bt_enable_raw | ( | struct k_fifo * | rx_queue | ) |
#include <zephyr/bluetooth/hci_raw.h>
Enable Bluetooth RAW channel:
Enable Bluetooth RAW HCI channel.
rx_queue | netbuf queue where HCI packets received from the Bluetooth controller are to be queued. The queue is defined in the caller while the available buffers pools are handled in the stack. |
void bt_hci_raw_cmd_ext_register | ( | struct bt_hci_raw_cmd_ext * | cmds, |
size_t | size ) |
#include <zephyr/bluetooth/hci_raw.h>
Register Bluetooth RAW command extension table.
Register Bluetooth RAW channel command extension table, opcodes in this table are intercepted to sent to the handler function.
cmds | Pointer to the command extension table. |
size | Size of the command extension table. |
uint8_t bt_hci_raw_get_mode | ( | void | ) |
#include <zephyr/bluetooth/hci_raw.h>
Get Bluetooth RAW channel mode.
Get access mode of Bluetooth RAW channel.
int bt_hci_raw_set_mode | ( | uint8_t | mode | ) |
#include <zephyr/bluetooth/hci_raw.h>
Set Bluetooth RAW channel mode.
Set access mode of Bluetooth RAW channel.
mode | Access mode. |
int bt_send | ( | struct net_buf * | buf | ) |
#include <zephyr/bluetooth/hci_raw.h>
Send packet to the Bluetooth controller.
Send packet to the Bluetooth controller. Caller needs to implement netbuf pool.
buf | netbuf packet to be send |