mirror of
https://github.com/felis/USB_Host_Shield_2.0.git
synced 2024-03-22 11:31:26 +01:00
Fixed bug when pairing
This commit is contained in:
parent
2a6fa135e5
commit
d445689813
4 changed files with 6 additions and 6 deletions
12
BTD.cpp
Normal file → Executable file
12
BTD.cpp
Normal file → Executable file
|
@ -869,12 +869,12 @@ void BTD::hci_pin_code_request_reply() {
|
|||
hcibuf[8] = disc_bdaddr[5];
|
||||
if(pairWithWii) {
|
||||
hcibuf[9] = 6; // Pin length is the length of the bt address
|
||||
hcibuf[10] = disc_bdaddr[5]; // The pin is the Wiimotes bt address backwards
|
||||
hcibuf[11] = disc_bdaddr[4];
|
||||
hcibuf[12] = disc_bdaddr[3];
|
||||
hcibuf[13] = disc_bdaddr[2];
|
||||
hcibuf[14] = disc_bdaddr[1];
|
||||
hcibuf[15] = disc_bdaddr[0];
|
||||
hcibuf[10] = disc_bdaddr[0]; // The pin is the Wiimotes bt address backwards
|
||||
hcibuf[11] = disc_bdaddr[1];
|
||||
hcibuf[12] = disc_bdaddr[2];
|
||||
hcibuf[13] = disc_bdaddr[3];
|
||||
hcibuf[14] = disc_bdaddr[4];
|
||||
hcibuf[15] = disc_bdaddr[5];
|
||||
for(uint8_t i = 16; i < 26; i++)
|
||||
hcibuf[i] = 0x00; // The rest should be 0
|
||||
} else {
|
||||
|
|
0
BTD.h
Normal file → Executable file
0
BTD.h
Normal file → Executable file
0
Wii.cpp
Normal file → Executable file
0
Wii.cpp
Normal file → Executable file
0
Wii.h
Normal file → Executable file
0
Wii.h
Normal file → Executable file
Loading…
Reference in a new issue