Page 1 of 1

BT Pairing Pro Controller Failed

Posted: Fri Nov 08, 2024 10:02 am
by Philippe69

Hello everybody,

My Mister works perfectly and I still have paired BT Joystick. But I recently bought a chinese new one without brand but named "Wireless Pro game controller".
I have modified the btctl script to try to obtain error explanation but I obtain nothing that help.

I tried

Code: Select all

hcitool dev

to verify my BT Dongle : all is OK

I tried

Code: Select all

hcitool scan

to verify my jystick : all seems OK

And the pair failed.

Code: Select all

/root# hcitool dev
Devices:
	hci0	00:E0:4C:6A:F8:03
/root# hcitool scan
Scanning ...
	A0:5A:5E:65:12:F2	Pro Controller
	1E:E0:15:B8:87:78	S1WP_SPP
/root# btctl pair
NAME: Pro Controller
MAC:  A0:5A:5E:65:12:F2

Removing existing pair...
Searching...
Pairing...
Trusting...
Connecting...
Failed.
/root#

Would you have an idea ?
Regards


Re: BT Pairing Pro Controller Failed

Posted: Fri Nov 08, 2024 2:03 pm
by egrath

Hi,

open a console connection and type:

Code: Select all

bluetoothctl

then, in there:

Code: Select all

agent on
scan

Now you get a list of devices which are currently pairable. Select the MAC address of the controller in question and type:

Code: Select all

pair AA:BB:CC:DD:EE:FF
connect AA:BB:CC:DD:EE:FF
trust AA:BB:CC:DD:EE:FF

Obviously, replace "AA:BB:CC:DD:EE:FF" with the actual MAC address. This way I pair all the stuff on my MiSTer. Additional note: For some reasons, some controllers disconnect after a short amount of time when they are not used (especially cheaper ones) - if you want to precent this, add the following to your u-boot.txt:

Code: Select all

usbcore.autosuspend=-1

With kind regards,
egrath


Re: BT Pairing Pro Controller Failed

Posted: Fri Nov 08, 2024 2:12 pm
by FPGA64

why muck around with the console just follow

https://mister-devel.github.io/MkDocs_M ... r-unstable


Re: BT Pairing Pro Controller Failed

Posted: Fri Nov 08, 2024 2:59 pm
by egrath
FPGA64 wrote: Fri Nov 08, 2024 2:12 pm

why muck around with the console just follow

https://mister-devel.github.io/MkDocs_M ... r-unstable

Because you learn something along the way :)


Re: BT Pairing Pro Controller Failed

Posted: Fri Nov 08, 2024 3:38 pm
by Philippe69

Code: Select all

[bluetooth]# agent on
Agent is already registered
[DEL] Device 52:D3:42:E0:8D:12 52-D3-42-E0-8D-12
[DEL] Device 60:3B:E7:37:FE:06 60-3B-E7-37-FE-06
[DEL] Device 6D:6A:87:99:9B:EF 6D-6A-87-99-9B-EF
[DEL] Device 4B:90:36:04:53:3F 4B-90-36-04-53-3F

[bluetooth]# scan on
Discovery started
[CHG] Controller 00:E0:4C:6A:F8:03 Discovering: yes
[NEW] Device 6D:6A:87:99:9B:EF 6D-6A-87-99-9B-EF
[NEW] Device 4B:90:36:04:53:3F 4B-90-36-04-53-3F
[NEW] Device 60:3B:E7:37:FE:06 60-3B-E7-37-FE-06
[NEW] Device 52:D3:42:E0:8D:12 52-D3-42-E0-8D-12
[CHG] Device A0:5A:5E:65:12:F2 LegacyPairing: no
[CHG] Device A0:5A:5E:65:12:F2 RSSI: -48
[NEW] Device 1E:E0:15:B8:87:78 S1WP_SPP

[bluetooth]# pair A0:5A:5E:65:12:F2
Attempting to pair with A0:5A:5E:65:12:F2
Failed to pair: org.bluez.Error.AlreadyExists
[CHG] Device A0:5A:5E:65:12:F2 LegacyPairing: yes
[CHG] Device A0:5A:5E:65:12:F2 LegacyPairing: no

[bluetooth]# connect A0:5A:5E:65:12:F2
Attempting to connect to A0:5A:5E:65:12:F2
[CHG] Device A0:5A:5E:65:12:F2 Connected: yes
[CHG] Device A0:5A:5E:65:12:F2 ServicesResolved: yes
Failed to connect: org.bluez.Error.NotAvailable
[CHG] Device A0:5A:5E:65:12:F2 ServicesResolved: no
[CHG] Device A0:5A:5E:65:12:F2 Connected: no
[bluetooth]# quit
/root#

I get Failed to connect: org.bluez.Error.NotAvailable error


Re: BT Pairing Pro Controller Failed

Posted: Sat Nov 09, 2024 7:18 am
by egrath

You can try to remove all the files in "/var/lib/bluetooth" (but not the directory itself!) to start completely from scratch without any former bluetooth configuration/settings. Maybe something has gone completely lost inside there (like BT keys that don't match up anymore, things like this).

To do so, you have to first stop the blutooth daemon:

Code: Select all

killall bluetoothd

And then remove the files. I would recommend to do this remote with a SFTP browser because I don't want to give commands which may render your system unusable in case of a typo along the way.

Reboot your system after you purged the files.


Re: BT Pairing Pro Controller Failed

Posted: Sat Nov 09, 2024 8:51 am
by FPGA64

And again I would not mess with the console but use the documented way.


Re: BT Pairing Pro Controller Failed

Posted: Mon Nov 11, 2024 3:12 pm
by Philippe69

@egrath : thank's for help.
I killed bluetooth daemon and deleted /var/lib/bluetooth/* : it has changed nothing.

I'm familiar with unix and the command line over ssh. Don't hesitate to use the command lines.
On the other hand, I have backups of my SD card.

Thank's a lot
Philippe69


Re: BT Pairing Pro Controller Failed

Posted: Thu Nov 21, 2024 11:16 am
by Philippe69

Hello everyone,
I bought a new joystick (a different model).
I created a new SD card and flashed the mr-fusion.img file to it.
However, I'm getting the same result.

Code: Select all

/root# btctl pair
NAME: Pro Controller
MAC:  A0:5A:5E:1B:43:22

Removing existing pair...
Searching...
Pairing...
Trusting...
Connecting...
Failed!

Re: BT Pairing Pro Controller Failed

Posted: Thu Nov 21, 2024 4:32 pm
by FPGA64

Again what happens using the official method rather than the command line


Re: BT Pairing Pro Controller Failed

Posted: Fri Nov 22, 2024 7:33 am
by Philippe69

For those who might have the same problem,
I found the problem.
Although the 2 joysticks are aesthetically identical, their coupling mode is different:
1st/ long press on the home key
2nd/press 3s on the home and A keys
now it works :D