[HowTo] Moonlight-Embedded (former Limelight) using Luna Launcher

On to the next problem. How do i map my controller? If i go intro the luna settings and click custom input, i can select my bt controller (steelseries stratus xl) but the “Add Mapping” option is greyed out. Atm the dpad is “turned 90 degrees” so up is left, down is right, left is down and right is up. And i am pretty sure some other button are wrong too.

I tried to add/change the default moonlight mappings, but i dont seem to have acces to change or add anything there.

Advice?

common rule here on OSMC explained in the wiki to never use upgrade always

dist-upgrade

check the wiki for more info

Thanks, first time i read that part i skipped the command line instructions, opting to use the inbuilt gui option. But that did not work for this.
Any advice one changeing my controller setup? Im not afraid to try stuff and dig trough stuff, but cant seem to find out how todo this.

The ‘add mapping’ button is greyed out (inactive) if either of the following three conditions is met:

  • no device is selected (it says None (Disabled) as controller name)
  • the selected input is a keyboard or mouse
  • a mapping is already present (the path to the selected mapping or ‘Select Mapping’ should be visible underneath the controller in this case)

I suspect that your controller is recognised as a keyboard / mouse for some reason. Could you send me the output of cat /proc/bus/input/devices to help me see if this is indeed the case? Off the top of my head I can’t think of any other reason why that button may be inactive.

I’m not entirely sure if you’re able to override Luna’s behaviour by editing the config file, but you might as well try:
In the config file (~/.kodi/userdata/addon_data/script.luna/.storage/luna.conf or wherever your addon_data dir is located) there’s a section for each input device, e.g.:

mapping = /home/osmc/xbox-1.map
input = /dev/input/event2

If the ‘mapping’ line is missing just add it to your device. Should you be using multiple controllers the next section would be ‘Input 1’ obviously and the path to the mapping file needs to be present for every device.

Changing the luna.conf file worked, sort of, the controller worked more then before, but the buttons were still turned. And after stopping the stream it auto reset the file to what it was. So this is not a real solution.

returns this:

osmc@Pi-Jorith:~$ cat /proc/bus/input/devices
I: Bus=0000 Vendor=0000 Product=0000 Version=0000
N: Name=“lircd”
P: Phys=
S: Sysfs=/devices/virtual/input/input0
U: Uniq=
H: Handlers=sysrq kbd rfkill event0
B: PROP=0
B: EV=100003
B: KEY=1fff 7fe001f ffff000f 3ffffff ffffffff ffffffff 0 0 0 7fffff ffffff07 ffffffff ffffffff ffffffff ffefffff ffffffff fffffffe

I: Bus=0005 Vendor=0111 Product=1419 Version=0109
N: Name=“SteelSeries Stratus XL”
P: Phys=b8:27:eb:3b:51:28
S: Sysfs=/devices/platform/soc/3f201000.uart/tty/ttyAMA0/hci0/hci0:11/0005:0111:1419.0006/input/input7
U: Uniq=28:9a:4b:08:16:ac
H: Handlers=kbd leds mouse0 event1 js0
B: PROP=0
B: EV=2001f
B: KEY=ffff0000 1f0000 0 0 1000 40000800 0 0 0 0
B: REL=103
B: ABS=ffffff00 30627
B: MSC=10
B: LED=f

Yep, pretty much as I suspected. I’ll update the code responsible for keyboard / mouse detection and make it less ‘aggressive’ - guess it’s better if you’re able to add a mapping file to a keyboard in an edge case instead of not being able to do so on a gamepad.
Thanks for letting me know about this issue :slight_smile:

Edit: You can track the progress on this GitHub issue. Just keep in mind that I’m doing all of this in my spare time and while I try to get simple stuff like this done as quickly as possible, I can’t give you any ETAs :confused:

No problem, love the work.
Updated the post with info on the config file.

Well to be honest I’m not surprised that the file was reset after ending the stream. Luna is a little clepto and she doesn’t like it when others mess with her stuff :stuck_out_tongue:

About the ‘turned’ buttons: are you talking about the 90 degree rotation of the D-Pad or are the A / B / X / Y buttons mixed up?

the 90 degree stuff, on the dpad. rest seemed to work. But tbh havent tested all buttons further, A and B are 100 correct though.

EDIT: Yeah, the xbox map makes it work a bit, ingame it flips out. But that should be solved by mapping it correctly.

Hi, I’m new to Raspberry Pi and Linux, so bear with me if the solution is painfully obvious.

I followed the instructions and was able to install Moonlight and Luna on my Raspberry Pi. There were a few hiccups, but I finally got everything installed and and paired up with my host PC. Once paired I started Luna and it recognized my games. However, when I attempt to launch a game, it opens up on my host computer and not my tv (which is the display for my raspberry pi.) I tried searching for a solution, but haven’t come across one that has worked yet.

A user, Spamm00r had this issue about a year ago (here), I tried his solution of using the command “sudo modprobe snd-bcm2835” but that didn’t seem to work. (at least after entering that phrase into the command line, it didn’t seem to make any difference.)

I’d really appreciate any suggestions or tips, thanks!

Getting the following trying to configure xbox 360 wireless controller:

osmc@osmc:~$ sudo “echo uinput” | tee -a /etc/modules-load.d/modules.conf
tee: /etc/modules-load.d/modules.conf: Permission denied
sudo: echo uinput: command not found

you need to be root.

kinda basic so if your unsure google on how to and basics of linux :slight_smile:

Move sudo to after the pipe and before tee command

Hey thanks for the reply. Why would people know they have to be root for this? I know basic linux, so I’m asking more to learn. Not trying to be a dick. Thanks.

Now running the command at root and still not working:

root@osmc:~# sudo “echo uinput” | tee -a /etc/modules-load.d/modules.conf
sudo: echo uinput: command not found

Thanks, but still not working:

root@osmc:~# “echo uinput” | sudo tee -a /etc/modules-load.d/modules.conf
-su: echo uinput: command not found

sudo echo “uinput” | sudo tee -a /etc/modules-lo

You got the quotemarks wrong.

yepp thats my bad was half buzzed when i wrote that script :stuck_out_tongue:

OP script has been updated and corrected :smiley: and @lebleu29 its good to learn new stuff etc, so keep it up :slight_smile: just remember if something goes wrong a simple google can often solve your question rather then waiting for a person to answer unless you need your issue to be confirmed.

@mkub, @jorith you seem to have succeeded in installing everything on Vero? As you can maybe see in the post trail I tried the same steps but didn’t get so far :frowning: any chance that everything is still working foryou and we could create a how-to for Vero users? I’d certainly be glad to support you in any way and be the guinea pig to test all the commands on :wink:

tell me where you are stuck and i will try to remember my steps.