libnx  v4.6.0
Data Structures | Functions
btdrv.h File Reference

Bluetooth driver (btdrv) service IPC wrapper. More...

#include "../types.h"
#include "../kernel/event.h"
#include "../services/btdrv_types.h"
#include "../services/set.h"
#include "../sf/service.h"

Go to the source code of this file.

Data Structures

struct  BtdrvEventInfo
 Data for btdrvGetEventInfo. The data stored here depends on the BtdrvEventType. More...
 
struct  BtdrvHidEventInfo
 Data for btdrvGetHidEventInfo. The data stored here depends on the BtdrvHidEventType. More...
 
struct  BtdrvHidReportEventInfo
 Data for btdrvGetHidReportEventInfo. The data stored here depends on the BtdrvHidEventType. More...
 
struct  BtdrvHidReportEventInfoBufferData
 The raw sharedmem data for HidReportEventInfo. More...
 
union  BtdrvAudioEventInfo
 Data for btdrvGetAudioEventInfo. The data stored here depends on the BtdrvAudioEventType. More...
 
struct  BtdrvCircularBuffer
 CircularBuffer. More...
 
struct  BtdrvBleEventInfo
 Data for btdrvGetBleManagedEventInfo and btdrvGetLeHidEventInfo. The data stored here depends on the BtdrvBleEventType. More...
 

Functions

Result btdrvInitialize (void)
 Initialize btdrv.
 
void btdrvExit (void)
 Exit btdrv.
 
ServicebtdrvGetServiceSession (void)
 Gets the Service object for the actual btdrv service session.
 
Result btdrvInitializeBluetooth (Event *out_event)
 InitializeBluetooth. More...
 
Result btdrvEnableBluetooth (void)
 EnableBluetooth. More...
 
Result btdrvDisableBluetooth (void)
 DisableBluetooth. More...
 
Result btdrvFinalizeBluetooth (void)
 FinalizeBluetooth. More...
 
Result btdrvLegacyGetAdapterProperties (BtdrvAdapterPropertyOld *properties)
 GetAdapterProperties [1.0.0-11.0.1]. More...
 
Result btdrvGetAdapterProperties (BtdrvAdapterPropertySet *properties)
 GetAdapterProperties [12.0.0+]. More...
 
Result btdrvLegacyGetAdapterProperty (BtdrvBluetoothPropertyType type, void *buffer, size_t size)
 GetAdapterProperty [1.0.0-11.0.1]. More...
 
Result btdrvGetAdapterProperty (BtdrvAdapterPropertyType type, BtdrvAdapterProperty *property)
 GetAdapterProperty [12.0.0+]. More...
 
Result btdrvLegacySetAdapterProperty (BtdrvBluetoothPropertyType type, const void *buffer, size_t size)
 SetAdapterProperty [1.0.0-11.0.1]. More...
 
Result btdrvSetAdapterProperty (BtdrvAdapterPropertyType type, const BtdrvAdapterProperty *property)
 SetAdapterProperty [12.0.0+]. More...
 
Result btdrvLegacyStartInquiry (void)
 StartInquiry [1.0.0-11.0.1]. More...
 
Result btdrvStartInquiry (u32 services, s64 duration)
 StartInquiry [12.0.0+]. More...
 
Result btdrvStopInquiry (void)
 This stops Inquiry which was started by btdrvStartInquiry, if it's still active. More...
 
Result btdrvCreateBond (BtdrvAddress addr, u32 type)
 CreateBond. More...
 
Result btdrvRemoveBond (BtdrvAddress addr)
 RemoveBond. More...
 
Result btdrvCancelBond (BtdrvAddress addr)
 CancelBond. More...
 
Result btdrvLegacyRespondToPinRequest (BtdrvAddress addr, bool flag, const BtdrvBluetoothPinCode *pin_code, u8 length)
 RespondToPinRequest [1.0.0-11.0.1]. More...
 
Result btdrvRespondToPinRequest (BtdrvAddress addr, const BtdrvPinCode *pin_code)
 RespondToPinRequest [12.0.0+]. More...
 
Result btdrvRespondToSspRequest (BtdrvAddress addr, u32 variant, bool accept, u32 passkey)
 RespondToSspRequest. More...
 
Result btdrvGetEventInfo (void *buffer, size_t size, BtdrvEventType *type)
 GetEventInfo. More...
 
Result btdrvInitializeHid (Event *out_event)
 InitializeHid. More...
 
Result btdrvOpenHidConnection (BtdrvAddress addr)
 OpenHidConnection. More...
 
Result btdrvCloseHidConnection (BtdrvAddress addr)
 CloseHidConnection. More...
 
Result btdrvWriteHidData (BtdrvAddress addr, const BtdrvHidReport *buffer)
 This sends a HID DATA transaction packet with report-type Output. More...
 
Result btdrvWriteHidData2 (BtdrvAddress addr, const void *buffer, size_t size)
 WriteHidData2. More...
 
Result btdrvSetHidReport (BtdrvAddress addr, BtdrvBluetoothHhReportType type, const BtdrvHidReport *buffer)
 This sends a HID SET_REPORT transaction packet. More...
 
Result btdrvGetHidReport (BtdrvAddress addr, u8 report_id, BtdrvBluetoothHhReportType type)
 This sends a HID GET_REPORT transaction packet. More...
 
Result btdrvTriggerConnection (BtdrvAddress addr, u16 unk)
 TriggerConnection. More...
 
Result btdrvAddPairedDeviceInfo (const SetSysBluetoothDevicesSettings *settings)
 AddPairedDeviceInfo. More...
 
Result btdrvGetPairedDeviceInfo (BtdrvAddress addr, SetSysBluetoothDevicesSettings *settings)
 GetPairedDeviceInfo. More...
 
Result btdrvFinalizeHid (void)
 FinalizeHid. More...
 
Result btdrvGetHidEventInfo (void *buffer, size_t size, BtdrvHidEventType *type)
 GetHidEventInfo. More...
 
Result btdrvSetTsi (BtdrvAddress addr, u8 tsi)
 SetTsi. More...
 
Result btdrvEnableBurstMode (BtdrvAddress addr, bool flag)
 EnableBurstMode. More...
 
Result btdrvSetZeroRetransmission (BtdrvAddress addr, u8 *report_ids, u8 count)
 SetZeroRetransmission. More...
 
Result btdrvEnableMcMode (bool flag)
 EnableMcMode. More...
 
Result btdrvEnableLlrScan (void)
 EnableLlrScan. More...
 
Result btdrvDisableLlrScan (void)
 DisableLlrScan. More...
 
Result btdrvEnableRadio (bool flag)
 EnableRadio. More...
 
Result btdrvSetVisibility (bool inquiry_scan, bool page_scan)
 SetVisibility. More...
 
Result btdrvEnableTbfcScan (bool flag)
 EnableTbfcScan. More...
 
Result btdrvRegisterHidReportEvent (Event *out_event)
 RegisterHidReportEvent. More...
 
Result btdrvGetHidReportEventInfo (void *buffer, size_t size, BtdrvHidEventType *type)
 GetHidReportEventInfo. More...
 
void * btdrvGetHidReportEventInfoSharedmemAddr (void)
 Gets the SharedMemory addr for HidReportEventInfo (BtdrvCircularBuffer), only valid when btdrvRegisterHidReportEvent was previously used, on [7.0.0+].
 
Result btdrvGetLatestPlr (BtdrvPlrList *out)
 GetLatestPlr. More...
 
Result btdrvGetPendingConnections (void)
 GetPendingConnections. More...
 
Result btdrvGetChannelMap (BtdrvChannelMapList *out)
 GetChannelMap. More...
 
Result btdrvEnableTxPowerBoostSetting (bool flag)
 EnableTxPowerBoostSetting. More...
 
Result btdrvIsTxPowerBoostSettingEnabled (bool *out)
 IsTxPowerBoostSettingEnabled. More...
 
Result btdrvEnableAfhSetting (bool flag)
 EnableAfhSetting. More...
 
Result btdrvIsAfhSettingEnabled (bool *out)
 IsAfhSettingEnabled. More...
 
Result btdrvInitializeBle (Event *out_event)
 InitializeBle. More...
 
Result btdrvEnableBle (void)
 EnableBle. More...
 
Result btdrvDisableBle (void)
 DisableBle. More...
 
Result btdrvFinalizeBle (void)
 FinalizeBle. More...
 
Result btdrvSetBleVisibility (bool discoverable, bool connectable)
 SetBleVisibility. More...
 
Result btdrvSetLeConnectionParameter (const BtdrvLeConnectionParams *param)
 SetLeConnectionParameter. More...
 
Result btdrvSetBleConnectionParameter (BtdrvAddress addr, const BtdrvBleConnectionParameter *param, bool preference)
 SetBleConnectionParameter. More...
 
Result btdrvSetLeDefaultConnectionParameter (const BtdrvLeConnectionParams *param)
 SetLeDefaultConnectionParameter. More...
 
Result btdrvSetBleDefaultConnectionParameter (const BtdrvBleConnectionParameter *param)
 SetBleDefaultConnectionParameter. More...
 
Result btdrvSetBleAdvertiseData (const BtdrvBleAdvertisePacketData *data)
 SetBleAdvertiseData. More...
 
Result btdrvSetBleAdvertiseParameter (BtdrvAddress addr, u16 min_interval, u16 max_interval)
 SetBleAdvertiseParameter. More...
 
Result btdrvStartBleScan (void)
 StartBleScan. More...
 
Result btdrvStopBleScan (void)
 StopBleScan. More...
 
Result btdrvAddBleScanFilterCondition (const BtdrvBleAdvertiseFilter *filter)
 AddBleScanFilterCondition. More...
 
Result btdrvDeleteBleScanFilterCondition (const BtdrvBleAdvertiseFilter *filter)
 DeleteBleScanFilterCondition. More...
 
Result btdrvDeleteBleScanFilter (u8 index)
 DeleteBleScanFilter. More...
 
Result btdrvClearBleScanFilters (void)
 ClearBleScanFilters. More...
 
Result btdrvEnableBleScanFilter (bool flag)
 EnableBleScanFilter. More...
 
Result btdrvRegisterGattClient (const BtdrvGattAttributeUuid *uuid)
 RegisterGattClient. More...
 
Result btdrvUnregisterGattClient (u8 client_if)
 UnregisterGattClient. More...
 
Result btdrvUnregisterAllGattClients (void)
 UnregisterAllGattClients. More...
 
Result btdrvConnectGattServer (u8 client_if, BtdrvAddress addr, bool is_direct, u64 AppletResourceUserId)
 ConnectGattServer. More...
 
Result btdrvCancelConnectGattServer (u8 client_if, BtdrvAddress addr, bool is_direct)
 CancelConnectGattServer. More...
 
Result btdrvDisconnectGattServer (u32 conn_id)
 DisconnectGattServer. More...
 
Result btdrvGetGattAttribute (BtdrvAddress addr, u32 conn_id)
 GetGattAttribute. More...
 
Result btdrvGetGattService (u32 conn_id, const BtdrvGattAttributeUuid *uuid)
 GetGattService. More...
 
Result btdrvConfigureAttMtu (u32 conn_id, u16 mtu)
 ConfigureAttMtu. More...
 
Result btdrvRegisterGattServer (const BtdrvGattAttributeUuid *uuid)
 RegisterGattServer. More...
 
Result btdrvUnregisterGattServer (u8 server_if)
 UnregisterGattServer. More...
 
Result btdrvConnectGattClient (u8 server_if, BtdrvAddress addr, bool is_direct)
 ConnectGattClient. More...
 
Result btdrvDisconnectGattClient (u8 conn_id, BtdrvAddress addr)
 DisconnectGattClient. More...
 
Result btdrvAddGattService (u8 server_if, const BtdrvGattAttributeUuid *uuid, u8 num_handle, bool is_primary)
 AddGattService. More...
 
Result btdrvEnableGattService (u8 service_id, const BtdrvGattAttributeUuid *uuid)
 EnableGattService. More...
 
Result btdrvAddGattCharacteristic (u8 service_id, const BtdrvGattAttributeUuid *serv_uuid, const BtdrvGattAttributeUuid *char_uuid, u8 permissions, u16 property)
 AddGattCharacteristic. More...
 
Result btdrvAddGattDescriptor (u8 service_id, const BtdrvGattAttributeUuid *serv_uuid, const BtdrvGattAttributeUuid *desc_uuid, u16 permissions)
 AddGattDescriptor. More...
 
Result btdrvGetBleManagedEventInfo (void *buffer, size_t size, BtdrvBleEventType *type)
 GetBleManagedEventInfo. More...
 
Result btdrvGetGattFirstCharacteristic (u32 conn_id, const BtdrvGattId *serv_id, bool is_primary, const BtdrvGattAttributeUuid *filter_uuid, u8 *out_property, BtdrvGattId *out_char_id)
 GetGattFirstCharacteristic. More...
 
Result btdrvGetGattNextCharacteristic (u32 conn_id, const BtdrvGattId *serv_id, bool is_primary, const BtdrvGattId *char_id, const BtdrvGattAttributeUuid *filter_uuid, u8 *out_property, BtdrvGattId *out_char_id)
 GetGattNextCharacteristic. More...
 
Result btdrvGetGattFirstDescriptor (u32 conn_id, const BtdrvGattId *serv_id, bool is_primary, const BtdrvGattId *char_id, const BtdrvGattAttributeUuid *filter_uuid, BtdrvGattId *out_desc_id)
 GetGattFirstDescriptor. More...
 
Result btdrvGetGattNextDescriptor (u32 conn_id, const BtdrvGattId *serv_id, bool is_primary, const BtdrvGattId *char_id, const BtdrvGattId *desc_id, const BtdrvGattAttributeUuid *filter_uuid, BtdrvGattId *out_desc_id)
 GetGattNextDescriptor. More...
 
Result btdrvRegisterGattManagedDataPath (const BtdrvGattAttributeUuid *uuid)
 RegisterGattManagedDataPath. More...
 
Result btdrvUnregisterGattManagedDataPath (const BtdrvGattAttributeUuid *uuid)
 UnregisterGattManagedDataPath. More...
 
Result btdrvRegisterGattHidDataPath (const BtdrvGattAttributeUuid *uuid)
 RegisterGattHidDataPath. More...
 
Result btdrvUnregisterGattHidDataPath (const BtdrvGattAttributeUuid *uuid)
 UnregisterGattHidDataPath. More...
 
Result btdrvRegisterGattDataPath (const BtdrvGattAttributeUuid *uuid)
 RegisterGattDataPath. More...
 
Result btdrvUnregisterGattDataPath (const BtdrvGattAttributeUuid *uuid)
 UnregisterGattDataPath. More...
 
Result btdrvReadGattCharacteristic (u32 connection_handle, bool is_primary, const BtdrvGattId *serv_id, const BtdrvGattId *char_id, u8 auth_req)
 ReadGattCharacteristic. More...
 
Result btdrvReadGattDescriptor (u32 connection_handle, bool is_primary, const BtdrvGattId *serv_id, const BtdrvGattId *char_id, const BtdrvGattId *desc_id, u8 auth_req)
 ReadGattDescriptor. More...
 
Result btdrvWriteGattCharacteristic (u32 connection_handle, bool is_primary, const BtdrvGattId *serv_id, const BtdrvGattId *char_id, const void *buffer, size_t size, u8 auth_req, bool with_response)
 WriteGattCharacteristic. More...
 
Result btdrvWriteGattDescriptor (u32 connection_handle, bool is_primary, const BtdrvGattId *serv_id, const BtdrvGattId *char_id, const BtdrvGattId *desc_id, const void *buffer, size_t size, u8 auth_req)
 WriteGattDescriptor. More...
 
Result btdrvRegisterGattNotification (u32 connection_handle, bool is_primary, const BtdrvGattId *serv_id, const BtdrvGattId *char_id)
 RegisterGattNotification. More...
 
Result btdrvUnregisterGattNotification (u32 connection_handle, bool is_primary, const BtdrvGattId *serv_id, const BtdrvGattId *char_id)
 UnregisterGattNotification. More...
 
Result btdrvGetLeHidEventInfo (void *buffer, size_t size, BtdrvBleEventType *type)
 GetLeHidEventInfo. More...
 
Result btdrvRegisterBleHidEvent (Event *out_event)
 RegisterBleHidEvent. More...
 
Result btdrvSetBleScanParameter (u16 scan_interval, u16 scan_window)
 SetBleScanParameter. More...
 
Result btdrvMoveToSecondaryPiconet (BtdrvAddress addr)
 MoveToSecondaryPiconet. More...
 
Result btdrvIsBluetoothEnabled (bool *out)
 IsBluetoothEnabled. More...
 
Result btdrvAcquireAudioEvent (Event *out_event, bool autoclear)
 AcquireAudioEvent. More...
 
Result btdrvGetAudioEventInfo (void *buffer, size_t size, BtdrvAudioEventType *type)
 GetAudioEventInfo. More...
 
Result btdrvOpenAudioConnection (BtdrvAddress addr)
 OpenAudioConnection. More...
 
Result btdrvCloseAudioConnection (BtdrvAddress addr)
 CloseAudioConnection. More...
 
Result btdrvOpenAudioOut (BtdrvAddress addr, u32 *audio_handle)
 OpenAudioOut. More...
 
Result btdrvCloseAudioOut (u32 audio_handle)
 CloseAudioOut. More...
 
Result btdrvStartAudioOut (u32 audio_handle, const BtdrvPcmParameter *pcm_param, s64 in_latency, s64 *out_latency, u64 *out1)
 StartAudioOut. More...
 
Result btdrvStopAudioOut (u32 audio_handle)
 StopAudioOut. More...
 
Result btdrvGetAudioOutState (u32 audio_handle, BtdrvAudioOutState *out)
 GetAudioOutState. More...
 
Result btdrvGetAudioOutFeedingCodec (u32 audio_handle, BtdrvAudioCodec *out)
 GetAudioOutFeedingCodec. More...
 
Result btdrvGetAudioOutFeedingParameter (u32 audio_handle, BtdrvPcmParameter *out)
 GetAudioOutFeedingParameter. More...
 
Result btdrvAcquireAudioOutStateChangedEvent (u32 audio_handle, Event *out_event, bool autoclear)
 AcquireAudioOutStateChangedEvent. More...
 
Result btdrvAcquireAudioOutBufferAvailableEvent (u32 audio_handle, Event *out_event, bool autoclear)
 AcquireAudioOutBufferAvailableEvent. More...
 
Result btdrvSendAudioData (u32 audio_handle, const void *buffer, size_t size, u64 *transferred_size)
 SendAudioData. More...
 
Result btdrvAcquireAudioControlInputStateChangedEvent (Event *out_event, bool autoclear)
 AcquireAudioControlInputStateChangedEvent. More...
 
Result btdrvGetAudioControlInputState (BtdrvAudioControlButtonState *states, s32 count, s32 *total_out)
 GetAudioControlInputState. More...
 
Result btdrvAcquireAudioConnectionStateChangedEvent (Event *out_event, bool autoclear)
 AcquireAudioConnectionStateChangedEvent. More...
 
Result btdrvGetConnectedAudioDevice (BtdrvAddress *addrs, s32 count, s32 *total_out)
 GetConnectedAudioDevice. More...
 
Result btdrvCloseAudioControlInput (BtdrvAddress addr)
 CloseAudioControlInput. More...
 
Result btdrvRegisterAudioControlNotification (BtdrvAddress addr, u32 event_type)
 RegisterAudioControlNotification. More...
 
Result btdrvSendAudioControlPassthroughCommand (BtdrvAddress addr, u32 op_id, u32 state_type)
 SendAudioControlPassthroughCommand. More...
 
Result btdrvSendAudioControlSetAbsoluteVolumeCommand (BtdrvAddress addr, s32 val)
 SendAudioControlSetAbsoluteVolumeCommand. More...
 
Result btdrvIsManufacturingMode (bool *out)
 IsManufacturingMode. More...
 
Result btdrvEmulateBluetoothCrash (BtdrvFatalReason reason)
 EmulateBluetoothCrash. More...
 
Result btdrvGetBleChannelMap (BtdrvChannelMapList *out)
 GetBleChannelMap. More...
 
CircularBuffer
void * btdrvCircularBufferRead (BtdrvCircularBuffer *c)
 Read. More...
 
bool btdrvCircularBufferFree (BtdrvCircularBuffer *c)
 Free. More...
 

Detailed Description

Bluetooth driver (btdrv) service IPC wrapper.

Author
yellows8, ndeadly

Function Documentation

◆ btdrvAcquireAudioConnectionStateChangedEvent()

Result btdrvAcquireAudioConnectionStateChangedEvent ( Event out_event,
bool  autoclear 
)

AcquireAudioConnectionStateChangedEvent.

Note
Only available on [12.0.0-13.2.1].
Parameters
[out]out_eventOutput Event.
[in]autoclearEvent autoclear.

◆ btdrvAcquireAudioControlInputStateChangedEvent()

Result btdrvAcquireAudioControlInputStateChangedEvent ( Event out_event,
bool  autoclear 
)

AcquireAudioControlInputStateChangedEvent.

Note
Only available on [12.0.0+].
Parameters
[out]out_eventOutput Event.
[in]autoclearEvent autoclear.

◆ btdrvAcquireAudioEvent()

Result btdrvAcquireAudioEvent ( Event out_event,
bool  autoclear 
)

AcquireAudioEvent.

Note
Only available on [12.0.0+].
Parameters
[out]out_eventOutput Event.
[in]autoclearEvent autoclear.

◆ btdrvAcquireAudioOutBufferAvailableEvent()

Result btdrvAcquireAudioOutBufferAvailableEvent ( u32  audio_handle,
Event out_event,
bool  autoclear 
)

AcquireAudioOutBufferAvailableEvent.

Note
Only available on [12.0.0+].
Parameters
[in]audio_handleAudio handle from btdrvOpenAudioOut.
[out]out_eventOutput Event.
[in]autoclearEvent autoclear.

◆ btdrvAcquireAudioOutStateChangedEvent()

Result btdrvAcquireAudioOutStateChangedEvent ( u32  audio_handle,
Event out_event,
bool  autoclear 
)

AcquireAudioOutStateChangedEvent.

Note
Only available on [12.0.0+].
Parameters
[in]audio_handleAudio handle from btdrvOpenAudioOut.
[out]out_eventOutput Event.
[in]autoclearEvent autoclear.

◆ btdrvAddBleScanFilterCondition()

Result btdrvAddBleScanFilterCondition ( const BtdrvBleAdvertiseFilter filter)

AddBleScanFilterCondition.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]filterBtdrvBleAdvertiseFilter

◆ btdrvAddGattCharacteristic()

Result btdrvAddGattCharacteristic ( u8  service_id,
const BtdrvGattAttributeUuid serv_uuid,
const BtdrvGattAttributeUuid char_uuid,
u8  permissions,
u16  property 
)

AddGattCharacteristic.

Note
Only available on [5.0.0+].
Parameters
[in]service_idService ID
[in]serv_uuidService UUID BtdrvGattAttributeUuid
[in]char_uuidCharacteristic UUID BtdrvGattAttributeUuid
[in]permissionsBtdrvGattAttributePermission
[in]propertyBtdrvGattCharacteristicProperty

◆ btdrvAddGattDescriptor()

Result btdrvAddGattDescriptor ( u8  service_id,
const BtdrvGattAttributeUuid serv_uuid,
const BtdrvGattAttributeUuid desc_uuid,
u16  permissions 
)

AddGattDescriptor.

Note
Only available on [5.0.0+].
Parameters
[in]service_idService ID
[in]serv_uuidService UUID BtdrvGattAttributeUuid
[in]desc_uuidDescriptor UUID BtdrvGattAttributeUuid
[in]permissionsBtdrvGattAttributePermission

◆ btdrvAddGattService()

Result btdrvAddGattService ( u8  server_if,
const BtdrvGattAttributeUuid uuid,
u8  num_handle,
bool  is_primary 
)

AddGattService.

Note
Only available on [5.0.0+].
Parameters
[in]server_ifServer interface ID
[in]uuidBtdrvGattAttributeUuid
[in]num_handleNumber of handles
[in]is_primaryIs a primary service or not

◆ btdrvAddPairedDeviceInfo()

Result btdrvAddPairedDeviceInfo ( const SetSysBluetoothDevicesSettings settings)

AddPairedDeviceInfo.

Note
This is used by btm-sysmodule.
Parameters
[in]settingsSetSysBluetoothDevicesSettings

◆ btdrvCancelBond()

Result btdrvCancelBond ( BtdrvAddress  addr)

CancelBond.

Note
This is used by btm-sysmodule.
Parameters
[in]addrBtdrvAddress

◆ btdrvCancelConnectGattServer()

Result btdrvCancelConnectGattServer ( u8  client_if,
BtdrvAddress  addr,
bool  is_direct 
)

CancelConnectGattServer.

Note
Only available on [5.1.0+].
This is used by btm-sysmodule.
Parameters
[in]client_ifClient interface ID
[in]addrBtdrvAddress
[in]is_directWhether a direct connection or a background auto connection

◆ btdrvCircularBufferFree()

bool btdrvCircularBufferFree ( BtdrvCircularBuffer c)

Free.

Note
Used by btdrvGetHidReportEventInfo on [7.0.0+].
Parameters
cBtdrvCircularBuffer

◆ btdrvCircularBufferRead()

void* btdrvCircularBufferRead ( BtdrvCircularBuffer c)

Read.

Note
Used by btdrvGetHidReportEventInfo on [7.0.0+].
Parameters
cBtdrvCircularBuffer

◆ btdrvClearBleScanFilters()

Result btdrvClearBleScanFilters ( void  )

ClearBleScanFilters.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.

◆ btdrvCloseAudioConnection()

Result btdrvCloseAudioConnection ( BtdrvAddress  addr)

CloseAudioConnection.

Note
Only available on [12.0.0+].
Parameters
[in]addrBtdrvAddress

◆ btdrvCloseAudioControlInput()

Result btdrvCloseAudioControlInput ( BtdrvAddress  addr)

CloseAudioControlInput.

Note
Only available on [13.0.0+].
Parameters
[in]addrBtdrvAddress

◆ btdrvCloseAudioOut()

Result btdrvCloseAudioOut ( u32  audio_handle)

CloseAudioOut.

Note
Only available on [12.0.0+].
Parameters
[in]audio_handleAudio handle from btdrvOpenAudioOut.

◆ btdrvCloseHidConnection()

Result btdrvCloseHidConnection ( BtdrvAddress  addr)

CloseHidConnection.

Note
This is used by btm-sysmodule.
Parameters
[in]addrBtdrvAddress

◆ btdrvConfigureAttMtu()

Result btdrvConfigureAttMtu ( u32  conn_id,
u16  mtu 
)

ConfigureAttMtu.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]conn_idConnection ID
[in]mtuMTU

◆ btdrvConnectGattClient()

Result btdrvConnectGattClient ( u8  server_if,
BtdrvAddress  addr,
bool  is_direct 
)

ConnectGattClient.

Note
Only available on [5.0.0+].
Parameters
[in]server_ifServer interface ID
[in]addrBtdrvAddress
[in]is_directWhether a direct connection or a background auto connection

◆ btdrvConnectGattServer()

Result btdrvConnectGattServer ( u8  client_if,
BtdrvAddress  addr,
bool  is_direct,
u64  AppletResourceUserId 
)

ConnectGattServer.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]client_ifClient interface ID
[in]addrBtdrvAddress
[in]is_directWhether a direct connection or a background auto connection
[in]AppletResourceUserIdAppletResourceUserId

◆ btdrvCreateBond()

Result btdrvCreateBond ( BtdrvAddress  addr,
u32  type 
)

CreateBond.

Note
This is used by btm-sysmodule.
Parameters
[in]addrBtdrvAddress
[in]typeTransportType

◆ btdrvDeleteBleScanFilter()

Result btdrvDeleteBleScanFilter ( u8  index)

DeleteBleScanFilter.

Note
Only available on [5.0.0+].
Parameters
[in]indexFilter index

◆ btdrvDeleteBleScanFilterCondition()

Result btdrvDeleteBleScanFilterCondition ( const BtdrvBleAdvertiseFilter filter)

DeleteBleScanFilterCondition.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]filterBtdrvBleAdvertiseFilter

◆ btdrvDisableBle()

Result btdrvDisableBle ( void  )

DisableBle.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.

◆ btdrvDisableBluetooth()

Result btdrvDisableBluetooth ( void  )

DisableBluetooth.

Note
This is used by btm-sysmodule.

◆ btdrvDisableLlrScan()

Result btdrvDisableLlrScan ( void  )

DisableLlrScan.

Note
This is used by btm-sysmodule.

◆ btdrvDisconnectGattClient()

Result btdrvDisconnectGattClient ( u8  conn_id,
BtdrvAddress  addr 
)

DisconnectGattClient.

Note
Only available on [5.0.0+].
Parameters
[in]conn_idConnection ID
[in]addrBtdrvAddress, only used on pre-9.0.0.

◆ btdrvDisconnectGattServer()

Result btdrvDisconnectGattServer ( u32  conn_id)

DisconnectGattServer.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]conn_idConnection ID

◆ btdrvEmulateBluetoothCrash()

Result btdrvEmulateBluetoothCrash ( BtdrvFatalReason  reason)

EmulateBluetoothCrash.

Note
Only available on [7.0.0+].
Parameters
[in]reasonBtdrvFatalReason

◆ btdrvEnableAfhSetting()

Result btdrvEnableAfhSetting ( bool  flag)

EnableAfhSetting.

Note
Only available on [3.0.0+].
Parameters
[in]flagInput flag.

◆ btdrvEnableBle()

Result btdrvEnableBle ( void  )

EnableBle.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.

◆ btdrvEnableBleScanFilter()

Result btdrvEnableBleScanFilter ( bool  flag)

EnableBleScanFilter.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]flagFlag

◆ btdrvEnableBluetooth()

Result btdrvEnableBluetooth ( void  )

EnableBluetooth.

Note
This is used by btm-sysmodule.

◆ btdrvEnableBurstMode()

Result btdrvEnableBurstMode ( BtdrvAddress  addr,
bool  flag 
)

EnableBurstMode.

Note
The response will be available via btdrvGetHidEventInfo ([12.0.0+] btdrvGetEventInfo).
This is used by btm-sysmodule.
Parameters
[in]addrBtdrvAddress
[in]flagFlag: true = Set, false = Exit.

◆ btdrvEnableGattService()

Result btdrvEnableGattService ( u8  service_id,
const BtdrvGattAttributeUuid uuid 
)

EnableGattService.

Note
Only available on [5.0.0+].
Parameters
[in]service_idService ID
[in]uuidBtdrvGattAttributeUuid

◆ btdrvEnableLlrScan()

Result btdrvEnableLlrScan ( void  )

EnableLlrScan.

Note
This is used by btm-sysmodule.

◆ btdrvEnableMcMode()

Result btdrvEnableMcMode ( bool  flag)

EnableMcMode.

Note
This is used by btm-sysmodule.
Parameters
[in]flagFlag

◆ btdrvEnableRadio()

Result btdrvEnableRadio ( bool  flag)

EnableRadio.

Note
This is used by btm-sysmodule.
Parameters
[in]flagFlag

◆ btdrvEnableTbfcScan()

Result btdrvEnableTbfcScan ( bool  flag)

EnableTbfcScan.

Note
Only available on [4.0.0+].
This is used by btm-sysmodule.
Parameters
[in]flagFlag

◆ btdrvEnableTxPowerBoostSetting()

Result btdrvEnableTxPowerBoostSetting ( bool  flag)

EnableTxPowerBoostSetting.

Note
Only available on [3.0.0+].
Parameters
[in]flagInput flag.

◆ btdrvFinalizeBle()

Result btdrvFinalizeBle ( void  )

FinalizeBle.

Note
Only available on [5.0.0+].

◆ btdrvFinalizeBluetooth()

Result btdrvFinalizeBluetooth ( void  )

FinalizeBluetooth.

Note
This is not used by btm-sysmodule, this should not be used by other processes.

◆ btdrvFinalizeHid()

Result btdrvFinalizeHid ( void  )

FinalizeHid.

Note
This is not used by btm-sysmodule, this should not be used by other processes.

◆ btdrvGetAdapterProperties()

Result btdrvGetAdapterProperties ( BtdrvAdapterPropertySet properties)

GetAdapterProperties [12.0.0+].

Parameters
[out]propertiesBtdrvAdapterPropertySet

◆ btdrvGetAdapterProperty()

Result btdrvGetAdapterProperty ( BtdrvAdapterPropertyType  type,
BtdrvAdapterProperty property 
)

GetAdapterProperty [12.0.0+].

Parameters
[in]typeBtdrvAdapterPropertyType
[in]propertyBtdrvAdapterProperty

◆ btdrvGetAudioControlInputState()

Result btdrvGetAudioControlInputState ( BtdrvAudioControlButtonState states,
s32  count,
s32 total_out 
)

GetAudioControlInputState.

Note
Only available on [12.0.0+].
Parameters
[out]statesOutput array of BtdrvAudioControlButtonState.
[in]countSize of the states array in entries, the maximum is 0xF.
[out]total_outTotal output entries.

◆ btdrvGetAudioEventInfo()

Result btdrvGetAudioEventInfo ( void *  buffer,
size_t  size,
BtdrvAudioEventType type 
)

GetAudioEventInfo.

Note
Only available on [12.0.0+].
Parameters
[out]bufferOutput buffer, see BtdrvAudioEventInfo.
[in]sizeOutput buffer size.
[out]typeBtdrvAudioEventType.

◆ btdrvGetAudioOutFeedingCodec()

Result btdrvGetAudioOutFeedingCodec ( u32  audio_handle,
BtdrvAudioCodec out 
)

GetAudioOutFeedingCodec.

Note
Only available on [12.0.0+].
Parameters
[in]audio_handleAudio handle from btdrvOpenAudioOut.
[out]outBtdrvAudioCodec

◆ btdrvGetAudioOutFeedingParameter()

Result btdrvGetAudioOutFeedingParameter ( u32  audio_handle,
BtdrvPcmParameter out 
)

GetAudioOutFeedingParameter.

Note
Only available on [12.0.0+].
Parameters
[in]audio_handleAudio handle from btdrvOpenAudioOut.
[out]outBtdrvPcmParameter

◆ btdrvGetAudioOutState()

Result btdrvGetAudioOutState ( u32  audio_handle,
BtdrvAudioOutState out 
)

GetAudioOutState.

Note
Only available on [12.0.0+].
Parameters
[in]audio_handleAudio handle from btdrvOpenAudioOut.
[out]outBtdrvAudioOutState

◆ btdrvGetBleChannelMap()

Result btdrvGetBleChannelMap ( BtdrvChannelMapList out)

GetBleChannelMap.

Note
Only available on [9.0.0+].
Parameters
[out]outBtdrvChannelMapList

◆ btdrvGetBleManagedEventInfo()

Result btdrvGetBleManagedEventInfo ( void *  buffer,
size_t  size,
BtdrvBleEventType type 
)

GetBleManagedEventInfo.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[out]bufferOutput buffer. 0x400-bytes from state is written here. See BtdrvBleEventInfo.
[in]sizeOutput buffer size.
[out]typeOutput BtdrvBleEventType.

◆ btdrvGetChannelMap()

Result btdrvGetChannelMap ( BtdrvChannelMapList out)

GetChannelMap.

Note
Only available on [3.0.0+].
Parameters
[out]outBtdrvChannelMapList

◆ btdrvGetConnectedAudioDevice()

Result btdrvGetConnectedAudioDevice ( BtdrvAddress addrs,
s32  count,
s32 total_out 
)

GetConnectedAudioDevice.

Note
Only available on [12.0.0-13.2.1].
Parameters
[out]addrsOutput array of BtdrvAddress.
[in]countSize of the addrs array in entries, the maximum is 0x8.
[out]total_outTotal output entries.

◆ btdrvGetEventInfo()

Result btdrvGetEventInfo ( void *  buffer,
size_t  size,
BtdrvEventType type 
)

GetEventInfo.

Note
This is used by btm-sysmodule.
Parameters
[out]bufferOutput buffer, see BtdrvEventInfo.
[in]sizeOutput buffer size.
[out]typeOutput BtdrvEventType.

◆ btdrvGetGattAttribute()

Result btdrvGetGattAttribute ( BtdrvAddress  addr,
u32  conn_id 
)

GetGattAttribute.

Note
Only available on [5.0.0+].
Parameters
[in]addrBtdrvAddress, only used on pre-9.0.0.
[in]conn_idConnection ID

◆ btdrvGetGattFirstCharacteristic()

Result btdrvGetGattFirstCharacteristic ( u32  conn_id,
const BtdrvGattId serv_id,
bool  is_primary,
const BtdrvGattAttributeUuid filter_uuid,
u8 out_property,
BtdrvGattId out_char_id 
)

GetGattFirstCharacteristic.

Note
Only available on [5.0.0+].
Parameters
[in]conn_idConnection ID
[in]serv_idService GATT ID BtdrvGattId
[in]is_primaryIs a primary service or not
[in]filter_uuidCharacteristic filter UUID BtdrvGattAttributeUuid
[out]out_propertyOutput property BtdrvGattCharacteristicProperty
[out]out_char_idOutput characteristic GATT ID BtdrvGattId

◆ btdrvGetGattFirstDescriptor()

Result btdrvGetGattFirstDescriptor ( u32  conn_id,
const BtdrvGattId serv_id,
bool  is_primary,
const BtdrvGattId char_id,
const BtdrvGattAttributeUuid filter_uuid,
BtdrvGattId out_desc_id 
)

GetGattFirstDescriptor.

Note
Only available on [5.0.0+].
Parameters
[in]conn_idConnection ID
[in]serv_idService GATT ID BtdrvGattId
[in]is_primaryIs a primary service or not
[in]char_idCharacteristic GATT ID BtdrvGattId
[in]filter_uuidDescriptor filter UUID BtdrvGattAttributeUuid
[out]out_desc_idOutput descriptor GATT ID BtdrvGattId

◆ btdrvGetGattNextCharacteristic()

Result btdrvGetGattNextCharacteristic ( u32  conn_id,
const BtdrvGattId serv_id,
bool  is_primary,
const BtdrvGattId char_id,
const BtdrvGattAttributeUuid filter_uuid,
u8 out_property,
BtdrvGattId out_char_id 
)

GetGattNextCharacteristic.

Note
Only available on [5.0.0+].
Parameters
[in]conn_idConnection ID
[in]serv_idService ID BtdrvGattId
[in]is_primaryIs a primary service or not
[in]char_idPrevious characteristic GATT ID BtdrvGattId
[in]filter_uuidCharacteristic filter UUID BtdrvGattAttributeUuid
[out]out_propertyOutput property BtdrvGattCharacteristicProperty
[out]out_char_idOutput characteristic GATT ID BtdrvGattId

◆ btdrvGetGattNextDescriptor()

Result btdrvGetGattNextDescriptor ( u32  conn_id,
const BtdrvGattId serv_id,
bool  is_primary,
const BtdrvGattId char_id,
const BtdrvGattId desc_id,
const BtdrvGattAttributeUuid filter_uuid,
BtdrvGattId out_desc_id 
)

GetGattNextDescriptor.

Note
Only available on [5.0.0+].
Parameters
[in]conn_idConnection ID
[in]serv_idService GATT ID BtdrvGattId
[in]is_primaryIs a primary service or not
[in]char_idCharacteristic GATT ID BtdrvGattId
[in]desc_idPrevious descriptor GATT ID BtdrvGattId
[in]filter_uuidDescriptor filter UUID BtdrvGattAttributeUuid
[out]out_desc_idOutput descriptor GATT ID BtdrvGattId

◆ btdrvGetGattService()

Result btdrvGetGattService ( u32  conn_id,
const BtdrvGattAttributeUuid uuid 
)

GetGattService.

Note
Only available on [5.0.0+].
Parameters
[in]conn_idConnection ID
[in]uuidBtdrvGattAttributeUuid

◆ btdrvGetHidEventInfo()

Result btdrvGetHidEventInfo ( void *  buffer,
size_t  size,
BtdrvHidEventType type 
)

GetHidEventInfo.

Note
This is used by btm-sysmodule.
Parameters
[out]bufferOutput buffer, see BtdrvHidEventInfo.
[in]sizeOutput buffer size.
[out]typeBtdrvHidEventType, always BtdrvHidEventType_Connection or ::BtdrvHidEventType_Ext.

◆ btdrvGetHidReport()

Result btdrvGetHidReport ( BtdrvAddress  addr,
u8  report_id,
BtdrvBluetoothHhReportType  type 
)

This sends a HID GET_REPORT transaction packet.

Parameters
[in]addrBtdrvAddress
[in]report_idThis is sent in the packet for the Report Id, when non-zero.
[in]typeBtdrvBluetoothHhReportType

◆ btdrvGetHidReportEventInfo()

Result btdrvGetHidReportEventInfo ( void *  buffer,
size_t  size,
BtdrvHidEventType type 
)

GetHidReportEventInfo.

Note
btdrvRegisterHidReportEvent must be used before this, on [7.0.0+].
This is used by hid-sysmodule. When used by other processes, hid/user-process will conflict. No events will be received by that user-process, or it will be corrupted, etc.
[7.0.0+] When data isn't available, the type is set to BtdrvHidEventType_Data, with the buffer cleared to all-zero.
Parameters
[out]bufferOutput buffer, see BtdrvHidReportEventInfo.
[in]sizeOutput buffer size.
[out]typeBtdrvHidEventType

◆ btdrvGetLatestPlr()

Result btdrvGetLatestPlr ( BtdrvPlrList out)

GetLatestPlr.

Parameters
[out]outOutput BtdrvPlrList, on pre-9.0.0 this is BtdrvPlrStatistics.

◆ btdrvGetLeHidEventInfo()

Result btdrvGetLeHidEventInfo ( void *  buffer,
size_t  size,
BtdrvBleEventType type 
)

GetLeHidEventInfo.

Note
Only available on [5.0.0+].
The state used by this is reset after writing the data to output.
Parameters
[out]bufferOutput buffer. 0x400-bytes from state is written here. See BtdrvBleEventInfo.
[in]sizeOutput buffer size.
[out]typeBtdrvBleEventType.

◆ btdrvGetPairedDeviceInfo()

Result btdrvGetPairedDeviceInfo ( BtdrvAddress  addr,
SetSysBluetoothDevicesSettings settings 
)

GetPairedDeviceInfo.

Note
This is used by btm-sysmodule.
Parameters
[in]addrBtdrvAddress
[out]settingsSetSysBluetoothDevicesSettings

◆ btdrvGetPendingConnections()

Result btdrvGetPendingConnections ( void  )

GetPendingConnections.

Note
The output data will be available via btdrvGetHidEventInfo ([12.0.0+] btdrvGetEventInfo).
This is used by btm-sysmodule.
Only available on [3.0.0+].

◆ btdrvInitializeBle()

Result btdrvInitializeBle ( Event out_event)

InitializeBle.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
The Event must be closed by the user once finished with it.
Parameters
[out]out_eventOutput Event with autoclear=true.

◆ btdrvInitializeBluetooth()

Result btdrvInitializeBluetooth ( Event out_event)

InitializeBluetooth.

Note
This is used by btm-sysmodule, this should not be used by other processes.
The Event must be closed by the user once finished with it.
Parameters
[out]out_eventOutput Event with autoclear=true.

◆ btdrvInitializeHid()

Result btdrvInitializeHid ( Event out_event)

InitializeHid.

Note
This is used by btm-sysmodule, this should not be used by other processes.
The Event must be closed by the user once finished with it.
Parameters
[out]out_eventOutput Event with autoclear=true.

◆ btdrvIsAfhSettingEnabled()

Result btdrvIsAfhSettingEnabled ( bool *  out)

IsAfhSettingEnabled.

Note
Only available on [3.0.0+].
Parameters
[out]outOutput flag.

◆ btdrvIsBluetoothEnabled()

Result btdrvIsBluetoothEnabled ( bool *  out)

IsBluetoothEnabled.

Note
Only available on [12.0.0+].
Parameters
[out]outOutput flag.

◆ btdrvIsManufacturingMode()

Result btdrvIsManufacturingMode ( bool *  out)

IsManufacturingMode.

Note
Only available on [5.0.0+].
Parameters
[out]outOutput flag.

◆ btdrvIsTxPowerBoostSettingEnabled()

Result btdrvIsTxPowerBoostSettingEnabled ( bool *  out)

IsTxPowerBoostSettingEnabled.

Note
Only available on [3.0.0+].
Parameters
[out]outOutput flag.

◆ btdrvLegacyGetAdapterProperties()

Result btdrvLegacyGetAdapterProperties ( BtdrvAdapterPropertyOld properties)

GetAdapterProperties [1.0.0-11.0.1].

Parameters
[out]propertiesBtdrvAdapterPropertyOld

◆ btdrvLegacyGetAdapterProperty()

Result btdrvLegacyGetAdapterProperty ( BtdrvBluetoothPropertyType  type,
void *  buffer,
size_t  size 
)

GetAdapterProperty [1.0.0-11.0.1].

Parameters
[in]typeBtdrvBluetoothPropertyType
[out]bufferOutput buffer, see BtdrvBluetoothPropertyType for the contents.
[in]sizeOutput buffer size.

◆ btdrvLegacyRespondToPinRequest()

Result btdrvLegacyRespondToPinRequest ( BtdrvAddress  addr,
bool  flag,
const BtdrvBluetoothPinCode pin_code,
u8  length 
)

RespondToPinRequest [1.0.0-11.0.1].

Note
The official sysmodule only uses the input BtdrvAddress.
Parameters
[in]addrBtdrvAddress
[in]flagFlag
[in]pin_codeBtdrvBluetoothPinCode
[in]lengthLength of pin_code

◆ btdrvLegacySetAdapterProperty()

Result btdrvLegacySetAdapterProperty ( BtdrvBluetoothPropertyType  type,
const void *  buffer,
size_t  size 
)

SetAdapterProperty [1.0.0-11.0.1].

Parameters
[in]typeBtdrvBluetoothPropertyType
[in]bufferInput buffer, see BtdrvBluetoothPropertyType for the contents.
[in]sizeInput buffer size.

◆ btdrvLegacyStartInquiry()

Result btdrvLegacyStartInquiry ( void  )

StartInquiry [1.0.0-11.0.1].

This starts Inquiry, the output data will be available via btdrvGetEventInfo. Inquiry will automatically stop in 10.24 seconds.

Note
This is used by btm-sysmodule.

◆ btdrvMoveToSecondaryPiconet()

Result btdrvMoveToSecondaryPiconet ( BtdrvAddress  addr)

MoveToSecondaryPiconet.

Note
The response will be available via btdrvGetHidEventInfo ([12.0.0+] btdrvGetEventInfo).
Only available on [10.0.0+].
Parameters
[in]addrBtdrvAddress

◆ btdrvOpenAudioConnection()

Result btdrvOpenAudioConnection ( BtdrvAddress  addr)

OpenAudioConnection.

Note
Only available on [12.0.0+].
Parameters
[in]addrBtdrvAddress

◆ btdrvOpenAudioOut()

Result btdrvOpenAudioOut ( BtdrvAddress  addr,
u32 audio_handle 
)

OpenAudioOut.

Note
Only available on [12.0.0+].
Parameters
[in]addrBtdrvAddress
[out]audio_handleAudio handle.

◆ btdrvOpenHidConnection()

Result btdrvOpenHidConnection ( BtdrvAddress  addr)

OpenHidConnection.

Note
This is used by btm-sysmodule.
Parameters
[in]addrBtdrvAddress

◆ btdrvReadGattCharacteristic()

Result btdrvReadGattCharacteristic ( u32  connection_handle,
bool  is_primary,
const BtdrvGattId serv_id,
const BtdrvGattId char_id,
u8  auth_req 
)

ReadGattCharacteristic.

Note
Only available on [5.0.0+].
Parameters
[in]connection_handleConnectionHandle
[in]is_primaryIs a primary service or not
[in]serv_idService GATT ID BtdrvGattId
[in]char_idCharacteristic GATT ID BtdrvGattId
[in]auth_reqBtdrvGattAuthReqType

◆ btdrvReadGattDescriptor()

Result btdrvReadGattDescriptor ( u32  connection_handle,
bool  is_primary,
const BtdrvGattId serv_id,
const BtdrvGattId char_id,
const BtdrvGattId desc_id,
u8  auth_req 
)

ReadGattDescriptor.

Note
Only available on [5.0.0+].
Parameters
[in]connection_handleConnectionHandle
[in]is_primaryIs a primary service or not
[in]serv_idService GATT ID BtdrvGattId
[in]char_idCharacteristic GATT ID BtdrvGattId
[in]desc_idDescriptor GATT ID BtdrvGattId
[in]auth_reqBtdrvGattAuthReqType

◆ btdrvRegisterAudioControlNotification()

Result btdrvRegisterAudioControlNotification ( BtdrvAddress  addr,
u32  event_type 
)

RegisterAudioControlNotification.

Note
Only available on [13.0.0+].
Parameters
[in]addrBtdrvAddress
[in]event_typeAvrcEventType

◆ btdrvRegisterBleHidEvent()

Result btdrvRegisterBleHidEvent ( Event out_event)

RegisterBleHidEvent.

Note
Only available on [5.0.0+].
The Event must be closed by the user once finished with it.
Parameters
[out]out_eventOutput Event with autoclear=true.

◆ btdrvRegisterGattClient()

Result btdrvRegisterGattClient ( const BtdrvGattAttributeUuid uuid)

RegisterGattClient.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]uuidBtdrvGattAttributeUuid

◆ btdrvRegisterGattDataPath()

Result btdrvRegisterGattDataPath ( const BtdrvGattAttributeUuid uuid)

RegisterGattDataPath.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]uuidBtdrvGattAttributeUuid

◆ btdrvRegisterGattHidDataPath()

Result btdrvRegisterGattHidDataPath ( const BtdrvGattAttributeUuid uuid)

RegisterGattHidDataPath.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]uuidBtdrvGattAttributeUuid

◆ btdrvRegisterGattManagedDataPath()

Result btdrvRegisterGattManagedDataPath ( const BtdrvGattAttributeUuid uuid)

RegisterGattManagedDataPath.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]uuidBtdrvGattAttributeUuid

◆ btdrvRegisterGattNotification()

Result btdrvRegisterGattNotification ( u32  connection_handle,
bool  is_primary,
const BtdrvGattId serv_id,
const BtdrvGattId char_id 
)

RegisterGattNotification.

Note
Only available on [5.0.0+].
Parameters
[in]connection_handleConnectionHandle
[in]is_primaryIs a primary service or not
[in]serv_idService GATT ID BtdrvGattId
[in]char_idCharacteristic GATT ID BtdrvGattId

◆ btdrvRegisterGattServer()

Result btdrvRegisterGattServer ( const BtdrvGattAttributeUuid uuid)

RegisterGattServer.

Note
Only available on [5.0.0+].
Parameters
[in]uuidBtdrvGattAttributeUuid

◆ btdrvRegisterHidReportEvent()

Result btdrvRegisterHidReportEvent ( Event out_event)

RegisterHidReportEvent.

Note
This also does sharedmem init/handling if needed, on [7.0.0+].
The Event must be closed by the user once finished with it.
Parameters
[out]out_eventOutput Event with autoclear=true. This is signaled when data is available with btdrvGetHidReportEventInfo.

◆ btdrvRemoveBond()

Result btdrvRemoveBond ( BtdrvAddress  addr)

RemoveBond.

Note
This is used by btm-sysmodule.
Parameters
[in]addrBtdrvAddress

◆ btdrvRespondToPinRequest()

Result btdrvRespondToPinRequest ( BtdrvAddress  addr,
const BtdrvPinCode pin_code 
)

RespondToPinRequest [12.0.0+].

Parameters
[in]addrBtdrvAddress
[in]pin_codeBtdrvPinCode

◆ btdrvRespondToSspRequest()

Result btdrvRespondToSspRequest ( BtdrvAddress  addr,
u32  variant,
bool  accept,
u32  passkey 
)

RespondToSspRequest.

Note
The official sysmodule only uses the input BtdrvAddress and the flag.
This is used by btm-sysmodule.
Parameters
[in]addrBtdrvAddress
[in]variantBluetoothSspVariant
[in]acceptWhether the request is accepted.
[in]passkeyPasskey.

◆ btdrvSendAudioControlPassthroughCommand()

Result btdrvSendAudioControlPassthroughCommand ( BtdrvAddress  addr,
u32  op_id,
u32  state_type 
)

SendAudioControlPassthroughCommand.

Note
Only available on [13.0.0+].
Parameters
[in]addrBtdrvAddress
[in]op_idAvrcOperationId
[in]state_typeAvrcStateType

◆ btdrvSendAudioControlSetAbsoluteVolumeCommand()

Result btdrvSendAudioControlSetAbsoluteVolumeCommand ( BtdrvAddress  addr,
s32  val 
)

SendAudioControlSetAbsoluteVolumeCommand.

Note
Only available on [13.0.0+].
Parameters
[in]addrBtdrvAddress
[in]valInput value

◆ btdrvSendAudioData()

Result btdrvSendAudioData ( u32  audio_handle,
const void *  buffer,
size_t  size,
u64 transferred_size 
)

SendAudioData.

Note
Only available on [12.0.0+].
Parameters
[in]audio_handleAudio handle from btdrvOpenAudioOut.
[in]bufferInput buffer.
[in]sizeInput buffer size.
[out]Outputtransferred size. This is always either 0 (error occured) or the buffer size.

◆ btdrvSetAdapterProperty()

Result btdrvSetAdapterProperty ( BtdrvAdapterPropertyType  type,
const BtdrvAdapterProperty property 
)

SetAdapterProperty [12.0.0+].

Parameters
[in]typeBtdrvAdapterPropertyType
[in]propertyBtdrvAdapterProperty

◆ btdrvSetBleAdvertiseData()

Result btdrvSetBleAdvertiseData ( const BtdrvBleAdvertisePacketData data)

SetBleAdvertiseData.

Note
Only available on [5.0.0+].
Parameters
[in]dataBtdrvBleAdvertisePacketData

◆ btdrvSetBleAdvertiseParameter()

Result btdrvSetBleAdvertiseParameter ( BtdrvAddress  addr,
u16  min_interval,
u16  max_interval 
)

SetBleAdvertiseParameter.

Note
Only available on [5.0.0+].
Parameters
[in]addrBtdrvAddress
[in]min_intervalMinimum advertisement interval
[in]max_intervalMaximum advertisement interval

◆ btdrvSetBleConnectionParameter()

Result btdrvSetBleConnectionParameter ( BtdrvAddress  addr,
const BtdrvBleConnectionParameter param,
bool  preference 
)

SetBleConnectionParameter.

Note
Only available on [9.0.0+]. This is the newer version of btdrvSetLeConnectionParameter.
Parameters
[in]addrBtdrvAddress
[in]paramBtdrvBleConnectionParameter
[in]preferenceUnused

◆ btdrvSetBleDefaultConnectionParameter()

Result btdrvSetBleDefaultConnectionParameter ( const BtdrvBleConnectionParameter param)

SetBleDefaultConnectionParameter.

Note
Only available on [9.0.0+]. This is the newer version of btdrvSetLeDefaultConnectionParameter.
Parameters
[in]paramBtdrvBleConnectionParameter

◆ btdrvSetBleScanParameter()

Result btdrvSetBleScanParameter ( u16  scan_interval,
u16  scan_window 
)

SetBleScanParameter.

Note
Only available on [5.1.0+].
This is used by btm-sysmodule.
Parameters
[in]scan_intervalScan interval
[in]scan_windowScan window

◆ btdrvSetBleVisibility()

Result btdrvSetBleVisibility ( bool  discoverable,
bool  connectable 
)

SetBleVisibility.

Note
Only available on [5.0.0+].
Parameters
[in]discoverableWhether the BLE device is discoverable.
[in]connectableWhether the BLE device is connectable.

◆ btdrvSetHidReport()

Result btdrvSetHidReport ( BtdrvAddress  addr,
BtdrvBluetoothHhReportType  type,
const BtdrvHidReport buffer 
)

This sends a HID SET_REPORT transaction packet.

Parameters
[in]addrBtdrvAddress
[in]typeBtdrvBluetoothHhReportType
[in]bufferInput BtdrvHidReport, on pre-9.0.0 this is BtdrvHidData.

◆ btdrvSetLeConnectionParameter()

Result btdrvSetLeConnectionParameter ( const BtdrvLeConnectionParams param)

SetLeConnectionParameter.

Note
Only available on [5.0.0-8.1.1]. This is the older version of btdrvSetBleConnectionParameter.
Parameters
[in]paramBtdrvLeConnectionParams

◆ btdrvSetLeDefaultConnectionParameter()

Result btdrvSetLeDefaultConnectionParameter ( const BtdrvLeConnectionParams param)

SetLeDefaultConnectionParameter.

Note
Only available on [5.0.0-8.1.1]. This is the older version of btdrvSetBleDefaultConnectionParameter.
Parameters
[in]paramBtdrvLeConnectionParams

◆ btdrvSetTsi()

Result btdrvSetTsi ( BtdrvAddress  addr,
u8  tsi 
)

SetTsi.

Note
The response will be available via btdrvGetHidEventInfo ([12.0.0+] btdrvGetEventInfo).
This is used by btm-sysmodule.
Parameters
[in]addrBtdrvAddress
[in]tsiTsi: non-value-0xFF to Set, value 0xFF to Exit. See also BtmTsiMode.

◆ btdrvSetVisibility()

Result btdrvSetVisibility ( bool  inquiry_scan,
bool  page_scan 
)

SetVisibility.

Note
This is used by btm-sysmodule.
Parameters
[in]inquiry_scanControls Inquiry Scan, whether the device can be discovered during Inquiry.
[in]page_scanControls Page Scan, whether the device accepts connections.

◆ btdrvSetZeroRetransmission()

Result btdrvSetZeroRetransmission ( BtdrvAddress  addr,
u8 report_ids,
u8  count 
)

SetZeroRetransmission.

Note
The response will be available via btdrvGetHidEventInfo ([12.0.0+] btdrvGetEventInfo).
This is used by btm-sysmodule.
Parameters
[in]addrBtdrvAddress
[in]report_idsInput buffer containing an array of u8s.
[in]countTotal u8s in the input buffer. This can be 0, the max is 5.

◆ btdrvStartAudioOut()

Result btdrvStartAudioOut ( u32  audio_handle,
const BtdrvPcmParameter pcm_param,
s64  in_latency,
s64 out_latency,
u64 out1 
)

StartAudioOut.

Note
Only available on [12.0.0+].
Parameters
[in]audio_handleAudio handle from btdrvOpenAudioOut.
[in]pcm_paramBtdrvPcmParameter
[in]in_latencyInput latency in nanoseconds.
[out]out_latencyOutput latency in nanoseconds.
[out]out1Unknown output.

◆ btdrvStartBleScan()

Result btdrvStartBleScan ( void  )

StartBleScan.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.

◆ btdrvStartInquiry()

Result btdrvStartInquiry ( u32  services,
s64  duration 
)

StartInquiry [12.0.0+].

This starts Inquiry, the output data will be available via btdrvGetEventInfo.

Parameters
[in]servicesBitfield of allowed services. When -1 the original defaults from pre-12.0.0 are used.
[in]durationInquiry duration in nanoseconds.
Note
This is used by btm-sysmodule.

◆ btdrvStopAudioOut()

Result btdrvStopAudioOut ( u32  audio_handle)

StopAudioOut.

Note
Only available on [12.0.0+].
Parameters
[in]audio_handleAudio handle from btdrvOpenAudioOut.

◆ btdrvStopBleScan()

Result btdrvStopBleScan ( void  )

StopBleScan.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.

◆ btdrvStopInquiry()

Result btdrvStopInquiry ( void  )

This stops Inquiry which was started by btdrvStartInquiry, if it's still active.

Note
This is used by btm-sysmodule.

◆ btdrvTriggerConnection()

Result btdrvTriggerConnection ( BtdrvAddress  addr,
u16  unk 
)

TriggerConnection.

Note
This is used by btm-sysmodule.
Parameters
[in]addrBtdrvAddress
[in]unk[9.0.0+] Unknown

◆ btdrvUnregisterAllGattClients()

Result btdrvUnregisterAllGattClients ( void  )

UnregisterAllGattClients.

Note
Only available on [5.0.0+].

◆ btdrvUnregisterGattClient()

Result btdrvUnregisterGattClient ( u8  client_if)

UnregisterGattClient.

Note
Only available on [5.0.0+].
Parameters
[in]client_ifClient interface ID

◆ btdrvUnregisterGattDataPath()

Result btdrvUnregisterGattDataPath ( const BtdrvGattAttributeUuid uuid)

UnregisterGattDataPath.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]uuidBtdrvGattAttributeUuid

◆ btdrvUnregisterGattHidDataPath()

Result btdrvUnregisterGattHidDataPath ( const BtdrvGattAttributeUuid uuid)

UnregisterGattHidDataPath.

Note
Only available on [5.0.0+].
This is used by btm-sysmodule.
Parameters
[in]uuidBtdrvGattAttributeUuid

◆ btdrvUnregisterGattManagedDataPath()

Result btdrvUnregisterGattManagedDataPath ( const BtdrvGattAttributeUuid uuid)

UnregisterGattManagedDataPath.

Note
Only available on [5.0.0+].
Parameters
[in]uuidBtdrvGattAttributeUuid

◆ btdrvUnregisterGattNotification()

Result btdrvUnregisterGattNotification ( u32  connection_handle,
bool  is_primary,
const BtdrvGattId serv_id,
const BtdrvGattId char_id 
)

UnregisterGattNotification.

Note
Only available on [5.0.0+].
Parameters
[in]connection_handleConnectionHandle
[in]is_primaryIs a primary service or not
[in]serv_idService GATT ID BtdrvGattId
[in]char_idCharacteristic GATT ID BtdrvGattId

◆ btdrvUnregisterGattServer()

Result btdrvUnregisterGattServer ( u8  server_if)

UnregisterGattServer.

Note
Only available on [5.0.0+].
Parameters
[in]server_ifServer interface ID

◆ btdrvWriteGattCharacteristic()

Result btdrvWriteGattCharacteristic ( u32  connection_handle,
bool  is_primary,
const BtdrvGattId serv_id,
const BtdrvGattId char_id,
const void *  buffer,
size_t  size,
u8  auth_req,
bool  with_response 
)

WriteGattCharacteristic.

Note
Only available on [5.0.0+].
Parameters
[in]connection_handleConnectionHandle
[in]is_primaryIs a primary service or not
[in]serv_idService GATT ID BtdrvGattId
[in]char_idCharacteristic GATT ID BtdrvGattId
[in]bufferInput buffer.
[in]sizeInput buffer size, must be <=0x258.
[in]auth_reqBtdrvGattAuthReqType
[in]with_responseWhether to use Write-With-Response write type or not

◆ btdrvWriteGattDescriptor()

Result btdrvWriteGattDescriptor ( u32  connection_handle,
bool  is_primary,
const BtdrvGattId serv_id,
const BtdrvGattId char_id,
const BtdrvGattId desc_id,
const void *  buffer,
size_t  size,
u8  auth_req 
)

WriteGattDescriptor.

Note
Only available on [5.0.0+].
Parameters
[in]connection_handleConnectionHandle
[in]is_primaryIs a primary service or not
[in]serv_idService GATT ID BtdrvGattId
[in]char_idCharacteristic GATT ID BtdrvGattId
[in]desc_idDescriptor GATT ID BtdrvGattId
[in]bufferInput buffer.
[in]sizeInput buffer size, must be <=0x258.
[in]auth_reqBtdrvGattAuthReqType

◆ btdrvWriteHidData()

Result btdrvWriteHidData ( BtdrvAddress  addr,
const BtdrvHidReport buffer 
)

This sends a HID DATA transaction packet with report-type Output.

Parameters
[in]addrBtdrvAddress
[in]bufferInput BtdrvHidReport, on pre-9.0.0 this is BtdrvHidData.

◆ btdrvWriteHidData2()

Result btdrvWriteHidData2 ( BtdrvAddress  addr,
const void *  buffer,
size_t  size 
)

WriteHidData2.

Parameters
[in]addrBtdrvAddress
[in]bufferInput buffer, same as the buffer for btdrvWriteHidData.
[in]sizeInput buffer size.