A compilation of concepts I want to remember...

Navigation
 » Home
 » About Me
 » Github

Autonomous Mobile Robot #3: Pairing with a PS3 Controller for teleop

22 Dec 2018 » amr, deeplearning, machinelearning

Series:

  1. Autonomous Mobile Robot #1: Data collection to a trained model
  2. Autonomous Mobile Robot #2: Inference as a ROS service
  3. Autonomous Mobile Robot #3: Pairing with a PS3 Controller for teleop
  4. Autonomous Mobile Robot #4: Using GCP Storage

I ran into issues trying to pair a PS3 dual shock controller with a Raspberry Pi to be used for training an autonomous mobile robot (e.g. Donkey) running on ROS. Note that I am using Ubuntu Mate as the OS as opposed to Raspbian, the de-facto OS for the Raspberry Pi.

First try the ROS recommended method.

If this does not work try the following:

Start with the PS3 controller disconnected. If you see the PS3 Controller listed as a device remove the device first using the remove command, otherwise you can skip that step.

$ surferta@surfertas: sudo bash
$ root@surfertas:~# bluetoothctl
$ [NEW] Controller B8:27:EB:05:90:2E surfertas [default]
$ [NEW] Device 28:A1:83:4B:3A:30 PLAYSTATION(R)3 Controller
$ [PLAYSTATION(R)3 Controller]# remove 28:A1:83:4B:3A:30
$ [bluetooth]# scan on

Connect PS3 controller to the Raspberry Pi.

$ [PLAYSTATION(R)3 Controller]# power on
$ [bluetooth]# devices

Disconnect the PS3 controller from the Raspberry Pi.

$ [bluetooth]# agent on
$ [bluetooth]# trust 28:A1:83:4B:3A:30

References

  1. https://wiki.debian.org/BluetoothUser