Connect PS4 Controller to Raspberry Pi and Python

Published: 28 January 2020
on channel: Artur Spirin
34,159
412

Connect Playstation 4 DuelShock4 controller over Bluetooth to Raspberry Pi (or other Linux machine) and access its inputs from Python code.

SOFTWARE:
pyPS4Controller module is available on PyPi and GitHub
Pypi: https://pypi.org/project/pyPS4Control...
GitHub: https://github.com/ArturSpirin/pyPS4C...

HARDWARE:
PS4 DualShock 4 Controller: https://ebay.us/PnXchi

For Raspberry Pi you can use any one of the following:
Raspberry Pi 3 b: https://ebay.us/dfe2Nu
Raspberry Pi 3 b+: https://ebay.us/m7bc5q
Raspberry Pi 4 b: https://ebay.us/GLE3QE
All of those RPi models have built in Bluetooth.