Wiimote Still Not Connecting after Following Steps
-
Pi Model: Raspberry Pi 3 - Model B
Power Supply: CanaKit 5V 2.5A Raspberry Pi 3 Power Supply / Adapter / Charger
RetroPie Version: 4.1
Built From: Pre made SD image. (Boots on Micro SD, filesystem is on Flash Drive)
USB Devices: Keyboard, Flash Drive with filesystem on itAfter following the steps on this guide here I still can't seem to get single Wiimote I configured to connect. Bluetooth sees it but it won't connect after setting up all the scripts and rules.
Steps and information about the steps I took.
-
The RetroPie image is fresh from today. I did sudo ./retropie_setup.sh but for some reason it didn't ask me anything related to choose Binary-based installation.
-
wminput has been installed
-
nano /etc/udev/rules.d/wiimote.rules
KERNEL=="uinput", MODE="0666"
-
nano /home/pi/mywminput
Classic-Controller
Classic.Dpad.X = ABS_X
Classic.Dpad.Y = ABS_Y
Classic.LStick.X = ABS_HAT0X
Classic.LStick.Y = ABS_HAT0Y
Classic.RStick.X = ABS_HAT1X
Classic.RStick.Y = ABS_HAT1Y
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_TR2WiiMote
Wiimote.A = BTN_A
Wiimote.B = BTN_B
Wiimote.Dpad.X = ABS_Y
Wiimote.Dpad.Y = -ABS_X
Wiimote.Minus = BTN_SELECT
Wiimote.Plus = BTN_START
Wiimote.Home = BTN_MODE
Wiimote.1 = BTN_X
Wiimote.2 = BTN_YNunchuk
Nunchuk.C = BTN_C
Nunchuk.Z = BTN_ZPlugin.led.Led1 = 1
-
hcitool scan resulted in "00:1C:BE:F2:D8:64 Nintendo RVL-CNT-01"
-
nano /home/pi/bin/attachwii.sh
#!/bin/bash
sleep 1 # Wait until Bluetooth services are fully initialized
hcitool dev | grep hci >/dev/null
if test $? -eq 0 ; then
wminput -d -c /home/pi/mywminput 00:1C:BE:F2:D8:64 &
else
echo "Blue-tooth adapter not present!"
exit 1
fi -
I've executed chmod 775 /home/pi/bin/attachwii.sh and even added a sudo in front to see if that helps.
I've rebooted multiple times after all this and the wiimote still refuses to connect when ES is running after holding down 1+2 or the red sync button.
-
-
So I've figured out something.
if you run /home/pi/bin/attachwii.sh from the terminal the Wiimote can connect. So for some reason the executable isn't starting up like it should.
Does anyone have any insight onto why /home/pi/bin/attachwii.sh isn't running on startup?
-
I think I've finally solved this. I have no issues currently but I'm worried some might pop up. Anyways, here's what I did.
The RetroPie 3.x section in Register Wiimotes Before Emulationstation Starts actually has an unwritten counterpart for what to do in RetroPie 4.1 (4.x maybe?).
- Edit /etc/profile.d/10-retropie.sh.
- Follow the instructions for 3.x except put the line before if [ "
tty
" = "/dev/tty1" ]; then
The result should be this:
rebootWithoutWiimotes=0 /home/pi/bin/attachwii.sh if [ "`tty`" = "/dev/tty1" ]; then bash "/opt/retropie/configs/all/autostart.sh" fi
- Follow the instructions for My SSH terminal is unusable and giving me socket control errors! in the Known Issues section.
- This will make sure the terminal isn't flooded and fixes a problem where at least I couldn't access the RetroPie through SSH or SFTP.
The wminput lines in /home/pi/bin/attachwii.sh should now look like this:
wminput -d -q -c /home/pi/mywminput XX:XX:XX:XX:XX:XX > /dev/null 2>&1 &
After doing all that, order has been restored and the Wiimote pairs perfectly! I hope this helps anyone whose come across this. I'm not the best at writing wordy guide instructions so I'd recommend someone update the wiimote guide to have information for 4.1 (4.x maybe?).
-
@trigger_death it's a wiki. Anyone can add to it. Feel free.
-
Alright it's updated now. I'm going to assume the file has been changed from 10-emulationstation.sh to 10-retropie.sh starting in 4.0. I'm not entirely sure how to go about confirming that though.
-
@trigger_death looks like it's there in the code:
I'm not super familiar with the auto start scripts and I don't have a Wii mote to test but if you have it running then great!
Thanks for updating the docs so that others can benefit from it
-
Yup no problem. I also feel like the guide should be more specific in stating the SSH and terminal spam problem, other than in the issues section that may not be noticed. I'm just not sure what section to state it in.
Contributions to the project are always appreciated, so if you would like to support us with a donation you can do so here.
Hosting provided by Mythic-Beasts. See the Hosting Information page for more information.