Homepage › Forums › RetroPie Project › Controller Configuration in RetroPie › Pairing bluetooth based controllers like ipega controllers
- This topic has 4 replies, 4 voices, and was last updated 9 years, 1 month ago by drakkan88.
-
AuthorPosts
-
08/14/2015 at 11:00 #103972AnonymousInactive
Hi,
After lots of researching and trying out things, I was able to pair a bluetooth controller over a bluetooth dongle with rasbian over the terminal.
My primary purpose with this post is to reach out to the retropie developers to share my solution in order to integrate it cleanly into retropie.
For all the users who struggled, and failed, and who are still struggling of finding a way to pair their bluetooth based gamepad over their bluetooth dongle. Can simply leave for me a message in this thread, I’ll try to post my solution as soon as I can.Looking forward for the feedback.
08/21/2015 at 10:53 #104389philocritusParticipantI was also able to pair my ipega controller to a bt dongle on my osmc system.
Problem is I can’t get it to work as gamepad on emulationstation(stuck on press any button to configure screen)
Since the ipega has a keyboard mode I can get it to work like that, but no thumbstick.
Did you get it to work as a gamepad?08/23/2015 at 01:26 #104491s0nikParticipantI’m trying to pair my g910 aka wamo pro. I can find its mac address and hcitool info gives me some details but when trying to pair I get a generic dsub error.
I’m on retropie 3.0 with bluez5Verstuurd vanaf mijn LG-D855 met Tapatalk
10/08/2015 at 21:08 #107472AnonymousInactiveHi,
sorry for keeping you waiting so long. I was very busy and didn’t have the opportunity to reply to you.
Here is my solution. Enjoy… :)Open your terminal and enter the following command:
$ sudo hcitool dev
The last command will display the output for your device such as:
Devices:
hci0 00:00:00:00:00:00Install a new package to allow you to connect bluetooth via the command line.
$ sudo apt-get install bluez-compat
Once this has completed, you will now have hidd program installed. At this point, turn on your controller in gamepad mode and enter the following command. It will output the MAC Address of your keyboard, which you will need to copy and paste into the subsequent command, as seen below:
$ hcitool scan
Scanning …
AA:BB:CC:DD:EE:FF Bluetooth Device Name
$ sudo hidd –connect AA:BB:CC:DD:EE:FFNow we have to create a startup file to auto connect the device when the pc starts. Via the terminal…
$ gedit ~/.keyboard.sh
Enter the following text, substituting AA:BB:CC:DD:EE:FF with the hardware ID you saw above. Finally, save the file.
#! /bin/bash
address=”AA:BB:CC:DD:EE:FF”
while (sleep 1)
do
connected=sudo hidd --show
> /dev/null
if [[ ! $connected =~ .*${address}.* ]] ; then
sudo hidd –connect ${address} > /dev/null 2>&1
fi
doneNow create a new startup file. Substitute “keyboard” for whatever device name you choose. This is simply the name of the file.
$ sudo gedit /etc/init.d/keyboard
Paste the following, which tells your Ubuntu to run the file you just created at startup.
#!/bin/sh
/home/ubuntu/.keyboard.sh &exit 0
Now set both files permissions to executable via the terminal.
$ sudo chmod +x /etc/init.d/keyboard
$ chmod +x ~/.keyboard.sh
$ sudo update-rc.d keyboard defaultsRestart your computer and your device should auto connect and be working without you having to do anything.
I hope this helps a few people, it took me a long time to find a solution to my problem and I wanted to cement this tutorial a little deeper into the web.
This is my source: https://askubuntu.com/questions/17504/how-can-i-have-a-bluetooth-keyboard-auto-connect-at-startup
Please note that this is a quick and dirty way of doing this, and that the link is old and so are the commands. You till receive a warning when doing “sudo update-rc.d keyboard defaults” telling you that this method is deprecated. A google search would tell you straight away what to do.
10/20/2015 at 03:50 #108092drakkan88ParticipantDude, you just saved my life! I have been fighting for months trying to get an ASUS Gamepad to connect…OpenELECT and Linux Mint could find/pair/use the BT dongle and gamepad just fine. I was getting input/output errors and security warnings non-stop but your hidd –connect command worked flawlessly… little advise for dev, add this routine to the new Bluetooth option in V3.1!!!!
-
AuthorPosts
- The forum ‘Controller Configuration in RetroPie’ is closed to new topics and replies.