Changes

Jump to navigation Jump to search
no edit summary
Line 314: Line 314:     
This is used by [[BTM_services|btm]].
 
This is used by [[BTM_services|btm]].
 +
 +
See [[#EventInfo]].
    
== InitializeHid ==
 
== InitializeHid ==
Line 878: Line 880:  
= EventType =
 
= EventType =
 
This is u32 enum "nn::bluetooth::EventType".
 
This is u32 enum "nn::bluetooth::EventType".
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
!  Value
 +
!  Name
 +
!  Description
 +
|-
 +
| 0 || || The funcptr which writes the data into state for this event is not called (only checked on [10.0.0]).
 +
|-
 +
| 3 || || New device discovered.
 +
|-
 +
| 4 || || Discovery status changed.
 +
|-
 +
| 5 || || Triggered by BSA_SEC_PIN_REQ_EVT: PIN code request for pairing.
 +
|-
 +
| 6 || ||
 +
|-
 +
| 7 || ||
 +
|-
 +
| 13 || ||
 +
|}
    
= BluetoothHhReportType =
 
= BluetoothHhReportType =
Line 958: Line 981:  
= Address =
 
= Address =
 
This is "nn::bluetooth::Address". This is a 0x6-byte struct with 1-byte alignment.
 
This is "nn::bluetooth::Address". This is a 0x6-byte struct with 1-byte alignment.
 +
 +
= EventInfo =
 +
This is the output buffer for [[#GetEventInfo]]. The data stored here depends on the [[#EventType]].
 +
 +
[[#EventType|Type0]]:
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x4 ||
 +
|}
 +
 +
[[#EventType|Type3]]:
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0xF9 || Device name, NUL-terminated string.
 +
|-
 +
| 0xF9 || 0x6 || Device [[#Address|address]].
 +
|-
 +
| 0xFF || 0x10 ||
 +
|-
 +
| 0x10F || 0x3 || Device class.
 +
|-
 +
| 0x112 || 0x4 || Set to fixed value u32 0x1.
 +
|-
 +
| 0x116 || 0xFA ||
 +
|-
 +
| 0x210 || 0x5C || Reserved
 +
|-
 +
| 0x26C || 0xF9 || Device name, NUL-terminated string. Same as name above, except starting at index 1.
 +
|-
 +
| 0x365 || 0x4 || s32 RSSI
 +
|-
 +
| 0x369 || 0x4 || Two bytes which are the same as name[11-12].
 +
|-
 +
| 0x36D || 0x10 || Reserved
 +
|}
 +
 +
[[#EventType|Type4]]:
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x4 || Status: 0 = stopped, 1 = started.
 +
|}
 +
 +
[[#EventType|Type5]]:
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x6 || Device [[#Address|address]].
 +
|-
 +
| 0x6 || 0xF9 || Device name, NUL-terminated string.
 +
|-
 +
| 0xFF || 0x3 || Device class.
 +
|}
 +
 +
[[#EventType|Type6]]:
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x6 || Device [[#Address|address]].
 +
|-
 +
| 0x6 || 0xF9 || Device name, NUL-terminated string.
 +
|-
 +
| 0xFF || 0x3 || Device class.
 +
|-
 +
| 0x103 || 0x1 || Padding
 +
|-
 +
| 0x104 || 0x4 ||
 +
|-
 +
| 0x108 || 0x4 || s32 Passkey
 +
|}
 +
 +
[[#EventType|Type7]]:
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x4 ||
 +
|-
 +
| 0x4 || 0x6 || Device [[#Address|address]].
 +
|-
 +
| 0xA || 0x2 || Padding
 +
|-
 +
| 0xC || 0x4 ||
 +
|}
 +
 +
[[#EventType|Type13]]:
 +
 +
{| class="wikitable" border="1"
 +
|-
 +
! Offset
 +
! Size
 +
! Description
 +
|-
 +
| 0x0 || 0x2 ||
 +
|}
    
= BluetoothPinCode =
 
= BluetoothPinCode =

Navigation menu