Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Wii remote as Lightgun
I followed the ideas of this post in German and managed to make the wii remote work in emulationstation and reatroarch, but I can not make the wii remote run as lightgun in games like Lethal Enforces, any ideas?

this is the suggested mapping:

# WiiMote
Wiimote.A      = BTN_A
Wiimote.B      = BTN_B
Wiimote.Dpad.X = ABS_X
Wiimote.Dpad.Y = ABS_Y
Wiimote.Minus  = BTN_SELECT
Wiimote.Plus   = BTN_START
Wiimote.Home   = BTN_MODE
Wiimote.1      = BTN_X
Wiimote.2      = BTN_Y
# Classic-Controller
Classic.Dpad.X   = ABS_X
Classic.Dpad.Y   = ABS_Y
Classic.LStick.X = ABS_RX
Classic.LStick.Y = ABS_RY
Classic.RStick.X = ABS_Z
Classic.RStick.Y = ABS_RZ
Classic.A        = BTN_A
Classic.B        = BTN_B
Classic.X        = BTN_X
Classic.Y        = BTN_Y
Classic.Minus    = BTN_SELECT
Classic.Plus     = BTN_START
Classic.Home     = BTN_MODE
Classic.L        = BTN_TL
Classic.R        = BTN_TR
Classic.ZL       = BTN_TL2
Classic.ZR       = BTN_TR2
# Nunchuk
Nunchuk.C            = BTN_C
Nunchuk.Z            = BTN_Z
Nunchuk.Stick.X      = ABS_TILT_X
Nunchuk.Stick.Y      = ABS_TILT_Y
# LEDs
Plugin.led.Led1 = 1
Bluetooth configuration and pairing
First check Kernel module hid-wiimote is loaded.

$ sudo modprobe hid-wiimote
$ lsmod | grep wii
Expected output:
hid_wiimote XXXX 0
To make the loading of this module permanent after boot:

$ sudo nano /etc/modules
Add current user to group "input" (from here):

$ sudo usermod -aG input $USER
Pair your Wiimote with your computer using blueman (Bluetooth device manager) and connect to HID:

$ sudo hcitool dev
hci0 00:19:0E:16:AF:22
$ sudo hcitool scan
Scanning ...
40:F4:07:C5:B7:BD Nintendo RVL-CNT-01-TR
$ blueman-manager
Press the red sync button on the back of the WiiMote, the 4 leds will blink. Then in the Bluetooth device manager:

"Search" button
Nintendo RVL-CNT-01-TR
Right click > Pair
Right click > Connect to HID
See image "blueman.png". Check it works:

$ sudo evtest
/dev/input/event15: Nintendo Wii Remote Accelerometer
/dev/input/event16: Nintendo Wii Remote IR
/dev/input/event17: Nintendo Wii Remote
/dev/input/event18: Nintendo Wii Remote Nunchuk
/dev/input/event19: Nintendo Wii Remote Motion Plus

If you are prompted for PIN input, it is because you pressed 1+2 instead of the red sync button. If it still asks for the PIN code with the red button, you can try "Installation > pair without PIN code".

xwiimote installation
xwiimote (version 2-3build1) is included in Ubuntu packages. Unfortunately, you need to compile the latest version from sources if you want the Nunchuk to be recognized. To do so:

$ sudo apt purge xwiimote libxwiimote2
$ sudo apt install libudev-dev libncurses-dev
$ git clone
$ cd xwiimote
$ sh
$ make
$ sudo make install
Then to use it:

$ xwiishow list
Listing connected Wii Remote devices:
Found device #1: /sys/devices/pci0000:00/0000:00:1d.0/usb5/5-2/5-2:1.0/bluetooth/hci0/hci0:12/0005:057E:0330.0002
End of device list

$ xwiishow 1
See image "xwiishow1.png"
You might need to resize the font of the terminal to see the extensions (Nunchuk for instance). For instance, size 10 is enough: see image "xwiishow2.png" You can also use xterm that has a small font:

$ xterm -e xwiishow 1
If you get the following error:

$ xwiishow
Xwiishow: error while loading shared library: cannot open shared object file: No such file or directory
Then your LD_LIBRARY_PATH environment variable must be incomplete:

$ export | grep LD_LIBRARY_PATH
It should contain "/usr/local/lib". Otherwise append at the end of the file and save:

$ nano ~/.bashrc
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
Then reload your environment variables:

$ source ~/.bashrc

Does anyone know how to install Kernel module hid-wiimote in retrorange?
kernel module is supposed to be there already

sudo modprobe hid-wiimote

Possibly Related Threads...
Thread Author Replies Views Last Post
  kodi android remote problem feel2death 0 528 05-01-2019, 03:40 PM
Last Post: feel2death
  Sunvell R69 remote control saroninux 1 1,428 09-28-2018, 05:17 PM
Last Post: alexkidd

Forum Jump:

Users browsing this thread: 1 Guest(s)