Raspberry Pi 2 Nvidia Game Stream with OSMC + LUNA

OSMC is a very extensiable media centre operating system for the raspberry pi. Getting nVidia Game stream up and running is now much easier with the LUNA package by wackerl91. Installation requires a few packages and a little bit of configuration.

1.0 Install Moonlight-embedded

For steps 1 and 2, logging into OSMC using ssh is recommended in order to run the following commands.

1.1: Add the repositiory with the moonlight-embedded package to your sources file, you’ll need your password for this:

sudo echo 'deb http://archive.itimmer.nl/raspbian/moonlight jessie main' | sudo tee --append /etc/apt/sources.list > /dev/null

1.2 Update and install the moonlight-embedded package

The following two commands update your package list now that we have added a new repository, and install the moonlight-embedded package

sudo apt update
sudo apt install moonlight-embedded

2.0 Create GamePad Map File

Due to a bug in the LUNA interface, generating map files for custom controllers isn’t always reliable yet. A work around for this is to create the ‘Map’ file directly using the moonlight-embedded interface. You can skip this section if you are using a xbox 360 controller and follow the instructions here.

2.1 Create Map File

The following command creates a ‘GamePad.map’ file that contains the key button and axis mapping for your controller. You can use the same map file for multiple controllers of the same type.

moonlight map GamePad.map

Simply follow the instructions and press/move the button/joystick as required. A file called GamePad.map will be saved to ‘/home/osmc‘.

3.0 Download and Install LUNA

Download the latest luna release from LUNA Releases. At the time of writing the latest release is 0.6.3

3.1 Download .zip file

The easiest way to do this is use the following command.

wget https://github.com/wackerl91/luna/releases/download/v0.6.3-alpha/script.luna-0.6.3-alpha.zip

Remeber to change the link address to the version you want to download.

3.2 Install LUNA through OSMC user interface

The following screenshots show how to install the LUNA.zip file through OSMC user interface.

3.2.1 Navigate to Programs


3.2.2 Select the Puzzle Piece

3.2.3 Navigate to the top directory using the ‘..’screenshot003

3.2.4 In the top directory, select ‘Install from zip file’screenshot004

3.2.5 If you downloaded the zip to your home folder, select ‘Home Folder’ nowscreenshot005

3.2.6 Select the downloaded zip filescreenshot006

3.2.7 Once it has installed, you will see the message belowscreenshot007

3.2.8 You can now find the LUNA application in the Programs screenscreenshot008

4.0 Setting up nVidia Game Stream on Host PC

The nVidia Geforce Experience (GFE) application will be used to both enable and pair your host PC to your OSMC device.

To enable nVidia Game Stream, the following options must be enabled in the settings window, see below:


 4.0 Pairing OSMC and LUNA to your nVidia Game Stream device

Once you’ve enabled Shield Game Stream in the nVidia Geforce Experience application, you can now pair LUNA to it. To do this you will need the IP address of the machine.

4.1 Open Add-on settingsscreenshot000

4.2 Select Host IPscreenshot001

4.3 Enter your Host IP, in my case my machine was

4.4 Select Pair host, you will be presented with a code to enter on your host PC(Ignore the error message at the top)screenshot003

4.5 Enter the Code on your host PC


4.6 You have now successfully paired your devices. Your OSMC should now start grabbing game data.screenshot004

5.0 Assign Controller Mapping LUNA

To assign a controller map file in LUNA, such as that created earlier using the moonlight-embedded map command earlier we use the LUNA Add-On settings dialog, shown below:


4 thoughts on “Raspberry Pi 2 Nvidia Game Stream with OSMC + LUNA

  1. Hi !
    I tried what you were writting. It worked but when I open Luna, add my gamer pc and click on it, it loads information from Online Sources and then does nothing else. I can’t even see the information loaded.

    1. I found it took along time to load the data on my system. Have you tried restarting OSMC and restarting LUNA to see if it has appeared?

  2. HI,
    so i installed LUNA as you said but whenever i click on the games section the top left says movies and nothing happens. ive tried rebooting osmc, and ive uninstalled and re installed luna and still no fix hope you can help out 🙂

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.