Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
bluetooth_controllers_-_manual_setup [2022/08/02 08:49] – it's not permanent ataribluetooth_controllers_-_manual_setup [2023/01/11 07:19] (current) – [Pair Bluetooth Controllers - manual setup] no more blank spaces atari
Line 1: Line 1:
 ====== Pair Bluetooth Controllers - manual setup ====== ====== Pair Bluetooth Controllers - manual setup ======
  
-First ensure that Bluetooth is enabled on your device. The line ''controllers.bluetooth.enabled=1'' should be present in your ''batocera.conf'' and not commented out. If it is missing, add it in. Note that doing this won't suddenly make a non-functional Bluetooth dongle start working, only the ones that are already compatible with the Linux kernel and the drivers included in Batocera.+First ensure that Bluetooth is enabled on your device. First, the line ''controllers.bluetooth.enabled=1'' should be present in your ''system/batocera.conf'' file and not commented out ([[:batocera_conf_syntax|how to access the batocera.conf file]]). If it is missing, add it in. Note that doing this won't suddenly make a non-functional Bluetooth dongle start working, only the ones that are already compatible with the Linux kernel and the drivers included in Batocera.
  
 Establish an [[:access_the_batocera_via_ssh|SSH connection]] (or open up Xterm) to start the manual connection process. Get started by typing ''bluetoothctl'' and hitting ''[Enter]''. Establish an [[:access_the_batocera_via_ssh|SSH connection]] (or open up Xterm) to start the manual connection process. Get started by typing ''bluetoothctl'' and hitting ''[Enter]''.
Line 7: Line 7:
 Now you are in the Bluetooth control unit. Type following commands and confirm every single one with ''[Enter]'' Now you are in the Bluetooth control unit. Type following commands and confirm every single one with ''[Enter]''
  
-    agent on +<code> 
-    default-agent +agent on 
-    power on +default-agent 
-    scan on+power on 
 +scan on 
 +</code>
  
 Now set the controller in pairing mode! This strongly depends from your [[:supported_controllers|controller type]]. Now set the controller in pairing mode! This strongly depends from your [[:supported_controllers|controller type]].
Line 85: Line 87:
 Some devices out there break Bluetooth protocol and are always in "pairing" mode, common with modern "smart" TVs. Since Batocera will automatically connect to any device in pair mode, this could cause unintended connections. Some devices out there break Bluetooth protocol and are always in "pairing" mode, common with modern "smart" TVs. Since Batocera will automatically connect to any device in pair mode, this could cause unintended connections.
  
-Enter the Bluetooth ctl: +To work around this, it is possible to pair to only strictly padsPut your controller into its pairing mode and then run the following:
- +
-<code bash> +
-bluetoothctl +
-</code> +
- +
-then turn on scanning: +
- +
-<code bash> +
-scan on +
-</code> +
- +
-Wait for your malfunctional device to appear (and perhaps even attempt to pair)Then run the following+
- +
-<code bash> +
-block <MAC> +
-</code> +
- +
-where ''<MAC>'' is the MAC address of your device. For example:+
  
 <code> <code>
-block 69:4B:CC:8A:A5:5B+batocera-bluetooth trust-pad
 </code> </code>
  
-<WRAP center round important> +Batocera will explicitly only search for and connect to Bluetooth controllers. This may take a while as it methodically goes throughparses and accepts/rejects devices in the background. Once the pad is found, Batocera will attempt to pair to it:
-Write down the MAC address somewhereyou'll need to know this if you ever want to unblock the device in the future! +
-</WRAP> +
- +
-If successfulthen Batocera will no longer attempt to connect to that device. This setting however will be lost upon reboot, to keep it permanent run the overlay:+
  
 <code> <code>
-batocera-save-overlay+[root@RPI3-BATOCERA /userdata/system]# batocera-bluetooth trust-pad 
 +Pairing 8BitDo M30 gamepad... 
 +Trusting 8BitDo M30 gamepad... 
 +[root@RPI3-BATOCERA /userdata/system]#
 </code> </code>
  
-You can check if the device had unintentionally paired by running the following:+The Bluetooth controller can now be used with Batocera.
  
-<code bash> +Conversely, the same can be done to connect strictly to audio devices:
-paired-devices +
-</code> +
- +
-and if it hasremove it: +
- +
-<code bash> +
-remove <MAC> +
-</code> +
- +
-If you change your mind in the future and wish to unblock it, simply run:+
  
 <code> <code>
-unblock <MAC>+batocera-bluetooth trust-audio
 </code> </code>
- 
---> Using the live_devices function (currently broken) # 
- 
-This can be avoided by utilizing the ''live_devices'' function. 
- 
-<WRAP center round todo> 
-Demonstration needed! 
-</WRAP> 
- 
-Run: 
- 
-<code> 
-batocera-bluetooth live_devices 
-</code> 
- 
-Note down which device you want to connect to. Then: 
- 
-<code> 
-batocera-bluetooth trust [MAC address] 
-</code> 
- 
-<-- 
  
 --> Blacklisting a device in Batocera v33 # --> Blacklisting a device in Batocera v33 #
  
 <WRAP center round important> <WRAP center round important>
-The functionality of this has been supplanted by ''live_devices'' described above. These instructions are retained here specifically for Batocera **v33** and no other version. +The functionality of this has been supplanted by ''trust-pad'' method described above. These instructions are retained here specifically for Batocera **v33** and no other version.
-</WRAP> +
- +
-<WRAP center round todo> +
-Demonstration needed!+
 </WRAP> </WRAP>
  
Line 203: Line 150:
 <code> <code>
 batocera-bluetooth list                          Print the list of currently trusted and saved Bluetooth devices. batocera-bluetooth list                          Print the list of currently trusted and saved Bluetooth devices.
-batocera-bluetooth list_blacklistable            Print the list of currently blacklisted Bluetooth devices. +batocera-bluetooth trust                         Scan for and trust a new, randomly(?) selected device. Good luck! 
-batocera-bluetooth trust                         Trust a new, randomly(?) selected device. Good luck!+batocera-bluetooth trust-pad                     Scan for and trust only controllers. 
 +batocera-bluetooth trust-audio                   Scan for and trust only audio devices. 
 +batocera-bluetooth starttrust 
 +batocera-bluetooth stoptrust
 batocera-bluetooth remove <device address>       Removes (untrusts) specified Bluetooth device from the list and removes its connection from memory. batocera-bluetooth remove <device address>       Removes (untrusts) specified Bluetooth device from the list and removes its connection from memory.
 batocera-bluetooth save                          Saves the newly trusted device to memory. batocera-bluetooth save                          Saves the newly trusted device to memory.
Line 214: Line 164:
  
 <code> <code>
 +batocera-bluetooth list_blacklistable            Print the list of currently blacklisted Bluetooth devices.
 batocera-bluetooth blacklist <device address> <device name>  Adds a device to the blacklist, preventing it from being paired to. batocera-bluetooth blacklist <device address> <device name>  Adds a device to the blacklist, preventing it from being paired to.
 batocera-bluetooth unblacklist <device address>  Removes specified Bluetooth device from the blacklist. batocera-bluetooth unblacklist <device address>  Removes specified Bluetooth device from the blacklist.
  • bluetooth_controllers_-_manual_setup.1659422992.txt.gz
  • Last modified: 20 months ago
  • by atari