source: flair-bin/trunk/tools/scripts/dualshock3.sh@ 68

Last change on this file since 68 was 66, checked in by Sanahuja Guillaume, 7 years ago

prevent ds3 from acting like a mouse

  • Property svn:executable set to *
File size: 709 bytes
Line 
1#! /bin/bash
2ARCH_DIR=$(uname -m)
3
4#on kernel >=4.13, ds3 is seen as a mouse
5/usr/bin/xinput set-prop 'Sony PLAYSTATION(R)3 Controller' 'Device Enabled' 0
6
7#This script is the only one that calls itself with sudo.
8#As a consequence, only one exception is needed in sudoers (the following 2 lines)
9# Defaults!/opt/flair/flair-bin/tools/scripts/dualshock3.sh setenv
10# uav ALL=(root) /opt/flair/flair-bin/tools/scripts/dualshock3.sh
11
12#we must run as root
13if [ $EUID -ne 0 ]; then
14 exec sudo -E $0 $*
15fi
16
17. ${FLAIR_ROOT}/flair-bin/tools/scripts/ubuntu_cgroup_hack.sh
18
19export LD_LIBRARY_PATH="${OECORE_HOST_SYSROOT}/usr/lib:${OECORE_HOST_SYSROOT}/lib"
20${FLAIR_ROOT}/flair-bin/tools/$ARCH_DIR/unix/dualshock3 $*
Note: See TracBrowser for help on using the repository browser.