[HOWTO] From command line
Posted: Fri Mar 02, 2012 8:27 pm
I would *love* to get this working from my command line. Can you please help me and correct everything I am doing wrong please?
This tutorial is for SVN version of GIMX.
- my PS3 is turned off
- I connect my paired sixaxis controller to the USB port (it starts charging)
So AA:AA:AA:AA:AA:AA is the PS3 address and BB:BB:BB:BB:BB:BB is sixaxis addres. Now you can disconnect the controller, do not turn it on, keep it turned off! PS3 is also turned off. You will need to know controller number (LED that is shown on it - usually 1).
Now connect your BT dongle, if you have a notebook you need to turn on its bluetooth because if you turn it off most Linux distributions unloads modules from the kernel. I recommend to do "hciconfig" command and to write down your notebook BD address just in case you make a mistake and overwrite it (just like I did).
Plug your BT dongle and do hciconfig again:
So in my case the BT dongle address is XX:XX:XX:XX:XX:XX because the other address was there when BT was disconnected. As you can see its device id is "hci0" and number is 0. Quite unusual (I would expect it to be hci1 but this is my case).
Now write down your XX:XX:XX:XX:XX:XX address and do not lost it, you will need it to recover the dongle back after you finish using GIMX. Overwrite the address now:
Few remarks. hci0 is your device, BB is your sixaxis controller number. And you need to be root for that. Disconnect it, reconnect after that and check the "hciconfig" again to see if everything works.
If you run into problems when changing address you need to try different BT dongle, see FAQ and other posts here. I also recommend to include information about your BT dongle with the following command:
Now, when PS3 is still turned off, do this:
You found AA and BB addresses above, 0 is your device number (hci0 = 0, hci1 = 1 etc) and the last parameter is your controller number (0 for controller 1, 1 for 2 etc - the LED you determined above). Now even when PS3 is turned off (in standby mode), it should connect. If not, remove the BT dongle and try the controller you used to turn it on. If it does not work, you need to re-pair it and do everything again - make sure you turn it off when trying BT dongle. If controller works, turn it off and try again.
Now you are ready to prepare configuration using nice GIMX tools, I will use one from example directory which is great:
Please note emuclient loads configuration from ~/.emuclient/config directory on Linux, make sure you have it there. Small black window opens, you can try if it works - in this case PS button is mapped to right shift, arrows to ASDW and buttons to ERF.
You should be able to use PS3 using BT dongle. Unfortunately I am having terrible lag issues with Fedora.
This tutorial is for SVN version of GIMX.
- my PS3 is turned off
- I connect my paired sixaxis controller to the USB port (it starts charging)
Code: Select all
sixaddr
Current Bluetooth master: AA:AA:AA:AA:AA:AA
Current Bluetooth Device Address: BB:BB:BB:BB:BB:BB
Now connect your BT dongle, if you have a notebook you need to turn on its bluetooth because if you turn it off most Linux distributions unloads modules from the kernel. I recommend to do "hciconfig" command and to write down your notebook BD address just in case you make a mistake and overwrite it (just like I did).
Plug your BT dongle and do hciconfig again:
Code: Select all
hciconfig
hci0: Type: BR/EDR Bus: USB
BD Address: XX:XX:XX:XX:XX:XX ACL MTU: 310:10 SCO MTU: 64:8
UP RUNNING PSCAN
RX bytes:1127 acl:0 sco:0 events:37 errors:0
TX bytes:664 acl:0 sco:0 commands:32 errors:0
hci1: Type: BR/EDR Bus: USB
BD Address: YY:YY:YY:YY:YY:YY ACL MTU: 1021:8 SCO MTU: 64:1
UP RUNNING PSCAN ISCAN
RX bytes:1155 acl:0 sco:0 events:42 errors:0
TX bytes:918 acl:0 sco:0 commands:42 errors:0
Now write down your XX:XX:XX:XX:XX:XX address and do not lost it, you will need it to recover the dongle back after you finish using GIMX. Overwrite the address now:
Code: Select all
sudo ./bdaddr -i hci0 BB:BB:BB:BB:BB:BB
Manufacturer: Cambridge Silicon Radio (10)
Device address: XX:XX:XX:XX:XX:XX
New BD address: BB:BB:BB:BB:BB:BB
If you run into problems when changing address you need to try different BT dongle, see FAQ and other posts here. I also recommend to include information about your BT dongle with the following command:
Code: Select all
hciconfig hci0 revision
hci0: Type: BR/EDR Bus: USB
BD Address: BB:BB:BB:BB:BB:BB ACL MTU: 310:10 SCO MTU: 64:8
Unified 21e
Chip version: BlueCore4-ROM
Max key size: 128 bit
SCO mapping: HCI
Code: Select all
emu AA:AA:AA:AA:AA:AA 0 0
connecting with hci0 = BB:BB:BB:BB:BB:BB to AA:AA:AA:AA:AA:AA psm 17
connecting with hci0 = BB:BB:BB:BB:BB:BB to AA:AA:AA:AA:AA:AA psm 19
connected
Now you are ready to prepare configuration using nice GIMX tools, I will use one from example directory which is great:
Code: Select all
emuclient --status --force-updates --subpos --config BattlefieldBadCompany2.xml
You should be able to use PS3 using BT dongle. Unfortunately I am having terrible lag issues with Fedora.